From: Bdale Garbee Date: Mon, 19 Mar 2012 14:39:49 +0000 (+0100) Subject: Imported Upstream version 3.3.1 X-Git-Tag: upstream/3.3.1 X-Git-Url: https://git.gag.com/?p=debian%2Famanda;a=commitdiff_plain;h=refs%2Ftags%2Fupstream%2F3.3.1 Imported Upstream version 3.3.1 --- diff --git a/ChangeLog b/ChangeLog index 7a2efca..d7f5466 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,729 @@ +2012-02-21 Jean-Louis Martineau + * perl/make_html.pl: Add link at top, better list display. + * perl/Makefile.am: Execute make_html with a --homeurl argument. + +2012-02-21 Jean-Louis Martineau + * VERSION: 3.3.1 + * ReleaseNotes, NEWS: update for 3.3.1 + +2012-02-16 Jean-Louis Martineau + * server-src/amadmin.c (disklist_one): print the filename. + * server-src/diskfile.c: Add includefile directive. + * server-src/diskfile.h (disk_t): Add filename. + +2012-02-13 Jean-Louis Martineau + * man/xml-source/amanda.conf.5.xml: Fix default netusage. + +2012-02-13 Jean-Louis Martineau + * perl/Amanda/Recovery/Clerk.pm: Typo. + +2012-02-13 Jean-Louis Martineau + * perl/make_html.pl: generate correct absolute link. + +2012-02-10 Jean-Louis Martineau + * device-src/s3.c: Do not print the data to the debug file. + +2012-02-08 Jean-Louis Martineau + * application-src/ampgsql.pl: Do not use temporary disk space while + doing backup or recovery. + +2012-02-08 Jean-Louis Martineau + * perl/Amanda/DB/Catalog.pm: filenum must be sorted numerically. + +2012-02-07 Jean-Louis Martineau + * application-src/ampgsql.pl: pg_version 802000 => 80200. + +2012-02-01 Jean-Louis Martineau + * application-src/ampgsql.pl: Do not print normal + pg_xlogfile_name_offset output to MESG stream. + +2012-01-31 Dan Locks + * packaging/deb/preinst, packaging/rpm/amanda.spec.src: change /bin/sh + to /bin/bash. + +2012-01-27 Jean-Louis Martineau + * application-src/ampgsql.pl: Run pg_switch_xlog() and wait for the + archived WAl before doing an incremental backup. + +2012-01-23 Jean-Louis Martineau + * device-src/s3.c: Set xmlns for IIJ. + +2012-01-23 Jean-Louis Martineau + * device-src/s3-device.c: Fix for openstack swift api. + +2012-01-23 Jean-Louis Martineau + * perl/Amanda/Taper/Scribe.pm, server-src/amlabel.pl:use the + block_size instead of the header-block_size to write the BLOCK_SIZE + in the tapelist. + +2012-01-19 Jean-Louis Martineau + * device-src/s3-device.c: Add support for openstack swift api. + * device-src/s3.c: Add support for openstack swift api. + * device-src/s3.h: Add support for openstack swift api. + * man/xml-source/amanda-devices.7.xml: Add openstack-swift-api + property. + +2012-01-13 Jean-Louis Martineau + * device-src/s3-device.c: Fix deleting files. + +2012-01-09 Jean-Louis Martineau + * server-src/amtape.pl: Fix amtape show for non numeric slot. + +2012-01-04 Jean-Louis Martineau + * recover-src/extract_list.c: Fix for compilation on AIX. + +2012-01-04 Dan Locks + * packaging/sun-pkg/buildpkg: Add GLIB_* flags to sun packages + * config/amanda/libs.m4: fix "exit when explicit flags are given" + error, and require all flags when one is given. + +2012-01-03 Jean-Louis Martineau + * device-src/s3-device.c: Report DEVICE ERROR if s3_is_bucket_exists + response with curl error CURLE_COULDNT_CONNECT or + CURLE_COULDNT_RESOLVE_HOST. + +2012-01-02 Jean-Louis Martineau + * perl/Amanda/Changer/multi.pm: Print the state filename to the debug + file. + +2012-01-02 Jean-Louis Martineau + * perl/Amanda/ScanInventory.pm: Correctly set 'err'. + * server-src/amtape.pl: quit the changer even on error. + +2011-12-23 Jean-Louis Martineau + Patch by Nathan Stratton Treadway. + * common-src/conffile.c (read_int_or_str): Fix error message. + +2011-12-22 Jean-Louis Martineau + * server-src/planner.c: Fix force-bump with overdue filesystem. + +2011-12-22 Jean-Louis Martineau + * server-src/amlabel.pl: --asign require --meta or --barcode. + +2011-12-16 Jean-Louis Martineau + * application-src/amgtar.c: Fix GNUTAR-LISTDIR property. + +2011-12-14 Jean-Louis Martineau + * device-src/s3.c (s3_is_bucket_exists): Set max-keys=1. + +2011-12-14 Jean-Louis Martineau + * perl/Amanda/Recovery/Scan.pm (new): Return changer error. + +2011-12-12 Jean-Louis Martineau + * common-src/amfeatures.c: Add fe_dumptype_property. + * common-src/amfeatures.h: Add fe_dumptype_property. + * common-src/amxml.c: Parse dumptype properties. + * common-src/amxml.h (dle_t): Add property field. + * perl/Amanda/Disklist.swg: Add clean_dle_str_for_client. + * perl/Amanda/Feature.pod: Add fe_dumptype_property. + * perl/Amanda/Feature.swg: Add Amanda::Feature::Set::features + * server-src/amidxtaped.pl: Call clean_dle_str_for_client. + * server-src/diskfile.c (xml_dumptype_properties): New function to + return dumptype propertyes. + * server-src/diskfile.h (xml_dumptype_properties) Add prototype. + * server-src/driverio.c: Add xml_dumptype_properties to dumper cmd. + * server-src/dumper.c: Call clean_dle_str_for_client. + +2011-12-08 Jean-Louis Martineau + * example/template.d/amanda-harddisk.conf.in: fix for installcheck. + +2011-12-08 Jean-Louis Martineau + * NEWS, ReleaseNotes: Update for 3.3.1 + +2011-12-08 Jean-Louis Martineau + * server-src/amindex.c (getheaderfname): New function. + * server-src/amindex.h (getheaderfname): New prototype. + * server-src/dumper.c: Wrtie header to a file in indexdir. + +2011-12-07 Jean-Louis Martineau + * example/template.d/amanda-S3.conf.in, + example/template.d/amanda-harddisk.conf.in, + example/template.d/amanda-single-tape.conf.in, + example/template.d/amanda-tape-changer.conf.in: Use new changer api. + * server-src/amserverconfig.pl: Use new changer api. + +2011-12-07 Jean-Louis Martineau + * man/xml-source/amvault.8.xml: Improve. + +2011-12-07 Jean-Louis Martineau + * perl/Amanda/ScanInventory.pm (volume_is_labelable): New method. + * perl/Amanda/Taper/Scan/lexical.pm, perl/Amanda/Taper/Scan/oldest.pm: + Use volume_is_labelable from ScanInventory. + * perl/Amanda/Taper/Scan/traditional.pm: Fix bad logging. + * perl/Amanda/Taper/Scribe.pm: Print "autolabel disabled". + * perl/Amanda/Taper/Worker.pm: Add debugging. + * server-src/amvault.pl: Quit both changer, add debugging. + +2011-12-07 Jean-Louis Martineau + * server-src/amcleanup.pl, server-src/amcleanupdisk.pl: use + Amanda::Debug. + +2011-12-05 Jean-Louis Martineau + Fix for previous patch. + * application-src/amlog-script.pl, application-src/ampgsql.pl, + application-src/amraw.pl, application-src/amsamba.pl, + application-src/amsuntar.pl, application-src/amzfs-sendrecv.pl, + application-src/amzfs-snapshot.pl, + application-src/script-email.pl: Undo previous patch, + * perl/Amanda/Script_App.pm: Do it here instead. + server-src/amlogroll.pl, server-src/amvault.pl + server-src/taper.pl: Import the debug method. + * server-src/amoverview.pl, server-src/amserverconfig.pl, + server-src/amstatus.pl: Undo previous patch, they do not use the + debug file. + +2011-12-05 Jean-Louis Martineau + * application-src/amlog-script.pl, application-src/ampgsql.pl, + application-src/amraw.pl, application-src/amsamba.pl, + application-src/amsuntar.pl, application-src/amzfs-sendrecv.pl, + application-src/amzfs-snapshot.pl, application-src/script-email.pl, + client-src/amdump_client.pl, common-src/amgetconf.pl, + device-src/amdevcheck.pl, device-src/amtapetype.pl, + server-src/amcheckdump.pl, server-src/amcleanup.pl, + server-src/amcleanupdisk.pl, server-src/amdump.pl, + server-src/amfetchdump.pl, server-src/amlabel.pl, + server-src/amlogroll.pl, server-src/amoverview.pl, + server-src/amreport.pl, server-src/amrestore.pl, + server-src/amrmtape.pl, server-src/amserverconfig.pl, + server-src/amstatus.pl, server-src/amtape.pl, + server-src/amvault.pl, + server-src/taper.pl: Print command line arguments to debug file. + +2011-12-05 Jean-Louis Martineau + * device-src/device.c, device-src/ndmp-device.c, + device-src/tape-device.c: Call device_set_error if setting a + property fail. + * perl/Amanda/Changer.pm: Use device error message. + +2011-12-02 Jean-Louis Martineau + * device-src/s3-device.c, device-src/vfs-device.c (*_device_erase): + set the device state to unlabeled. + * perl/Amanda/Changer/compat.pm, perl/Amanda/Changer/multi.pm + (set_label): works with undefined label. + * perl/Amanda/Changer/robot.pm: small cleanup. + * server-src/amrmtape.pl: Call reservation set_label method to remove + the label from the state. + +2011-12-02 Jean-Louis Martineau + * man/xml-source/amanda.conf.5.xml (autolabel): Document it must match + labelstr. + +2011-12-01 Jean-Louis Martineau + * device-src/s3-device.c (delete_file): Use multiple threads. + +2011-11-30 Jean-Louis Martineau + * device-src/xfer-dest-taper-splitter.c: Set the xmsg even if the xfer + is cancelled. + * perl/Amanda/Taper/Scribe.pm: result is PARTIAL|FAILED if + !last_part_successful. + +2011-11-30 Jean-Louis Martineau + * device-src/xfer-source-recovery.c (pull_buffer_impl): Release lock + before calling wait_until_xfer_cancelled. + +2011-11-28 Jean-Louis Martineau + * server-src/amfetchdump.pl: Fix usage. + * man/xml-source/amfetchdump.8.xml: Fix synopsis. + +2011-11-25 Jean-Louis Martineau + * installcheck/gnutar.pl: Change expectations to an array that can be + scanned in order, fix for tar-1.25 on fc15. + +2011-11-22 Jean-Louis Martineau + * device-src/s3.c (build_url): curl is G_GNUC_UNUSED. + +2011-11-21 Jean-Louis Martineau + * server-src/amtape.pl: Fix 'amtape show' with one slot. + * installcheck/amtape.pl: Test it. + +2011-11-21 Jean-Louis Martineau + * server-src/amreport.pl: Check if executable before open3(). + * installcheck/amreport.pl: Fix for new message. + +2011-11-21 Jean-Louis Martineau + * perl/Amanda/Changer.pm: Correctly check barcode is not defined. + +2011-11-21 Jean-Louis Martineau + * perl/Amanda/Changer.pm: Correctly substititue '%' if not present. + +2011-11-21 Jean-Louis Martineau + * server-src/amtape.pl: Add [slots] argument to amtape show. + * man/xml-source/amtape.8.xml: Document it. + +2011-11-21 Jean-Louis Martineau + * device-src/s3.c: Disable the service_path if it is set to an empty + string or '/', also remove trailing slash. + +2011-11-21 Jean-Louis Martineau + * server-src/amdump.pl: Log a 'START planner date' line on error'. + +2011-11-14 Jean-Louis Martineau + * device-src/s3.c: Use curl_easy_escape. + +2011-11-14 Jean-Louis Martineau + * installcheck/gnutar.pl: Fix for fc16. + +2011-11-10 Jean-Louis Martineau + * installcheck/mock/mtx.pl: Fix qw. + +2011-11-10 Jean-Louis Martineau + * server-src/amstatus.pl: Use Getopt::Long + +2011-11-10 Jean-Louis Martineau + * device-src/s3.c: Use CURLOPT_MAX_RECV_SPEED_LARGE. + +2011-11-10 Jean-Louis Martineau + * perl/Amanda/Logfile.pod: Remove match_* functions + * perl/Amanda/Logfile.swg: Remove match_* functions + * perl/Amanda/Util.pod: Add match_* functions + * perl/Amanda/Util.swg: Add match_* functions + * client-src/amdump_client.pl, perl/Amanda/DB/Catalog.pm, + server-src/amdumpd.pl, server-src/amidxtaped.pl, + server-src/amvault.pl: Use match_* functions for Amanda::Util + +2011-11-10 Jean-Louis Martineau + * perl/Amanda/Report.pm: Always report the first 100 strange lines. + * installcheck/catalogs/longstrange.cat: Fix test. + + +2011-11-09 Jean-Louis Martineau + * server-src/amreport.pl: Fix for perl-5.14 + * installcheck/amreport.pl: Add test. + +2011-11-09 Jean-Louis Martineau + * installcheck/Installcheck/Changer.pm: Fix warnign for perl 5.14. + +2011-11-09 Jean-Louis Martineau + * application-src/ampgsql.pl: Print state filename to debug file. + +2011-11-07 Jean-Louis Martineau + * device-src/s3-device.c: Add S3_SERVER_SIDE_ENCRYPTION property. + * device-src/s3.c: Add server_side_encryption. + * device-src/s3.h: Add server_side_encryption. + * man/xml-source/amanda-devices.7.xml: Document + S3_SERVER_SIDE_ENCRYPTION property + +2011-11-07 Jean-Louis Martineau + * perl/Amanda/Changer.pm (release): Always call finished_cb. + * installcheck/amcheck-device.pl: Add a check. + +2011-10-12 Jean-Louis Martineau + * server-src/driverio.c (update_info_dumper): Set date to 0 if + datestamp is 0. + +2011-10-07 Jean-Louis Martineau + * application-src/ampgsql.pl: If datadir is not set, use the disk + argument. + +2011-10-07 Jean-Louis Martineau + * common-src/conffile.c: Do not free cwd. + * common-src/amgetconf.pl: Allow to get one property. + * installcheck/amgetconf.pl: Test it. + +2011-10-05 Jean-Louis Martineau + * common-src/match.c: Update from trunk. + +2011-10-05 Jean-Louis Martineau + * device-src/s3.c: Retry in case of CURLE_SSL_CONNECT_ERROR error. + +2011-10-05 Jean-Louis Martineau + * installcheck/gnutar.pl: Add support for fc14 and fc15. + +2011-10-04 Jean-Louis Martineau + * recover-src/extract_list.c: Do not crahs if amidxtaped close the + connection. + +2011-10-04 Jean-Louis Martineau + * device-src/s3.c: Correctly set thunk->next_marker. + +2011-09-30 Dan Locks + * packaging/common/substitute.pl: fix PKG_REV missing message. + * packaging/sun-pkg/buildpkg, packaging/deb/buildpkg, + packaging/rpm/buildpkg: create PKG_REV file until the machinery to + process svn tags for PKG_REV is in place + +2011-09-29 Dan Locks + * packaging/sun-pkg: sun package subdirectories + * packaging/sun-pkg/buildpkg: sun package building script + * packaging/common/mock_utils.sh: mocked utilities used by pre/post + scripts + * packaging/common/post_inst_functions.sh, + packaging/common/post_rm_functions.sh, + packaging/common/pre_inst_functions.sh, + packaging/common/common_functions.sh: shared shell functions for + pre/post scripts. + * packaging/common/substitute.pl: update to handle sun packages and + shell functions + * packaging/common/test_sh_libs.sh: unit tests for shell functions + * packaging/common/shunit2: unit test framework + * packaging/Makefile.am: add sun package to dist tarball. + * note: S3 device is not enabled; solaris compilation has me stumped. + +2011-09-21 Jean-Louis Martineau + * perl/Amanda/Holding.pm: fix dirfn. + +2011-09-21 Jean-Louis Martineau + Patch by Sam Stuck + * man/xml-source/amanda-changers.7.xml: Typo. + +2011-09-20 Jean-Louis Martineau + * man/Makefile.am (SERVER_MAN_PAGES): Add amcleanupdisk.8 + * man/xml-source/amcleanup.8.xml:Add -r option. + * man/xml-source/amcleanupdisk.8.xml: New man page. + * perl/Amanda/Holding.pm (all_files, merge_all_files, rename_tmp): + New methods. + * server-src/Makefile.am (amlibexec_PROGRAMS): Remove amcleanupdisk. + * server-src/Makefile.am (sbin_SCRIPTS_PERL): Add amcleanupdisk. + * server-src/amcleanup.pl: Add -r option. + * server-src/amcleanupdisk.c: Remove file + * server-src/amcleanupdisk.pl: New perl version. + * server-src/holding.c: Fix max level to 399. + +2011-09-07 Jean-Louis Martineau + * installcheck/Amanda_Device.pl: Check setting a property with an + invalid name. + +2011-09-07 Jean-Louis Martineau + * perl/Amanda/Device.swg: Do not g_value_unset an uninitialized value. + +2011-09-07 Jean-Louis Martineau + * application-src/amzfs-sendrecv.pl: restore works without --device. + +2011-09-06 Jean-Louis Martineau + * common-src/amcryptsimple.pl: Do not use gpg-agent if it is not + available. + +2011-09-02 Jean-Louis Martineau + * client-src/selfcheck.c (print_platform): Another fix. + +2011-09-02 Jean-Louis Martineau + * common-src/amcryptsimple.pl: Use gpg-agent. + +2011-09-02 Jean-Louis Martineau + * client-src/selfcheck.c (print_platform): Fix. + +2011-09-01 Jean-Louis Martineau + * server-src/amadmin.c (export) parse version without patch number. + +2011-09-01 Jean-Louis Martineau + * perl/Amanda/ScanInventory.pm: Get the meta label before + calling make_new_tape_label. + * perl/Amanda/Taper/Scan/traditional.pm: Get the meta label before + calling make_new_tape_label. + * perl/Amanda/Taper/Scribe.pm: Return the reservation on error. + * server-src/amcheck-device.pl: Release the reservation on error. + * server-src/amtape.pl: Release the reservation on error, + change 'amtape taper' output to be the same as amcheck. + * installcheck/amtape.pl: Fix for new amtape output. + +2011-08-31 Jean-Louis Martineau + * common-src/debug.c (debug_printf): Print a thread id. + * device-src/xfer-dest-taper-cacher.c, + device-src/xfer-dest-taper-directtcp.c, + device-src/xfer-dest-taper-splitter.c, + device-src/xfer-source-recovery.c: Remove printing of thread id. + +2011-08-31 Jean-Louis Martineau + * server-src/dumper.c: filter stderr make result strange, + filter exit_code != 0 make it fail. + +2011-08-31 Jean-Louis Martineau + * application-src/amgtar.c: Do not rename gnutar-list if record is not + set. + +2011-08-31 Jean-Louis Martineau + * server-src/tapefile.h (struct tape_s): Add blocksize. + * server-src/tapefile.c: Print and parse blocksize in tapelist file. + * perl/Amanda/Tapelist.swg: Print and parse blocksize in tapelist file. + * perl/Amanda/Taper/Scribe.pm: Add blocksize argument to add_tapelabel. + * server-src/amlabel.pl: Add blocksize argument to add_tapelabel. + * installcheck/Amanda_Tapelist.pl: Fix for tapelist file format. + * installcheck/amlabel.pl: Fix for tapelist file format. + +2011-08-31 Jean-Louis Martineau + * device-src/device.h (struct Device): Add header_block_size. + * device-src/null-device.c, device-src/rait-device.c, + device-src/s3-device.c, device-src/tape-device.c, + device-src/vfs-device.c: Set header_block_size. + * perl/Amanda/Device.swg: Swig header_block_size. + +2011-08-31 Jean-Louis Martineau + * installcheck/Amanda_Device.pl: Fix number of skipped test for S3. + +2011-08-31 Jean-Louis Martineau + * server-src/planner.c: Print why a disk is skip if DS_NOINC. + +2011-08-30 Jean-Louis Martineau + * installcheck/Amanda_Device.pl: Check invalid location on s3 device. + +2011-08-30 Jean-Louis Martineau + * device-src/s3.c (s3_is_bucket_exists): Do not retry if bucket do + not exists. + +2011-08-30 Jean-Louis Martineau + * device-src/s3.c (s3_is_bucket_exists): New function to check if a + bucket exists. + * device-src/s3.h (s3_is_bucket_exists): Prototype. + * device-src/s3-device.c: Call s3_is_bucket_exists before + s3_make_bucket. + +2011-08-29 Jean-Louis Martineau + * perl/Amanda/Changer/multi.pm: Keep the device_error in the state file. + * perl/Amanda/Changer/robot.pm: Keep the device_error in the state file. + * server-src/amtape.pl (inventory): Print inventory device error. + * installcheck/Amanda_Changer_multi.pl, + installcheck/Amanda_Changer_ndmp.pl, + installcheck/Amanda_Changer_robot.pl: Fix for device_error in + state file. + +2011-08-29 Jean-Louis Martineau + * perl/Amanda/Changer.pm: Fix warning. + +2011-08-29 Jean-Louis Martineau + * installcheck/Amanda_Changer_ndmp.pl, + installcheck/Amanda_Changer_robot.pl: Fix for previous patch. + +2011-08-29 Jean-Louis Martineau + * perl/Amanda/Changer/robot.pm: return a reservation even on error. + +2011-08-29 Jean-Louis Martineau + Patch by Gunar Gunnarsson + * server-src/amvault.pl: Cast $dump->{'kb'} to int. + +2011-08-24 Jean-Louis Martineau + * man/xml-source/amanda-devices.7.xml: Update S3 location url. + +2011-08-24 Jean-Louis Martineau + * common-src/match.c: Fix for 'Trailing backslash' error + * common-src/match-test.c: Add test + +2011-07-27 Jean-Louis Martineau + * amandad-src/amandad.c, client-src/calcsize.c, + client-src/killpgrp.c, client-src/noop.c, + client-src/rundump.c, client-src/runtar.c, + client-src/selfcheck.c, client-src/sendbackup.c, + client-src/sendsize.c, ndmp-src/amndmjob_main.c, + server-src/amcleanupdisk.c, server-src/amindexd.c, + server-src/amtrmidx.c, server-src/amtrmlog.c, + server-src/driver.c, server-src/dumper.c, + server-src/planner.c: Add a --version argument. + +2011-07-27 Jean-Louis Martineau + * common-src/amservice.c, recover-src/amrecover.c, + server-src/amflush.c: #include "getopt.h" + +2011-07-27 Jean-Louis Martineau + * application-src/ampgsql.pl: add ARCHIVEDIR, CLEANUPWAL, DB, + HOST, MAX-WAL-WAIT, PASSFILE, PORT, PSQL-PATH and USER + properties. + * man/xml-source/ampgsql.8.xml: Document them. + +2011-07-27 Jean-Louis Martineau + * common-src/amservice.c, recover-src/amrecover.c, + server-src/amcheck.c, server-src/amflush.c: Add a --version argument. + +2011-07-27 Jean-Louis Martineau + * client-src/selfcheck.c: Check return value of fgets. + +2011-07-27 Jean-Louis Martineau + * many */*.pl: add --version option. + +2011-07-27 Jean-Louis Martineau + * application-src/ampgsql.pl: print to debug file and server if unlink + fail. + +2011-07-25 Jean-Louis Martineau + * man/xml-source/amgtar.8.xml, man/xml-source/amraw.8.xml, + man/xml-source/amsamba.8.xml, man/xml-source/amstar.8.xml, + man/xml-source/amsuntar.8.xml, + man/xml-source/amzfs-sendrecv.8.xml: Document the diskdevice. + +2011-07-25 Jean-Louis Martineau + * client-src/client_util.c: fix + +2011-07-25 Jean-Louis Martineau + * server-src/amcheck.c: new '--client-verbose' option. + * man/xml-source/amcheck.8.xml: Document --client-verbos + * config/amanda/progs.m4 (AMANDA_PROG_UNAME): new macro to find uname + path. + * configure.in: call AMANDA_PROG_UNAME. + * client-src/client_util.c (check_access, check_file, check_dir, + check_suid): return a gboolean. + * client-src/client_util.h: Change prototypes. + * client-src/selfcheck.c: Print the platform. + * common-src/util.c (get_first_line): new function to return the first + output line of a command. + * common-src/util.h (get_first_line): add prototype. + * application-src/amgtar.c, application-src/ampgsql.pl, + application-src/amraw.pl, application-src/amsamba.pl, + application-src/amstar.c, application-src/amsuntar.pl, + application-src/amzfs-sendrecv.pl: print version of program. + +2011-07-22 Jean-Louis Martineau + * perl/Amanda/Changer.pm: Fix warning if $s is not used. + +2011-07-22 Jean-Louis Martineau + * perl/Amanda/Changer.pm: Support minimun number of digit in $3s + autolabel template. + * man/xml-source/amanda.conf.5.xml: Document it. + +2011-07-21 Jean-Louis Martineau + * perl/Amanda/Changer/multi.pm (do_release): Support eject params. + * perl/Amanda/Changer/single.pm (do_release): Do the eject correctly. + +2011-07-21 Jean-Louis Martineau + * man/xml-source/amanda-taperscan.7.xml: Typo. + +2011-07-20 Jean-Louis Martineau + * common-src/conffile.h: Add CONF_EJECT_VOLUME + * common-src/conffile.c: Add CNF_EJECT_VOLUME + * man/xml-source/amanda.conf.5.xml: Document eject-volume. + * perl/Amanda/Config.swg: Add CNF_EJECT_VOLUME. + * perl/Amanda/Changer/single.pm: Eject the device if the eject + params is set in $res->release() + * perl/Amanda/Taper/Scribe.pm (new): Get eject_volume params. + * perl/Amanda/Taper/Scribe.pm (_release_reservation): Call + $res->release with the eject params if needed. + * perl/Amanda/Taper/Worker.pm: Make the Scribe with the eject_volume + params set to $CNF_EJECT_VOLUME + +2011-07-20 Jean-Louis Martineau + * perl/Amanda/Changer.pm (make_error): callback is optional. + * perl/Amanda/Changer/disk.pm: Check if disk is mounted before locking. + * perl/Amanda/ScanInventory.pm (_scan): fail only on fatal error. + * perl/Amanda/Taper/Controller.pm: Put error message in double quote. + * perl/Amanda/Taper/Worker.pm: Put message in double quote. + +2011-07-19 Jean-Louis Martineau + * server-src/driver.c (tape_action): consider number of dle on volume + and max-dle-by-volume for allowing use of new volume. + +2011-07-15 Jean-Louis Martineau + * man/xml-source/amanda-changers.7.xml: Add chg-single documentation. + +2011-07-14 Jean-Louis Martineau + * device-src/s3-device.c:Increase S3_DEVICE_MAX_BLOCK_SIZE to 3GiB. + +2011-07-14 Jean-Louis Martineau + * device-src/s3-device.c:Increase S3_DEVICE_MAX_BLOCK_SIZE to 5TiB. + +2011-07-13 Jean-Louis Martineau + * common-src/conffile.c: Add CONF_MAX_DLE_BY_VOLUME. + * common-src/conffile.h: Add CNF_MAX_DLE_BY_VOLUME. + * man/xml-source/amanda.conf.5.xml: Document max-dle-by-volume. + * perl/Amanda/Config.swg: Add CNF_MAX_DLE_BY_VOLUME. + * perl/Amanda/Taper/Controller.pm: Add msg_CLOSE_VOLUME method. + * perl/Amanda/Taper/Protocol.pm: Add CLOSE_VOLUME. + * perl/Amanda/Taper/Scribe.pm: Add close_volume method, call + _get_new_volume() is close_volume was called. + * perl/Amanda/Taper/Worker.pm: Add CLOSE_VOLUME method. + * server-src/driver.c: Send CLOSE_VOLUME command to taper if the + number of dle on a volume is larger than max-dle-by-volume + * server-src/driverio.c: Send CLOSE_VOLUME command. + * server-src/driverio.h: Add nb_dle to taper_t. + * server-src/server_util.c: Add "CLOSE-VOLUME" to cmdstr. + * server-src/server_util.h: Add CLOSE_VOLUME. + +2011-07-12 Jean-Louis Martineau + * device-src/s3-device.c: Fix gcc warning for s3_rval set but not used + +2011-07-12 Jean-Louis Martineau + * config/amanda/libs.m4: Fix use of AC_LINK_IFELSE. + +2011-07-12 Jean-Louis Martineau + * common-src/match.c (match_word): better matching for anchored + expression. + * common-src/match-test.c: Add new tests. + +2011-07-11 Jean-Louis Martineau + Add '$s' substitution to autolabel. + * perl/Amanda/Changer.pm (make_new_tape_label): Handle $s. + * perl/Amanda/Taper/Scan/lexical.pm, perl/Amanda/Taper/Scan/oldest.pm, + perl/Amanda/Taper/Scribe.pm: Call make_new_tape_label with the slot. + * man/xml-source/amanda.conf.5.xml: Document $s substitution. + +2011-07-08 Jean-Louis Martineau + * config/amanda/libs.m4: Fix for newer aclocal. + * config/libtool.m4, config/ltmain.sh, + config/ltoptions.m4, config/ltsugar.m4, + config/ltversion.m4, + config/lt~obsolete.m4: Upgrade libtool to 2.4. + +2011-07-08 Jean-Louis Martineau + * Many *.c files: Fix for gcc-4.6.0 warning: variable ‘NAME’ set but + not used. + +2011-07-07 Jean-Louis Martineau + * perl/Amanda/Taper/Scribe.pm: Keep the barcode when relabeling a tape + +2011-07-05 Jean-Louis Martineau + * perl/Amanda/Changer/robot.pm: Retry up to 120 seconds if the sense + key is 'Not Ready' + +2011-06-29 Jean-Louis Martineau + * application-src/amstar.c: typo. + +2011-06-29 Jean-Louis Martineau + * server-src/driver.c: Call short_dump_state on all state change. + +2011-06-29 Jean-Louis Martineau + Patch by p_michalczyk + * application-src/amstar.c: Place command_options at the and of + command line. + +2011-06-29 Jean-Louis Martineau + Patch by p_michalczyk + * application-src/amstar.c: Add missing break statement. + +2011-06-29 Jean-Louis Martineau + Replace semaphore by amsemaphore. + * common-src/Makefile.am: Remove semaphore.*, add amsemaphore.* + * common-src/amsemaphore-test.c: New copy of semaphore-test.c + * common-src/amsemaphore.c: New copy of semaphore.c + * common-src/amsemaphore.h: New copy of semaphore.h + * common-src/semaphore-test.c: Removed file. + * common-src/semaphore.c: Removed file. + * common-src/semaphore.h: Removed file. + * device-src/rait-device.c: s/semaphore_/amsemaphore_/g + * xfer-src/element-glue.c: s/semaphore_/amsemaphore_/g + * xfer-src/element-glue.h: s/semaphore_/amsemaphore_/g + +2011-06-28 Jean-Louis Martineau + * server-src/driver.c: Check holding file is in a holding directory. + +2011-06-27 Jean-Louis Martineau + * man/xml-source/amanda-devices.7.xml: s/Witout/Without/ + +2011-06-21 Jean-Louis Martineau + * man/xml-source/amanda-client.conf.5.xml: Add amdump-server. + * man/xml-source/amdump_client.8.xml: Fix doc. + +2011-06-21 Jean-Louis Martineau + * perl/Amanda/Taper/Scribe.pm: Fix add_tapelabel call. + +2011-06-20 Jean-Louis Martineau + * perl/Amanda/Taper/Scribe.pm: Correcly make label with meta and barcode + +2011-06-20 Jean-Louis Martineau + * man/xml-source/amrecover.8.xml: Document new settranslate command. + * recover-src/amrecover.c: Add disk_tpath, + * recover-src/amrecover.c (translate_octal): New function. + * recover-src/amrecover.h: Add tpath to DIR_ITEM. + * recover-src/display_commands.c: Set and use tpath. + * recover-src/extract_list.c: Use tpath + * recover-src/help.c: Add settranslate command. + * recover-src/set_commands.c: Set and tpath. + * recover-src/uparse.y: Parse settranslate command. + * recover-src/uscan.l: Add SETTRANSLATE keyword. + +2011-06-17 Jean-Louis Martineau + * perl/Amanda/Changer/robot.pm, perl/Amanda/Recovery/Planner.pm, + perl/Amanda/Recovery/Clerk.pm, + perl/Amanda/Taper/Scribe.pm: Fix for qw syntax in perl 5.14. + +2011-06-13 Jean-Louis Martineau + * perl/Amanda/Taper/Worker.pm: s/messsage/message/. + 2011-05-31 Jean-Louis Martineau * VERSION: 3.3.0 diff --git a/FULL_VERSION b/FULL_VERSION index 15a2799..bea438e 100644 --- a/FULL_VERSION +++ b/FULL_VERSION @@ -1 +1 @@ -3.3.0 +3.3.1 diff --git a/Makefile.in b/Makefile.in index 1f9f408..8a973bc 100644 --- a/Makefile.in +++ b/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -413,6 +413,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -845,6 +846,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -894,6 +896,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -902,6 +905,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -909,6 +913,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1053,6 +1059,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1086,6 +1093,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1128,7 +1136,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -1312,7 +1319,7 @@ uninstall-pkgdataDATA: # (which will cause the Makefiles to be regenerated when you run `make'); # (2) otherwise, pass the desired values on the `make' command line. $(RECURSIVE_TARGETS): - @failcom='exit 1'; \ + @fail= failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ @@ -1337,7 +1344,7 @@ $(RECURSIVE_TARGETS): fi; test -z "$$fail" $(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ + @fail= failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ @@ -1504,7 +1511,8 @@ distdir: $(DISTFILES) top_distdir="$(top_distdir)" distdir="$(distdir)" \ dist-hook -test -n "$(am__skip_mode_fix)" \ - || find "$(distdir)" -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ + || find "$(distdir)" -type d ! -perm -755 \ + -exec chmod u+rwx,go+rx {} \; -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 $(install_sh) -c -m a+r {} {} \; \ @@ -1548,17 +1556,17 @@ dist dist-all: distdir distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ - bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ + bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.lzma*) \ - unlzma -c $(distdir).tar.lzma | $(am__untar) ;;\ + lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\ *.tar.xz*) \ xz -dc $(distdir).tar.xz | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ - GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ + GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac diff --git a/NEWS b/NEWS index cba8972..48f53ef 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,23 @@ +Changes in release 3.3.1 + + * amrecover + o New 'settransalte' command. + * amanda.conf + o new '$s' substitution in autolabel. + o new 'max-dle-by-volume' global option. + o new 'eject-volume' global option. + * diskfile + o new 'includefile' option. + * amcheck + o new '--client-verbose' argument. + * All programs have a new '--version' argument. + * ampgsql can take property from server configuration. + * amgetconf can print one property of a section. + * s3 device + o new S3_SERVER_SIDE_ENCRYPTION property. + o use multiple thread to speedup deleting a volume. + * Many bug fix. + Changes in release 3.3.0 * The default auth is changed to "bsdtcp", if you are using the default bsd diff --git a/ReleaseNotes b/ReleaseNotes index 916b0aa..d4f5e8c 100644 --- a/ReleaseNotes +++ b/ReleaseNotes @@ -1,3 +1,24 @@ + Release Notes for amanda-3.3.1 + +* amrecover + o New 'settransalte' command. +* amanda.conf + o new '$s' substitution in autolabel. + o new 'max-dle-by-volume' global option. + o new 'eject-volume' global option. +* diskfile + o new 'includefile' option +* amcheck + o new '--client-verbose' argument. +* All programs have a new '--version' argument. +* ampgsql can take property from server configuration. +* amgetconf can print one property of a section. +* s3 device + o new S3_SERVER_SIDE_ENCRYPTION property. + o use multiple thread to speedup deleting a volume. +* Many bug fix. + + Release Notes for amanda-3.3.0 * The default auth is changed to "bsdtcp", if you are using the default bsd diff --git a/VERSION b/VERSION index 15a2799..bea438e 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -3.3.0 +3.3.1 diff --git a/aclocal.m4 b/aclocal.m4 index 5e62a53..f5a2ff7 100644 --- a/aclocal.m4 +++ b/aclocal.m4 @@ -1,4 +1,4 @@ -# generated automatically by aclocal 1.11 -*- Autoconf -*- +# generated automatically by aclocal 1.11.1 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. @@ -13,8 +13,8 @@ m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl -m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.63],, -[m4_warning([this file was generated for autoconf 2.63. +m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],, +[m4_warning([this file was generated for autoconf 2.68. You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically `autoreconf'.])]) @@ -112,14 +112,14 @@ dnl int main () { - int major, minor, micro; + unsigned int major, minor, micro; char *tmp_version; - system ("touch conf.glibtest"); + fclose (fopen ("conf.glibtest", "w")); /* HP/UX 9 (%@#!) writes to sscanf strings */ tmp_version = g_strdup("$min_glib_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { + if (sscanf(tmp_version, "%u.%u.%u", &major, &minor, µ) != 3) { printf("%s, bad version string\n", "$min_glib_version"); exit(1); } @@ -158,9 +158,9 @@ main () } else { - printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n", + printf("\n*** An old version of GLIB (%u.%u.%u) was found.\n", glib_major_version, glib_minor_version, glib_micro_version); - printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n", + printf("*** You need a version of GLIB newer than %u.%u.%u. The latest version of\n", major, minor, micro); printf("*** GLIB is always available from ftp://ftp.gtk.org.\n"); printf("***\n"); @@ -231,6646 +231,8 @@ main () rm -f conf.glibtest ]) -# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- - -# serial 52 AC_PROG_LIBTOOL - - -# AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) -# ----------------------------------------------------------- -# If this macro is not defined by Autoconf, define it here. -m4_ifdef([AC_PROVIDE_IFELSE], - [], - [m4_define([AC_PROVIDE_IFELSE], - [m4_ifdef([AC_PROVIDE_$1], - [$2], [$3])])]) - - -# AC_PROG_LIBTOOL -# --------------- -AC_DEFUN([AC_PROG_LIBTOOL], -[AC_REQUIRE([_AC_PROG_LIBTOOL])dnl -dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX -dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. - AC_PROVIDE_IFELSE([AC_PROG_CXX], - [AC_LIBTOOL_CXX], - [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX - ])]) -dnl And a similar setup for Fortran 77 support - AC_PROVIDE_IFELSE([AC_PROG_F77], - [AC_LIBTOOL_F77], - [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 -])]) - -dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. -dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run -dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. - AC_PROVIDE_IFELSE([AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], - [AC_LIBTOOL_GCJ], - [ifdef([AC_PROG_GCJ], - [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([A][M_PROG_GCJ], - [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) - ifdef([LT_AC_PROG_GCJ], - [define([LT_AC_PROG_GCJ], - defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) -])])# AC_PROG_LIBTOOL - - -# _AC_PROG_LIBTOOL -# ---------------- -AC_DEFUN([_AC_PROG_LIBTOOL], -[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl -AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl -AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl -AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl - -# This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" - -# Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' -AC_SUBST(LIBTOOL)dnl - -# Prevent multiple expansion -define([AC_PROG_LIBTOOL], []) -])# _AC_PROG_LIBTOOL - - -# AC_LIBTOOL_SETUP -# ---------------- -AC_DEFUN([AC_LIBTOOL_SETUP], -[AC_PREREQ(2.50)dnl -AC_REQUIRE([AC_ENABLE_SHARED])dnl -AC_REQUIRE([AC_ENABLE_STATIC])dnl -AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_PROG_LD])dnl -AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl -AC_REQUIRE([AC_PROG_NM])dnl - -AC_REQUIRE([AC_PROG_LN_S])dnl -AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl -# Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! -AC_REQUIRE([AC_OBJEXT])dnl -AC_REQUIRE([AC_EXEEXT])dnl -dnl -AC_LIBTOOL_SYS_MAX_CMD_LEN -AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE -AC_LIBTOOL_OBJDIR - -AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -_LT_AC_PROG_ECHO_BACKSLASH - -case $host_os in -aix3*) - # AIX sometimes has problems with the GCC collect2 program. For some - # reason, if we set the COLLECT_NAMES environment variable, the problems - # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES - fi - ;; -esac - -# Sed substitution that helps us do robust quoting. It backslashifies -# metacharacters that are still active within double-quoted strings. -Xsed='sed -e 1s/^X//' -[sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] - -# Same as above, but do not quote variable references. -[double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] - -# Sed substitution to delay expansion of an escaped shell variable in a -# double_quote_subst'ed string. -delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' - -# Sed substitution to avoid accidental globbing in evaled expressions -no_glob_subst='s/\*/\\\*/g' - -# Constants: -rm="rm -f" - -# Global variables: -default_ofile=libtool -can_build_shared=yes - -# All known linkers require a `.a' archive for static linking (except MSVC, -# which needs '.lib'). -libext=a -ltmain="$ac_aux_dir/ltmain.sh" -ofile="$default_ofile" -with_gnu_ld="$lt_cv_prog_gnu_ld" - -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 "$LTCFLAGS" && LTCFLAGS=$CFLAGS -test -z "$DLLTOOL" && DLLTOOL=dlltool -test -z "$LD" && LD=ld -test -z "$LN_S" && LN_S="ln -s" -test -z "$MAGIC_CMD" && MAGIC_CMD=file -test -z "$NM" && NM=nm -test -z "$SED" && SED=sed -test -z "$OBJDUMP" && OBJDUMP=objdump -test -z "$RANLIB" && RANLIB=: -test -z "$STRIP" && STRIP=: -test -z "$ac_objext" && ac_objext=o - -# Determine commands to create old-style static archives. -old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' -old_postinstall_cmds='chmod 644 $oldlib' -old_postuninstall_cmds= - -if test -n "$RANLIB"; then - case $host_os in - openbsd*) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" - ;; - *) - old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" - ;; - esac - old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" -fi - -_LT_CC_BASENAME([$compiler]) - -# 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 - -_LT_REQUIRED_DARWIN_CHECKS - -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"} - -# If no C compiler flags were specified, use CFLAGS. -LTCFLAGS=${LTCFLAGS-"$CFLAGS"} - -# Allow CC to be a program name with arguments. -compiler=$CC -])# _LT_AC_SYS_COMPILER - - -# _LT_CC_BASENAME(CC) -# ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. -AC_DEFUN([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` -]) - - -# _LT_COMPILER_BOILERPLATE -# ------------------------ -# Check for compiler boilerplate output or warnings with -# the simple compiler test code. -AC_DEFUN([_LT_COMPILER_BOILERPLATE], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_compile_test_code" >conftest.$ac_ext -eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_compiler_boilerplate=`cat conftest.err` -$rm conftest* -])# _LT_COMPILER_BOILERPLATE - - -# _LT_LINKER_BOILERPLATE -# ---------------------- -# Check for linker boilerplate output or warnings with -# the simple link test code. -AC_DEFUN([_LT_LINKER_BOILERPLATE], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -ac_outfile=conftest.$ac_objext -echo "$lt_simple_link_test_code" >conftest.$ac_ext -eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err -_lt_linker_boilerplate=`cat conftest.err` -$rm -r conftest* -])# _LT_LINKER_BOILERPLATE - -# _LT_REQUIRED_DARWIN_CHECKS -# -------------------------- -# Check for some things on darwin -AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[ - case $host_os in - rhapsody* | darwin*) - AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) - AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) - - AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], - [lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then - # By default we will add the -single_module flag. You can override - # by either setting the environment variable LT_MULTI_MODULE - # non-empty at configure time, or by adding -multi_module to the - # link flags. - echo "int foo(void){return 1;}" > conftest.c - $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib ${wl}-single_module conftest.c - if test -f libconftest.dylib; then - lt_cv_apple_cc_single_mod=yes - rm -rf libconftest.dylib* - fi - rm conftest.c - fi]) - AC_CACHE_CHECK([for -exported_symbols_list linker flag], - [lt_cv_ld_exported_symbols_list], - [lt_cv_ld_exported_symbols_list=no - save_LDFLAGS=$LDFLAGS - echo "_main" > conftest.sym - LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" - AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], - [lt_cv_ld_exported_symbols_list=yes], - [lt_cv_ld_exported_symbols_list=no]) - LDFLAGS="$save_LDFLAGS" - ]) - case $host_os in - rhapsody* | darwin1.[[0123]]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; - darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - darwin*) - # if running on 10.5 or later, the deployment target defaults - # to the OS version, if on x86, and 10.4, the deployment - # target defaults to 10.4. Don't you love it? - case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[[012]]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - esac - ;; - esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then - _lt_dar_single_mod='$single_module' - fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' - else - _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}" - fi - if test "$DSYMUTIL" != ":"; then - _lt_dsymutil="~$DSYMUTIL \$lib || :" - else - _lt_dsymutil= - fi - ;; - esac -]) - -# _LT_AC_SYS_LIBPATH_AIX -# ---------------------- -# Links a minimal program and checks the executable -# for the system default hardcoded library path. In most cases, -# this is /usr/lib:/lib, but when the MPI compilers are used -# the location of the communication and MPI libs are included too. -# If we don't find anything, use the default library path according -# to the aix ld manual. -AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_LINK_IFELSE(AC_LANG_PROGRAM,[ -lt_aix_libpath_sed=' - /Import File Strings/,/^$/ { - /^0/ { - s/^0 *\(.*\)$/\1/ - p - } - }' -aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -# Check for a 64-bit object if we didn't find anything. -if test -z "$aix_libpath"; then - aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` -fi],[]) -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi -])# _LT_AC_SYS_LIBPATH_AIX - - -# _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 2>&1 && unset CDPATH - -if test -z "$ECHO"; then -if test "X${echo_test_string+set}" != Xset; then -# find a string as large as possible, as long as the shell can cope with it - for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do - # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... - if (echo_test_string=`eval $cmd`) 2>/dev/null && - echo_test_string=`eval $cmd` && - (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null - then - break - fi - done -fi - -if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && - echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && - test "X$echo_testing_string" = "X$echo_test_string"; then - : -else - # The Solaris, AIX, and Digital Unix default echo programs unquote - # backslashes. This makes it impossible to quote backslashes using - # echo "$something" | sed 's/\\/\\\\/g' - # - # So, first we look for a working echo in the user's PATH. - - 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-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ -s390*-*linux*|sparc*-*linux*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *32-bit*) - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_i386_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_i386" - ;; - ppc64-*linux*|powerpc64-*linux*) - LD="${LD-ld} -m elf32ppclinux" - ;; - s390x-*linux*) - LD="${LD-ld} -m elf_s390" - ;; - sparc64-*linux*) - LD="${LD-ld} -m elf32_sparc" - ;; - esac - ;; - *64-bit*) - libsuff=64 - case $host in - x86_64-*kfreebsd*-gnu) - LD="${LD-ld} -m elf_x86_64_fbsd" - ;; - x86_64-*linux*) - LD="${LD-ld} -m elf_x86_64" - ;; - ppc*-*linux*|powerpc*-*linux*) - LD="${LD-ld} -m elf64ppc" - ;; - s390*-*linux*) - LD="${LD-ld} -m elf64_s390" - ;; - sparc*-*linux*) - LD="${LD-ld} -m elf64_sparc" - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -*-*-sco3.2v5*) - # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" - CFLAGS="$CFLAGS -belf" - AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, - [AC_LANG_PUSH(C) - AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) - AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then - # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" - fi - ;; -sparc*-*solaris*) - # Find out which ABI we are using. - echo 'int i;' > conftest.$ac_ext - if AC_TRY_EVAL(ac_compile); then - case `/usr/bin/file conftest.o` in - *64-bit*) - case $lt_cv_prog_gnu_ld in - yes*) LD="${LD-ld} -m elf64_sparc" ;; - *) - if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then - LD="${LD-ld} -64" - fi - ;; - esac - ;; - esac - fi - rm -rf conftest* - ;; - -AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], -[*-*-cygwin* | *-*-mingw* | *-*-pw32*) - AC_CHECK_TOOL(DLLTOOL, dlltool, false) - AC_CHECK_TOOL(AS, as, false) - AC_CHECK_TOOL(OBJDUMP, objdump, false) - ;; - ]) -esac - -need_locks="$enable_libtool_lock" - -])# _LT_AC_LOCK - - -# AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) -# ---------------------------------------------------------------- -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], -[AC_REQUIRE([LT_AC_PROG_SED]) -AC_CACHE_CHECK([$1], [$2], - [$2=no - ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - # The option is referenced via a variable to avoid confusing sed. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. - $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - fi - $rm conftest* -]) - -if test x"[$]$2" = xyes; then - ifelse([$5], , :, [$5]) -else - ifelse([$6], , :, [$6]) -fi -])# AC_LIBTOOL_COMPILER_OPTION - - -# AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, -# [ACTION-SUCCESS], [ACTION-FAILURE]) -# ------------------------------------------------------------ -# Check whether the given compiler option works -AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_CACHE_CHECK([$1], [$2], - [$2=no - save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS $3" - echo "$lt_simple_link_test_code" > conftest.$ac_ext - if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then - # The linker can only warn and ignore the option if not recognized - # So say no if there are warnings - if test -s conftest.err; then - # Append any errors to the config.log. - cat conftest.err 1>&AS_MESSAGE_LOG_FD - $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp - $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 - if diff conftest.exp conftest.er2 >/dev/null; then - $2=yes - fi - else - $2=yes - fi - fi - $rm -r conftest* - LDFLAGS="$save_LDFLAGS" -]) - -if test x"[$]$2" = xyes; then - ifelse([$4], , :, [$4]) -else - ifelse([$5], , :, [$5]) -fi -])# AC_LIBTOOL_LINKER_OPTION - - -# AC_LIBTOOL_SYS_MAX_CMD_LEN -# -------------------------- -AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], -[# find the maximum length of command line arguments -AC_MSG_CHECKING([the maximum length of command line arguments]) -AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl - i=0 - teststring="ABCD" - - case $build_os in - msdosdjgpp*) - # On DJGPP, this test can blow up pretty badly due to problems in libc - # (any single argument exceeding 2000 bytes causes a buffer overrun - # during glob expansion). Even if it were fixed, the result of this - # check would be larger than it should be. - lt_cv_sys_max_cmd_len=12288; # 12K is about right - ;; - - gnu*) - # Under GNU Hurd, this test is not required because there is - # no limit to the length of command line arguments. - # Libtool will interpret -1 as no limit whatsoever - lt_cv_sys_max_cmd_len=-1; - ;; - - cygwin* | mingw*) - # On Win9x/ME, this test blows up -- it succeeds, but takes - # about 5 minutes as the teststring grows exponentially. - # Worse, since 9x/ME are not pre-emptively multitasking, - # you end up with a "frozen" computer, even though with patience - # the test eventually succeeds (with a max line length of 256k). - # Instead, let's just punt: use the minimum linelength reported by - # all of the supported platforms: 8192 (on NT/2K/XP). - lt_cv_sys_max_cmd_len=8192; - ;; - - amigaos*) - # On AmigaOS with pdksh, this test takes hours, literally. - # So we just punt and use a minimum line length of 8192. - lt_cv_sys_max_cmd_len=8192; - ;; - - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) - # This has been around since 386BSD, at least. Likely further. - if test -x /sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` - elif test -x /usr/sbin/sysctl; then - lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` - else - lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs - fi - # And add a safety zone - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - ;; - - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; - - osf*) - # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure - # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not - # nice to cause kernel panics so lets avoid the loop below. - # First set a reasonable default. - lt_cv_sys_max_cmd_len=16384 - # - if test -x /sbin/sysconfig; then - case `/sbin/sysconfig -q proc exec_disable_arg_limit` in - *1*) lt_cv_sys_max_cmd_len=-1 ;; - esac - fi - ;; - sco3.2v5*) - lt_cv_sys_max_cmd_len=102400 - ;; - sysv5* | sco5v6* | sysv4.2uw2*) - kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` - if test -n "$kargmax"; then - lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` - else - lt_cv_sys_max_cmd_len=32768 - fi - ;; - *) - lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len"; then - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` - else - SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} - while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ - = "XX$teststring") >/dev/null 2>&1 && - new_result=`expr "X$teststring" : ".*" 2>&1` && - lt_cv_sys_max_cmd_len=$new_result && - test $i != 17 # 1/2 MB should be enough - do - i=`expr $i + 1` - teststring=$teststring$teststring - done - teststring= - # Add a significant safety factor because C++ compilers can tack on massive - # amounts of additional arguments before passing them to the linker. - # It appears as though 1/2 is a usable value. - lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` - fi - ;; - esac -]) -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); */ - } - else - puts (dlerror ()); - - exit (status); -}] -EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then - (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null - lt_status=$? - case x$lt_status in - x$lt_dlno_uscore) $1 ;; - x$lt_dlneed_uscore) $2 ;; - x$lt_dlunknown|x*) $3 ;; - esac - else : - # compilation failed - $3 - fi -fi -rm -fr conftest* -])# _LT_AC_TRY_DLOPEN_SELF - - -# AC_LIBTOOL_DLOPEN_SELF -# ---------------------- -AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], -[AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then - enable_dlopen=unknown - enable_dlopen_self=unknown - enable_dlopen_self_static=unknown -else - lt_cv_dlopen=no - lt_cv_dlopen_libs= - - case $host_os in - beos*) - lt_cv_dlopen="load_add_on" - lt_cv_dlopen_libs= - lt_cv_dlopen_self=yes - ;; - - 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="-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_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 - wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" - AC_CACHE_CHECK([whether a statically linked program can dlopen itself], - lt_cv_dlopen_self_static, [dnl - _LT_AC_TRY_DLOPEN_SELF( - lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, - lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) - ]) - fi - - 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_PROG_SED])dnl -AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl -AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], - [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no - $rm -r conftest 2>/dev/null - mkdir conftest - cd conftest - mkdir out - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - lt_compiler_flag="-o out/conftest2.$ac_objext" - # Insert the option either (1) after the last *FLAGS variable, or - # (2) before a word containing "conftest.", or (3) at the end. - # Note that $ac_compile itself does not contain backslashes and begins - # with a dollar sign (not a hyphen), so the echo should work correctly. - lt_compile=`echo "$ac_compile" | $SED \ - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&AS_MESSAGE_LOG_FD - echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings - $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp - $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 - if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then - _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - fi - fi - chmod u+w . 2>&AS_MESSAGE_LOG_FD - $rm conftest* - # SGI C++ compiler will create directory out/ii_files/ for - # template instantiation - test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files - $rm out/* && rmdir out - cd .. - rmdir conftest - $rm conftest* -]) -])# AC_LIBTOOL_PROG_CC_C_O - - -# 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" - old_striplib="$STRIP -S" - AC_MSG_RESULT([yes]) - else - AC_MSG_RESULT([no]) -fi - ;; - *) - AC_MSG_RESULT([no]) - ;; - esac -fi -])# AC_LIBTOOL_SYS_LIB_STRIP - - -# AC_LIBTOOL_SYS_DYNAMIC_LINKER -# ----------------------------- -# PORTME Fill in your ld.so characteristics -AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_MSG_CHECKING([dynamic linker characteristics]) -library_names_spec= -libname_spec='lib$name' -soname_spec= -shrext_cmds=".so" -postinstall_cmds= -postuninstall_cmds= -finish_cmds= -finish_eval= -shlibpath_var= -shlibpath_overrides_runpath=unknown -version_type=none -dynamic_linker="$host_os ld.so" -sys_lib_dlsearch_path_spec="/lib /usr/lib" -m4_if($1,[],[ -if test "$GCC" = yes; then - case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; - esac - lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` - if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then - # if the path contains ";" then we assume it to be the separator - # otherwise default to the standard path separator (i.e. ":") - it is - # assumed that no part of a normal pathname contains ";" but that should - # okay in the real world where ";" in dirpaths is itself problematic. - lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` - else - lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` - fi - # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. - lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` - for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else - test -d "$lt_sys_path" && \ - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" - fi - done - lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; - for (lt_i = NF; lt_i > 0; lt_i--) { - if ($lt_i != "" && $lt_i != ".") { - if ($lt_i == "..") { - lt_count++; - } else { - if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; - } else { - lt_count--; - } - } - } - } - if (lt_foo != "") { lt_freq[[lt_foo]]++; } - if (lt_freq[[lt_foo]] == 1) { print lt_foo; } -}'` - sys_lib_search_path_spec=`echo $lt_search_path_spec` -else - sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" -fi]) -need_lib_prefix=unknown -hardcode_into_libs=no - -# when you set need_version to no, make sure it does not cause -set_version -# flags to be left without arguments -need_version=unknown - -case $host_os in -aix3*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' - shlibpath_var=LIBPATH - - # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' - ;; - -aix[[4-9]]*) - version_type=linux - need_lib_prefix=no - need_version=no - hardcode_into_libs=yes - if test "$host_cpu" = ia64; then - # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' - shlibpath_var=LD_LIBRARY_PATH - else - # With GCC up to 2.95.x, collect2 would create an import file - # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in - # development snapshots of GCC prior to 3.0. - case $host_os in - aix4 | aix4.[[01]] | aix4.[[01]].*) - if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' - echo ' yes ' - echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then - : - else - can_build_shared=no - fi - ;; - esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct - # soname into executable. Probably we can add versioning support to - # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then - # If using run time linking (on AIX 4.2 or later) use lib.so - # instead of lib.a to let people know that these are not - # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else - # We preserve .a as extension for shared libraries through AIX4.2 - # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi - shlibpath_var=LIBPATH - fi - ;; - -amigaos*) - library_names_spec='$libname.ixlibrary $libname.a' - # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' - ;; - -beos*) - library_names_spec='${libname}${shared_ext}' - dynamic_linker="$host_os ld.so" - shlibpath_var=LIBRARY_PATH - ;; - -bsdi[[45]]*) - version_type=linux - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' - shlibpath_var=LD_LIBRARY_PATH - sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" - sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" - # the default ld.so.conf also contains /usr/contrib/lib and - # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow - # libtool to hard-code these into programs - ;; - -cygwin* | mingw* | pw32*) - version_type=windows - shrext_cmds=".dll" - need_version=no - need_lib_prefix=no - - case $GCC,$host_os in - yes,cygwin* | yes,mingw* | yes,pw32*) - library_names_spec='$libname.dll.a' - # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ - dldir=$destdir/`dirname \$dlpath`~ - test -d \$dldir || mkdir -p \$dldir~ - $install_prog $dir/$dlname \$dldir/$dlname~ - chmod a+x \$dldir/$dlname' - postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ - dlpath=$dir/\$dldll~ - $rm \$dlpath' - shlibpath_overrides_runpath=yes - - 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`' - 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) - 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 - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" - - # Append ld.so.conf contents to the search path - if test -f /etc/ld.so.conf; then - lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - fi - - # We used to test for /lib/ld.so.1 and disable shared libraries on - # powerpc, because MkLinux only supported shared libraries with the - # GNU dynamic linker. Since this was broken with cross compilers, - # most powerpc-linux boxes support dynamic linking these days and - # people can always --disable-shared, the test was removed, and we - # assume the GNU/Linux dynamic linker is in use. - dynamic_linker='GNU/Linux ld.so' - ;; - -netbsd*) - version_type=sunos - need_lib_prefix=no - need_version=no - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - dynamic_linker='NetBSD (a.out) ld.so' - else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - dynamic_linker='NetBSD ld.elf_so' - fi - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=yes - hardcode_into_libs=yes - ;; - -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 - 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 - export_dynamic_flag_spec='${wl}-Blargedynsym' - runpath_var=LD_RUN_PATH - ;; - siemens) - need_lib_prefix=no - ;; - motorola) - need_lib_prefix=no - need_version=no - shlibpath_overrides_runpath=no - sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' - ;; - esac - ;; - -sysv4*MP*) - if test -d /usr/nec ;then - version_type=linux - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' - shlibpath_var=LD_LIBRARY_PATH - fi - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then - sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' - shlibpath_overrides_runpath=no - else - sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' - shlibpath_overrides_runpath=yes - case $host_os in - sco3.2v5*) - sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" - ;; - esac - fi - sys_lib_dlsearch_path_spec='/usr/lib' - ;; - -uts4*) - version_type=linux - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - ;; - -*) - dynamic_linker=no - ;; -esac -AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no - -AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec], -[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"]) -sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" -AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec], -[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"]) -sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" - -variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then - variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" -fi -])# AC_LIBTOOL_SYS_DYNAMIC_LINKER - - -# _LT_AC_TAGCONFIG -# ---------------- -AC_DEFUN([_LT_AC_TAGCONFIG], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_ARG_WITH([tags], - [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], - [include additional configurations @<:@automatic@:>@])], - [tagnames="$withval"]) - -if test -f "$ltmain" && test -n "$tagnames"; then - if test ! -f "${ofile}"; then - AC_MSG_WARN([output file `$ofile' does not exist]) - fi - - if test -z "$LTCC"; then - eval "`$SHELL ${ofile} --config | grep '^LTCC='`" - if test -z "$LTCC"; then - AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) - else - AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) - fi - fi - if test -z "$LTCFLAGS"; then - eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" - fi - - # Extract list of available tagged configurations in $ofile. - # Note that this assumes the entire list is on one line. - available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` - - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for tagname in $tagnames; do - IFS="$lt_save_ifs" - # Check whether tagname contains only valid characters - case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in - "") ;; - *) 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" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; 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 DLLs -AC_DEFUN([AC_LIBTOOL_WIN32_DLL], -[AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) -])# AC_LIBTOOL_WIN32_DLL - - -# AC_ENABLE_SHARED([DEFAULT]) -# --------------------------- -# implement the --enable-shared flag -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. -AC_DEFUN([AC_ENABLE_SHARED], -[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl -AC_ARG_ENABLE([shared], - [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], - [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], - [p=${PACKAGE-default} - case $enableval in - yes) enable_shared=yes ;; - no) enable_shared=no ;; - *) - enable_shared=no - # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," - for pkg in $enableval; do - IFS="$lt_save_ifs" - if test "X$pkg" = "X$p"; then - enable_shared=yes - fi - done - IFS="$lt_save_ifs" - ;; - esac], - [enable_shared=]AC_ENABLE_SHARED_DEFAULT) -])# AC_ENABLE_SHARED - - -# 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 recognize shared library -AC_DEFUN([AC_PATH_TOOL_PREFIX], -[AC_REQUIRE([AC_PROG_EGREP])dnl -AC_MSG_CHECKING([for $1]) -AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, -[case $MAGIC_CMD in -[[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. - ;; -*) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR -dnl $ac_dummy forces splitting on constant user-supplied paths. -dnl POSIX.2 word splitting is done only on the output of word expansions, -dnl not every word. This closes a longstanding sh security hole. - ac_dummy="ifelse([$2], , $PATH, [$2])" - for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" - if test -n "$file_magic_test_file"; then - case $deplibs_check_method in - "file_magic "*) - file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" - if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | - $EGREP "$file_magic_regex" > /dev/null; then - : - else - 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 recognize a shared library -AC_DEFUN([AC_PATH_MAGIC], -[AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) -if test -z "$lt_cv_path_MAGIC_CMD"; then - if test -n "$ac_tool_prefix"; then - AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) - else - MAGIC_CMD=: - fi -fi -])# AC_PATH_MAGIC - - -# AC_PROG_LD -# ---------- -# find the pathname to the GNU or non-GNU linker -AC_DEFUN([AC_PROG_LD], -[AC_ARG_WITH([gnu-ld], - [AC_HELP_STRING([--with-gnu-ld], - [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], - [with_gnu_ld=no]) -AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_REQUIRE([AC_CANONICAL_BUILD])dnl -ac_prog=ld -if test "$GCC" = yes; then - # Check if gcc -print-prog-name=ld gives a path. - AC_MSG_CHECKING([for ld used by $CC]) - case $host in - *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw - ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; - *) - ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; - esac - case $ac_prog in - # Accept absolute paths. - [[\\/]]* | ?:[[\\/]]*) - re_direlt='/[[^/]][[^/]]*/\.\./' - # Canonicalize the pathname of ld - ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` - while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do - ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` - done - test -z "$LD" && LD="$ac_prog" - ;; - "") - # If it fails, then pretend we aren't using GCC. - ac_prog=ld - ;; - *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown - ;; - esac -elif test "$with_gnu_ld" = yes; then - AC_MSG_CHECKING([for GNU ld]) -else - AC_MSG_CHECKING([for non-GNU ld]) -fi -AC_CACHE_VAL(lt_cv_path_LD, -[if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" - # Check to see if the program is GNU ld. I'd rather use --version, - # but apparently some variants of GNU ld only accept -v. - # Break only if it was the GNU/non-GNU ld that we prefer. - case `"$lt_cv_path_LD" -v 2>&1 &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 - ;; - -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) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' - fi - ;; - -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*) - 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 - ;; - -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 - ;; - -sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - lt_cv_deplibs_check_method=pass_all - ;; -esac -]) -file_magic_cmd=$lt_cv_file_magic_cmd -deplibs_check_method=$lt_cv_deplibs_check_method -test -z "$deplibs_check_method" && deplibs_check_method=unknown -])# AC_DEPLIBS_CHECK_METHOD - - -# AC_PROG_NM -# ---------- -# find the pathname to a BSD-compatible name lister -AC_DEFUN([AC_PROG_NM], -[AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, -[if test -n "$NM"; then - # Let the user override the test. - lt_cv_path_NM="$NM" -else - lt_nm_to_check="${ac_tool_prefix}nm" - if test -n "$ac_tool_prefix" && test "$build" = "$host"; then - lt_nm_to_check="$lt_nm_to_check nm" - fi - for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" - test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then - # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: - # nm: unknown option "B" ignored - # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) - lt_cv_path_NM="$tmp_nm -B" - break - ;; - *) - 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 - 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 -# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, -# it is assumed to be `libltdl'. LIBLTDL will be prefixed with -# '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/' -# (note the single quotes!). If your package is not flat and you're not -# using automake, define top_builddir and top_srcdir appropriately in -# the Makefiles. -AC_DEFUN([AC_LIBLTDL_CONVENIENCE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - case $enable_ltdl_convenience in - no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; - "") enable_ltdl_convenience=yes - ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; - esac - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_CONVENIENCE - - -# AC_LIBLTDL_INSTALLABLE([DIRECTORY]) -# ----------------------------------- -# sets LIBLTDL to the link flags for the libltdl installable library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-install to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, -# and an installed libltdl is not found, it is assumed to be `libltdl'. -# LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with -# '${top_srcdir}/' (note the single quotes!). If your package is not -# flat and you're not using automake, define top_builddir and top_srcdir -# appropriately in the Makefiles. -# In the future, this macro may have to be called after AC_PROG_LIBTOOL. -AC_DEFUN([AC_LIBLTDL_INSTALLABLE], -[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl - AC_CHECK_LIB(ltdl, lt_dlinit, - [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], - [if test x"$enable_ltdl_install" = xno; then - AC_MSG_WARN([libltdl not installed, but installation disabled]) - else - enable_ltdl_install=yes - fi - ]) - if test x"$enable_ltdl_install" = x"yes"; then - ac_configure_args="$ac_configure_args --enable-ltdl-install" - LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la - LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) - else - ac_configure_args="$ac_configure_args --enable-ltdl-install=no" - LIBLTDL="-lltdl" - LTDLINCL= - fi - # For backwards non-gettext consistent compatibility... - INCLTDL="$LTDLINCL" -])# AC_LIBLTDL_INSTALLABLE - - -# 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([_LT_AC_PROG_CXXCPP]) -_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) -])# _LT_AC_LANG_CXX - -# _LT_AC_PROG_CXXCPP -# ------------------ -AC_DEFUN([_LT_AC_PROG_CXXCPP], -[ -AC_REQUIRE([AC_PROG_CXX]) -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then - AC_PROG_CXXCPP -fi -])# _LT_AC_PROG_CXXCPP - -# 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;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(){return(0);}' - -_LT_AC_SYS_COMPILER - -# save warnings/boilerplate of simple test code -_LT_COMPILER_BOILERPLATE -_LT_LINKER_BOILERPLATE - -AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) -AC_LIBTOOL_SYS_LIB_STRIP -AC_LIBTOOL_DLOPEN_SELF - -# Report which library types will actually be built -AC_MSG_CHECKING([if libtool supports shared libraries]) -AC_MSG_RESULT([$can_build_shared]) - -AC_MSG_CHECKING([whether to build shared libraries]) -test "$can_build_shared" = "no" && enable_shared=no - -# On AIX, shared libraries and static libraries use the same namespace, and -# are all built from PIC. -case $host_os in -aix3*) - test "$enable_shared" = yes && enable_static=no - if test -n "$RANLIB"; then - archive_cmds="$archive_cmds~\$RANLIB \$lib" - postinstall_cmds='$RANLIB $lib' - fi - ;; - -aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no - fi - ;; -esac -AC_MSG_RESULT([$enable_shared]) - -AC_MSG_CHECKING([whether to build static libraries]) -# Make sure either enable_shared or enable_static is yes. -test "$enable_shared" = yes || enable_static=yes -AC_MSG_RESULT([$enable_static]) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_C_CONFIG - - -# AC_LIBTOOL_LANG_CXX_CONFIG -# -------------------------- -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) -AC_DEFUN([_LT_AC_LANG_CXX_CONFIG], -[AC_LANG_PUSH(C++) -AC_REQUIRE([AC_PROG_CXX]) -AC_REQUIRE([_LT_AC_PROG_CXXCPP]) - -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_AC_TAGVAR(allow_undefined_flag, $1)= -_LT_AC_TAGVAR(always_export_symbols, $1)=no -_LT_AC_TAGVAR(archive_expsym_cmds, $1)= -_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_direct, $1)=no -_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= -_LT_AC_TAGVAR(hardcode_minus_L, $1)=no -_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported -_LT_AC_TAGVAR(hardcode_automatic, $1)=no -_LT_AC_TAGVAR(module_cmds, $1)= -_LT_AC_TAGVAR(module_expsym_cmds, $1)= -_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_AC_TAGVAR(no_undefined_flag, $1)= -_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= -_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Dependencies to place before and after the object being linked: -_LT_AC_TAGVAR(predep_objects, $1)= -_LT_AC_TAGVAR(postdep_objects, $1)= -_LT_AC_TAGVAR(predeps, $1)= -_LT_AC_TAGVAR(postdeps, $1)= -_LT_AC_TAGVAR(compiler_lib_search_path, $1)= -_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)= - -# Source file extension for C++ test sources. -ac_ext=cpp - -# Object file extension for compiled C++ test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# Code to be used in simple compile tests -lt_simple_compile_test_code="int some_variable = 0;" - -# Code to be used in simple link tests -lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' - -# ltmain only uses $CC for tagged configurations so make sure $CC is set. -_LT_AC_SYS_COMPILER - -# 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_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -# 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 - ;; - 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_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 - : - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - 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 '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - 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 - ;; - - 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}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - darwin* | rhapsody*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - _LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" - if test "$GXX" = yes ; then - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" - _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" - if test "$lt_cv_apple_cc_single_mod" != "yes"; then - _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" - fi - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - dgux*) - case $cc_basename in - ec++*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - ghcx*) - # Green Hills C++ Compiler - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - freebsd[[12]]*) - # C++ shared libraries reported to be fairly broken before switch to ELF - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - freebsd-elf*) - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - ;; - freebsd* | dragonfly*) - # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF - # conventions - _LT_AC_TAGVAR(ld_shlibs, $1)=yes - ;; - gnu*) - ;; - hpux9*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - - case $cc_basename in - CC*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - aCC*) - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' - else - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - hpux10*|hpux11*) - if test $with_gnu_ld = no; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) ;; - *) - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - ;; - esac - fi - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, - # but as the default - # location of the library. - ;; - esac - - 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*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - esac - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - ;; - *) - _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 - ;; - interix[[3-9]]*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - irix5* | irix6*) - case $cc_basename in - CC*) - # SGI C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - # Archives containing C++ object files must be created using - # "CC -ar", where "CC" is the IRIX C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' - ;; - *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' - fi - fi - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - esac - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - ;; - linux* | k*bsd*-gnu) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - ;; - icpc*) - # Intel C++ - with_gnu_ld=yes - # version 8.0 and above of icpc choke on multiply defined symbols - # if we add $predep_objects and $postdep_objects, however 7.1 and - # earlier do not add the objects themselves. - case `$CC -V 2>&1` in - *"Version 7."*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - *) # Version 8.0 or newer - tmp_idyn= - case $host_cpu in - ia64*) tmp_idyn=' -i_dynamic';; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - ;; - cxx*) - # Compaq C++ - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' - - 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' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - - # Not sure whether something based on - # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 - # would be better. - output_verbose_link_cmd='echo' - - # Archives containing C++ object files must be created using - # "CC -xar", where "CC" is the Sun C++ compiler. This is - # necessary to make sure instantiated templates are included - # in the archive. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' - ;; - esac - ;; - 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*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - fi - # Workaround some broken pre-1.5 toolchains - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' - ;; - openbsd2*) - # C++ shared libraries are fairly broken - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - openbsd*) - if test -f /usr/libexec/ld.so; then - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - fi - output_verbose_link_cmd='echo' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - osf3*) - case $cc_basename in - KCC*) - # Kuck and Associates, Inc. (KAI) C++ Compiler - - # KCC will only create a shared library if the output file - # ends with ".so" (or ".sl" for HP-UX), so rename the library - # to its proper name (with version) after linking. - _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Archives containing C++ object files must be created using - # "CC -Bstatic", where "CC" is the KAI C++ compiler. - _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' - - ;; - RCC*) - # Rational C++ 2.4.1 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - cxx*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' - - 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 ${output_objdir}/so_locations -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ - $rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - # Commands to make compiler produce verbose output that lists - # what "hidden" libraries, object files and flags are used when - # linking a shared library. - # - # There doesn't appear to be a way to prevent this compiler from - # explicitly linking system object files so we need to strip them - # from the output so that they don't get included in the library - # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' - ;; - *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - - _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 - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - lcc*) - # Lucid - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' - - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. - # Supported since Solaris 2.6 (maybe 2.5.1?) - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - ;; - esac - _LT_AC_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_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' - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - _LT_AC_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_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - # For security reasons, it is highly recommended that you always - # use absolute paths for naming shared libraries, and exclude the - # DT_RUNPATH tag from executables and libraries. But doing so - # requires that you compile everything twice, which is a pain. - # So that behaviour is only enabled if SCOABSPATH is set to a - # non-empty value in the environment. Most likely only useful for - # creating official distributions of packages. - # This is a hack until libtool officially supports absolute path - # names for shared libraries. - _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - case $cc_basename in - CC*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - ;; - vxworks*) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - *) - # FIXME: insert proper C++ library support - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; -esac -AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) -test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no - -_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_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], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -dnl we can't use the lt_simple_compile_test_code here, -dnl because it contains code intended for an executable, -dnl not a library. It's possible we should let each -dnl tag define a new lt_????_link_test_code variable, -dnl but it's only used here... -ifelse([$1],[],[cat > conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext <&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - # - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - if test "$solaris_use_stlport4" != yes; then - _LT_AC_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_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; -esac -]) -case " $_LT_AC_TAGVAR(postdeps, $1) " in -*" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; -esac -])# AC_LIBTOOL_POSTDEP_PREDEP - -# AC_LIBTOOL_LANG_F77_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_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)]) -AC_DEFUN([_LT_AC_LANG_F77_CONFIG], -[AC_REQUIRE([AC_PROG_F77]) -AC_LANG_PUSH(Fortran 77) - -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no -_LT_AC_TAGVAR(allow_undefined_flag, $1)= -_LT_AC_TAGVAR(always_export_symbols, $1)=no -_LT_AC_TAGVAR(archive_expsym_cmds, $1)= -_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_direct, $1)=no -_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= -_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= -_LT_AC_TAGVAR(hardcode_libdir_separator, $1)= -_LT_AC_TAGVAR(hardcode_minus_L, $1)=no -_LT_AC_TAGVAR(hardcode_automatic, $1)=no -_LT_AC_TAGVAR(module_cmds, $1)= -_LT_AC_TAGVAR(module_expsym_cmds, $1)= -_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds -_LT_AC_TAGVAR(no_undefined_flag, $1)= -_LT_AC_TAGVAR(whole_archive_flag_spec, $1)= -_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - -# Source file extension for f77 test sources. -ac_ext=f - -# Object file extension for compiled f77 test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# 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_AC_SYS_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" -CC=${F77-"f77"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -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_AC_TAGVAR(GCC, $1)="$G77" -_LT_AC_TAGVAR(LD, $1)="$LD" - -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_POP -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_F77_CONFIG - - -# AC_LIBTOOL_LANG_GCJ_CONFIG -# -------------------------- -# Ensure that the configuration vars for the C compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)]) -AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG], -[AC_LANG_SAVE - -# Source file extension for Java test sources. -ac_ext=java - -# Object file extension for compiled Java test sources. -objext=o -_LT_AC_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_AC_SYS_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" -CC=${GCJ-"gcj"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) - -# GCJ did not exist at the time GCC didn't implicitly link libc in. -_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - -_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds - -AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) -AC_LIBTOOL_PROG_COMPILER_PIC($1) -AC_LIBTOOL_PROG_CC_C_O($1) -AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) -AC_LIBTOOL_PROG_LD_SHLIBS($1) -AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) -AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_RESTORE -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_GCJ_CONFIG - - -# AC_LIBTOOL_LANG_RC_CONFIG -# ------------------------- -# Ensure that the configuration vars for the Windows resource compiler are -# suitably defined. Those variables are subsequently used by -# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. -AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)]) -AC_DEFUN([_LT_AC_LANG_RC_CONFIG], -[AC_LANG_SAVE - -# Source file extension for RC test sources. -ac_ext=rc - -# Object file extension for compiled RC test sources. -objext=o -_LT_AC_TAGVAR(objext, $1)=$objext - -# 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_AC_SYS_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" -CC=${RC-"windres"} -compiler=$CC -_LT_AC_TAGVAR(compiler, $1)=$CC -_LT_CC_BASENAME([$compiler]) -_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes - -AC_LIBTOOL_CONFIG($1) - -AC_LANG_RESTORE -CC="$lt_save_CC" -])# AC_LIBTOOL_LANG_RC_CONFIG - - -# AC_LIBTOOL_CONFIG([TAGNAME]) -# ---------------------------- -# If TAGNAME is not passed, then create an initial libtool script -# with a default configuration from the untagged config vars. Otherwise -# add code to config.status for appending the configuration named by -# TAGNAME from the matching tagged config vars. -AC_DEFUN([AC_LIBTOOL_CONFIG], -[# The else clause should only fire when bootstrapping the -# libtool distribution, otherwise you forgot to ship ltmain.sh -# with your package, and you will get complaints that there are -# no rules to generate ltmain.sh. -if test -f "$ltmain"; then - # See if we are running on zsh, and set the options which allow our commands through - # without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then - setopt NO_GLOB_SUBST - fi - # Now quote all the things that may contain metacharacters while being - # careful not to overquote the AC_SUBSTed values. We take copies of the - # variables and quote the copies for generation of the libtool script. - for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ - SED SHELL STRIP \ - libname_spec library_names_spec soname_spec extract_expsyms_cmds \ - old_striplib striplib file_magic_cmd finish_cmds finish_eval \ - deplibs_check_method reload_flag reload_cmds need_locks \ - lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ - lt_cv_sys_global_symbol_to_c_name_address \ - sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ - old_postinstall_cmds old_postuninstall_cmds \ - _LT_AC_TAGVAR(compiler, $1) \ - _LT_AC_TAGVAR(CC, $1) \ - _LT_AC_TAGVAR(LD, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \ - _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \ - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \ - _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \ - _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \ - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \ - _LT_AC_TAGVAR(old_archive_cmds, $1) \ - _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \ - _LT_AC_TAGVAR(predep_objects, $1) \ - _LT_AC_TAGVAR(postdep_objects, $1) \ - _LT_AC_TAGVAR(predeps, $1) \ - _LT_AC_TAGVAR(postdeps, $1) \ - _LT_AC_TAGVAR(compiler_lib_search_path, $1) \ - _LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \ - _LT_AC_TAGVAR(archive_cmds, $1) \ - _LT_AC_TAGVAR(archive_expsym_cmds, $1) \ - _LT_AC_TAGVAR(postinstall_cmds, $1) \ - _LT_AC_TAGVAR(postuninstall_cmds, $1) \ - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \ - _LT_AC_TAGVAR(allow_undefined_flag, $1) \ - _LT_AC_TAGVAR(no_undefined_flag, $1) \ - _LT_AC_TAGVAR(export_symbols_cmds, $1) \ - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \ - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \ - _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \ - _LT_AC_TAGVAR(hardcode_automatic, $1) \ - _LT_AC_TAGVAR(module_cmds, $1) \ - _LT_AC_TAGVAR(module_expsym_cmds, $1) \ - _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \ - _LT_AC_TAGVAR(fix_srcfile_path, $1) \ - _LT_AC_TAGVAR(exclude_expsyms, $1) \ - _LT_AC_TAGVAR(include_expsyms, $1); do - - case $var in - _LT_AC_TAGVAR(old_archive_cmds, $1) | \ - _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \ - _LT_AC_TAGVAR(archive_cmds, $1) | \ - _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \ - _LT_AC_TAGVAR(module_cmds, $1) | \ - _LT_AC_TAGVAR(module_expsym_cmds, $1) | \ - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \ - _LT_AC_TAGVAR(export_symbols_cmds, $1) | \ - extract_expsyms_cmds | reload_cmds | finish_cmds | \ - postinstall_cmds | postuninstall_cmds | \ - old_postinstall_cmds | old_postuninstall_cmds | \ - sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) - # Double-quote double-evaled strings. - eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" - ;; - *) - 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 - -ifelse([$1], [], - [cfgfile="${ofile}T" - trap "$rm \"$cfgfile\"; exit 1" 1 2 15 - $rm -f "$cfgfile" - AC_MSG_NOTICE([creating $ofile])], - [cfgfile="$ofile"]) - - cat <<__EOF__ >> "$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, 2002, 2003, 2004, 2005, 2006, 2007, 2008 -# Free Software Foundation, Inc. -# -# This file is part of GNU Libtool: -# Originally by Gordon Matzigkeit , 1996 -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -# General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -# -# As a special exception to the GNU General Public License, if you -# distribute this file as part of a program that contains a -# configuration script generated by Autoconf, you may include it under -# the same distribution terms that you use for the rest of that program. - -# A sed program that does not truncate output. -SED=$lt_SED - -# Sed that helps us avoid accidentally triggering echo(1) options like -n. -Xsed="$SED -e 1s/^X//" - -# The HP-UX ksh and POSIX shell print the target directory to stdout -# if CDPATH is set. -(unset CDPATH) >/dev/null 2>&1 && unset CDPATH - -# The names of the tagged configurations supported by this script. -available_tags= - -# ### BEGIN LIBTOOL CONFIG], -[# ### 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 -host_os=$host_os - -# The build system. -build_alias=$build_alias -build=$build -build_os=$build_os - -# An echo program that does not interpret backslashes. -echo=$lt_echo - -# The archiver. -AR=$lt_AR -AR_FLAGS=$lt_AR_FLAGS - -# A C compiler. -LTCC=$lt_LTCC - -# LTCC compiler flags. -LTCFLAGS=$lt_LTCFLAGS - -# A language-specific compiler. -CC=$lt_[]_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 directories searched by this compiler when creating a shared -# library -compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $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_fix_srcfile_path - -# Set to yes if exported symbols are required. -always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) - -# The commands to list exported symbols. -export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) - -# The commands to extract the exported symbol list from a shared archive. -extract_expsyms_cmds=$lt_extract_expsyms_cmds - -# Symbols that should not be listed in the preloaded symbols. -exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) - -# Symbols that must always be exported. -include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) - -ifelse([$1],[], -[# ### END LIBTOOL CONFIG], -[# ### END LIBTOOL TAG CONFIG: $tagname]) - -__EOF__ - -ifelse([$1],[], [ - case $host_os in - aix3*) - cat <<\EOF >> "$cfgfile" - -# AIX sometimes has problems with the GCC collect2 program. For some -# reason, if we set the COLLECT_NAMES environment variable, the problems -# vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then - COLLECT_NAMES= - export COLLECT_NAMES -fi -EOF - ;; - esac - - # We 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([LT_AC_PROG_SED]) -AC_REQUIRE([AC_PROG_NM]) -AC_REQUIRE([AC_OBJEXT]) -# Check for command to grab the raw symbol name followed by C symbol from nm. -AC_MSG_CHECKING([command to parse $NM output from $compiler object]) -AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], -[ -# These are sane defaults that work on at least a few old systems. -# [They come from Ultrix. What could be older than Ultrix?!! ;)] - -# 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 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'" - ;; -linux* | k*bsd*-gnu) - if test "$host_cpu" = ia64; then - symcode='[[ABCDGIRSTW]]' - lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" - lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" - fi - ;; -irix* | nonstopux*) - symcode='[[BCDEGRST]]' - ;; -osf*) - symcode='[[BCDEGQRST]]' - ;; -solaris*) - symcode='[[BDRT]]' - ;; -sco3.2v5*) - symcode='[[DT]]' - ;; -sysv4.2uw2*) - symcode='[[DT]]' - ;; -sysv5* | sco5v6* | unixware* | OpenUNIX*) - symcode='[[ABDT]]' - ;; -sysv4) - symcode='[[DFNSTU]]' - ;; -esac - -# Handle CRLF in mingw tool chain -opt_cr= -case $build_os in -mingw*) - opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp - ;; -esac - -# If we're using GNU nm, then use its standard symbol codes. -case `$NM -V 2>&1` in -*GNU* | *'with BFD'*) - symcode='[[ABCDGIRSTW]]' ;; -esac - -# Try without a prefix undercore, then with it. -for ac_symprfx in "" "_"; do - - # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. - symxfrm="\\1 $ac_symprfx\\2 \\2" - - # Write the raw and C identifiers. - lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" - - # Check to see that the pipe works correctly. - pipe_works=no - - rm -f conftest* - cat > conftest.$ac_ext < $nlist) && test -s "$nlist"; then - # Try sorting and uniquifying the output. - if sort "$nlist" | uniq > "$nlist"T; then - mv -f "$nlist"T "$nlist" - else - rm -f "$nlist"T - fi - - # 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 -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 -]) # 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* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - mingw* | cygwin* | os2* | pw32*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - *djgpp*) - # DJGPP does not support shared libraries at all - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - interix[[3-9]]*) - # Interix 3.x gcc -fpic/-fPIC options generate broken code. - # Instead, we relocate shared libraries at runtime. - ;; - sysv4*MP*) - if test -d /usr/nec; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic - fi - ;; - hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. - case $host_cpu in - hppa*64*|ia64*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - esac - else - case $host_os in - aix[[4-9]]*) - # All AIX code is PIC. - if test "$host_cpu" = ia64; then - # AIX 5 now supports IA64 processor - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - else - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' - fi - ;; - chorus*) - case $cc_basename in - cxch68*) - # Green Hills C++ Compiler - # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" - ;; - esac - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - dgux*) - case $cc_basename in - ec++*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - ghcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - freebsd* | dragonfly*) - # FreeBSD uses GNU C++ - ;; - hpux9* | hpux10* | hpux11*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - fi - ;; - aCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - case $host_cpu in - hppa*64*|ia64*) - # +Z the default - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' - ;; - esac - ;; - *) - ;; - esac - ;; - interix*) - # This is c89, which is MS Visual C++ (no shared libs) - # Anyone wants to do a port? - ;; - irix5* | irix6* | nonstopux*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - # CC pic flag -KPIC is the default. - ;; - *) - ;; - esac - ;; - linux* | k*bsd*-gnu) - case $cc_basename in - KCC*) - # KAI C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' - ;; - icpc* | ecpc*) - # Intel C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgCC* | pgcpp*) - # Portland Group C++ compiler. - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - cxx*) - # Compaq C++ - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - esac - ;; - esac - ;; - lynxos*) - ;; - m88k*) - ;; - mvs*) - case $cc_basename in - cxx*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' - ;; - *) - ;; - esac - ;; - netbsd*) - ;; - osf3* | osf4* | osf5*) - case $cc_basename in - KCC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' - ;; - RCC*) - # Rational C++ 2.4.1 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - cxx*) - # Digital/Compaq C++ - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # Make sure the PIC flag is empty. It appears that all Alpha - # Linux and Compaq Tru64 Unix objects are PIC. - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - ;; - esac - ;; - psos*) - ;; - solaris*) - case $cc_basename in - CC*) - # Sun C++ 4.2, 5.x and Centerline C++ - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' - ;; - gcx*) - # Green Hills C++ Compiler - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' - ;; - *) - ;; - esac - ;; - sunos4*) - case $cc_basename in - CC*) - # Sun C++ 4.x - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - lcc*) - # Lucid - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - ;; - *) - ;; - esac - ;; - tandem*) - case $cc_basename in - NCC*) - # NonStop-UX NCC 3.20 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - ;; - *) - ;; - esac - ;; - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - case $cc_basename in - CC*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - esac - ;; - vxworks*) - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - esac - fi -], -[ - 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* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) - # PIC is the default for these OSes. - ;; - - mingw* | cygwin* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - # Although the cygwin gcc ignores -fPIC, still need this for old-style - # (--disable-auto-import) libraries - m4_if([$1], [GCJ], [], - [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - - darwin* | rhapsody*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' - ;; - - 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_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 - ;; - darwin*) - # PIC is the default on this platform - # Common symbols not allowed in MH_DYLIB files - case $cc_basename in - xlc*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - esac - ;; - - mingw* | cygwin* | pw32* | os2*) - # This hack is so that the source file can tell whether it is being - # built for inclusion in a dll (and should export symbols for example). - m4_if([$1], [GCJ], [], - [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) - ;; - - 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* | k*bsd*-gnu) - case $cc_basename in - icc* | ecc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' - ;; - pgcc* | pgf77* | pgf90* | pgf95*) - # Portland Group compilers (*not* the Pentium gcc compiler, - # which looks to be a dead project) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - ccc*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - # All Alpha code is PIC. - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - *) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C 5.9 - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - ;; - *Sun\ F*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='' - ;; - esac - ;; - esac - ;; - - 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' - ;; - - rdos*) - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' - ;; - - solaris*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - case $cc_basename in - f77* | f90* | f95*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; - *) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; - esac - ;; - - 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*) - _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 - ;; - - sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - unicos*) - _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no - ;; - - uts4*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' - _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' - ;; - - *) - _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_cv_prog_compiler_pic_works, $1), - [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], - [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in - "" | " "*) ;; - *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; - esac], - [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) -fi -case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: - *djgpp*) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= - ;; - *) - _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" - ;; -esac - -# -# Check to make sure the static flag actually works. -# -wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\" -AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], - _LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1), - $lt_tmp_static_flag, - [], - [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) -]) - - -# AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) -# ------------------------------------ -# See if the linker supports building shared libraries. -AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], -[AC_REQUIRE([LT_AC_PROG_SED])dnl -AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) -ifelse([$1],[CXX],[ - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - case $host_os in - aix[[4-9]]*) - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - ;; - pw32*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" - ;; - cygwin* | mingw*) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' - ;; - *) - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - ;; - esac - _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] -],[ - runpath_var= - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no - _LT_AC_TAGVAR(archive_cmds, $1)= - _LT_AC_TAGVAR(archive_expsym_cmds, $1)= - _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= - _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_minus_L, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown - _LT_AC_TAGVAR(hardcode_automatic, $1)=no - _LT_AC_TAGVAR(module_cmds, $1)= - _LT_AC_TAGVAR(module_expsym_cmds, $1)= - _LT_AC_TAGVAR(always_export_symbols, $1)=no - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' - # include_expsyms should be a list of space-separated symbols to be *always* - # included in the symbol list - _LT_AC_TAGVAR(include_expsyms, $1)= - # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. - _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] - # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out - # platforms (ab)use it in PIC code, but their linkers get confused if - # the symbol is explicitly referenced. Since portable code cannot - # rely on this symbol name, it's probably fine to never include it in - # preloaded symbol tables. - # Exclude shared library initialization/finalization symbols. -dnl Note also adjust exclude_expsyms for C++ above. - extract_expsyms_cmds= - # Just being paranoid about ensuring that cc_basename is set. - _LT_CC_BASENAME([$compiler]) - case $host_os in - cygwin* | mingw* | pw32*) - # FIXME: the MSVC++ port hasn't been tested in a loooong time - # When not using gcc, we currently assume that we are using - # Microsoft Visual C++. - if test "$GCC" != yes; then - with_gnu_ld=no - fi - ;; - interix*) - # we just hope/assume this is gcc and not c89 (= MSVC++) - with_gnu_ld=yes - ;; - openbsd*) - with_gnu_ld=no - ;; - esac - - _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}' - - # Set some defaults for GNU ld with shared library support. These - # are reset later if shared libraries are not supported. Putting them - # here allows them to be overridden if necessary. - runpath_var=LD_RUN_PATH - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - # ancient GNU ld didn't support --whole-archive et. al. - if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - supports_anon_versioning=no - case `$LD -v 2>/dev/null` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 - *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... - *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... - *\ 2.11.*) ;; # other 2.11 versions - *) supports_anon_versioning=yes ;; - esac - - # See if GNU ld supports shared libraries. - case $host_os in - aix[[3-9]]*) - # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <&2 - -*** 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 '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' - - if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - interix[[3-9]]*) - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. - # Instead, shared libraries are loaded at an image base (0x10000000 by - # default) and relocated if they conflict, which is a slow very memory - # consuming and fragmenting process. To avoid this, we pick a random, - # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link - # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - ;; - - gnu* | linux* | k*bsd*-gnu) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - tmp_addflag= - case $cc_basename,$host_cpu in - pgcc*) # Portland Group C compiler - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag' - ;; - pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_addflag=' $pic_flag -Mnomain' ;; - ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 - tmp_addflag=' -i_dynamic' ;; - efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 - tmp_addflag=' -i_dynamic -nofor_main' ;; - ifc* | ifort*) # Intel Fortran compiler - tmp_addflag=' -nofor_main' ;; - esac - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) # Sun C 5.9 - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' - tmp_sharedflag='-G' ;; - *Sun\ F*) # Sun Fortran 8.3 - tmp_sharedflag='-G' ;; - *) - tmp_sharedflag='-shared' ;; - esac - _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - - if test $supports_anon_versioning = yes; then - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - $echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' - fi - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - netbsd*) - if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' - wlarc= - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' - fi - ;; - - solaris*) - 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 - ;; - - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) - case `$LD -v 2>&1` in - *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - cat <<_LT_EOF 1>&2 - -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not -*** reliably create shared libraries on SCO systems. Therefore, libtool -*** is disabling shared libraries support. We urge you to upgrade GNU -*** binutils to release 2.16.91.0.3 or newer. Another option is to modify -*** your PATH or compiler configuration so that the native linker is -*** used, and then restart. - -_LT_EOF - ;; - *) - if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - esac - ;; - - sunos4*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' - wlarc= - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - *) - if $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)" = no; then - runpath_var= - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= - fi - else - # PORTME fill in a description of your system's linker (not GNU ld) - case $host_os in - aix3*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_AC_TAGVAR(always_export_symbols, $1)=yes - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' - # Note: this linker hardcodes the directories in LIBPATH if there - # are no directories specified by -L. - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then - # Neither direct hardcoding nor static linking is supported with a - # broken collect2. - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - fi - ;; - - aix[[4-9]]*) - if test "$host_cpu" = ia64; then - # On IA64, the linker does run time linking by default, so we don't - # have to do anything special. - aix_use_runtimelinking=no - exp_sym_flag='-Bexport' - no_entry_flag="" - else - # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - if $NM -V 2>&1 | grep 'GNU' > /dev/null; then - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - else - _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' - fi - aix_use_runtimelinking=no - - # 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_AC_TAGVAR(archive_cmds, $1)='' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - - if test "$GCC" = yes; then - case $host_os in aix4.[[012]]|aix4.[[012]].*) - # We only want to do this on AIX 4.2 and lower, the check - # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` - if test -f "$collect2name" && \ - strings "$collect2name" | grep resolve_lib_name >/dev/null - then - # We have reworked collect2 - : - else - # We have old collect2 - _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported - # It fails to find uninstalled libraries when the uninstalled - # path is not listed in the libpath. Setting hardcode_minus_L - # to unsupported forces relinking - _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= - fi - ;; - esac - shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' - fi - else - # not using gcc - if test "$host_cpu" = ia64; then - # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release - # chokes on -Wl,-G. The following line is correct: - shared_flag='-G' - else - 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 '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" - else - if test "$host_cpu" = ia64; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' - _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" - else - # Determine the default libpath from the value encoded in an empty executable. - _LT_AC_SYS_LIBPATH_AIX - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - # Warning - without using the other run time loading flags, - # -berok will link without error, but may produce a broken library. - _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - # Exported symbols can be pulled into shared objects from archives - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' - fi - fi - ;; - - 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 - ;; - - bsdi[[45]]*) - _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' - _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' - _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes - ;; - - darwin* | rhapsody*) - case $host_os in - rhapsody* | darwin1.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' - ;; - *) # Darwin 1.3 on - if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - else - case ${MACOSX_DEPLOYMENT_TARGET} in - 10.[[012]]) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' - ;; - 10.*) - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' - ;; - esac - fi - ;; - esac - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_automatic, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - if test "$GCC" = yes ; then - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" - _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" - else - case $cc_basename in - xlc*) - output_verbose_link_cmd='echo' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' - _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' - # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' - ;; - *) - _LT_AC_TAGVAR(ld_shlibs, $1)=no - ;; - esac - fi - ;; - - 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* | dragonfly*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - - 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*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' - fi - if test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - _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 - fi - ;; - - hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - else - case $host_cpu in - hppa*64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - ;; - ia64*) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' - ;; - esac - fi - if test "$with_gnu_ld" = no; then - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: - - case $host_cpu in - hppa*64*|ia64*) - _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' - _LT_AC_TAGVAR(hardcode_direct, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - ;; - *) - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - - # 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*) - 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*) - if test -f /usr/libexec/ld.so; then - _LT_AC_TAGVAR(hardcode_direct, $1)=yes - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac - fi - else - _LT_AC_TAGVAR(ld_shlibs, $1)=no - fi - ;; - - 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 ${output_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)=: - ;; - - solaris*) - _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' - else - wlarc='' - _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' - fi - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - case $host_os in - solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; - *) - # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', - # but is careful enough not to reorder. - # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' - else - _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' - fi - ;; - esac - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - ;; - - 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*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not - # link with -lc, and that would cause any symbols used from libc to - # always be unresolved, which means just about no library would - # ever link correctly. If we're not using GNU ld we use -z text - # though, which does catch some bad symbols but isn't as heavy-handed - # as -z defs. - _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' - _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' - _LT_AC_TAGVAR(link_all_deplibs, $1)=yes - _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' - runpath_var='LD_RUN_PATH' - - if test "$GCC" = yes; then - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - else - _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' - fi - ;; - - 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 - -# -# 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* - echo "$lt_simple_compile_test_code" > conftest.$ac_ext - - if AC_TRY_EVAL(ac_compile) 2>conftest.err; then - soname=conftest - lib=conftest - libobjs=conftest.$ac_objext - deplibs= - wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) - pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) - compiler_flags=-v - linker_flags=-v - verstring= - output_objdir=. - libname=conftest - lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) - _LT_AC_TAGVAR(allow_undefined_flag, $1)= - if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) - then - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no - else - _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes - fi - _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag - else - cat conftest.err 1>&5 - fi - $rm conftest* - AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) - ;; - esac - fi - ;; -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) -]) - - -# Cheap backport of AS_EXECUTABLE_P and required macros -# from Autoconf 2.59; we should not use $as_executable_p directly. - -# _AS_TEST_PREPARE -# ---------------- -m4_ifndef([_AS_TEST_PREPARE], -[m4_defun([_AS_TEST_PREPARE], -[if test -x / >/dev/null 2>&1; then - as_executable_p='test -x' -else - as_executable_p='test -f' -fi -])])# _AS_TEST_PREPARE - -# AS_EXECUTABLE_P -# --------------- -# Check whether a file is executable. -m4_ifndef([AS_EXECUTABLE_P], -[m4_defun([AS_EXECUTABLE_P], -[AS_REQUIRE([_AS_TEST_PREPARE])dnl -$as_executable_p $1[]dnl -])])# AS_EXECUTABLE_P - -# NOTE: This macro has been submitted for inclusion into # -# GNU Autoconf as AC_PROG_SED. When it is available in # -# a released version of Autoconf we should remove this # -# macro and use it instead. # -# LT_AC_PROG_SED -# -------------- -# Check for a fully-functional sed program, that truncates -# as few characters as possible. Prefer GNU sed if found. -AC_DEFUN([LT_AC_PROG_SED], -[AC_MSG_CHECKING([for a sed that does not truncate output]) -AC_CACHE_VAL(lt_cv_path_SED, -[# Loop through the user's path and test for sed and gsed. -# Then use that list of sed's as ones to test for truncation. -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for lt_ac_prog in sed gsed; do - for ac_exec_ext in '' $ac_executable_extensions; do - if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then - lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" - fi - done - done -done -IFS=$as_save_IFS -lt_ac_max=0 -lt_ac_count=0 -# Add /usr/xpg4/bin/sed as it is typically found on Solaris -# along with /bin/sed that truncates output. -for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue - cat /dev/null > conftest.in - lt_ac_count=0 - echo $ECHO_N "0123456789$ECHO_C" >conftest.in - # Check for GNU sed and select it if it is found. - if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then - lt_cv_path_SED=$lt_ac_sed - break - fi - while true; do - cat conftest.in conftest.in >conftest.tmp - mv conftest.tmp conftest.in - cp conftest.in conftest.nl - echo >>conftest.nl - $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break - cmp -s conftest.out conftest.nl || break - # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break - lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then - lt_ac_max=$lt_ac_count - lt_cv_path_SED=$lt_ac_sed - fi - done -done -]) -SED=$lt_cv_path_SED -AC_SUBST([SED]) -AC_MSG_RESULT([$SED]) -]) - # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- +# serial 1 (pkg-config-0.24) # # Copyright © 2004 Scott James Remnant . # @@ -6898,7 +260,10 @@ AC_MSG_RESULT([$SED]) AC_DEFUN([PKG_PROG_PKG_CONFIG], [m4_pattern_forbid([^_?PKG_[A-Z_]+$]) m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) -AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl +AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) +AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) +AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) + if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) fi @@ -6911,7 +276,6 @@ if test -n "$PKG_CONFIG"; then AC_MSG_RESULT([no]) PKG_CONFIG="" fi - fi[]dnl ])# PKG_PROG_PKG_CONFIG @@ -6920,21 +284,20 @@ fi[]dnl # Check to see whether a particular set of modules exists. Similar # to PKG_CHECK_MODULES(), but does not set variables or print errors. # -# -# Similar to PKG_CHECK_MODULES, make sure that the first instance of -# this or PKG_CHECK_MODULES is called, or make sure to call -# PKG_CHECK_EXISTS manually +# Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) +# only at the first occurence in configure.ac, so if the first place +# it's called might be skipped (such as if it is within an "if", you +# have to call PKG_CHECK_EXISTS manually # -------------------------------------------------------------- AC_DEFUN([PKG_CHECK_EXISTS], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl if test -n "$PKG_CONFIG" && \ AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then - m4_ifval([$2], [$2], [:]) + m4_default([$2], [:]) m4_ifvaln([$3], [else $3])dnl fi]) - # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) # --------------------------------------------- m4_define([_PKG_CONFIG], @@ -6987,6 +350,7 @@ and $1[]_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details.]) if test $pkg_failed = yes; then + AC_MSG_RESULT([no]) _PKG_SHORT_ERRORS_SUPPORTED if test $_pkg_short_errors_supported = yes; then $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` @@ -6996,7 +360,7 @@ if test $pkg_failed = yes; then # Put the nasty error message in config.log where it belongs echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD - ifelse([$4], , [AC_MSG_ERROR(dnl + m4_default([$4], [AC_MSG_ERROR( [Package requirements ($2) were not met: $$1_PKG_ERRORS @@ -7004,25 +368,24 @@ $$1_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. -_PKG_TEXT -])], - [AC_MSG_RESULT([no]) - $4]) +_PKG_TEXT]) + ]) elif test $pkg_failed = untried; then - ifelse([$4], , [AC_MSG_FAILURE(dnl + AC_MSG_RESULT([no]) + m4_default([$4], [AC_MSG_FAILURE( [The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. _PKG_TEXT -To get pkg-config, see .])], - [$4]) +To get pkg-config, see .]) + ]) else $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS $1[]_LIBS=$pkg_cv_[]$1[]_LIBS AC_MSG_RESULT([yes]) - ifelse([$3], , :, [$3]) + $3 fi[]dnl ])# PKG_CHECK_MODULES @@ -7041,7 +404,7 @@ AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version='1.11' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. -m4_if([$1], [1.11], [], +m4_if([$1], [1.11.1], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) @@ -7057,7 +420,7 @@ m4_define([_AM_AUTOCONF_VERSION], []) # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], -[AM_AUTOMAKE_VERSION([1.11])dnl +[AM_AUTOMAKE_VERSION([1.11.1])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) diff --git a/amandad-src/Makefile.in b/amandad-src/Makefile.in index d3e941c..7f309a0 100644 --- a/amandad-src/Makefile.in +++ b/amandad-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -393,6 +393,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -825,6 +826,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -874,6 +876,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -882,6 +885,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -889,6 +893,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1033,6 +1039,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1066,6 +1073,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1108,7 +1116,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/amandad-src/amandad.c b/amandad-src/amandad.c index 0477434..e3f11a0 100644 --- a/amandad-src/amandad.c +++ b/amandad-src/amandad.c @@ -244,6 +244,11 @@ main( /*NOTREACHED*/ } + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("amandad-%s\n", VERSION); + return (0); + } + /* Don't die when child closes pipe */ signal(SIGPIPE, SIG_IGN); diff --git a/amar-src/Makefile.in b/amar-src/Makefile.in index 6df5c0a..1bea528 100644 --- a/amar-src/Makefile.in +++ b/amar-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -401,6 +401,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -833,6 +834,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -882,6 +884,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -890,6 +893,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -897,6 +901,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1041,6 +1047,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1074,6 +1081,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1116,7 +1124,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/amplot/Makefile.in b/amplot/Makefile.in index e9c34f4..9fd64b9 100644 --- a/amplot/Makefile.in +++ b/amplot/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -435,6 +435,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -867,6 +868,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -916,6 +918,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -924,6 +927,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -931,6 +935,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1075,6 +1081,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1108,6 +1115,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1150,7 +1158,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/application-src/Makefile.in b/application-src/Makefile.in index fdbf7f3..c73b974 100644 --- a/application-src/Makefile.in +++ b/application-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -472,6 +472,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -904,6 +905,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -953,6 +955,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -961,6 +964,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -968,6 +972,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1112,6 +1118,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1145,6 +1152,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1187,7 +1195,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/application-src/amgtar.c b/application-src/amgtar.c index fd13a6c..7cf28a1 100644 --- a/application-src/amgtar.c +++ b/application-src/amgtar.c @@ -296,6 +296,7 @@ main( #else gnutar_path = NULL; #endif + gnutar_listdir = NULL; gnutar_directory = NULL; gnutar_onefilesystem = 1; gnutar_atimepreserve = 1; @@ -357,6 +358,7 @@ main( /* parse argument */ command = argv[1]; + gnutar_listdir = stralloc(getconf_str(CNF_GNUTAR_LIST_DIR)); argument.config = NULL; argument.host = NULL; argument.message = 0; @@ -369,6 +371,7 @@ main( argument.exclude_list_glob = NULL; argument.verbose = 0; init_dle(&argument.dle); + argument.dle.record = 0; while (1) { int option_index = 0; @@ -546,7 +549,6 @@ main( } } - gnutar_listdir = getconf_str(CNF_GNUTAR_LIST_DIR); if (strlen(gnutar_listdir) == 0) gnutar_listdir = NULL; @@ -636,11 +638,37 @@ static void amgtar_selfcheck( application_argument_t *argument) { + if (argument->dle.disk) { + char *qdisk = quote_string(argument->dle.disk); + fprintf(stdout, "OK disk %s\n", qdisk); + amfree(qdisk); + } + + printf("OK amgtar version %s\n", VERSION); amgtar_build_exinclude(&argument->dle, 1, NULL, NULL, NULL, NULL); printf("OK amgtar\n"); if (gnutar_path) { - check_file(gnutar_path, X_OK); + if (check_file(gnutar_path, X_OK)) { + char *gtar_version; + GPtrArray *argv_ptr = g_ptr_array_new(); + + g_ptr_array_add(argv_ptr, gnutar_path); + g_ptr_array_add(argv_ptr, "--version"); + g_ptr_array_add(argv_ptr, NULL); + + gtar_version = get_first_line(argv_ptr); + if (gtar_version) { + char *gv; + for (gv = gtar_version; *gv && !g_ascii_isdigit(*gv); gv++); + printf("OK amgtar gtar-version %s\n", gv); + } else { + printf(_("ERROR [Can't get %s version]\n"), gnutar_path); + } + + g_ptr_array_free(argv_ptr, TRUE); + amfree(gtar_version); + } } else { printf(_("ERROR [GNUTAR program not available]\n")); } @@ -654,11 +682,6 @@ amgtar_selfcheck( printf(_("ERROR [No GNUTAR-LISTDIR]\n")); } - if (argument->dle.disk) { - char *qdisk = quote_string(argument->dle.disk); - fprintf(stdout, "OK %s\n", qdisk); - amfree(qdisk); - } if (gnutar_directory) { check_dir(gnutar_directory, R_OK); } else if (argument->dle.device) { @@ -1022,16 +1045,25 @@ amgtar_backup( } if (!errmsg && incrname && strlen(incrname) > 4) { - char *nodotnew; - nodotnew = stralloc(incrname); - nodotnew[strlen(nodotnew)-4] = '\0'; - if (rename(incrname, nodotnew)) { - dbprintf(_("%s: warning [renaming %s to %s: %s]\n"), - get_pname(), incrname, nodotnew, strerror(errno)); - g_fprintf(mesgstream, _("? warning [renaming %s to %s: %s]\n"), - incrname, nodotnew, strerror(errno)); + if (argument->dle.record) { + char *nodotnew; + nodotnew = stralloc(incrname); + nodotnew[strlen(nodotnew)-4] = '\0'; + if (rename(incrname, nodotnew)) { + dbprintf(_("%s: warning [renaming %s to %s: %s]\n"), + get_pname(), incrname, nodotnew, strerror(errno)); + g_fprintf(mesgstream, _("? warning [renaming %s to %s: %s]\n"), + incrname, nodotnew, strerror(errno)); + } + amfree(nodotnew); + } else { + if (unlink(incrname) == -1) { + dbprintf(_("%s: warning [unlink %s: %s]\n"), + get_pname(), incrname, strerror(errno)); + g_fprintf(mesgstream, _("? warning [unlink %s: %s]\n"), + incrname, strerror(errno)); + } } - amfree(nodotnew); } dbprintf("sendbackup: size %lld\n", (long long)dump_size); diff --git a/application-src/ampgsql.pl b/application-src/ampgsql.pl index 5c930ed..0150af1 100644 --- a/application-src/ampgsql.pl +++ b/application-src/ampgsql.pl @@ -38,7 +38,7 @@ use Amanda::Constants; use Amanda::Config qw( :init :getconf config_dir_relative string_to_boolean ); use Amanda::Debug qw( :logging ); use Amanda::Paths; -use Amanda::Util qw( :constants :encoding ); +use Amanda::Util qw( :constants :encoding quote_string ); use Amanda::MainLoop qw( :GIOCondition ); my $_DATA_DIR_TAR = "data_dir.tar"; @@ -90,6 +90,7 @@ sub new { $self->{'props'}->{$pname} = $conf_props->{$pname}->{'values'}->[0]; } } + # check for properties like 'foo-pg-host' where the diskname is 'foo' if ($self->{'args'}->{'disk'}) { foreach my $pname (@PROP_NAMES) { @@ -102,6 +103,16 @@ sub new { } } + # overwrite with dumptype properties if they are set. + foreach my $pname (@PROP_NAMES) { + my $pdumpname = $pname; + $pdumpname =~ s/^pg-//g; + $self->{'props'}->{$pname} = $self->{'args'}->{$pdumpname} + if defined $self->{'args'}->{$pdumpname}; +debug("prop $pname set from dumpname $pdumpname: $self->{'args'}->{$pdumpname}") +if defined $self->{'args'}->{$pdumpname}; + } + unless ($self->{'props'}->{'psql-path'}) { foreach my $pre (split(/:/, $ENV{PATH})) { my $psql = "$pre/psql"; @@ -128,6 +139,10 @@ sub new { } } + if (!exists $self->{'props'}->{'pg-datadir'}) { + $self->{'props'}->{'pg-datadir'} = $self->{'args'}->{'device'}; + } + return $self; } @@ -207,7 +222,8 @@ sub _run_psql_command { push @cmd, "-p", $self->{'props'}->{'pg-port'} if ($self->{'props'}->{'pg-port'}); push @cmd, "-U", $self->{'props'}->{'pg-user'} if ($self->{'props'}->{'pg-user'}); - push @cmd, '--quiet', '--output', '/dev/null', '--command', $cmd, $self->{'props'}->{'pg-db'}; + push @cmd, '--quiet', '--output', '/dev/null' if (!($cmd =~ /pg_xlogfile_name_offset/)); + push @cmd, '--command', $cmd, $self->{'props'}->{'pg-db'}; debug("running " . join(" ", @cmd)); my ($wtr, $rdr); @@ -229,7 +245,17 @@ sub _run_psql_command { return; } chomp $line; + return if $line =~ /^\s*$/; debug("psql stdout: $line"); + if ($cmd =~ /pg_xlogfile_name_offset/) { + return if $line =~ /file_name/; + return if $line =~ /------/; + return if $line =~ /\(1 row\)/; + if ($line =~ /^ ($_WAL_FILE_PAT)/) { + $self->{'switch_xlog_filename'} = $1; + return; + } + } if ($line =~ /NOTICE: pg_stop_backup complete, all required WAL segments have been archived/) { } else { $self->print_to_server("psql stdout: $line", @@ -278,6 +304,11 @@ sub command_selfcheck { exit(1); }; + $self->print_to_server("disk " . quote_string($self->{args}->{disk})); + + $self->print_to_server("ampgsql version " . $Amanda::Constants::VERSION, + $Amanda::Script_App::GOOD); + for my $k (keys %{$self->{'args'}}) { print "OK application property: $k = $self->{'args'}->{$k}\n"; } @@ -375,6 +406,20 @@ sub command_selfcheck { $try_connect = 0; } + if ($try_connect) { + my @pv = `$self->{'props'}->{'psql-path'} --version`; + if ($? >> 8 == 0) { + $pv[0] =~ /^[^0-9]*([0-9.]*)[^0-9]*$/; + my $pv = $1; + $self->print_to_server("ampgsql psql-version $pv", + $Amanda::Script_App::GOOD); + } else { + $self->print_to_server( + "[Can't get " . $self->{'props'}->{'psql-path'} . " version]\n", + $Amanda::Script_App::ERROR); + } + } + if ($try_connect) { $try_connect &&= _check("Connecting to database server", "succeeded", "failed", @@ -393,6 +438,20 @@ sub command_selfcheck { sub {my ($start, $end) = _get_backup_info($self, $label); $start and $end}); } } + + { + my @gv = `$self->{'args'}->{'gnutar-path'} --version`; + if ($? >> 8 == 0) { + $gv[0] =~ /^[^0-9]*([0-9.]*)[^0-9]*$/; + my $gv = $1; + $self->print_to_server("ampgsql gtar-version $gv", + $Amanda::Script_App::GOOD); + } else { + $self->print_to_server( + "[Can't get " . $self->{'props'}->{'gnutar-path'} . " version]\n", + $Amanda::Script_App::ERROR); + } + } } } @@ -400,7 +459,9 @@ sub _state_filename { my ($self, $level) = @_; my @parts = ("ampgsql", hexencode($self->{'args'}->{'host'}), hexencode($self->{'args'}->{'disk'}), $level); - $self->{'args'}->{'statedir'} . '/' . join("-", @parts); + my $statefile = $self->{'args'}->{'statedir'} . '/' . join("-", @parts); + debug("statefile: $statefile"); + return $statefile; } sub _write_state_file { @@ -443,6 +504,15 @@ sub _get_prev_state { $end_wal; } +sub _make_dummy_dir_base { + my ($self) = @_; + + my $dummydir = "$self->{'args'}->{'tmpdir'}/ampgsql-dummy-$$"; + mkpath("$dummydir/$_ARCHIVE_DIR_RESTORE"); + + return $dummydir; +} + sub _make_dummy_dir { my ($self) = @_; @@ -457,9 +527,10 @@ sub _make_dummy_dir { sub _run_tar_totals { my ($self, @other_args) = @_; - my @cmd = ($self->{'runtar'}, $self->{'args'}->{'config'}, + my @cmd; + @cmd = ($self->{'runtar'}, $self->{'args'}->{'config'}, $Amanda::Constants::GNUTAR, '--create', '--totals', @other_args); - debug("running " . join(" ", @cmd)); + debug("running: " . join(" ", @cmd)); local (*TAR_IN, *TAR_OUT, *TAR_ERR); open TAR_OUT, ">&", $self->{'out_h'}; @@ -556,6 +627,7 @@ sub _get_backup_info { $lab = $1; } } + close TAROUT; if ($lab and $lab eq $label) { $start_wal = $start; $end_wal = $end; @@ -571,7 +643,12 @@ sub _get_backup_info { debug("$bfile named WALs $start_wal .. $end_wal"); # try to cleanup a bit, although this may fail and that's ok - unlink("$self->{'props'}->{'pg-archivedir'}/$bfile"); + my $filename = "$self->{'props'}->{'pg-archivedir'}/$bfile"; + if (unlink($filename) == 0) { + debug("Failed to unlink '$filename': $!"); + $self->print_to_server("Failed to unlink '$filename': $!", + $Amanda::Script_App::ERROR); + } last; } sleep(1); @@ -632,10 +709,10 @@ sub _wait_for_wal { my $stoptime = time() + $maxwait; while ($maxwait == 0 || time < $stoptime || $count++ < 4) { return if -f "$archive_dir/$wal"; - + # for versions 8.0 or 8.1, the only way to "force" a WAL archive is to write # garbage to the database. - if ($pg_version < 802000) { + if ($pg_version < 80200) { $self->_write_garbage_to_db(); } else { sleep(1); @@ -651,28 +728,10 @@ sub _base_backup { debug("running _base_backup"); my $label = "$self->{'label-prefix'}-" . time(); - my $tmp = "$self->{'args'}->{'tmpdir'}/$label"; -d $self->{'props'}->{'pg-archivedir'} or die("WAL file archive directory does not exist (or is not a directory)"); - # try to protect what we create - my $old_umask = umask(); - umask(077); - - my $cleanup = sub { - umask($old_umask); - eval {rmtree($tmp); 1} - }; - my $old_die = $self->{'die_cb'}; - $self->{'die_cb'} = sub { - my $msg = shift @_; - $cleanup->(); - $old_die->($msg); - }; - eval {rmtree($tmp,{'keep_root' => 1}); 1} or $self->{'die_cb'}->("Failed to clear tmp directory: $@"); - eval {mkpath($tmp, 0, 0700); 1} or $self->{'die_cb'}->("Failed to create tmp directory: $@"); - _run_psql_command($self, "SELECT pg_start_backup('$label')") or $self->{'die_cb'}->("Failed to call pg_start_backup"); @@ -687,10 +746,11 @@ sub _base_backup { } $old_die_cb->($msg); }; - _run_tar_totals($self, '--file', "$tmp/$_DATA_DIR_TAR", + my $size = _run_tar_totals($self, '--file', "-", '--directory', $self->{'props'}->{'pg-datadir'}, '--exclude', 'postmaster.pid', '--exclude', 'pg_xlog/*', # contains WAL files; will be handled below + '--transform', "s,^,$_DATA_DIR_RESTORE/,S", "."); $self->{'die_cb'} = $old_die_cb; @@ -723,22 +783,19 @@ sub _base_backup { $adir->close(); if (@wal_files) { - _run_tar_totals($self, '--file', "$tmp/$_ARCHIVE_DIR_TAR", - '--directory', $self->{'props'}->{'pg-archivedir'}, @wal_files); + $size += _run_tar_totals($self, '--file', "-", + '--directory', $self->{'props'}->{'pg-archivedir'}, + '--transform', "s,^,$_ARCHIVE_DIR_RESTORE/,S", + @wal_files); } else { - my $dummydir = $self->_make_dummy_dir(); + my $dummydir = $self->_make_dummy_dir_base(); $self->{'done_cb'}->(_run_tar_totals($self, '--file', '-', - '--directory', $dummydir, "empty-incremental")); + '--directory', $dummydir, "$_ARCHIVE_DIR_RESTORE")); rmtree($dummydir); } - # create the final tar file - my $size = _run_tar_totals($self, '--directory', $tmp, '--file', '-', - $_ARCHIVE_DIR_TAR, $_DATA_DIR_TAR); - $self->{'state_cb'}->($self, $end_wal); - $cleanup->(); $self->{'done_cb'}->($size); } @@ -747,6 +804,13 @@ sub _incr_backup { debug("running _incr_backup"); + if ($self->{'action'} eq 'backup') { + _run_psql_command($self, "SELECT file_name from pg_xlogfile_name_offset(pg_switch_xlog())"); + if (defined($self->{'switch_xlog_filename'})) { + $self->_wait_for_wal($self->{'switch_xlog_filename'}); + } + } + my $end_wal = _get_prev_state($self); if ($end_wal) { debug("previously ended at: $end_wal"); @@ -820,7 +884,11 @@ sub command_backup { $self->{'unlink_cb'} = sub { my $filename = shift @_; debug("unlinking WAL file $filename"); - unlink($filename); + if (unlink($filename) == 0) { + debug("Failed to unlink '$filename': $!"); + $self->print_to_server("Failed to unlink '$filename': $!", + $Amanda::Script_App::ERROR); + } }; } else { $self->{'unlink_cb'} = sub { @@ -836,55 +904,82 @@ sub command_backup { } sub command_restore { - my $self = shift; + my $self = shift; - chdir(Amanda::Util::get_original_cwd()); - if (defined $self->{'args'}->{directory}) { - if (!-d $self->{'args'}->{directory}) { - $self->print_to_server_and_die("Directory $self->{directory}: $!", - $Amanda::Script_App::ERROR); - } - if (!-w $self->{'args'}->{directory}) { - $self->print_to_server_and_die("Directory $self->{directory}: $!", - $Amanda::Script_App::ERROR); - } - chdir($self->{'args'}->{directory}); - } - my $cur_dir = POSIX::getcwd(); + chdir(Amanda::Util::get_original_cwd()); + if (defined $self->{'args'}->{directory}) { + if (!-d $self->{'args'}->{directory}) { + $self->print_to_server_and_die("Directory $self->{directory}: $!", + $Amanda::Script_App::ERROR); + } + if (!-w $self->{'args'}->{directory}) { + $self->print_to_server_and_die("Directory $self->{directory}: $!", + $Amanda::Script_App::ERROR); + } + chdir($self->{'args'}->{directory}); + } + my $cur_dir = POSIX::getcwd(); - if (!-d $_ARCHIVE_DIR_RESTORE) { - mkdir($_ARCHIVE_DIR_RESTORE) or die("could not create archive WAL directory: $!"); - } - my $status; - if ($self->{'args'}->{'level'} > 0) { - debug("extracting incremental backup to $cur_dir/$_ARCHIVE_DIR_RESTORE"); - $status = system($self->{'args'}->{'gnutar-path'}, '--extract', - '--file', '-', - '--ignore-zeros', - '--exclude', 'empty-incremental', - '--directory', $_ARCHIVE_DIR_RESTORE) >> 8; - (0 == $status) or die("Failed to extract level $self->{'args'}->{'level'} backup (exit status: $status)"); - } else { - debug("extracting base of full backup"); - if (!-d $_DATA_DIR_RESTORE) { - mkdir($_DATA_DIR_RESTORE) or die("could not create archive WAL directory: $!"); - } - $status = system($self->{'args'}->{'gnutar-path'}, '--extract', '--file', '-',) >> 8; - (0 == $status) or die("Failed to extract base backup (exit status: $status)"); - - debug("extracting archive dir to $cur_dir/$_ARCHIVE_DIR_RESTORE"); - $status = system($self->{'args'}->{'gnutar-path'}, '--extract', - '--exclude', 'empty-incremental', - '--file', $_ARCHIVE_DIR_TAR, '--directory', $_ARCHIVE_DIR_RESTORE) >> 8; - (0 == $status) or die("Failed to extract archived WAL files from base backup (exit status: $status)"); - unlink($_ARCHIVE_DIR_TAR); - - debug("extracting data dir to $cur_dir/$_DATA_DIR_RESTORE"); - $status = system($self->{'args'}->{'gnutar-path'}, '--extract', - '--file', $_DATA_DIR_TAR, '--directory', $_DATA_DIR_RESTORE) >> 8; - (0 == $status) or die("Failed to extract data directory from base backup (exit status: $status)"); - unlink($_DATA_DIR_TAR); - } + if (!-d $_ARCHIVE_DIR_RESTORE) { + mkdir($_ARCHIVE_DIR_RESTORE) or die("could not create archive WAL directory: $!"); + } + my $status; + if ($self->{'args'}->{'level'} > 0) { + debug("extracting incremental backup to $cur_dir/$_ARCHIVE_DIR_RESTORE"); + $status = system($self->{'args'}->{'gnutar-path'}, + '--extract', + '--file', '-', + '--ignore-zeros', + '--exclude', 'empty-incremental', + '--directory', $_ARCHIVE_DIR_RESTORE) >> 8; + (0 == $status) or die("Failed to extract level $self->{'args'}->{'level'} backup (exit status: $status)"); + } else { + debug("extracting base of full backup to $cur_dir/$_DATA_DIR_RESTORE"); + debug("extracting archive dir to $cur_dir/$_ARCHIVE_DIR_RESTORE"); + if (!-d $_DATA_DIR_RESTORE) { + mkdir($_DATA_DIR_RESTORE) or die("could not create archive WAL directory: $!"); + } + my @cmd = ($self->{'args'}->{'gnutar-path'}, '--extract', + '--file', '-', + '--ignore-zero', + '--transform', "s,^DATA/,$_DATA_DIR_RESTORE/,S", + '--transform', "s,^WAL/,$_ARCHIVE_DIR_RESTORE/,S"); + debug("run: " . join ' ',@cmd); + $status = system(@cmd) >> 8; + (0 == $status) or die("Failed to extract base backup (exit status: $status)"); + + if (-f $_ARCHIVE_DIR_TAR) { + debug("extracting archive dir to $cur_dir/$_ARCHIVE_DIR_RESTORE"); + my @cmd = ($self->{'args'}->{'gnutar-path'}, '--extract', + '--exclude', 'empty-incremental', + '--file', $_ARCHIVE_DIR_TAR, '--directory', + $_ARCHIVE_DIR_RESTORE); + debug("run: " . join ' ',@cmd); + $status = system(@cmd) >> 8; + (0 == $status) or die("Failed to extract archived WAL files from base backup (exit status: $status)"); + if (unlink($_ARCHIVE_DIR_TAR) == 0) { + debug("Failed to unlink '$_ARCHIVE_DIR_TAR': $!"); + $self->print_to_server( + "Failed to unlink '$_ARCHIVE_DIR_TAR': $!", + $Amanda::Script_App::ERROR); + } + } + + if (-f $_DATA_DIR_TAR) { + debug("extracting data dir to $cur_dir/$_DATA_DIR_RESTORE"); + my @cmd = ($self->{'args'}->{'gnutar-path'}, '--extract', + '--file', $_DATA_DIR_TAR, + '--directory', $_DATA_DIR_RESTORE); + debug("run: " . join ' ',@cmd); + $status = system(@cmd) >> 8; + (0 == $status) or die("Failed to extract data directory from base backup (exit status: $status)"); + if (unlink($_DATA_DIR_TAR) == 0) { + debug("Failed to unlink '$_DATA_DIR_TAR': $!"); + $self->print_to_server("Failed to unlink '$_DATA_DIR_TAR': $!", + $Amanda::Script_App::ERROR); + } + } + } } sub command_validate { @@ -926,9 +1021,11 @@ EOF } my $opts = {}; +my $opt_version; GetOptions( $opts, + 'version' => \$opt_version, 'config=s', 'host=s', 'disk=s', @@ -946,8 +1043,22 @@ GetOptions( 'statedir=s', 'tmpdir=s', 'gnutar-path=s', + 'cleanupwal=s', + 'archivedir=s', + 'db=s', + 'host=s', + 'max-wal-wait=s', + 'passfile=s', + 'port=s', + 'user=s', + 'psql-path=s' ) or usage(); +if (defined $opt_version) { + print "ampgsql-" . $Amanda::Constants::VERSION , "\n"; + exit(0); +} + my $application = Amanda::Application::ampgsql->new($opts); $application->do($ARGV[0]); diff --git a/application-src/amraw.pl b/application-src/amraw.pl index cfd7e42..5502657 100644 --- a/application-src/amraw.pl +++ b/application-src/amraw.pl @@ -30,7 +30,7 @@ use Symbol; use IO::Handle; use Amanda::Constants; use Amanda::Debug qw( :logging ); -use Amanda::Util; +use Amanda::Util qw( quote_string ); sub new { my $class = shift; @@ -83,8 +83,16 @@ sub command_support { sub command_selfcheck { my $self = shift; - print "OK " . $self->{disk} . "\n"; - print "OK " . $self->{device} . "\n"; + $self->print_to_server("disk " . quote_string($self->{disk}), + $Amanda::Script_App::GOOD) + if defined $self->{disk}; + + $self->print_to_server("amraw version " . $Amanda::Constants::VERSION, + $Amanda::Script_App::GOOD); + + $self->print_to_server(quote_string($self->{device}), + $Amanda::Script_App::GOOD) + if defined $self->{device}; if (! -r $self->{device}) { $self->print_to_server("$self->{device} can't be read", diff --git a/application-src/amsamba.pl b/application-src/amsamba.pl index f05ac08..d1f0bda 100644 --- a/application-src/amsamba.pl +++ b/application-src/amsamba.pl @@ -331,6 +331,10 @@ sub command_support { sub command_selfcheck { my $self = shift; + $self->print_to_server("disk " . quote_string($self->{disk})); + + $self->print_to_server("amsamba version " . $Amanda::Constants::VERSION, + $Amanda::Script_App::GOOD); #check binary if (!defined($self->{smbclient}) || $self->{smbclient} eq "") { $self->print_to_server( @@ -344,7 +348,20 @@ sub command_selfcheck { elsif (! -x $self->{smbclient}) { $self->print_to_server("$self->{smbclient} is not executable", $Amanda::Script_App::ERROR); + } else { + my @sv = `$self->{smbclient} --version`; + if ($? >> 8 == 0) { + $sv[0] =~ /^[^0-9]*(.*)$/; + my $sv = $1; + $self->print_to_server("amsamba smbclient-version $sv", + $Amanda::Script_App::GOOD); + } else { + $self->print_to_server( + "[Can't get " . $self->{smbclient} . " version]\n", + $Amanda::Script_App::ERROR); + } } + $self->print_to_server("$self->{smbclient}", $Amanda::Script_App::GOOD); if (!defined $self->{disk} || !defined $self->{device}) { @@ -355,7 +372,6 @@ sub command_selfcheck { $self->validate_inexclude(); print "OK " . $self->{share} . "\n"; - print "OK " . $self->{disk} . "\n"; print "OK " . $self->{device} . "\n"; print "OK " . $self->{directory} . "\n" if defined $self->{directory}; diff --git a/application-src/amstar.c b/application-src/amstar.c index c676b40..0959a16 100644 --- a/application-src/amstar.c +++ b/application-src/amstar.c @@ -246,6 +246,7 @@ main( argument.level = NULL; argument.command_options = NULL; init_dle(&argument.dle); + argument.dle.record = 0; opterr = 0; while (1) { @@ -325,6 +326,7 @@ main( case 22: argument.command_options = g_slist_append(argument.command_options, stralloc(optarg)); + break; case 23: if (optarg) argument.dle.exclude_file = append_sl(argument.dle.exclude_file, optarg); @@ -412,12 +414,15 @@ static void amstar_selfcheck( application_argument_t *argument) { - fprintf(stdout, "OK amstar\n"); if (argument->dle.disk) { char *qdisk = quote_string(argument->dle.disk); - fprintf(stdout, "OK %s\n", qdisk); + fprintf(stdout, "OK disk %s\n", qdisk); amfree(qdisk); } + + fprintf(stdout, "OK amstar version %s\n", VERSION); + fprintf(stdout, "OK amstar\n"); + if (argument->dle.device) { char *qdevice = quote_string(argument->dle.device); fprintf(stdout, "OK %s\n", qdevice); @@ -437,7 +442,29 @@ amstar_selfcheck( if (!star_path) { fprintf(stdout, "ERROR STAR-PATH not defined\n"); } else { - check_file(star_path, X_OK); + if (check_file(star_path, X_OK)) { + char *star_version; + GPtrArray *argv_ptr = g_ptr_array_new(); + + g_ptr_array_add(argv_ptr, star_path); + g_ptr_array_add(argv_ptr, "--version"); + g_ptr_array_add(argv_ptr, NULL); + + star_version = get_first_line(argv_ptr); + + if (star_version) { + char *sv, *sv1; + for (sv = star_version; *sv && !g_ascii_isdigit(*sv); sv++); + for (sv1 = sv; *sv1 && *sv1 != ' '; sv1++); + *sv1 = '\0'; + printf("OK amstar star-version %s\n", sv); + } else { + printf(_("ERROR [Can't get %s version]\n"), star_path); + } + g_ptr_array_free(argv_ptr, TRUE); + amfree(star_version); + + } } if (argument->calcsize) { @@ -995,10 +1022,6 @@ static GPtrArray *amstar_build_argv( g_ptr_array_add(argv_ptr, stralloc("-sparse")); g_ptr_array_add(argv_ptr, stralloc("-dodesc")); - for (copt = argument->command_options; copt != NULL; copt = copt->next) { - g_ptr_array_add(argv_ptr, stralloc((char *)copt->data)); - } - if (command == CMD_BACKUP && argument->dle.create_index) g_ptr_array_add(argv_ptr, stralloc("-v")); @@ -1050,6 +1073,14 @@ static GPtrArray *amstar_build_argv( } } + /* It is best to place command_options at the and of command line. + * For example '-find' option requires that it is the last option used. + * See: http://cdrecord.berlios.de/private/man/star/star.1.html + */ + for (copt = argument->command_options; copt != NULL; copt = copt->next) { + g_ptr_array_add(argv_ptr, stralloc((char *)copt->data)); + } + g_ptr_array_add(argv_ptr, stralloc(".")); g_ptr_array_add(argv_ptr, NULL); diff --git a/application-src/amsuntar.pl b/application-src/amsuntar.pl index ad32c16..bc2db31 100755 --- a/application-src/amsuntar.pl +++ b/application-src/amsuntar.pl @@ -35,7 +35,7 @@ use Amanda::Constants; use Amanda::Config qw( :init :getconf config_dir_relative ); use Amanda::Debug qw( :logging ); use Amanda::Paths; -use Amanda::Util qw( :constants ); +use Amanda::Util qw( :constants quote_string ); sub new { my $class = shift; @@ -144,6 +144,11 @@ sub command_support { sub command_selfcheck { my $self = shift; + $self->print_to_server("disk " . quote_string($self->{disk})); + + $self->print_to_server("amsuntar version " . $Amanda::Constants::VERSION, + $Amanda::Script_App::GOOD); + if (!-e $self->{suntar}) { $self->print_to_server_and_die( "application binary $self->{suntar} doesn't exist", @@ -157,7 +162,6 @@ sub command_selfcheck { if (!defined $self->{disk} || !defined $self->{device}) { return; } - print "OK " . $self->{disk} . "\n"; print "OK " . $self->{device} . "\n"; print "OK " . $self->{directory} . "\n" if defined $self->{directory}; $self->validate_inexclude(); diff --git a/application-src/amzfs-sendrecv.pl b/application-src/amzfs-sendrecv.pl index cd00993..1bbbb9c 100644 --- a/application-src/amzfs-sendrecv.pl +++ b/application-src/amzfs-sendrecv.pl @@ -33,7 +33,7 @@ use Amanda::Constants; use Amanda::Config qw( :init :getconf config_dir_relative ); use Amanda::Debug qw( :logging ); use Amanda::Paths; -use Amanda::Util qw( :constants ); +use Amanda::Util qw( :constants quote_string ); sub new { my $class = shift; @@ -102,6 +102,10 @@ sub command_support { sub command_selfcheck { my $self = shift; + $self->print_to_server("disk " . quote_string($self->{disk})); + + $self->print_to_server("amzfs-sendrecv version " . $Amanda::Constants::VERSION, + $Amanda::Script_App::GOOD); $self->zfs_set_value(); if (!defined $self->{device}) { @@ -111,7 +115,6 @@ sub command_selfcheck { if ($self->{error_status} == $Amanda::Script_App::GOOD) { $self->zfs_create_snapshot(); $self->zfs_destroy_snapshot(); - print "OK " . $self->{disk} . "\n"; print "OK " . $self->{device} . "\n"; } @@ -334,12 +337,18 @@ sub command_index_from_image { sub command_restore { my $self = shift; + my $current_snapshot; my $level = $self->{level}[0]; my $device = $self->{device}; - $device = $self->{directory} if defined $self->{directory}; - $device =~ s,^/,,; - my $current_snapshot = $self->zfs_build_snapshotname($device); - $self->{'snapshot'} = $self->zfs_build_snapshotname($device, $level); + if (defined $device) { + $device =~ s,^/,,; + $current_snapshot = $self->zfs_build_snapshotname($device); + $self->{'snapshot'} = $self->zfs_build_snapshotname($device, $level); + } + + my $directory = $device; + $directory = $self->{directory} if defined $self->{directory}; + $directory =~ s,^/,,; my @cmd = (); @@ -348,22 +357,81 @@ sub command_restore { } push @cmd, $self->{zfs_path}; push @cmd, "recv"; - push @cmd, $device; + push @cmd, $directory; debug("cmd:" . join(" ", @cmd)); system @cmd; - @cmd = (); - if ($self->{pfexec_cmd}) { - push @cmd, $self->{pfexec_cmd}; + my $snapshotname; + my $newsnapname; + if (defined $device) { + $snapshotname = "$directory\@$current_snapshot"; + $newsnapname = "$directory\@$self->{'snapshot'}"; + } else { + # find snapshot name + @cmd = (); + if ($self->{pfexec_cmd}) { + push @cmd, $self->{pfexec_cmd}; + } + push @cmd, $self->{zfs_path}; + push @cmd, "list"; + push @cmd, "-r"; + push @cmd, "-t"; + push @cmd, "snapshot"; + push @cmd, $directory; + debug("cmd:" . join(" ", @cmd)); + + my($wtr, $rdr, $err, $pid); + my($msg, $errmsg); + $err = Symbol::gensym; + $pid = open3($wtr, $rdr, $err, @cmd); + close $wtr; + while ($msg = <$rdr>) { + next if $msg =~ /^NAME/; + my ($name, $used, $avail) = split(/ +/, $msg); + if ($name =~ /-current$/) { + $snapshotname = $name; + last; + } + } + $errmsg = <$err>; + waitpid $pid, 0; + close $rdr; + close $err; + + if (defined $snapshotname and defined($level)) { + $newsnapname = $snapshotname; + $newsnapname =~ s/current$/$level/; + } else { + # destroy the snapshot + # restoring next level will fail. + @cmd = (); + if ($self->{pfexec_cmd}) { + push @cmd, $self->{pfexec_cmd}; + } + push @cmd, $self->{zfs_path}; + push @cmd, "destroy"; + push @cmd, $snapshotname; + + debug("cmd:" . join(" ", @cmd)); + system @cmd; + } } - push @cmd, $self->{zfs_path}; - push @cmd, "rename"; - push @cmd, "$device\@$current_snapshot"; - push @cmd, "$device\@$self->{'snapshot'}"; - debug("cmd:" . join(" ", @cmd)); - system @cmd; + if (defined $newsnapname) { + # rename -current snapshot to -level + @cmd = (); + if ($self->{pfexec_cmd}) { + push @cmd, $self->{pfexec_cmd}; + } + push @cmd, $self->{zfs_path}; + push @cmd, "rename"; + push @cmd, $snapshotname; + push @cmd, $newsnapname; + + debug("cmd:" . join(" ", @cmd)); + system @cmd; + } } sub command_print_command { diff --git a/changer-src/Makefile.in b/changer-src/Makefile.in index ce62866..f6e3b92 100644 --- a/changer-src/Makefile.in +++ b/changer-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -433,6 +433,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -865,6 +866,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -914,6 +916,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -922,6 +925,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -929,6 +933,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1073,6 +1079,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1106,6 +1113,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1148,7 +1156,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/client-src/Makefile.in b/client-src/Makefile.in index a385288..9bf098d 100644 --- a/client-src/Makefile.in +++ b/client-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -531,6 +531,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -963,6 +964,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -1012,6 +1014,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -1020,6 +1023,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -1027,6 +1031,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1171,6 +1177,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1204,6 +1211,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1246,7 +1254,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/client-src/amdump_client.pl b/client-src/amdump_client.pl index 672c259..560747c 100644 --- a/client-src/amdump_client.pl +++ b/client-src/amdump_client.pl @@ -28,15 +28,18 @@ use IPC::Open3; use Amanda::Util qw( :constants ); use Amanda::Config qw( :init :getconf ); use Amanda::Paths; -use Amanda::Logfile qw( log_rename get_current_log_timestamp $amanda_log_trace_log ); +use Amanda::Util qw ( match_disk ); use Amanda::Debug qw( debug ); Amanda::Util::setup_application("amdump_client", "client", $CONTEXT_CMDLINE); my $config; my $config_overrides = new_config_overrides($#ARGV+1); + +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw{bundling}); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'config=s' => sub { $config = $_[1]; }, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, ) or usage(); @@ -94,7 +97,7 @@ if ($cmd eq 'list') { #find the diskname that match for (my $i=1; $i <= $#ARGV; $i++) { for my $diskname (@disks) { - if (Amanda::Logfile::match_disk($ARGV[$i], $diskname)) { + if (match_disk($ARGV[$i], $diskname)) { debug("send: DISK " . Amanda::Util::quote_string($diskname)); print {$amservice_in} "DISK " . Amanda::Util::quote_string($diskname) . "\n"; my $a = <$amservice_out>; @@ -117,7 +120,7 @@ if ($cmd eq 'list') { #find the diskname that match for (my $i=1; $i <= $#ARGV; $i++) { for my $diskname (@disks) { - if (Amanda::Logfile::match_disk($ARGV[$i], $diskname)) { + if (match_disk($ARGV[$i], $diskname)) { debug("send: DISK " . Amanda::Util::quote_string($diskname)); print {$amservice_in} "DISK " . Amanda::Util::quote_string($diskname) . "\n"; my $a = <$amservice_out>; diff --git a/client-src/calcsize.c b/client-src/calcsize.c index f14fd17..5c77ef5 100644 --- a/client-src/calcsize.c +++ b/client-src/calcsize.c @@ -171,6 +171,11 @@ main( char *amname=NULL, *qamname=NULL; char *filename=NULL, *qfilename = NULL; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("calcsize-%s\n", VERSION); + return (0); + } + safe_fd(-1, 0); safe_cd(); diff --git a/client-src/client_util.c b/client-src/client_util.c index 89365ce..513d9ba 100644 --- a/client-src/client_util.c +++ b/client-src/client_util.c @@ -1425,7 +1425,6 @@ run_calcsize( FILE *dumpout = NULL; int dumpsince; char *errmsg = NULL; - off_t size = (off_t)1; char *line = NULL; amwait_t wait_status; int len; @@ -1521,7 +1520,7 @@ run_calcsize( match_expr = vstralloc(" %d SIZE %lld", NULL); len = strlen(qdisk); - for(size = (off_t)-1; (line = agets(dumpout)) != NULL; free(line)) { + for(; (line = agets(dumpout)) != NULL; free(line)) { long long size_ = (long long)0; if (line[0] == '\0' || (int)strlen(line) <= len) continue; @@ -1532,7 +1531,6 @@ run_calcsize( dbprintf(_("estimate size for %s level %d: %lld KB\n"), qdisk, level, size_); } - size = (off_t)size_; } amfree(match_expr); @@ -1576,11 +1574,10 @@ common_exit: amfree(errmsg); g_ptr_array_free_full(argv_ptr); amfree(cmd); - } -void +gboolean check_access( char * filename, int mode) @@ -1597,14 +1594,18 @@ check_access( else noun = "access", adjective = "accessible"; - if(access(filename, mode) == -1) + if(access(filename, mode) == -1) { g_printf(_("ERROR [can not %s %s: %s]\n"), noun, quoted, strerror(errno)); - else + amfree(quoted); + return FALSE; + } else { g_printf(_("OK %s %s\n"), quoted, adjective); + } amfree(quoted); + return TRUE; } -void +gboolean check_file( char * filename, int mode) @@ -1617,6 +1618,7 @@ check_file( quoted = quote_string(filename); g_printf(_("ERROR [%s is not a file]\n"), quoted); amfree(quoted); + return FALSE; } } else { int save_errno = errno; @@ -1624,13 +1626,19 @@ check_file( g_printf(_("ERROR [can not stat %s: %s]\n"), quoted, strerror(save_errno)); amfree(quoted); + return FALSE; } if (getuid() == geteuid()) { - check_access(filename, mode); + return check_access(filename, mode); + } else { + quoted = quote_string(filename); + g_printf("OK %s\n", quoted); + amfree(quoted); } + return TRUE; } -void +gboolean check_dir( char * dirname, int mode) @@ -1644,6 +1652,7 @@ check_dir( quoted = quote_string(dirname); g_printf(_("ERROR [%s is not a directory]\n"), quoted); amfree(quoted); + return FALSE; } } else { int save_errno = errno; @@ -1651,15 +1660,23 @@ check_dir( g_printf(_("ERROR [can not stat %s: %s]\n"), quoted, strerror(save_errno)); amfree(quoted); + return FALSE; } if (getuid() == geteuid()) { + gboolean result; dir = stralloc2(dirname, "/."); - check_access(dir, mode); + result = check_access(dir, mode); amfree(dir); + return result; + } else { + quoted = quote_string(dirname); + g_printf("OK %s\n", quoted); + amfree(quoted); } + return TRUE; } -void +gboolean check_suid( char * filename) { @@ -1670,18 +1687,25 @@ check_suid( if(!stat(filename, &stat_buf)) { if(stat_buf.st_uid != 0 ) { g_printf(_("ERROR [%s is not owned by root]\n"), quoted); + amfree(quoted); + return FALSE; } if((stat_buf.st_mode & S_ISUID) != S_ISUID) { g_printf(_("ERROR [%s is not SUID root]\n"), quoted); + amfree(quoted); + return FALSE; } } else { g_printf(_("ERROR [can not stat %s: %s]\n"), quoted, strerror(errno)); + amfree(quoted); + return FALSE; } amfree(quoted); #else (void)filename; /* Quiet unused parameter warning */ #endif + return TRUE; } /* diff --git a/client-src/client_util.h b/client-src/client_util.h index ef61786..a2c7442 100644 --- a/client-src/client_util.h +++ b/client-src/client_util.h @@ -145,10 +145,10 @@ void run_calcsize(char *config, char *program, char *disk, char *dirname, GSList *levels, char *file_exclude, char *file_include); -void check_access(char *filename, int mode); -void check_file(char *filename, int mode); -void check_dir(char *dirname, int mode); -void check_suid(char *filename); +gboolean check_access(char *filename, int mode); +gboolean check_file(char *filename, int mode); +gboolean check_dir(char *dirname, int mode); +gboolean check_suid(char *filename); double the_num(char * str, int pos); /* Convert a GSList returned from config_errors into an "ERROR " diff --git a/client-src/killpgrp.c b/client-src/killpgrp.c index ba433e4..49f51b7 100644 --- a/client-src/killpgrp.c +++ b/client-src/killpgrp.c @@ -61,6 +61,11 @@ main( char *exitstr; amwait_t status; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("killpgrp-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. diff --git a/client-src/noop.c b/client-src/noop.c index e9b6270..856fd15 100644 --- a/client-src/noop.c +++ b/client-src/noop.c @@ -52,6 +52,11 @@ main( (void)argc; /* Quiet unused parameter warning */ (void)argv; /* Quiet unused parameter warning */ + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("noop-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. diff --git a/client-src/rundump.c b/client-src/rundump.c index 7b1e6fb..ab10516 100644 --- a/client-src/rundump.c +++ b/client-src/rundump.c @@ -66,6 +66,11 @@ main( char *cmdline; #endif /* ERRMSG */ + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("rundump-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. diff --git a/client-src/runtar.c b/client-src/runtar.c index 3019087..1ab9ab7 100644 --- a/client-src/runtar.c +++ b/client-src/runtar.c @@ -51,6 +51,11 @@ main( char *cmdline; #endif + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("runtar-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. diff --git a/client-src/selfcheck.c b/client-src/selfcheck.c index a381233..e044a6c 100644 --- a/client-src/selfcheck.c +++ b/client-src/selfcheck.c @@ -78,6 +78,7 @@ static void check_disk(dle_t *dle); static void check_overall(void); static int check_file_exist(char *filename); static void check_space(char *dir, off_t kbytes); +static void print_platform(void); int main( @@ -96,6 +97,11 @@ main( GSList *errlist; level_t *alevel; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("selfcheck-%s\n", VERSION); + return (0); + } + /* initialize */ /* @@ -121,6 +127,8 @@ main( dbopen(DBG_SUBDIR_CLIENT); startclock(); dbprintf(_("version %s\n"), VERSION); + g_printf("OK version %s\n", VERSION); + print_platform(); if(argc > 2 && strcmp(argv[1], "amandad") == 0) { amandad_auth = stralloc(argv[2]); @@ -611,6 +619,7 @@ check_disk( #endif "-c", "quit", NULL); + checkpid = checkpid; amfree(domain); aclose(nullfd); /*@ignore@*/ @@ -921,8 +930,8 @@ check_disk( access_type = "access"; #endif if(access_result == -1) { - err = vstrallocf(_("Could not access %s (%s): %s"), - qdevice, qdisk, strerror(errno)); + err = vstrallocf(_("Could not %s %s (%s): %s"), + access_type, qdevice, qdisk, strerror(errno)); } #ifdef CHECK_FOR_ACCESS_WITH_OPEN aclose(access_result); @@ -1209,3 +1218,85 @@ check_file_exist( return 1; } +static void +print_platform(void) +{ + struct stat stat_buf; + char *uname; + char *distro = NULL; + char *platform = NULL; + char line[1025]; + GPtrArray *argv_ptr; + + if (stat("/etc/lsb-release", &stat_buf) == 0) { + FILE *release = fopen("/etc/lsb-release", "r"); + distro = "Ubuntu"; + if (release) { + char *result; + while ((result = fgets(line, 1024, release))) { + if (strstr(line, "DESCRIPTION")) { + platform = strchr(line, '='); + if (platform) platform++; + } + } + fclose(release); + } + } else if (stat("/etc/redhat-release", &stat_buf) == 0) { + FILE *release = fopen("/etc/redhat-release", "r"); + distro = "RPM"; + if (release) { + char *result; + result = fgets(line, 1024, release); + if (result) { + platform = line; + } + fclose(release); + } + } else if (stat("/etc/debian_version", &stat_buf) == 0) { + FILE *release = fopen("/etc/debian_version", "r"); + distro = "Debian"; + if (release) { + char *result; + result = fgets(line, 1024, release); + if (result) { + platform = line; + } + fclose(release); + } + } else { + argv_ptr = g_ptr_array_new(); + + g_ptr_array_add(argv_ptr, UNAME_PATH); + g_ptr_array_add(argv_ptr, "-s"); + g_ptr_array_add(argv_ptr, NULL); + uname = get_first_line(argv_ptr); + if (uname) { + if (strncmp(uname, "SunOS", 5) == 0) { + FILE *release = fopen("/etc/release", "r"); + distro = "Solaris"; + if (release) { + char *result; + result = fgets(line, 1024, release); + if (result) { + platform = line; + } + } + fclose(release); + } + amfree(uname); + } + g_ptr_array_free(argv_ptr, TRUE); + } + + if (!distro) { + distro = "Unknown"; + } + if (!platform) { + platform = "Unknown"; + } + if (platform[strlen(platform) -1] == '\n') { + platform[strlen(platform) -1] = '\0'; + } + g_fprintf(stdout, "OK distro %s\n", distro); + g_fprintf(stdout, "OK platform %s\n", platform); +} diff --git a/client-src/sendbackup.c b/client-src/sendbackup.c index 781dedb..506d45b 100644 --- a/client-src/sendbackup.c +++ b/client-src/sendbackup.c @@ -126,6 +126,11 @@ main( FILE *mesgstream; level_t *alevel; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("sendbackup-%s\n", VERSION); + return (0); + } + /* initialize */ /* * Configure program for internationalization: diff --git a/client-src/sendsize.c b/client-src/sendsize.c index 6d9f0c2..083ec65 100644 --- a/client-src/sendsize.c +++ b/client-src/sendsize.c @@ -140,6 +140,11 @@ main( (void)argc; /* Quiet unused parameter warning */ (void)argv; /* Quiet unused parameter warning */ + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("sendsize-%s\n", VERSION); + return (0); + } + /* initialize */ /* @@ -1007,7 +1012,6 @@ generic_calc_estimates( char *file_include = NULL; times_t start_time; FILE *dumpout = NULL; - off_t size = (off_t)1; char *line = NULL; char *match_expr; amwait_t wait_status; @@ -1097,7 +1101,7 @@ generic_calc_estimates( } match_expr = vstralloc(" %d SIZE %lld", NULL); len = strlen(est->qamname); - for(size = (off_t)-1; (line = agets(dumpout)) != NULL; free(line)) { + for(; (line = agets(dumpout)) != NULL; free(line)) { long long size_ = (long long)0; if (line[0] == '\0' || (int)strlen(line) <= len) continue; @@ -1110,7 +1114,6 @@ generic_calc_estimates( level, size_); } - size = (off_t)size_; } amfree(match_expr); diff --git a/common-src/Makefile.am b/common-src/Makefile.am index 58443ad..d1686f1 100644 --- a/common-src/Makefile.am +++ b/common-src/Makefile.am @@ -36,7 +36,7 @@ libamanda_la_SOURCES = \ packet.c \ pipespawn.c \ protocol.c \ - semaphore.c \ + amsemaphore.c \ security.c \ security-util.c \ simpleprng.c \ @@ -119,7 +119,7 @@ noinst_HEADERS = \ packet.h \ pipespawn.h \ protocol.h \ - semaphore.h \ + amsemaphore.h \ security.h \ security-util.h \ simpleprng.h \ @@ -211,7 +211,7 @@ libtestutils_la_SOURCES = \ # automake-style tests -TESTS = amflock-test event-test semaphore-test quoting-test \ +TESTS = amflock-test event-test amsemaphore-test quoting-test \ ipc-binary-test hexencode-test fileheader-test match-test noinst_PROGRAMS = $(TESTS) @@ -221,8 +221,8 @@ amflock_test_LDADD = libamanda.la libtestutils.la event_test_SOURCES = event-test.c event_test_LDADD = libamanda.la libtestutils.la -semaphore_test_SOURCES = semaphore-test.c -semaphore_test_LDADD = libamanda.la libtestutils.la +amsemaphore_test_SOURCES = amsemaphore-test.c +amsemaphore_test_LDADD = libamanda.la libtestutils.la quoting_test_SOURCES = quoting-test.c quoting_test_LDADD = libamanda.la libtestutils.la diff --git a/common-src/Makefile.in b/common-src/Makefile.in index 637af48..4b10810 100644 --- a/common-src/Makefile.in +++ b/common-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -204,7 +204,7 @@ sbin_PROGRAMS = amservice$(EXEEXT) @WANT_KRB5_SECURITY_TRUE@am__append_11 = krb5-security.c EXTRA_PROGRAMS = genversion$(EXEEXT) $(am__EXEEXT_1) TESTS = amflock-test$(EXEEXT) event-test$(EXEEXT) \ - semaphore-test$(EXEEXT) quoting-test$(EXEEXT) \ + amsemaphore-test$(EXEEXT) quoting-test$(EXEEXT) \ ipc-binary-test$(EXEEXT) hexencode-test$(EXEEXT) \ fileheader-test$(EXEEXT) match-test$(EXEEXT) noinst_PROGRAMS = $(am__EXEEXT_2) @@ -394,7 +394,7 @@ libamanda_la_DEPENDENCIES = ../gnulib/libgnu.la am__libamanda_la_SOURCES_DIST = alloc.c amfeatures.c amflock.c \ ipc-binary.c amxml.c clock.c columnar.c conffile.c debug.c \ dgram.c event.c file.c fileheader.c glib-util.c match.c \ - packet.c pipespawn.c protocol.c semaphore.c security.c \ + packet.c pipespawn.c protocol.c amsemaphore.c security.c \ security-util.c simpleprng.c sl.c sockaddr-util.c stream.c \ tapelist.c timestamp.c util.c amflock-posix.c amflock-flock.c \ amflock-lockf.c amflock-lnlock.c rsh-security.c ssh-security.c \ @@ -413,7 +413,7 @@ am__libamanda_la_SOURCES_DIST = alloc.c amfeatures.c amflock.c \ am_libamanda_la_OBJECTS = alloc.lo amfeatures.lo amflock.lo \ ipc-binary.lo amxml.lo clock.lo columnar.lo conffile.lo \ debug.lo dgram.lo event.lo file.lo fileheader.lo glib-util.lo \ - match.lo packet.lo pipespawn.lo protocol.lo semaphore.lo \ + match.lo packet.lo pipespawn.lo protocol.lo amsemaphore.lo \ security.lo security-util.lo simpleprng.lo sl.lo \ sockaddr-util.lo stream.lo tapelist.lo timestamp.lo util.lo \ $(am__objects_1) $(am__objects_2) $(am__objects_3) \ @@ -431,13 +431,16 @@ am_libtestutils_la_OBJECTS = testutils.lo libtestutils_la_OBJECTS = $(am_libtestutils_la_OBJECTS) am__EXEEXT_1 = file$(EXEEXT) bsdsecurity$(EXEEXT) am__EXEEXT_2 = amflock-test$(EXEEXT) event-test$(EXEEXT) \ - semaphore-test$(EXEEXT) quoting-test$(EXEEXT) \ + amsemaphore-test$(EXEEXT) quoting-test$(EXEEXT) \ ipc-binary-test$(EXEEXT) hexencode-test$(EXEEXT) \ fileheader-test$(EXEEXT) match-test$(EXEEXT) PROGRAMS = $(noinst_PROGRAMS) $(sbin_PROGRAMS) am_amflock_test_OBJECTS = amflock-test.$(OBJEXT) amflock_test_OBJECTS = $(am_amflock_test_OBJECTS) amflock_test_DEPENDENCIES = libamanda.la libtestutils.la +am_amsemaphore_test_OBJECTS = amsemaphore-test.$(OBJEXT) +amsemaphore_test_OBJECTS = $(am_amsemaphore_test_OBJECTS) +amsemaphore_test_DEPENDENCIES = libamanda.la libtestutils.la amservice_SOURCES = amservice.c amservice_OBJECTS = amservice.$(OBJEXT) amservice_LDADD = $(LDADD) @@ -471,9 +474,6 @@ match_test_DEPENDENCIES = libamanda.la libtestutils.la am_quoting_test_OBJECTS = quoting-test.$(OBJEXT) quoting_test_OBJECTS = $(am_quoting_test_OBJECTS) quoting_test_DEPENDENCIES = libamanda.la libtestutils.la -am_semaphore_test_OBJECTS = semaphore-test.$(OBJEXT) -semaphore_test_OBJECTS = $(am_semaphore_test_OBJECTS) -semaphore_test_DEPENDENCIES = libamanda.la libtestutils.la SCRIPTS = $(amlibexec_SCRIPTS) $(sbin_SCRIPTS) DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)/config depcomp = $(SHELL) $(top_srcdir)/config/depcomp @@ -489,19 +489,19 @@ LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ $(LDFLAGS) -o $@ SOURCES = $(libamanda_la_SOURCES) $(nodist_libamanda_la_SOURCES) \ - $(libtestutils_la_SOURCES) $(amflock_test_SOURCES) amservice.c \ - $(bsdsecurity_SOURCES) $(event_test_SOURCES) $(file_SOURCES) \ + $(libtestutils_la_SOURCES) $(amflock_test_SOURCES) \ + $(amsemaphore_test_SOURCES) amservice.c $(bsdsecurity_SOURCES) \ + $(event_test_SOURCES) $(file_SOURCES) \ $(fileheader_test_SOURCES) $(genversion_SOURCES) \ $(hexencode_test_SOURCES) $(ipc_binary_test_SOURCES) \ - $(match_test_SOURCES) $(quoting_test_SOURCES) \ - $(semaphore_test_SOURCES) + $(match_test_SOURCES) $(quoting_test_SOURCES) DIST_SOURCES = $(am__libamanda_la_SOURCES_DIST) \ - $(libtestutils_la_SOURCES) $(amflock_test_SOURCES) amservice.c \ - $(bsdsecurity_SOURCES) $(event_test_SOURCES) $(file_SOURCES) \ + $(libtestutils_la_SOURCES) $(amflock_test_SOURCES) \ + $(amsemaphore_test_SOURCES) amservice.c $(bsdsecurity_SOURCES) \ + $(event_test_SOURCES) $(file_SOURCES) \ $(fileheader_test_SOURCES) $(genversion_SOURCES) \ $(hexencode_test_SOURCES) $(ipc_binary_test_SOURCES) \ - $(match_test_SOURCES) $(quoting_test_SOURCES) \ - $(semaphore_test_SOURCES) + $(match_test_SOURCES) $(quoting_test_SOURCES) DATA = $(amlibexec_DATA) HEADERS = $(noinst_HEADERS) ETAGS = etags @@ -573,6 +573,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -1005,6 +1006,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -1054,6 +1056,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -1062,6 +1065,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -1069,6 +1073,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1213,6 +1219,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1246,6 +1253,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1288,7 +1296,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -1362,12 +1369,12 @@ LINTFLAGS = $(AMLINTFLAGS) libamanda_la_SOURCES = alloc.c amfeatures.c amflock.c ipc-binary.c \ amxml.c clock.c columnar.c conffile.c debug.c dgram.c event.c \ file.c fileheader.c glib-util.c match.c packet.c pipespawn.c \ - protocol.c semaphore.c security.c security-util.c simpleprng.c \ - sl.c sockaddr-util.c stream.c tapelist.c timestamp.c util.c \ - $(am__append_2) $(am__append_3) $(am__append_4) \ - $(am__append_5) $(am__append_6) $(am__append_7) \ - $(am__append_8) $(am__append_9) $(am__append_10) \ - $(am__append_11) local-security.c + protocol.c amsemaphore.c security.c security-util.c \ + simpleprng.c sl.c sockaddr-util.c stream.c tapelist.c \ + timestamp.c util.c $(am__append_2) $(am__append_3) \ + $(am__append_4) $(am__append_5) $(am__append_6) \ + $(am__append_7) $(am__append_8) $(am__append_9) \ + $(am__append_10) $(am__append_11) local-security.c # version.c is generated; see below nodist_libamanda_la_SOURCES = version.c INSTALLPERMS_exec = \ @@ -1400,7 +1407,7 @@ noinst_HEADERS = \ packet.h \ pipespawn.h \ protocol.h \ - semaphore.h \ + amsemaphore.h \ security.h \ security-util.h \ simpleprng.h \ @@ -1473,8 +1480,8 @@ amflock_test_SOURCES = amflock-test.c amflock_test_LDADD = libamanda.la libtestutils.la event_test_SOURCES = event-test.c event_test_LDADD = libamanda.la libtestutils.la -semaphore_test_SOURCES = semaphore-test.c -semaphore_test_LDADD = libamanda.la libtestutils.la +amsemaphore_test_SOURCES = amsemaphore-test.c +amsemaphore_test_LDADD = libamanda.la libtestutils.la quoting_test_SOURCES = quoting-test.c quoting_test_LDADD = libamanda.la libtestutils.la ipc_binary_test_SOURCES = ipc-binary-test.c @@ -1644,6 +1651,9 @@ clean-sbinPROGRAMS: amflock-test$(EXEEXT): $(amflock_test_OBJECTS) $(amflock_test_DEPENDENCIES) @rm -f amflock-test$(EXEEXT) $(LINK) $(amflock_test_OBJECTS) $(amflock_test_LDADD) $(LIBS) +amsemaphore-test$(EXEEXT): $(amsemaphore_test_OBJECTS) $(amsemaphore_test_DEPENDENCIES) + @rm -f amsemaphore-test$(EXEEXT) + $(LINK) $(amsemaphore_test_OBJECTS) $(amsemaphore_test_LDADD) $(LIBS) amservice$(EXEEXT): $(amservice_OBJECTS) $(amservice_DEPENDENCIES) @rm -f amservice$(EXEEXT) $(LINK) $(amservice_OBJECTS) $(amservice_LDADD) $(LIBS) @@ -1674,9 +1684,6 @@ match-test$(EXEEXT): $(match_test_OBJECTS) $(match_test_DEPENDENCIES) quoting-test$(EXEEXT): $(quoting_test_OBJECTS) $(quoting_test_DEPENDENCIES) @rm -f quoting-test$(EXEEXT) $(LINK) $(quoting_test_OBJECTS) $(quoting_test_LDADD) $(LIBS) -semaphore-test$(EXEEXT): $(semaphore_test_OBJECTS) $(semaphore_test_DEPENDENCIES) - @rm -f semaphore-test$(EXEEXT) - $(LINK) $(semaphore_test_OBJECTS) $(semaphore_test_LDADD) $(LIBS) install-amlibexecSCRIPTS: $(amlibexec_SCRIPTS) @$(NORMAL_INSTALL) test -z "$(amlibexecdir)" || $(MKDIR_P) "$(DESTDIR)$(amlibexecdir)" @@ -1760,6 +1767,8 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amflock-posix.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amflock-test.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amflock.Plo@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amsemaphore-test.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amsemaphore.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amservice.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amxml.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bsd-security.Plo@am__quote@ @@ -1793,8 +1802,6 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rsh-security.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/security-util.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/security.Plo@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/semaphore-test.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/semaphore.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simpleprng.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sl.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sockaddr-util.Plo@am__quote@ diff --git a/common-src/amcryptsimple.pl b/common-src/amcryptsimple.pl index cf5306b..e8d4922 100755 --- a/common-src/amcryptsimple.pl +++ b/common-src/amcryptsimple.pl @@ -53,9 +53,18 @@ $ENV{'PATH'} = '/usr/local/bin:/usr/bin:/usr/sbin:/bin:/sbin:/opt/csw/bin'; $ENV{'GNUPGHOME'} = "$AMANDA_HOME/.gnupg"; +sub do_gpg_agent() { + my $path=`which gpg-agent 2>/dev/null`; + chomp $path; + if (-x $path) { + return "gpg-agent --daemon --"; + } + return "" +} sub encrypt() { - system "gpg --batch --no-secmem-warning --disable-mdc --symmetric --cipher-algo AES256 --passphrase-fd 3 3<$AM_PASS"; + my $gpg_agent_cmd = do_gpg_agent(); + system "$gpg_agent_cmd gpg --batch --no-secmem-warning --disable-mdc --symmetric --cipher-algo AES256 --passphrase-fd 3 3<$AM_PASS"; if ($? == -1) { print STDERR "failed to execute gpg: $!\n"; exit (1); @@ -69,7 +78,8 @@ sub encrypt() { } sub decrypt() { - system "gpg --batch --quiet --no-mdc-warning --decrypt --passphrase-fd 3 3<$AM_PASS"; + my $gpg_agent_cmd = do_gpg_agent(); + system "$gpg_agent_cmd gpg --batch --quiet --no-mdc-warning --decrypt --passphrase-fd 3 3<$AM_PASS"; if ($? == -1) { print STDERR "failed to execute gpg: $!\n"; exit (1); diff --git a/common-src/amfeatures.c b/common-src/amfeatures.c index 085c8ea..78bf0d4 100644 --- a/common-src/amfeatures.c +++ b/common-src/amfeatures.c @@ -165,6 +165,7 @@ am_init_feature_set(void) am_add_feature(f, fe_amrecover_receive_unfiltered); am_add_feature(f, fe_application_client_name); am_add_feature(f, fe_script_client_name); + am_add_feature(f, fe_dumptype_property); } return f; } @@ -459,3 +460,10 @@ bad: am_release_feature_set(f); return NULL; } + +am_feature_t * +am_features( + am_feature_t *f) +{ + return f; +} diff --git a/common-src/amfeatures.h b/common-src/amfeatures.h index 068b8d5..f0d7559 100644 --- a/common-src/amfeatures.h +++ b/common-src/amfeatures.h @@ -192,6 +192,7 @@ typedef enum { fe_amrecover_receive_unfiltered, fe_application_client_name, fe_script_client_name, + fe_dumptype_property, /* * All new features must be inserted immediately *before* this entry. @@ -211,6 +212,7 @@ typedef struct am_feature_s { * Functions. */ +extern am_feature_t *am_features(am_feature_t *f); extern am_feature_t *am_init_feature_set(void); extern am_feature_t *am_set_default_feature_set(void); extern am_feature_t *am_allocate_feature_set(void); diff --git a/common-src/amgetconf.pl b/common-src/amgetconf.pl index c6636cd..23a9f1e 100644 --- a/common-src/amgetconf.pl +++ b/common-src/amgetconf.pl @@ -237,6 +237,24 @@ sub conf_param { for my $subsec (@list) { print "$subsec\n"; } + } elsif ($parameter =~ /^property:/i) { + my %properties = %{ getconf($CNF_PROPERTY)}; + my $propname = $parameter; + $propname =~ s/^property://i; + $propname = lc($propname); + if (exists $properties{$propname}) { + print $properties{$propname}->{'values'}[0], "\n"; + } + } elsif ($parameter =~ /^device-property:/i || + $parameter =~ /^device_property:/i) { + my %properties = %{ getconf($CNF_DEVICE_PROPERTY) }; + my $propname = $parameter; + $propname =~ s/^device-property://i; + $propname =~ s/^device_property://i; + $propname = lc($propname); + if (exists $properties{$propname}) { + print $properties{$propname}->{'values'}[0], "\n"; + } } else { no_such_param($parameter) unless defined(getconf_byname($parameter)); @@ -248,14 +266,18 @@ sub conf_param { } } +Amanda::Util::setup_application("amgetconf", "server", $CONTEXT_SCRIPTUTIL); + ## Command-line parsing my $opt_list = ''; my $config_overrides = new_config_overrides($#ARGV+1); my $execute_where = undef; +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw{bundling}); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'list|l' => \$opt_list, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, 'execute-where=s' => sub { @@ -291,8 +313,6 @@ if (@ARGV == 1) { ## Now start looking at the parameter. -Amanda::Util::setup_application("amgetconf", "server", $CONTEXT_SCRIPTUTIL); - if ($parameter =~ /^build(?:\..*)?/) { config_init(0|$execute_where, undef); build_param($parameter, $opt_list); @@ -309,7 +329,17 @@ if ($parameter =~ /^db(open|close)\./) { # finally, finish up the application startup procedure set_config_overrides($config_overrides); -config_init($CONFIG_INIT_EXPLICIT_NAME | $CONFIG_INIT_USE_CWD | $execute_where, $config_name); +if ($execute_where == $CONFIG_INIT_CLIENT && + defined($config_name) && $config_name eq '.') { + config_init($CONFIG_INIT_USE_CWD | $execute_where, undef); +} elsif ($execute_where == $CONFIG_INIT_CLIENT && + defined($config_name) && $config_name ne '.') { + config_init($CONFIG_INIT_EXPLICIT_NAME | $execute_where, $config_name); +} elsif ($execute_where == $CONFIG_INIT_CLIENT) { + config_init($execute_where, undef); +} else { + config_init($CONFIG_INIT_EXPLICIT_NAME | $CONFIG_INIT_USE_CWD | $execute_where, $config_name); +} my ($cfgerr_level, @cfgerr_errors) = config_errors(); if ($cfgerr_level >= $CFGERR_WARNINGS) { config_print_errors(); diff --git a/common-src/amsemaphore-test.c b/common-src/amsemaphore-test.c new file mode 100644 index 0000000..5ca4a40 --- /dev/null +++ b/common-src/amsemaphore-test.c @@ -0,0 +1,245 @@ +/* + * Copyright (c) 2008,2009 Zmanda, Inc. All Rights Reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 as published + * by the Free Software Foundation. + * + * 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 + * + * Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300 + * Sunnyvale, CA 94085, USA, or: http://www.zmanda.com + */ + +#include "amanda.h" +#include "amsemaphore.h" +#include "testutils.h" +#include "util.h" + +/* + * test that decrement waits properly + */ + +struct test_decr_wait_data { + amsemaphore_t *sem; + gboolean increment_called; +}; + +static gpointer +test_decr_wait_thread(gpointer datap) +{ + struct test_decr_wait_data *data = datap; + + /* should block */ + amsemaphore_decrement(data->sem, 20); + + /* if increment hasn't been called yet, that's an error. */ + if (!data->increment_called) + return GINT_TO_POINTER(0); + + return GINT_TO_POINTER(1); +} + +static gboolean +test_decr_wait(void) +{ + GThread *th; + struct test_decr_wait_data data = { NULL, FALSE }; + int rv; + + data.sem = amsemaphore_new_with_value(10), + + th = g_thread_create(test_decr_wait_thread, (gpointer)&data, TRUE, NULL); + + /* sleep to give amsemaphore_decrement() a chance to block (or not). */ + g_usleep(G_USEC_PER_SEC / 4); + + /* and then increment the semaphore enough that the decrement can succeed */ + data.increment_called = TRUE; + amsemaphore_increment(data.sem, 10); + + /* join the thread and see how it fared. */ + rv = GPOINTER_TO_INT(g_thread_join(th)); + + amsemaphore_free(data.sem); + + return (rv == 1); +} + + +/* + * test that amsemaphore_wait_empty waits properly + */ + +static gpointer +test_wait_empty_thread(gpointer datap) +{ + amsemaphore_t *sem = datap; + + /* should block */ + amsemaphore_decrement(sem, 20); + + /* value should be 10 now (decremented from 30) */ + if (sem->value != 10) + return GINT_TO_POINTER(1); + + /* sleep for a bit */ + g_usleep(G_USEC_PER_SEC / 4); + + /* decrement those last 10, which should trigger the zero */ + amsemaphore_decrement(sem, 10); + + return GINT_TO_POINTER(0); +} + +static gboolean +test_wait_empty(void) +{ + GThread *th; + amsemaphore_t *sem = amsemaphore_new_with_value(10); + int rv; + + th = g_thread_create(test_wait_empty_thread, (gpointer)sem, TRUE, NULL); + + /* sleep to give amsemaphore_decrement() a chance to block (or not). */ + g_usleep(G_USEC_PER_SEC / 4); + + /* add another 10, so decrement can hit zero next time it's called */ + amsemaphore_increment(sem, 10); + + /* and wait on the semaphore emptying */ + amsemaphore_wait_empty(sem); + + /* join the thread and see how it fared. */ + rv = GPOINTER_TO_INT(g_thread_join(th)); + + amsemaphore_free(sem); + + return (rv == 1); +} + +/* + * test that amsemaphore_force_adjust correctly wakes both + * amsemaphore_decrement and amsemaphore_wait_empty. + */ + +static gpointer +test_force_adjust_thread(gpointer datap) +{ + amsemaphore_t *sem = datap; + + /* this should block */ + amsemaphore_decrement(sem, 20); + + /* and this should block, too - it's fun */ + amsemaphore_wait_empty(sem); + + return NULL; +} + +static gboolean +test_force_adjust(void) +{ + GThread *th; + amsemaphore_t *sem = amsemaphore_new_with_value(10); + + th = g_thread_create(test_force_adjust_thread, (gpointer)sem, TRUE, NULL); + + /* sleep to give amsemaphore_decrement() a chance to block (or not). */ + g_usleep(G_USEC_PER_SEC / 4); + + /* add another 20, so decrement can proceed, but leave the value at 10 */ + amsemaphore_force_adjust(sem, 20); + + /* sleep to give amsemaphore_wait_empty() a chance to block (or not). */ + g_usleep(G_USEC_PER_SEC / 4); + + /* and empty out the semaphore */ + amsemaphore_force_adjust(sem, -10); + + g_thread_join(th); + + amsemaphore_free(sem); + + /* it we didn't hang yet, it's all good */ + return TRUE; +} + +/* + * test that amsemaphore_force_set correctly wakes both + * amsemaphore_decrement and amsemaphore_wait_empty. + */ + +static gpointer +test_force_set_thread(gpointer datap) +{ + amsemaphore_t *sem = datap; + + /* this should block */ + amsemaphore_decrement(sem, 20); + + /* and this should block, too - it's fun */ + amsemaphore_wait_empty(sem); + + return NULL; +} + +static gboolean +test_force_set(void) +{ + GThread *th; + amsemaphore_t *sem = amsemaphore_new_with_value(10); + + th = g_thread_create(test_force_set_thread, (gpointer)sem, TRUE, NULL); + + /* sleep to give amsemaphore_decrement() a chance to block (or not). */ + g_usleep(G_USEC_PER_SEC / 4); + + /* set it to 30, so decrement can proceed, but leave the value at 10 */ + amsemaphore_force_set(sem, 30); + + /* sleep to give amsemaphore_wait_empty() a chance to block (or not). */ + g_usleep(G_USEC_PER_SEC / 4); + + /* and empty out the semaphore */ + amsemaphore_force_set(sem, 0); + + g_thread_join(th); + + amsemaphore_free(sem); + + /* it we didn't hang yet, it's all good */ + return TRUE; +} + +/* + * Main loop + */ + +int +main(int argc, char **argv) +{ +#if defined(G_THREADS_ENABLED) && !defined(G_THREADS_IMPL_NONE) + static TestUtilsTest tests[] = { + TU_TEST(test_decr_wait, 90), + TU_TEST(test_wait_empty, 90), + TU_TEST(test_force_adjust, 90), + TU_TEST(test_force_set, 90), + TU_END() + }; + + glib_init(); + + return testutils_run_tests(argc, argv, tests); +#else + g_fprintf(stderr, "No thread support on this platform -- nothing to test\n"); + return 0; +#endif +} diff --git a/common-src/amsemaphore.c b/common-src/amsemaphore.c new file mode 100644 index 0000000..554e758 --- /dev/null +++ b/common-src/amsemaphore.c @@ -0,0 +1,122 @@ +/* + * Copyright (c) 2008, 2009, 2010 Zmanda, Inc. All Rights Reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 as published + * by the Free Software Foundation. + * + * 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 + * + * Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300 + * Sunnyvale, CA 94085, USA, or: http://www.zmanda.com + */ + +/* GLib does not provide semaphores, which are useful in queue.c. + So, we implement it here. */ + +#include "amanda.h" +#include "amsemaphore.h" + +amsemaphore_t* amsemaphore_new_with_value(int value) { + amsemaphore_t *rval; + + if (!g_thread_supported()) + return NULL; + + rval = malloc(sizeof(*rval)); + rval->value = value; + rval->mutex = g_mutex_new(); + rval->decrement_cond = g_cond_new(); + rval->zero_cond = g_cond_new(); + + if (rval->mutex == NULL || rval->decrement_cond == NULL || + rval->zero_cond == NULL) { + amsemaphore_free(rval); + return NULL; + } else { + return rval; + } +} + +void amsemaphore_free(amsemaphore_t* o) { + g_mutex_free(o->mutex); + g_cond_free(o->decrement_cond); + g_cond_free(o->zero_cond); + free(o); +} + +/* This function checks if the semaphore would is zero or negative. + * If so, the zero_cond is signalled. We assume that the mutex is + * locked. */ +static void check_empty(amsemaphore_t * o) { + if (o->value <= 0) { + g_cond_broadcast(o->zero_cond); + } +} + +void amsemaphore_increment(amsemaphore_t* o, unsigned int inc) { + g_return_if_fail(o != NULL); + g_return_if_fail(inc != 0); + + amsemaphore_force_adjust(o, inc); +} + +void amsemaphore_decrement(amsemaphore_t* o, unsigned int dec) { + int sdec; + g_return_if_fail(o != NULL); + sdec = (int) dec; + g_return_if_fail(sdec >= 0); + + g_mutex_lock(o->mutex); + while (o->value < sdec) { + g_cond_wait(o->decrement_cond, o->mutex); + } + o->value -= sdec; + check_empty(o); + g_mutex_unlock(o->mutex); +} + +void amsemaphore_force_adjust(amsemaphore_t* o, int inc) { + g_return_if_fail(o != NULL); + + g_mutex_lock(o->mutex); + o->value += inc; + if (inc < 0) + check_empty(o); + else + g_cond_broadcast(o->decrement_cond); + g_mutex_unlock(o->mutex); + +} + +void amsemaphore_force_set(amsemaphore_t* o, int value) { + int oldvalue; + g_return_if_fail(o != NULL); + + g_mutex_lock(o->mutex); + oldvalue = o->value; + o->value = value; + if (value < oldvalue) + check_empty(o); + else + g_cond_broadcast(o->decrement_cond); + g_mutex_unlock(o->mutex); + +} + +void amsemaphore_wait_empty(amsemaphore_t * o) { + g_return_if_fail(o != NULL); + + g_mutex_lock(o->mutex); + while (o->value > 0) { + g_cond_wait(o->zero_cond, o->mutex); + } + g_mutex_unlock(o->mutex); +} diff --git a/common-src/amsemaphore.h b/common-src/amsemaphore.h new file mode 100644 index 0000000..cf0b974 --- /dev/null +++ b/common-src/amsemaphore.h @@ -0,0 +1,107 @@ +/* + * Copyright (c) 2008,2009 Zmanda, Inc. All Rights Reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 as published + * by the Free Software Foundation. + * + * 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 + * + * Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300 + * Sunnyvale, CA 94085, USA, or: http://www.zmanda.com + */ + +/* GLib does not provide semaphores, which are useful in queue.c. + So, we implement it here. */ + +#include + +#ifndef SEMAPHORE_H + +typedef struct { + int value; + GMutex *mutex; + GCond * decrement_cond; + GCond * zero_cond; +} amsemaphore_t; + +/* Create a new semaphore object with the given value. + * + * @param value: new value + * @returns: newly allocated amsemaphore_t + */ +amsemaphore_t* amsemaphore_new_with_value(int value); + +/* Shortcut to make a new semaphore with value 1. + */ +#define amsemaphore_new() amsemaphore_new_with_value(1) + +/* Free a semaphore allocated by amsemaphore_with_new_value(). Be sure the + * semaphore is no longer in use by any threads. + * + * @param sem: the semaphore to free + */ +void amsemaphore_free(amsemaphore_t *sem); + +/* Increment the value of the semaphore by incr. This corresponds to + * Dijkstra's V(), or the typical semaphore's release(). + * + * This function will not block, but may wake other threads waiting + * on amsemaphore_decrement(). + * + * @param sem: the semaphore + * @param incr: added to the semaphore's value + */ +void amsemaphore_increment(amsemaphore_t *sem, unsigned int incr); + +/* Shortcut to increment the semaphore by 1. + */ +#define amsemaphore_up(semaphore) amsemaphore_increment(semaphore,1) + +/* Decrement the value of the semaphore by incr. If this operation + * would make the semaphore negative, block until the semaphore + * value is large enough, then perform the decerement operation. Threads + * waiting on amsemaphore_wait_empty() may be awakened if the value + * reaches 0. + * + * @param sem: the semaphore + * @param decr: subtracted from the semaphore's value + */ +void amsemaphore_decrement(amsemaphore_t *sem, unsigned int decr); + +/* Shortcut to decrement the semaphore by 1. + */ +#define amsemaphore_down(semaphore) amsemaphore_decrement(semaphore, 1) + +/* Increment or decrement (with a negative incr) the value without + * blocking. Threads waiting on amsemaphore_decrement() or + * amsemaphore_wait_empty() will be awakened if necessary. + * + * @param sem: the semaphore + * @param incr: added to the semaphore's value + */ +void amsemaphore_force_adjust(amsemaphore_t *sem, int incr); + +/* Set the semaphore to a given value without blocking. Threads + * waiting on amsemaphore_decrement() or amsemaphore_wait_empty() + * will be awakened if necessary. + * + * @param sem: the semaphore + * @param value: the new value + */ +void amsemaphore_force_set(amsemaphore_t *sem, int value); + +/* Block until the semaphore's value is zero. + * + * @param sem: the semaphore + */ +void amsemaphore_wait_empty(amsemaphore_t *sem); + +#endif /* SEMAPHORE_H */ diff --git a/common-src/amservice.c b/common-src/amservice.c index 286a770..b5346a1 100644 --- a/common-src/amservice.c +++ b/common-src/amservice.c @@ -35,6 +35,12 @@ #include "protocol.h" #include "amfeatures.h" #include "event.h" +#include "getopt.h" + +static struct option long_options[] = { + {"version" , 0, NULL, 1}, + {NULL, 0, NULL, 0} +}; static int copy_stream = 0; static time_t conf_ctimeout; @@ -58,7 +64,7 @@ static void read_server(void *cookie, void *buf, ssize_t size); void usage(void) { - error(_("Usage: amservice [-o configoption]* [-f input_file [-s]] host auth service")); + error(_("Usage: amservice [--version] [-o configoption]* [-f input_file [-s]] host auth service")); /*NOTREACHED*/ } @@ -110,8 +116,11 @@ main( cfg_ovr = new_config_overrides(argc/2); input_file = stdin; - while((opt = getopt(argc, argv, "o:f:s")) != EOF) { + while((opt = getopt_long(argc, argv, "o:f:s", long_options, NULL)) != EOF) { switch(opt) { + case 1: printf("amservice-%s\n", VERSION); + return(0); + break; case 'o': add_config_override_opt(cfg_ovr, optarg); break; case 'f': got_input_file = 1; diff --git a/common-src/amxml.c b/common-src/amxml.c index 28b88ae..7aab3f6 100644 --- a/common-src/amxml.c +++ b/common-src/amxml.c @@ -99,6 +99,8 @@ free_dle( free_sl(dle->exclude_list); free_sl(dle->include_file); free_sl(dle->include_list); + if (dle->property) + g_hash_table_destroy(dle->property); if (dle->application_property) g_hash_table_destroy(dle->application_property); for(scriptlist = dle->scriptlist; scriptlist != NULL; @@ -149,6 +151,7 @@ init_dle( dle->include_list = NULL; dle->exclude_optional = 0; dle->include_optional = 0; + dle->property = NULL; dle->application_property = NULL; dle->scriptlist = NULL; dle->data_path = DATA_PATH_AMANDA; @@ -250,7 +253,8 @@ amstart_element( data_user->has_optional = 0; data_user->property_name = NULL; data_user->property_data = NULL; - data_user->property = NULL; + data_user->property = + g_hash_table_new_full(g_str_hash, g_str_equal, &g_free, &free_property_t); data_user->script = NULL; data_user->alevel = NULL; data_user->encoding = NULL; @@ -363,8 +367,10 @@ amstart_element( return; } } else if(strcmp(element_name, "property") == 0) { - if (strcmp(last_element_name, "backup-program") != 0 && - strcmp(last_element_name, "script") != 0) { + if (!last_element || + (strcmp(last_element_name, "backup-program") != 0 && + strcmp(last_element_name, "script") != 0 && + strcmp(last_element_name, "dle") != 0)) { g_set_error(gerror, G_MARKUP_ERROR, G_MARKUP_ERROR_INVALID_CONTENT, "XML: Invalid %s element", element_name); return; @@ -495,6 +501,7 @@ amend_element( if (dle->estimatelist == NULL) dle->estimatelist = g_slist_append(dle->estimatelist, ES_CLIENT); /* Add check of required field */ + data_user->property = NULL; data_user->dle = NULL; } else if (strcmp(element_name, "backup-program") == 0) { if (dle->program == NULL) { @@ -503,7 +510,7 @@ amend_element( return; } dle->application_property = data_user->property; - data_user->property = NULL; + data_user->property = dle->property; } else if (strcmp(element_name, "script") == 0) { if (data_user->script->plugin == NULL) { g_set_error(gerror, G_MARKUP_ERROR, G_MARKUP_ERROR_INVALID_CONTENT, @@ -511,7 +518,7 @@ amend_element( return; } data_user->script->property = data_user->property; - data_user->property = NULL; + data_user->property = dle->property; dle->scriptlist = g_slist_append(dle->scriptlist, data_user->script); data_user->script = NULL; } else if (strcmp(element_name, "level") == 0) { @@ -540,7 +547,6 @@ amtext( GSList *last_element2; char *last_element2_name; dle_t *dle = data_user->dle; - int i; if (!last_element) { g_set_error(gerror, G_MARKUP_ERROR, G_MARKUP_ERROR_INVALID_CONTENT, @@ -860,7 +866,6 @@ amtext( error("bad list"); } } else if(strcmp(last_element_name, "optional") == 0) { - i = atoi(tt); last_element2 = g_slist_nth(data_user->element_names, 1); if (!last_element2) { error("XML: optional"); diff --git a/common-src/amxml.h b/common-src/amxml.h index a670ba9..a8d4045 100644 --- a/common-src/amxml.h +++ b/common-src/amxml.h @@ -79,6 +79,7 @@ typedef struct a_dle_s { sl_t *include_list; int exclude_optional; int include_optional; + proplist_t property; proplist_t application_property; char *application_client_name; scriptlist_t scriptlist; diff --git a/common-src/bsd-security.c b/common-src/bsd-security.c index ad929b3..2d4304e 100644 --- a/common-src/bsd-security.c +++ b/common-src/bsd-security.c @@ -178,10 +178,8 @@ bsd_connect( * Only init the IPv6 socket once */ if (res_addr->ai_addr->sa_family == AF_INET6 && not_init6 == 1) { - uid_t euid; dgram_zero(&netfd6.dgram); - euid = geteuid(); set_root_privs(1); result_bind = dgram_bind(&netfd6.dgram, res_addr->ai_addr->sa_family, &port); @@ -220,10 +218,8 @@ bsd_connect( * Only init the IPv4 socket once */ if (res_addr->ai_addr->sa_family == AF_INET && not_init4 == 1) { - uid_t euid; dgram_zero(&netfd4.dgram); - euid = geteuid(); set_root_privs(1); result_bind = dgram_bind(&netfd4.dgram, res_addr->ai_addr->sa_family, &port); diff --git a/common-src/bsdudp-security.c b/common-src/bsdudp-security.c index 41ff9bf..a4715ff 100644 --- a/common-src/bsdudp-security.c +++ b/common-src/bsdudp-security.c @@ -160,10 +160,8 @@ bsdudp_connect( * Only init the IPv6 socket once */ if (res_addr->ai_addr->sa_family == AF_INET6 && not_init6 == 1) { - uid_t euid; dgram_zero(&netfd6.dgram); - euid = geteuid(); set_root_privs(1); result_bind = dgram_bind(&netfd6.dgram, res_addr->ai_addr->sa_family, &port); @@ -202,10 +200,8 @@ bsdudp_connect( * Only init the IPv4 socket once */ if (res_addr->ai_addr->sa_family == AF_INET && not_init4 == 1) { - uid_t euid; dgram_zero(&netfd4.dgram); - euid = geteuid(); set_root_privs(1); result_bind = dgram_bind(&netfd4.dgram, res_addr->ai_addr->sa_family, &port); diff --git a/common-src/conffile.c b/common-src/conffile.c index 90b3723..7277e48 100644 --- a/common-src/conffile.c +++ b/common-src/conffile.c @@ -91,6 +91,7 @@ typedef enum { CONF_DEVICE, CONF_ORDER, CONF_SINGLE_EXECUTION, CONF_DATA_PATH, CONF_AMANDA, CONF_DIRECTTCP, CONF_TAPER_PARALLEL_WRITE, CONF_INTERACTIVITY, CONF_TAPERSCAN, + CONF_MAX_DLE_BY_VOLUME, CONF_EJECT_VOLUME, /* execute on */ CONF_PRE_AMCHECK, CONF_POST_AMCHECK, @@ -951,6 +952,7 @@ keytab_t server_keytab[] = { { "DUMPTYPE", CONF_DUMPTYPE }, { "DUMPUSER", CONF_DUMPUSER }, { "DUMP_LIMIT", CONF_DUMP_LIMIT }, + { "EJECT_VOLUME", CONF_EJECT_VOLUME }, { "EMPTY", CONF_EMPTY }, { "ENCRYPT", CONF_ENCRYPT }, { "ERROR", CONF_ERROR }, @@ -996,6 +998,7 @@ keytab_t server_keytab[] = { { "MAILER", CONF_MAILER }, { "MAILTO", CONF_MAILTO }, { "READBLOCKSIZE", CONF_READBLOCKSIZE }, + { "MAX_DLE_BY_VOLUME", CONF_MAX_DLE_BY_VOLUME }, { "MAXDUMPS", CONF_MAXDUMPS }, { "MAXDUMPSIZE", CONF_MAXDUMPSIZE }, { "MAXPROMOTEDAY", CONF_MAXPROMOTEDAY }, @@ -1257,6 +1260,7 @@ conf_var_t server_var [] = { { CONF_INPARALLEL , CONFTYPE_INT , read_int , CNF_INPARALLEL , validate_inparallel }, { CONF_DUMPORDER , CONFTYPE_STR , read_str , CNF_DUMPORDER , NULL }, { CONF_MAXDUMPS , CONFTYPE_INT , read_int , CNF_MAXDUMPS , validate_positive }, + { CONF_MAX_DLE_BY_VOLUME , CONFTYPE_INT , read_int , CNF_MAX_DLE_BY_VOLUME , validate_positive }, { CONF_ETIMEOUT , CONFTYPE_INT , read_int , CNF_ETIMEOUT , validate_non_zero }, { CONF_DTIMEOUT , CONFTYPE_INT , read_int , CNF_DTIMEOUT , validate_positive }, { CONF_CTIMEOUT , CONFTYPE_INT , read_int , CNF_CTIMEOUT , validate_positive }, @@ -1277,6 +1281,7 @@ conf_var_t server_var [] = { { CONF_LABEL_NEW_TAPES , CONFTYPE_STR , read_str , CNF_LABEL_NEW_TAPES , NULL }, { CONF_AUTOLABEL , CONFTYPE_AUTOLABEL, read_autolabel , CNF_AUTOLABEL , NULL }, { CONF_META_AUTOLABEL , CONFTYPE_STR , read_str , CNF_META_AUTOLABEL , NULL }, + { CONF_EJECT_VOLUME , CONFTYPE_BOOLEAN , read_bool , CNF_EJECT_VOLUME , NULL }, { CONF_USETIMESTAMPS , CONFTYPE_BOOLEAN , read_bool , CNF_USETIMESTAMPS , NULL }, { CONF_AMRECOVER_DO_FSF , CONFTYPE_BOOLEAN , read_bool , CNF_AMRECOVER_DO_FSF , NULL }, { CONF_AMRECOVER_CHANGER , CONFTYPE_STR , read_str , CNF_AMRECOVER_CHANGER , NULL }, @@ -4152,7 +4157,7 @@ read_int_or_str( val->v.s = newstralloc(val->v.s, tokenval.v.s); break; default: - conf_parserror(_("CLIENT or SERVER expected")); + conf_parserror(_("an integer or a quoted string is expected")); } } @@ -5096,7 +5101,6 @@ config_init( config_name = stralloc(config_name + 1); } - amfree(cwd); } else if (flags & CONFIG_INIT_CLIENT) { amfree(config_name); config_dir = newstralloc(config_dir, CONFIG_DIR); @@ -5344,6 +5348,7 @@ init_defaults( conf_init_str (&conf_data[CNF_TPCHANGER] , ""); conf_init_int (&conf_data[CNF_RUNTAPES] , 1); conf_init_int (&conf_data[CNF_MAXDUMPS] , 1); + conf_init_int (&conf_data[CNF_MAX_DLE_BY_VOLUME] , 1000000000); conf_init_int (&conf_data[CNF_ETIMEOUT] , 300); conf_init_int (&conf_data[CNF_DTIMEOUT] , 1800); conf_init_int (&conf_data[CNF_CTIMEOUT] , 30); @@ -5366,6 +5371,7 @@ init_defaults( conf_init_str (&conf_data[CNF_KRB5KEYTAB] , "/.amanda-v5-keytab"); conf_init_str (&conf_data[CNF_KRB5PRINCIPAL] , "service/amanda"); conf_init_str (&conf_data[CNF_LABEL_NEW_TAPES] , ""); + conf_init_bool (&conf_data[CNF_EJECT_VOLUME] , 0); conf_init_bool (&conf_data[CNF_USETIMESTAMPS] , 1); conf_init_int (&conf_data[CNF_CONNECT_TRIES] , 3); conf_init_int (&conf_data[CNF_REP_TRIES] , 5); diff --git a/common-src/conffile.h b/common-src/conffile.h index b901b6f..2c867cc 100644 --- a/common-src/conffile.h +++ b/common-src/conffile.h @@ -486,6 +486,8 @@ typedef enum { CNF_TAPER_PARALLEL_WRITE, CNF_RECOVERY_LIMIT, CNF_TAPERSCAN, + CNF_MAX_DLE_BY_VOLUME, + CNF_EJECT_VOLUME, CNF_CNF /* sentinel */ } confparm_key; diff --git a/common-src/debug.c b/common-src/debug.c index 233191d..82a5664 100644 --- a/common-src/debug.c +++ b/common-src/debug.c @@ -68,6 +68,7 @@ static void debug_unlink_old(void); static void debug_setup_1(char *config, char *subdir); static void debug_setup_2(char *s, int fd, char *annotation); static char *msg_timestamp(void); +static char *msg_thread(void); static void debug_logging_handler(const gchar *log_domain, GLogLevelFlags log_level, @@ -494,6 +495,22 @@ msg_timestamp(void) return timestamp; } +/* Get current GMT time and return a message timestamp. + * Used for g_printf calls to logs and such. The return value + * is to a static buffer, so it should be used immediately. + * + * @returns: timestamp + */ +static char * +msg_thread(void) +{ + static char thread[128]; + + sprintf(thread, "thd-%p", g_thread_self()); + + return thread; +} + /* * ---- public functions */ @@ -775,7 +792,7 @@ printf_arglist_function(void debug_printf, const char *, format) char *text; if (db_file != stderr) - prefix = g_strdup_printf("%s: %s:", msg_timestamp(), get_pname()); + prefix = g_strdup_printf("%s: %s: %s:", msg_timestamp(), msg_thread(), get_pname()); else prefix = g_strdup_printf("%s:", get_pname()); arglist_start(argp, format); diff --git a/common-src/match-test.c b/common-src/match-test.c index 8737e56..9be05ef 100644 --- a/common-src/match-test.c +++ b/common-src/match-test.c @@ -706,8 +706,10 @@ test_match_disk(void) { "\\\\\\\\windows\\\\share", "\\\\windows\\share", TRUE }, /* other expressions */ - { "^local", "/local", TRUE }, - { "^local", "/local/vore", TRUE }, + { "^local", "/local", FALSE }, + { "^/local", "/local", TRUE }, + { "^local", "/local/vore", FALSE }, + { "^/local", "/local/vore", TRUE }, { "^local", "/usr/local", FALSE }, { "local/bin", "/local/bin", TRUE }, @@ -740,7 +742,41 @@ test_match_disk(void) { "/usr\\/bin", "/usr/bin", TRUE }, { "^/usr\\/bin$", "/usr/bin", TRUE }, { "\\/usr\\/bin", "/usr/bin", FALSE }, - { "^\\/usr\\/bin$", "/usr/bin", FALSE }, + { "^\\/usr\\/bin$", "/usr/bin", TRUE }, + { "/usr\\/bin\\/", "/usr/bin/", TRUE }, + { "^/usr\\/bin\\/$", "/usr/bin/", TRUE }, + { "\\/usr\\/bin\\/", "/usr/bin/", FALSE }, + { "^\\/usr\\/bin\\/$", "/usr/bin/", TRUE }, + + { "oracle", "oracle", TRUE }, + { "oracle", "/oracle", TRUE }, + { "oracle", "oracle/", TRUE }, + { "oracle", "/oracle/", TRUE }, + { "/oracle", "oracle", TRUE }, + { "/oracle", "/oracle", TRUE }, + { "/oracle", "oracle/", TRUE }, + { "/oracle", "/oracle/", TRUE }, + { "^oracle", "oracle", TRUE }, + { "^oracle", "/oracle", FALSE }, + { "^oracle", "oracle/", TRUE }, + { "^oracle", "/oracle/", FALSE }, + { "^/oracle", "oracle", FALSE }, + { "^/oracle", "/oracle", TRUE }, + { "^/oracle", "oracle/", FALSE }, + { "^/oracle", "/oracle/", TRUE }, + + { "oracle", "oracle", TRUE }, + { "oracle", "/oracle", TRUE }, + { "oracle", "oracle/", TRUE }, + { "oracle", "/oracle/", TRUE }, + { "oracle$", "oracle", TRUE }, + { "oracle$", "/oracle", TRUE }, + { "oracle$", "oracle/", FALSE }, + { "oracle$", "/oracle/", FALSE }, + { "oracle/$", "oracle", FALSE }, + { "oracle/$", "/oracle", FALSE }, + { "oracle/$", "oracle/", TRUE }, + { "oracle/$", "/oracle/", TRUE }, { NULL, NULL, FALSE }, }, *t; diff --git a/common-src/match.c b/common-src/match.c index 362e345..0981a43 100644 --- a/common-src/match.c +++ b/common-src/match.c @@ -23,23 +23,37 @@ * Authors: the Amanda Development Team. Its members are listed in a * file named AUTHORS, in the root directory of this distribution. */ + /* - * $Id: match.c,v 1.23 2006/05/25 01:47:12 johnfranks Exp $ - * - * functions for checking and matching regular expressions + * See match.h for function prototypes and further explanations. */ #include "amanda.h" #include "match.h" #include -static int match_word(const char *glob, const char *word, const char separator); -static char *tar_to_regex(const char *glob); +/* + * DATA STRUCTURES, MACROS, STATIC DATA + */ /* - * REGEX MATCHING FUNCTIONS + * Return codes used by try_match() + */ + +#define MATCH_OK (1) +#define MATCH_NONE (0) +#define MATCH_ERROR (-1) + +/* + * Macro to tell whether a character is a regex metacharacter. Note that '*' + * and '?' are NOT included: they are themselves special in globs. */ +#define IS_REGEX_META(c) ( \ + (c) == '.' || (c) == '(' || (c) == ')' || (c) == '{' || (c) == '}' || \ + (c) == '+' || (c) == '^' || (c) == '$' || (c) == '|' \ +) + /* * Define a specific type to hold error messages in case regex compile/matching * fails @@ -48,41 +62,240 @@ static char *tar_to_regex(const char *glob); typedef char regex_errbuf[STR_SIZE]; /* - * Validate one regular expression. If the regex is invalid, copy the error - * message into the supplied regex_errbuf pointer. Also, we want to know whether - * flags should include REG_NEWLINE (See regcomp(3) for details). Since this is - * the more frequent case, add REG_NEWLINE to the default flags, and remove it - * only if match_newline is set to FALSE. + * Structure used by amglob_to_regex() to expand particular glob characters. Its + * fields are: + * - question_mark: what the question mark ('?') should be replaced with; + * - star: what the star ('*') should be replaced with; + * - double_star: what two consecutive stars should be replaced with. + * + * Note that apart from double_star, ALL OTHER FIELDS MUST NOT BE NULL. + */ + +struct subst_table { + const char *question_mark; + const char *star; + const char *double_star; +}; + +/* + * Susbtitution data for glob_to_regex() + */ + +static struct subst_table glob_subst_stable = { + "[^/]", /* question_mark */ + "[^/]*", /* star */ + NULL /* double_star */ +}; + +/* + * Substitution data for tar_to_regex() + */ + +static struct subst_table tar_subst_stable = { + "[^/]", /* question_mark */ + ".*", /* star */ + NULL /* double_star */ +}; + +/* + * Substitution data for match_word(): dot + */ + +static struct subst_table mword_dot_subst_table = { + "[^.]", /* question_mark */ + "[^.]*", /* star */ + ".*" /* double_star */ +}; + +/* + * Substitution data for match_word(): slash + */ + +static struct subst_table mword_slash_subst_table = { + "[^/]", /* question_mark */ + "[^/]*", /* star */ + ".*" /* double_star */ +}; + +/* + * match_word() specific data: + * - re_double_sep: anchored regex matching two separators; + * - re_separator: regex matching the separator; + * - re_begin_full: regex matching the separator, anchored at the beginning; + * - re_end_full: regex matching the separator, andchored at the end. + */ + +struct mword_regexes { + const char *re_double_sep; + const char *re_begin_full; + const char *re_separator; + const char *re_end_full; +}; + +static struct mword_regexes mword_dot_regexes = { + "^\\.\\.$", /* re_double_sep */ + "^\\.", /* re_begin_full */ + "\\.", /* re_separator */ + "\\.$" /* re_end_full */ +}; + +static struct mword_regexes mword_slash_regexes = { + "^\\/\\/$", /* re_double_sep */ + "^\\/", /* re_begin_full */ + "\\/", /* re_separator */ + "\\/$" /* re_end_full */ +}; + +/* + * Regular expression caches, and a static mutex to protect initialization and + * access. This may be unnecessarily coarse, but it is unknown at this time + * whether GHashTable accesses are thread-safe, and get_regex_from_cache() may + * be called from within threads, so play it safe. + */ + +static GStaticMutex re_cache_mutex = G_STATIC_MUTEX_INIT; +static GHashTable *regex_cache = NULL, *regex_cache_newline = NULL; + +/* + * REGEX FUNCTIONS + */ + +/* + * Initialize regex caches. NOTE: this function MUST be called with + * re_cache_mutex LOCKED, see get_regex_from_cache() */ -static gboolean do_validate_regex(const char *str, regex_t *regex, - regex_errbuf *errbuf, gboolean match_newline) +static void init_regex_caches(void) { - int flags = REG_EXTENDED | REG_NOSUB | REG_NEWLINE; - int result; + static gboolean initialized = FALSE; - if (!match_newline) - CLR(flags, REG_NEWLINE); + if (initialized) + return; - result = regcomp(regex, str, flags); + regex_cache = g_hash_table_new(g_str_hash, g_str_equal); + regex_cache_newline = g_hash_table_new(g_str_hash, g_str_equal); - if (!result) - return TRUE; + initialized = TRUE; +} + +/* + * Cleanup a regular expression by escaping all non alphanumeric characters, and + * append beginning/end anchors if need be + */ - regerror(result, regex, *errbuf, SIZEOF(*errbuf)); - return FALSE; +char *clean_regex(const char *str, gboolean anchor) +{ + const char *src; + char *result, *dst; + + result = g_malloc(2 * strlen(str) + 3); + dst = result; + + if (anchor) + *dst++ = '^'; + + for (src = str; *src; src++) { + if (!g_ascii_isalnum((int) *src)) + *dst++ = '\\'; + *dst++ = *src; + } + + if (anchor) + *dst++ = '$'; + + *dst = '\0'; + return result; } /* - * See if a string matches a regular expression. Return one of MATCH_* defined - * below. If, for some reason, regexec() returns something other than not 0 or - * REG_NOMATCH, return MATCH_ERROR and print the error message in the supplied - * regex_errbuf. + * Compile one regular expression. Return TRUE if the regex has been compiled + * successfully. Otherwise, return FALSE and copy the error message into the + * supplied regex_errbuf pointer. Also, we want to know whether flags should + * include REG_NEWLINE (See regcomp(3) for details). Since this is the more + * frequent case, add REG_NEWLINE to the default flags, and remove it only if + * match_newline is set to FALSE. */ -#define MATCH_OK (1) -#define MATCH_NONE (0) -#define MATCH_ERROR (-1) +static gboolean do_regex_compile(const char *str, regex_t *regex, + regex_errbuf *errbuf, gboolean match_newline) +{ + int flags = REG_EXTENDED | REG_NOSUB | REG_NEWLINE; + int result; + + if (!match_newline) + flags &= ~REG_NEWLINE; + + result = regcomp(regex, str, flags); + + if (!result) + return TRUE; + + regerror(result, regex, *errbuf, sizeof(*errbuf)); + return FALSE; +} + +/* + * Get an already compiled buffer from the regex cache. If the regex is not in + * the cache, allocate a new one and compile it using do_regex_compile(). If the + * compile fails, call regfree() on the object and return NULL to the caller. If + * it does succeed, put the regex buffer in cache and return a pointer to it. + */ + +static regex_t *get_regex_from_cache(const char *re_str, regex_errbuf *errbuf, + gboolean match_newline) +{ + regex_t *ret; + GHashTable *cache; + + g_static_mutex_lock(&re_cache_mutex); + + init_regex_caches(); + + cache = (match_newline) ? regex_cache_newline: regex_cache; + ret = g_hash_table_lookup(cache, re_str); + + if (ret) + goto out; + + ret = g_new(regex_t, 1); + + if (do_regex_compile(re_str, ret, errbuf, match_newline)) { + g_hash_table_insert(cache, g_strdup(re_str), ret); + goto out; + } + + regfree(ret); + g_free(ret); + ret = NULL; + +out: + g_static_mutex_unlock(&re_cache_mutex); + return ret; +} + +/* + * Validate one regular expression using do_regex_compile(), and return NULL if + * the regex is valid, or the error message otherwise. + */ + +char *validate_regexp(const char *regex) +{ + regex_t regc; + static regex_errbuf errmsg; + gboolean valid; + + valid = do_regex_compile(regex, ®c, &errmsg, TRUE); + + regfree(®c); + return (valid) ? NULL : errmsg; +} + +/* + * See if a string matches a compiled regular expression. Return one of MATCH_* + * defined above. If, for some reason, regexec() returns something other than + * not 0 or REG_NOMATCH, return MATCH_ERROR and print the error message in the + * supplied regex_errbuf. + */ static int try_match(regex_t *regex, const char *str, regex_errbuf *errbuf) @@ -97,48 +310,41 @@ static int try_match(regex_t *regex, const char *str, /* Fall through: something went really wrong */ } - regerror(result, regex, *errbuf, SIZEOF(*errbuf)); + regerror(result, regex, *errbuf, sizeof(*errbuf)); return MATCH_ERROR; } -char * -validate_regexp( - const char * regex) +/* + * Try and match a string against a regular expression, using + * do_regex_compile() and try_match(). Exit early if the regex didn't compile + * or there was an error during matching. + */ + +int do_match(const char *regex, const char *str, gboolean match_newline) { - regex_t regc; - static regex_errbuf errmsg; - gboolean valid; + regex_t *re; + int result; + regex_errbuf errmsg; - valid = do_validate_regex(regex, ®c, &errmsg, TRUE); + re = get_regex_from_cache(regex, &errmsg, match_newline); - regfree(®c); - return (valid) ? NULL : errmsg; -} + if (!re) + error("regex \"%s\": %s", regex, errmsg); + /*NOTREACHED*/ -char * -clean_regex( - const char * str, - gboolean anchor) -{ - char *result; - int j; - size_t i; - result = alloc(2*strlen(str)+3); + result = try_match(re, str, &errmsg); + + if (result == MATCH_ERROR) + error("regex \"%s\": %s", regex, errmsg); + /*NOTREACHED*/ - j = 0; - if (anchor) - result[j++] = '^'; - for(i=0;i regex \"%s\": %s"), glob, regex, errmsg); - /*NOTREACHED*/ - - result = try_match(®c, str, &errmsg); - - if (result == MATCH_ERROR) - error(_("glob \"%s\" -> regex \"%s\": %s"), glob, regex, errmsg); - /*NOTREACHED*/ - - regfree(®c); - amfree(regex); - - return result; + return full_amglob_from_expression(host, '.'); } /* - * Macro to tell whether a character is a regex metacharacter. Note that '*' - * and '?' are NOT included: they are themselves special in globs. + * GLOB HANDLING, as per amanda-match(7) */ -#define IS_REGEX_META(c) ( \ - (c) == '.' || (c) == '(' || (c) == ')' || (c) == '{' || (c) == '}' || \ - (c) == '+' || (c) == '^' || (c) == '$' || (c) == '|' \ -) - /* - * EXPANDING A MATCH TO A REGEX (as per amanda-match(7)) - * - * The function at the code of this operation is amglob_to_regex(). It - * takes three arguments: the string to convert, a substitution table and a - * worst-case expansion. - * - * The substitution table, defined right below, is used to replace particular - * string positions and/or characters. Its fields are: - * - begin: what the beginnin of the string should be replaced with; - * - end: what the end of the string should be replaced with; - * - question_mark: what the question mark ('?') should be replaced with; - * - star: what the star ('*') should be replaced with; - * - double_star: what two consecutive stars should be replaced with. - * - * Note that apart from double_star, ALL OTHER FIELDS MUST NOT BE NULL + * Turn a glob into a regex. */ -struct subst_table { - const char *begin; - const char *end; - const char *question_mark; - const char *star; - const char *double_star; -}; - -static char *amglob_to_regex(const char *str, struct subst_table *table, - size_t worst_case) +static char *amglob_to_regex(const char *str, const char *begin, + const char *end, struct subst_table *table) { const char *src; char *result, *dst; char c; + size_t worst_case; + gboolean double_star = (table->double_star != NULL); /* * There are two particular cases when building a regex out of a glob: @@ -337,16 +445,25 @@ static char *amglob_to_regex(const char *str, struct subst_table *table, * - size of original string multiplied by worst-case expansion; * - end of regex; * - final 0. + * + * Calculate the worst case expansion by walking our struct subst_table. */ - result = alloc(strlen(table->begin) + strlen(str) * worst_case - + strlen(table->end) + 1); + worst_case = strlen(table->question_mark); + + if (worst_case < strlen(table->star)) + worst_case = strlen(table->star); + + if (double_star && worst_case < strlen(table->double_star)) + worst_case = strlen(table->double_star); + + result = g_malloc(strlen(begin) + strlen(str) * worst_case + strlen(end) + 1); /* * Start by copying the beginning of the regex... */ - dst = g_stpcpy(result, table->begin); + dst = g_stpcpy(result, begin); /* * ... Now to the meat of it. @@ -428,7 +545,7 @@ static char *amglob_to_regex(const char *str, struct subst_table *table, * exponential regex execution time: consider [^/]*[^/]*. */ const char *p = table->star; - if (*(src + 1) == '*' && table->double_star) { + if (double_star && *(src + 1) == '*') { src++; p = table->double_star; } @@ -449,7 +566,7 @@ straight_copy: */ if (!in_quote) - dst = g_stpcpy(dst, table->end); + dst = g_stpcpy(dst, end); /* * Finalize, return. */ @@ -458,114 +575,97 @@ straight_copy: return result; } -static struct subst_table glob_subst_stable = { - "^", /* begin */ - "$", /* end */ - "[^/]", /* question_mark */ - "[^/]*", /* star */ - NULL /* double_star */ -}; - -static size_t glob_worst_case = 5; /* star */ +/* + * File globs + */ -char * -glob_to_regex( - const char * glob) +char *glob_to_regex(const char *glob) { - return amglob_to_regex(glob, &glob_subst_stable, glob_worst_case); + return amglob_to_regex(glob, "^", "$", &glob_subst_stable); } -int -match_tar( - const char * glob, - const char * str) +int match_glob(const char *glob, const char *str) { char *regex; - regex_t regc; + regex_t *re; int result; regex_errbuf errmsg; - gboolean ok; - regex = tar_to_regex(glob); - ok = do_validate_regex(regex, ®c, &errmsg, TRUE); + regex = glob_to_regex(glob); + re = get_regex_from_cache(regex, &errmsg, TRUE); - if (!ok) - error(_("glob \"%s\" -> regex \"%s\": %s"), glob, regex, errmsg); + if (!re) + error("glob \"%s\" -> regex \"%s\": %s", glob, regex, errmsg); /*NOTREACHED*/ - result = try_match(®c, str, &errmsg); + result = try_match(re, str, &errmsg); if (result == MATCH_ERROR) - error(_("glob \"%s\" -> regex \"%s\": %s"), glob, regex, errmsg); + error("glob \"%s\" -> regex \"%s\": %s", glob, regex, errmsg); /*NOTREACHED*/ - regfree(®c); - amfree(regex); + g_free(regex); return result; } -static struct subst_table tar_subst_stable = { - "(^|/)", /* begin */ - "($|/)", /* end */ - "[^/]", /* question_mark */ - ".*", /* star */ - NULL /* double_star */ -}; +char *validate_glob(const char *glob) +{ + char *regex, *ret = NULL; + regex_t regc; + static regex_errbuf errmsg; -static size_t tar_worst_case = 5; /* begin or end */ + regex = glob_to_regex(glob); -static char * -tar_to_regex( - const char * glob) -{ - return amglob_to_regex(glob, &tar_subst_stable, tar_worst_case); + if (!do_regex_compile(regex, ®c, &errmsg, TRUE)) + ret = errmsg; + + regfree(®c); + g_free(regex); + return ret; } /* - * Two utility functions used by match_disk() below: they are used to convert a - * disk and glob from Windows expressed paths (backslashes) into Unix paths - * (slashes). - * - * Note: the resulting string is dynamically allocated, it is up to the caller - * to free it. - * - * Note 2: UNC in convert_unc_to_unix stands for Uniform Naming Convention. + * Tar globs */ -static char *convert_unc_to_unix(const char *unc) +static char *tar_to_regex(const char *glob) { - const char *src; - char *result, *dst; - result = alloc(strlen(unc) + 1); - dst = result; - - for (src = unc; *src; src++) - *(dst++) = (*src == '\\') ? '/' : *src; - - *dst = '\0'; - return result; + return amglob_to_regex(glob, "(^|/)", "($|/)", &tar_subst_stable); } -static char *convert_winglob_to_unix(const char *glob) +int match_tar(const char *glob, const char *str) { - const char *src; - char *result, *dst; - result = alloc(strlen(glob) + 1); - dst = result; + char *regex; + regex_t *re; + int result; + regex_errbuf errmsg; + + regex = tar_to_regex(glob); + re = get_regex_from_cache(regex, &errmsg, TRUE); + + if (!re) + error("glob \"%s\" -> regex \"%s\": %s", glob, regex, errmsg); + /*NOTREACHED*/ + + result = try_match(re, str, &errmsg); + + if (result == MATCH_ERROR) + error("glob \"%s\" -> regex \"%s\": %s", glob, regex, errmsg); + /*NOTREACHED*/ + + g_free(regex); - for (src = glob; *src; src++) { - if (*src == '\\' && *(src + 1) == '\\') { - *(dst++) = '/'; - src++; - continue; - } - *(dst++) = *src; - } - *dst = '\0'; return result; } +/* + * DISK/HOST MATCHING + * + * The functions below wrap input strings with separators and attempt to match + * the result. The core of the operation is the match_word() function. + */ + /* * Check whether a glob passed as an argument to match_word() only looks for the * separator @@ -580,82 +680,114 @@ static gboolean glob_is_separator_only(const char *glob, char sep) { case 1: return (*glob == sep); case 2: - return !(strcmp(glob, len2_1) && strcmp(glob, len2_2)); + return !(!g_str_equal(glob, len2_1) && !g_str_equal(glob, len2_2)); case 3: - return !strcmp(glob, len3); + return g_str_equal(glob, len3); default: return FALSE; } } -static int -match_word( - const char * glob, - const char * word, - const char separator) +/* + * Given a word and a separator as an argument, wrap the word with separators - + * if need be. For instance, if '/' is the separator, the rules are: + * + * - "" -> "/" + * - "/" -> "//" + * - "//" -> left alone + * - "xxx" -> "/xxx/" + * - "/xxx" -> "/xxx/" + * - "xxx/" -> "/xxx/" + * - "/xxx/" -> left alone + * + * (note that xxx here may contain the separator as well) + * + * Note that the returned string is dynamically allocated: it is up to the + * caller to free it. Note also that the first argument MUST NOT BE NULL. + */ + +static char *wrap_word(const char *word, const char separator, const char *glob) { - char *regex; - char *dst; - size_t len; - size_t lenword; - char *nword; - char *nglob; - const char *src; - int ret; + size_t len = strlen(word); + size_t len_glob = strlen(glob); + char *result, *p; + + /* + * We allocate for the worst case, which is two bytes more than the input + * (have to prepend and append a separator). + */ + result = g_malloc(len + 3); + p = result; - lenword = strlen(word); - nword = (char *)alloc(lenword + 3); + /* + * Zero-length: separator only + */ - dst = nword; - src = word; - if(lenword == 1 && *src == separator) { - *dst++ = separator; - *dst++ = separator; + if (len == 0) { + *p++ = separator; + goto out; } - else { - if(*src != separator) - *dst++ = separator; - while(*src != '\0') - *dst++ = *src++; - if(*(dst-1) != separator) - *dst++ = separator; + + /* + * Length is one: if the only character is the separator only, the result + * string is two separators + */ + + if (len == 1 && word[0] == separator) { + *p++ = separator; + *p++ = separator; + goto out; } - *dst = '\0'; - len = strlen(glob); - nglob = stralloc(glob); - - if(glob_is_separator_only(nglob, separator)) { - regex = alloc(7); /* Length of what is written below plus '\0' */ - dst = regex; - *dst++ = '^'; - *dst++ = '\\'; - *dst++ = separator; - *dst++ = '\\'; - *dst++ = separator; - *dst++ = '$'; - *dst = '\0'; + /* + * Otherwise: prepend the separator if needed, append the separator if + * needed. + */ + + if (word[0] != separator && glob[0] != '^') + *p++ = separator; + + p = g_stpcpy(p, word); + + if (word[len - 1] != separator && glob[len_glob-1] != '$') + *p++ = separator; + +out: + *p++ = '\0'; + return result; +} + +static int match_word(const char *glob, const char *word, const char separator) +{ + char *wrapped_word = wrap_word(word, separator, glob); + struct mword_regexes *regexes = &mword_slash_regexes; + struct subst_table *table = &mword_slash_subst_table; + gboolean not_slash = (separator != '/'); + int ret; + + /* + * We only expect two separators: '/' or '.'. If it's not '/', it has to be + * the other one... + */ + if (not_slash) { + regexes = &mword_dot_regexes; + table = &mword_dot_subst_table; + } + + if(glob_is_separator_only(glob, separator)) { + ret = do_match(regexes->re_double_sep, wrapped_word, TRUE); + goto out; } else { /* - * Unlike what happens for tar and disk expressions, here the - * substitution table needs to be dynamically allocated. When we enter - * here, we know what the expansions will be for the question mark, the - * star and the double star, and also the worst case expansion. We - * calculate the begin and end expansions below. + * Unlike what happens for tar and disk expressions, we need to + * calculate the beginning and end of our regex before calling + * amglob_to_regex(). */ -#define MATCHWORD_STAR_EXPANSION(c) (const char []) { \ - '[', '^', (c), ']', '*', 0 \ -} -#define MATCHWORD_QUESTIONMARK_EXPANSION(c) (const char []) { \ - '[', '^', (c), ']', 0 \ -} -#define MATCHWORD_DOUBLESTAR_EXPANSION ".*" - - struct subst_table table; - size_t worst_case = 5; const char *begin, *end; - char *p, *g = nglob; + char *glob_copy = g_strdup(glob); + char *p, *g = glob_copy; + char *regex; /* * Calculate the beginning of the regex: @@ -665,22 +797,18 @@ match_word( * - if it begins with a separator, make it the empty string. */ - p = nglob; - -#define REGEX_BEGIN_FULL(c) (const char[]) { '^', '\\', (c), 0 } -#define REGEX_BEGIN_NOANCHOR(c) (const char[]) { '\\', (c), 0 } -#define REGEX_BEGIN_ANCHORONLY "^" /* Unused, but defined for consistency */ -#define REGEX_BEGIN_EMPTY "" - - begin = REGEX_BEGIN_NOANCHOR(separator); + p = glob_copy; + begin = regexes->re_separator; if (*p == '^') { - begin = REGEX_BEGIN_FULL(separator); + begin = "^"; p++, g++; - if (*p == separator) + if (*p == separator) { + begin = regexes->re_begin_full; g++; + } } else if (*p == separator) - begin = REGEX_BEGIN_EMPTY; + begin = ""; /* * Calculate the end of the regex: @@ -692,73 +820,103 @@ match_word( * end, otherwise, add a separator before the anchor. */ - p = &(nglob[strlen(nglob) - 1]); - -#define REGEX_END_FULL(c) (const char[]) { '\\', (c), '$', 0 } -#define REGEX_END_NOANCHOR(c) REGEX_BEGIN_NOANCHOR(c) -#define REGEX_END_ANCHORONLY "$" -#define REGEX_END_EMPTY REGEX_BEGIN_EMPTY - - end = REGEX_END_NOANCHOR(separator); - - if (*p == '\\' || *p == separator) - end = REGEX_END_EMPTY; - else if (*p == '$') { + p = &(glob_copy[strlen(glob_copy) - 1]); + end = regexes->re_separator; + if (*p == '\\' || *p == separator) { + end = ""; + } else if (*p == '$') { char prev = *(p - 1); *p = '\0'; - if (prev == separator) - end = REGEX_END_ANCHORONLY; - else - end = REGEX_END_FULL(separator); + if (prev == separator) { + *(p-1) = '\0'; + if (p-2 >= glob_copy) { + prev = *(p - 2); + if (prev == '\\') { + *(p-2) = '\0'; + } + } + end = regexes->re_end_full; + } else { + end = "$"; + } } - /* - * Fill in our substitution table and generate the regex - */ - - table.begin = begin; - table.end = end; - table.question_mark = MATCHWORD_QUESTIONMARK_EXPANSION(separator); - table.star = MATCHWORD_STAR_EXPANSION(separator); - table.double_star = MATCHWORD_DOUBLESTAR_EXPANSION; + regex = amglob_to_regex(g, begin, end, table); + ret = do_match(regex, wrapped_word, TRUE); - regex = amglob_to_regex(g, &table, worst_case); + g_free(glob_copy); + g_free(regex); } - ret = do_match(regex, nword, TRUE); - - amfree(nword); - amfree(nglob); - amfree(regex); - +out: + g_free(wrapped_word); return ret; } +/* + * Match a host expression + */ -int -match_host( - const char * glob, - const char * host) +int match_host(const char *glob, const char *host) { char *lglob, *lhost; int ret; - lglob = g_ascii_strdown(glob, -1); lhost = g_ascii_strdown(host, -1); ret = match_word(lglob, lhost, '.'); - amfree(lglob); - amfree(lhost); + g_free(lglob); + g_free(lhost); return ret; } +/* + * Match a disk expression. Not as straightforward, since Windows paths must be + * accounted for. + */ -int -match_disk( - const char * glob, - const char * disk) +/* + * Convert a disk and glob from Windows expressed paths (backslashes) into Unix + * paths (slashes). + * + * Note: the resulting string is dynamically allocated, it is up to the caller + * to free it. + * + * Note 2: UNC in convert_unc_to_unix stands for Uniform Naming Convention. + */ + +static char *convert_unc_to_unix(const char *unc) +{ + char *result = g_strdup(unc); + return g_strdelimit(result, "\\", '/'); +} + +static char *convert_winglob_to_unix(const char *glob) +{ + const char *src; + char *result, *dst; + result = g_malloc(strlen(glob) + 1); + dst = result; + + for (src = glob; *src; src++) { + if (*src == '\\' && *(src + 1) == '\\') { + *dst++ = '/'; + src++; + continue; + } + *dst++ = *src; + } + *dst = '\0'; + return result; +} + +/* + * Match a disk expression + */ + +int match_disk(const char *glob, const char *disk) { char *glob2 = NULL, *disk2 = NULL; const char *g = glob, *d = disk; @@ -767,10 +925,9 @@ match_disk( /* * Check whether our disk potentially refers to a Windows share (the first * two characters are '\' and there is no / in the word at all): if yes, - * convert all double backslashes to slashes in the glob, and simple - * backslashes into slashes in the disk, and pass these new strings as - * arguments instead of the originals. + * build Unix paths instead and pass those as arguments to match_word() */ + gboolean windows_share = !(strncmp(disk, "\\\\", 2) || strchr(disk, '/')); if (windows_share) { @@ -783,14 +940,18 @@ match_disk( result = match_word(g, d, '/'); /* - * We can amfree(NULL), so this is "safe" + * We can g_free(NULL), so this is "safe" */ - amfree(glob2); - amfree(disk2); + g_free(glob2); + g_free(disk2); return result; } +/* + * TIMESTAMPS/LEVEL MATCHING + */ + static int alldigits( const char *str) @@ -817,7 +978,7 @@ match_datestamp( if(strlen(dateexp) >= 100 || strlen(dateexp) < 1) { goto illegal; } - + /* strip and ignore an initial "^" */ if(dateexp[0] == '^') { strncpy(mydateexp, dateexp+1, sizeof(mydateexp)-1); @@ -828,6 +989,10 @@ match_datestamp( mydateexp[sizeof(mydateexp)-1] = '\0'; } + if(strlen(dateexp) < 1) { + goto illegal; + } + if(mydateexp[strlen(mydateexp)-1] == '$') { match_exact = 1; mydateexp[strlen(mydateexp)-1] = '\0'; /* strip the trailing $ */ @@ -846,6 +1011,9 @@ match_datestamp( len = (size_t)(dash - mydateexp); /* length of XXXYYYY */ len_suffix = strlen(dash) - 1; /* length of ZZZZ */ if (len_suffix > len) goto illegal; + if (len < len_suffix) { + goto illegal; + } len_prefix = len - len_suffix; /* length of XXX */ dash++; @@ -866,14 +1034,14 @@ match_datestamp( if (!alldigits(mydateexp)) goto illegal; if(match_exact == 1) { - return (strcmp(datestamp, mydateexp) == 0); + return (g_str_equal(datestamp, mydateexp)); } else { - return (strncmp(datestamp, mydateexp, strlen(mydateexp)) == 0); + return (g_str_has_prefix(datestamp, mydateexp)); } } illegal: - error(_("Illegal datestamp expression %s"),dateexp); + error("Illegal datestamp expression %s", dateexp); /*NOTREACHED*/ } @@ -889,13 +1057,17 @@ match_level( int match_exact; if(strlen(levelexp) >= 100 || strlen(levelexp) < 1) { - error(_("Illegal level expression %s"),levelexp); + error("Illegal level expression %s", levelexp); /*NOTREACHED*/ } - + if(levelexp[0] == '^') { - strncpy(mylevelexp, levelexp+1, strlen(levelexp)-1); + strncpy(mylevelexp, levelexp+1, strlen(levelexp)-1); mylevelexp[strlen(levelexp)-1] = '\0'; + if (strlen(levelexp) == 0) { + error("Illegal level expression %s", levelexp); + /*NOTREACHED*/ + } } else { strncpy(mylevelexp, levelexp, strlen(levelexp)); @@ -930,13 +1102,13 @@ match_level( else { if (!alldigits(mylevelexp)) goto illegal; if(match_exact == 1) { - return (strcmp(level, mylevelexp) == 0); + return (g_str_equal(level, mylevelexp)); } else { - return (strncmp(level, mylevelexp, strlen(mylevelexp)) == 0); + return (g_str_has_prefix(level, mylevelexp)); } } illegal: - error(_("Illegal level expression %s"),levelexp); + error("Illegal level expression %s", levelexp); /*NOTREACHED*/ } diff --git a/common-src/pipespawn.c b/common-src/pipespawn.c index 9e4e90c..3574acc 100644 --- a/common-src/pipespawn.c +++ b/common-src/pipespawn.c @@ -81,7 +81,6 @@ pipespawnv_passwd( int * stderrfd, char ** my_argv) { - int argc; pid_t pid; int i, inpipe[2], outpipe[2], errpipe[2], passwdpipe[2]; char number[NUM_STR_SIZE]; @@ -105,12 +104,10 @@ pipespawnv_passwd( memset(outpipe, -1, SIZEOF(outpipe)); memset(errpipe, -1, SIZEOF(errpipe)); memset(passwdpipe, -1, SIZEOF(passwdpipe)); - argc = 0; cmdline = stralloc(prog); for(arg = my_argv; *arg != NULL; arg++) { if (*arg != skip_argument) { - argc++; quoted = quote_string(*arg); cmdline = vstrextend(&cmdline, " ", quoted, NULL); amfree(quoted); diff --git a/common-src/security-util.c b/common-src/security-util.c index 3a2e056..2e0c0d0 100644 --- a/common-src/security-util.c +++ b/common-src/security-util.c @@ -988,6 +988,7 @@ bsd_recv_security_ok( */ s = body; if (strncmp_const_skip(s, "SERVICE ", s, ch) == 0) { + ch=ch; serviceX = stralloc(s); serviceY = strtok(serviceX, "\n"); if (serviceY) diff --git a/common-src/semaphore-test.c b/common-src/semaphore-test.c deleted file mode 100644 index 09547f5..0000000 --- a/common-src/semaphore-test.c +++ /dev/null @@ -1,245 +0,0 @@ -/* - * Copyright (c) 2008,2009 Zmanda, Inc. All Rights Reserved. - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 as published - * by the Free Software Foundation. - * - * 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 - * - * Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300 - * Sunnyvale, CA 94085, USA, or: http://www.zmanda.com - */ - -#include "amanda.h" -#include "semaphore.h" -#include "testutils.h" -#include "util.h" - -/* - * test that decrement waits properly - */ - -struct test_decr_wait_data { - semaphore_t *sem; - gboolean increment_called; -}; - -static gpointer -test_decr_wait_thread(gpointer datap) -{ - struct test_decr_wait_data *data = datap; - - /* should block */ - semaphore_decrement(data->sem, 20); - - /* if increment hasn't been called yet, that's an error. */ - if (!data->increment_called) - return GINT_TO_POINTER(0); - - return GINT_TO_POINTER(1); -} - -static gboolean -test_decr_wait(void) -{ - GThread *th; - struct test_decr_wait_data data = { NULL, FALSE }; - int rv; - - data.sem = semaphore_new_with_value(10), - - th = g_thread_create(test_decr_wait_thread, (gpointer)&data, TRUE, NULL); - - /* sleep to give semaphore_decrement() a chance to block (or not). */ - g_usleep(G_USEC_PER_SEC / 4); - - /* and then increment the semaphore enough that the decrement can succeed */ - data.increment_called = TRUE; - semaphore_increment(data.sem, 10); - - /* join the thread and see how it fared. */ - rv = GPOINTER_TO_INT(g_thread_join(th)); - - semaphore_free(data.sem); - - return (rv == 1); -} - - -/* - * test that semaphore_wait_empty waits properly - */ - -static gpointer -test_wait_empty_thread(gpointer datap) -{ - semaphore_t *sem = datap; - - /* should block */ - semaphore_decrement(sem, 20); - - /* value should be 10 now (decremented from 30) */ - if (sem->value != 10) - return GINT_TO_POINTER(1); - - /* sleep for a bit */ - g_usleep(G_USEC_PER_SEC / 4); - - /* decrement those last 10, which should trigger the zero */ - semaphore_decrement(sem, 10); - - return GINT_TO_POINTER(0); -} - -static gboolean -test_wait_empty(void) -{ - GThread *th; - semaphore_t *sem = semaphore_new_with_value(10); - int rv; - - th = g_thread_create(test_wait_empty_thread, (gpointer)sem, TRUE, NULL); - - /* sleep to give semaphore_decrement() a chance to block (or not). */ - g_usleep(G_USEC_PER_SEC / 4); - - /* add another 10, so decrement can hit zero next time it's called */ - semaphore_increment(sem, 10); - - /* and wait on the semaphore emptying */ - semaphore_wait_empty(sem); - - /* join the thread and see how it fared. */ - rv = GPOINTER_TO_INT(g_thread_join(th)); - - semaphore_free(sem); - - return (rv == 1); -} - -/* - * test that semaphore_force_adjust correctly wakes both - * semaphore_decrement and semaphore_wait_empty. - */ - -static gpointer -test_force_adjust_thread(gpointer datap) -{ - semaphore_t *sem = datap; - - /* this should block */ - semaphore_decrement(sem, 20); - - /* and this should block, too - it's fun */ - semaphore_wait_empty(sem); - - return NULL; -} - -static gboolean -test_force_adjust(void) -{ - GThread *th; - semaphore_t *sem = semaphore_new_with_value(10); - - th = g_thread_create(test_force_adjust_thread, (gpointer)sem, TRUE, NULL); - - /* sleep to give semaphore_decrement() a chance to block (or not). */ - g_usleep(G_USEC_PER_SEC / 4); - - /* add another 20, so decrement can proceed, but leave the value at 10 */ - semaphore_force_adjust(sem, 20); - - /* sleep to give semaphore_wait_empty() a chance to block (or not). */ - g_usleep(G_USEC_PER_SEC / 4); - - /* and empty out the semaphore */ - semaphore_force_adjust(sem, -10); - - g_thread_join(th); - - semaphore_free(sem); - - /* it we didn't hang yet, it's all good */ - return TRUE; -} - -/* - * test that semaphore_force_set correctly wakes both - * semaphore_decrement and semaphore_wait_empty. - */ - -static gpointer -test_force_set_thread(gpointer datap) -{ - semaphore_t *sem = datap; - - /* this should block */ - semaphore_decrement(sem, 20); - - /* and this should block, too - it's fun */ - semaphore_wait_empty(sem); - - return NULL; -} - -static gboolean -test_force_set(void) -{ - GThread *th; - semaphore_t *sem = semaphore_new_with_value(10); - - th = g_thread_create(test_force_set_thread, (gpointer)sem, TRUE, NULL); - - /* sleep to give semaphore_decrement() a chance to block (or not). */ - g_usleep(G_USEC_PER_SEC / 4); - - /* set it to 30, so decrement can proceed, but leave the value at 10 */ - semaphore_force_set(sem, 30); - - /* sleep to give semaphore_wait_empty() a chance to block (or not). */ - g_usleep(G_USEC_PER_SEC / 4); - - /* and empty out the semaphore */ - semaphore_force_set(sem, 0); - - g_thread_join(th); - - semaphore_free(sem); - - /* it we didn't hang yet, it's all good */ - return TRUE; -} - -/* - * Main loop - */ - -int -main(int argc, char **argv) -{ -#if defined(G_THREADS_ENABLED) && !defined(G_THREADS_IMPL_NONE) - static TestUtilsTest tests[] = { - TU_TEST(test_decr_wait, 90), - TU_TEST(test_wait_empty, 90), - TU_TEST(test_force_adjust, 90), - TU_TEST(test_force_set, 90), - TU_END() - }; - - glib_init(); - - return testutils_run_tests(argc, argv, tests); -#else - g_fprintf(stderr, "No thread support on this platform -- nothing to test\n"); - return 0; -#endif -} diff --git a/common-src/semaphore.c b/common-src/semaphore.c deleted file mode 100644 index d82baf4..0000000 --- a/common-src/semaphore.c +++ /dev/null @@ -1,122 +0,0 @@ -/* - * Copyright (c) 2008, 2009, 2010 Zmanda, Inc. All Rights Reserved. - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 as published - * by the Free Software Foundation. - * - * 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 - * - * Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300 - * Sunnyvale, CA 94085, USA, or: http://www.zmanda.com - */ - -/* GLib does not provide semaphores, which are useful in queue.c. - So, we implement it here. */ - -#include "amanda.h" -#include "semaphore.h" - -semaphore_t* semaphore_new_with_value(int value) { - semaphore_t *rval; - - if (!g_thread_supported()) - return NULL; - - rval = malloc(sizeof(*rval)); - rval->value = value; - rval->mutex = g_mutex_new(); - rval->decrement_cond = g_cond_new(); - rval->zero_cond = g_cond_new(); - - if (rval->mutex == NULL || rval->decrement_cond == NULL || - rval->zero_cond == NULL) { - semaphore_free(rval); - return NULL; - } else { - return rval; - } -} - -void semaphore_free(semaphore_t* o) { - g_mutex_free(o->mutex); - g_cond_free(o->decrement_cond); - g_cond_free(o->zero_cond); - free(o); -} - -/* This function checks if the semaphore would is zero or negative. - * If so, the zero_cond is signalled. We assume that the mutex is - * locked. */ -static void check_empty(semaphore_t * o) { - if (o->value <= 0) { - g_cond_broadcast(o->zero_cond); - } -} - -void semaphore_increment(semaphore_t* o, unsigned int inc) { - g_return_if_fail(o != NULL); - g_return_if_fail(inc != 0); - - semaphore_force_adjust(o, inc); -} - -void semaphore_decrement(semaphore_t* o, unsigned int dec) { - int sdec; - g_return_if_fail(o != NULL); - sdec = (int) dec; - g_return_if_fail(sdec >= 0); - - g_mutex_lock(o->mutex); - while (o->value < sdec) { - g_cond_wait(o->decrement_cond, o->mutex); - } - o->value -= sdec; - check_empty(o); - g_mutex_unlock(o->mutex); -} - -void semaphore_force_adjust(semaphore_t* o, int inc) { - g_return_if_fail(o != NULL); - - g_mutex_lock(o->mutex); - o->value += inc; - if (inc < 0) - check_empty(o); - else - g_cond_broadcast(o->decrement_cond); - g_mutex_unlock(o->mutex); - -} - -void semaphore_force_set(semaphore_t* o, int value) { - int oldvalue; - g_return_if_fail(o != NULL); - - g_mutex_lock(o->mutex); - oldvalue = o->value; - o->value = value; - if (value < oldvalue) - check_empty(o); - else - g_cond_broadcast(o->decrement_cond); - g_mutex_unlock(o->mutex); - -} - -void semaphore_wait_empty(semaphore_t * o) { - g_return_if_fail(o != NULL); - - g_mutex_lock(o->mutex); - while (o->value > 0) { - g_cond_wait(o->zero_cond, o->mutex); - } - g_mutex_unlock(o->mutex); -} diff --git a/common-src/semaphore.h b/common-src/semaphore.h deleted file mode 100644 index 204025d..0000000 --- a/common-src/semaphore.h +++ /dev/null @@ -1,107 +0,0 @@ -/* - * Copyright (c) 2008,2009 Zmanda, Inc. All Rights Reserved. - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 as published - * by the Free Software Foundation. - * - * 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 - * - * Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300 - * Sunnyvale, CA 94085, USA, or: http://www.zmanda.com - */ - -/* GLib does not provide semaphores, which are useful in queue.c. - So, we implement it here. */ - -#include - -#ifndef SEMAPHORE_H - -typedef struct { - int value; - GMutex *mutex; - GCond * decrement_cond; - GCond * zero_cond; -} semaphore_t; - -/* Create a new semaphore object with the given value. - * - * @param value: new value - * @returns: newly allocated semaphore_t - */ -semaphore_t* semaphore_new_with_value(int value); - -/* Shortcut to make a new semaphore with value 1. - */ -#define semaphore_new() semaphore_new_with_value(1) - -/* Free a semaphore allocated by semaphore_with_new_value(). Be sure the - * semaphore is no longer in use by any threads. - * - * @param sem: the semaphore to free - */ -void semaphore_free(semaphore_t *sem); - -/* Increment the value of the semaphore by incr. This corresponds to - * Dijkstra's V(), or the typical semaphore's release(). - * - * This function will not block, but may wake other threads waiting - * on semaphore_decrement(). - * - * @param sem: the semaphore - * @param incr: added to the semaphore's value - */ -void semaphore_increment(semaphore_t *sem, unsigned int incr); - -/* Shortcut to increment the semaphore by 1. - */ -#define semaphore_up(semaphore) semaphore_increment(semaphore,1) - -/* Decrement the value of the semaphore by incr. If this operation - * would make the semaphore negative, block until the semaphore - * value is large enough, then perform the decerement operation. Threads - * waiting on semaphore_wait_empty() may be awakened if the value - * reaches 0. - * - * @param sem: the semaphore - * @param decr: subtracted from the semaphore's value - */ -void semaphore_decrement(semaphore_t *sem, unsigned int decr); - -/* Shortcut to decrement the semaphore by 1. - */ -#define semaphore_down(semaphore) semaphore_decrement(semaphore, 1) - -/* Increment or decrement (with a negative incr) the value without - * blocking. Threads waiting on semaphore_decrement() or - * semaphore_wait_empty() will be awakened if necessary. - * - * @param sem: the semaphore - * @param incr: added to the semaphore's value - */ -void semaphore_force_adjust(semaphore_t *sem, int incr); - -/* Set the semaphore to a given value without blocking. Threads - * waiting on semaphore_decrement() or semaphore_wait_empty() - * will be awakened if necessary. - * - * @param sem: the semaphore - * @param value: the new value - */ -void semaphore_force_set(semaphore_t *sem, int value); - -/* Block until the semaphore's value is zero. - * - * @param sem: the semaphore - */ -void semaphore_wait_empty(semaphore_t *sem); - -#endif /* SEMAPHORE_H */ diff --git a/common-src/stream.c b/common-src/stream.c index 9f93cce..d02798f 100644 --- a/common-src/stream.c +++ b/common-src/stream.c @@ -205,14 +205,11 @@ stream_client_internal( { sockaddr_union svaddr, claddr; int save_errno = 0; - char *f; int client_socket = 0; int *portrange = NULL; int result; struct addrinfo *res, *res_addr; - f = priv ? "stream_client_privileged" : "stream_client"; - result = resolve_hostname(hostname, SOCK_STREAM, &res, NULL); if(result != 0) { g_debug(_("resolve_hostname(%s): %s"), hostname, gai_strerror(result)); diff --git a/common-src/svn-info.h b/common-src/svn-info.h index 51eff3b..1711f25 100644 --- a/common-src/svn-info.h +++ b/common-src/svn-info.h @@ -1,2 +1,2 @@ -#define BUILT_REV "4084" -#define BUILT_BRANCH "3_3" +#define BUILT_REV "4553" +#define BUILT_BRANCH "community_3_3_1" diff --git a/common-src/util.c b/common-src/util.c index c6368a2..b9172ca 100644 --- a/common-src/util.c +++ b/common-src/util.c @@ -1605,3 +1605,73 @@ debug_executing( amfree(cmdline); } +char * +get_first_line( + GPtrArray *argv_ptr) +{ + char *output_string = NULL; + int inpipe[2], outpipe[2], errpipe[2]; + int pid; + FILE *out, *err; + + assert(argv_ptr != NULL); + assert(argv_ptr->pdata != NULL); + assert(argv_ptr->len >= 1); + + if (pipe(inpipe) == -1) { + error(_("error [open pipe: %s]"), strerror(errno)); + /*NOTREACHED*/ + } + if (pipe(outpipe) == -1) { + error(_("error [open pipe: %s]"), strerror(errno)); + /*NOTREACHED*/ + } + if (pipe(errpipe) == -1) { + error(_("error [open pipe: %s]"), strerror(errno)); + /*NOTREACHED*/ + } + + fflush(stdout); + switch(pid = fork()) { + case -1: + error(_("error [fork: %s]"), strerror(errno)); + /*NOTREACHED*/ + + default: /* parent process */ + aclose(inpipe[0]); + aclose(outpipe[1]); + aclose(errpipe[1]); + break; + + case 0: /* child process */ + aclose(inpipe[1]); + aclose(outpipe[0]); + aclose(errpipe[0]); + + dup2(inpipe[0], 0); + dup2(outpipe[1], 1); + dup2(errpipe[1], 2); + + debug_executing(argv_ptr); + g_fprintf(stdout, "unknown\n"); + execv((char *)*argv_ptr->pdata, (char **)argv_ptr->pdata); + error(_("error [exec %s: %s]"), (char *)*argv_ptr->pdata, strerror(errno)); + } + + aclose(inpipe[1]); + + out = fdopen(outpipe[0],"r"); + err = fdopen(errpipe[0],"r"); + + output_string = agets(out); + if (!output_string) + output_string = agets(err); + + fclose(out); + fclose(err); + + waitpid(pid, NULL, 0); + + return output_string; +} + diff --git a/common-src/util.h b/common-src/util.h index a0a98e4..140982f 100644 --- a/common-src/util.h +++ b/common-src/util.h @@ -391,4 +391,6 @@ void property_add_to_argv(GPtrArray *argv_ptr, GHashTable *proplist); */ void debug_executing(GPtrArray *argv_ptr); +/* execute the program and get the first line from stdout ot stderr */ +char *get_first_line(GPtrArray *argv_ptr); #endif /* UTIL_H */ diff --git a/config/Makefile.in b/config/Makefile.in index e5fb104..9f8e8e6 100644 --- a/config/Makefile.in +++ b/config/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -263,6 +263,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -695,6 +696,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -744,6 +746,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -752,6 +755,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -759,6 +763,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -903,6 +909,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -936,6 +943,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -978,7 +986,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/config/amanda/libs.m4 b/config/amanda/libs.m4 index 1cee766..b853132 100644 --- a/config/amanda/libs.m4 +++ b/config/amanda/libs.m4 @@ -98,13 +98,14 @@ AC_DEFUN([AMANDA_CHECK_NET_LIBS], [ # "out of the box" on more boxes. # AC_DEFUN([AMANDA_CHECK_GLIB], [ - AC_ARG_VAR(GLIB_CFLAGS, [CFLAGS to build with glib; disables use of pkg-config]) - AC_ARG_VAR(GLIB_LIBS, [libraries to build with glib; disables use of pkg-config]) - AC_ARG_VAR(GLIB_GENMARSHAL, [genmarshal binary to use with glib; disables use of pkg-config]) - AC_ARG_VAR(GOBJECT_QUERY, [gobject_query binary to use with glib; disables use of pkg-config]) - AC_ARG_VAR(GLIB_MKENUMS, [mkenums binary to use with glib; disables use of pkg-config]) - - # if any of the precious variables are set, disable the pkg-config run + AC_ARG_VAR(GLIB_CFLAGS, [CFLAGS to build with glib; disables use of pkg-config; must specify all GLIB_ vars]) + AC_ARG_VAR(GLIB_LIBS, [libraries to build with glib; disables use of pkg-config; must specify all GLIB_vars]) + AC_ARG_VAR(GLIB_GENMARSHAL, [genmarshal binary to use with glib; disables use of pkg-config; must specify all GLIB_ vars]) + AC_ARG_VAR(GOBJECT_QUERY, [gobject_query binary to use with glib; disables use of pkg-config; must specify all GLIB_ vars]) + AC_ARG_VAR(GLIB_MKENUMS, [mkenums binary to use with glib; disables use of pkg-config; must specify all GLIB_ vars]) + + # if any of the precious variables are set, disable the pkg-config run. + # Further, if any is specified, all must be specified. explicit_glib=no test x"$GLIB_CFLAGS" = x"" || explicit_glib=yes test x"$GLIB_LIBS" = x"" || explicit_glib=yes @@ -134,7 +135,16 @@ AC_DEFUN([AMANDA_CHECK_GLIB], [ AC_MSG_ERROR(glib not found or too old; See http://wiki.zmanda.com/index.php/Installation for help) ], gmodule gobject gthread) else - AC_MSG_ERROR(explicit glib) + # Confirm that all GLIB_ variables are set + if test ! x"$GLIB_CFLAGS" = x"" && \ + test ! x"$GLIB_LIBS" = x"" && \ + test ! x"$GLIB_GENMARSHAL" = x"" && \ + test ! x"$GOBJECT_QUERY" = x"" && \ + test ! x"$GLIB_MKENUMS" = x""; then + : + else + AC_MSG_ERROR(Not all precious glib variables were set.) + fi fi # GLIB_CPPFLAGS is not set by autoconf, yet GLIB_CFLAGS contains what GLIB_CPPFLAGS should contain. @@ -296,7 +306,7 @@ AC_DEFUN([LIBCURL_CHECK_CONFIG], _libcurl_save_libs=$LIBS LIBS="$LIBCURL $LIBS" - AC_LINK_IFELSE(AC_LANG_PROGRAM([#include ],[ + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]],[[ /* Try and use a few common options to force a failure if we are missing symbols or can't link. */ int x; @@ -307,7 +317,7 @@ x=CURLOPT_FILE; x=CURLOPT_ERRORBUFFER; x=CURLOPT_STDERR; x=CURLOPT_VERBOSE; -]),libcurl_cv_lib_curl_usable=yes,libcurl_cv_lib_curl_usable=no) +]])],[libcurl_cv_lib_curl_usable=yes],[libcurl_cv_lib_curl_usable=no]) CPPFLAGS=$_libcurl_save_cppflags LIBS=$_libcurl_save_libs diff --git a/config/amanda/progs.m4 b/config/amanda/progs.m4 index 3f79e71..128b03d 100644 --- a/config/amanda/progs.m4 +++ b/config/amanda/progs.m4 @@ -312,6 +312,14 @@ AC_DEFUN([AMANDA_PROG_UMOUNT], AC_ARG_VAR([UMOUNT], [Path to the 'umount' binary]) ]) +AC_DEFUN([AMANDA_PROG_UNAME], +[ + AC_REQUIRE([AMANDA_INIT_PROGS]) + AC_PATH_PROG(UNAME,uname,,$LOCSYSPATH) + AC_DEFINE_UNQUOTED(UNAME_PATH,"$UNAME", + [Define the location of the uname program. ]) +]) + AC_DEFUN([AMANDA_PROG_PCAT], [ AC_REQUIRE([AMANDA_INIT_PROGS]) diff --git a/config/config.h.in b/config/config.h.in index 445f91f..d91daf7 100644 --- a/config/config.h.in +++ b/config/config.h.in @@ -1499,7 +1499,7 @@ /* Define to 1 if the system has the type `struct random_data'. */ #undef HAVE_STRUCT_RANDOM_DATA -/* Define to 1 if `sa_len' is member of `struct sockaddr'. */ +/* Define to 1 if `sa_len' is a member of `struct sockaddr'. */ #undef HAVE_STRUCT_SOCKADDR_SA_LEN /* Define to 1 if the system has the type `struct sockaddr_storage'. */ @@ -1875,6 +1875,9 @@ /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME +/* Define to the home page for this package. */ +#undef PACKAGE_URL + /* Define to the version of this package. */ #undef PACKAGE_VERSION @@ -2045,6 +2048,9 @@ maximum reserved UDP port numbers sockets should be bound to. */ #undef UDPPORTRANGE +/* Define the location of the uname program. */ +#undef UNAME_PATH + /* Define as any optional arguments to get UNCOMPRESS_PATH to uncompress. */ #undef UNCOMPRESS_OPT @@ -2369,13 +2375,14 @@ nothing if this is not supported. Do not define if restrict is supported directly. */ #undef restrict -/* Work around a bug in Sun C++: it does not support _Restrict, even - though the corresponding Sun C compiler does, which causes - "#define restrict _Restrict" in the previous line. Perhaps some future - version of Sun C++ will work with _Restrict; if so, it'll probably - define __RESTRICT, just as Sun C does. */ +/* Work around a bug in Sun C++: it does not support _Restrict or + __restrict__, even though the corresponding Sun C compiler ends up with + "#define restrict _Restrict" or "#define restrict __restrict__" in the + previous line. Perhaps some future version of Sun C++ will work with + restrict; if so, hopefully it defines __RESTRICT like Sun C does. */ #if defined __SUNPRO_CC && !defined __RESTRICT # define _Restrict +# define __restrict__ #endif /* Type for sa_family_t, if it is not defined by the system */ diff --git a/config/libtool.m4 b/config/libtool.m4 index ac0bd3c..88de383 100644 --- a/config/libtool.m4 +++ b/config/libtool.m4 @@ -1,7 +1,8 @@ # 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. +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives @@ -10,7 +11,8 @@ m4_define([_LT_COPYING], [dnl # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008 Free Software Foundation, Inc. +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. # Written by Gordon Matzigkeit, 1996 # # This file is part of GNU Libtool. @@ -37,7 +39,7 @@ m4_define([_LT_COPYING], [dnl # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. ]) -# serial 56 LT_INIT +# serial 57 LT_INIT # LT_PREREQ(VERSION) @@ -66,6 +68,7 @@ esac # ------------------ AC_DEFUN([LT_INIT], [AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT +AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl AC_BEFORE([$0], [LTDL_INIT])dnl @@ -82,6 +85,8 @@ AC_REQUIRE([LTVERSION_VERSION])dnl AC_REQUIRE([LTOBSOLETE_VERSION])dnl m4_require([_LT_PROG_LTMAIN])dnl +_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) + dnl Parse OPTIONS _LT_SET_OPTIONS([$0], [$1]) @@ -118,7 +123,7 @@ m4_defun([_LT_CC_BASENAME], *) break;; esac done -cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` ]) @@ -138,6 +143,9 @@ m4_defun([_LT_FILEUTILS_DEFAULTS], m4_defun([_LT_SETUP], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl + _LT_DECL([], [host_alias], [0], [The host system])dnl _LT_DECL([], [host], [0])dnl _LT_DECL([], [host_os], [0])dnl @@ -160,10 +168,13 @@ _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_PATH_CONVERSION_FUNCTIONS])dnl m4_require([_LT_CMD_RELOAD])dnl m4_require([_LT_CHECK_MAGIC_METHOD])dnl +m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +m4_require([_LT_WITH_SYSROOT])dnl _LT_CONFIG_LIBTOOL_INIT([ # See if we are running on zsh, and set the options which allow our @@ -179,7 +190,6 @@ fi _LT_CHECK_OBJDIR m4_require([_LT_TAG_COMPILER])dnl -_LT_PROG_ECHO_BACKSLASH case $host_os in aix3*) @@ -193,23 +203,6 @@ aix3*) ;; 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 @@ -250,6 +243,28 @@ _LT_CONFIG_COMMANDS ])# _LT_SETUP +# _LT_PREPARE_SED_QUOTE_VARS +# -------------------------- +# Define a few sed substitution that help us do robust quoting. +m4_defun([_LT_PREPARE_SED_QUOTE_VARS], +[# Backslashify 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' +]) + # _LT_PROG_LTMAIN # --------------- # Note that this code is called both from `configure', and `config.status' @@ -380,12 +395,12 @@ m4_define([lt_decl_dquote_varnames], # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_varnames_tagged], -[_$0(m4_quote(m4_default([$1], [[, ]])), - m4_quote(m4_if([$2], [], - m4_quote(lt_decl_tag_varnames), - m4_quote(m4_shift($@)))), - m4_split(m4_normalize(m4_quote(_LT_TAGS))))]) -m4_define([_lt_decl_varnames_tagged], [lt_combine([$1], [$2], [_], $3)]) +[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...]) @@ -408,7 +423,7 @@ m4_define([_lt_decl_all_varnames], # 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"`']) +[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) # _LT_CONFIG_STATUS_DECLARATIONS @@ -418,7 +433,7 @@ m4_define([_LT_CONFIG_STATUS_DECLARE], # 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"`' +# ='`$ECHO "$" | $SED "$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)])])]) @@ -517,12 +532,20 @@ LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$[]1 +_LTECHO_EOF' +} + # Quote evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_quote_varnames); do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -533,9 +556,9 @@ done # Double-quote double-evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_dquote_varnames); do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -543,16 +566,38 @@ for var in lt_decl_all_varnames([[ \ 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_GENERATED_FILE_INIT(FILE, [COMMENT]) +# ------------------------------------ +# Generate a child script FILE with all initialization necessary to +# reuse the environment learned by the parent script, and make the +# file executable. If COMMENT is supplied, it is inserted after the +# `#!' sequence but before initialization text begins. After this +# macro, additional text can be appended to FILE to form the body of +# the child script. The macro ends with non-zero status if the +# file could not be fully written (such as if the disk is full). +m4_ifdef([AS_INIT_GENERATED], +[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], +[m4_defun([_LT_GENERATED_FILE_INIT], +[m4_require([AS_PREPARE])]dnl +[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl +[lt_write_fail=0 +cat >$1 <<_ASEOF || lt_write_fail=1 +#! $SHELL +# Generated by $as_me. +$2 +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$1 <<\_ASEOF || lt_write_fail=1 +AS_SHELL_SANITIZE +_AS_PREPARE +exec AS_MESSAGE_FD>&1 +_ASEOF +test $lt_write_fail = 0 && chmod +x $1[]dnl +m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT # --------- @@ -562,20 +607,11 @@ _LT_OUTPUT_LIBTOOL_INIT 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 +_LT_GENERATED_FILE_INIT(["$CONFIG_LT"], +[# Run this file to recreate a libtool stub with the current configuration.]) cat >>"$CONFIG_LT" <<\_LTEOF -AS_SHELL_SANITIZE -_AS_PREPARE - -exec AS_MESSAGE_FD>&1 +lt_cl_silent=false exec AS_MESSAGE_LOG_FD>>config.log { echo @@ -601,7 +637,7 @@ 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. +Copyright (C) 2010 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation gives unlimited permision to copy, distribute and modify it." @@ -646,15 +682,13 @@ chmod +x "$CONFIG_LT" # 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_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) ])# LT_OUTPUT @@ -717,15 +751,12 @@ _LT_EOF # 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 '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) - sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \ - || (rm -f "$cfgfile"; exit 1) + _LT_PROG_REPLACE_SHELLFNS - mv -f "$cfgfile" "$ofile" || + mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ], @@ -831,11 +862,13 @@ 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)]) +AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) 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], []) +dnl AC_DEFUN([AC_LIBTOOL_RC], []) # _LT_TAG_COMPILER @@ -940,15 +973,40 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ [lt_cv_ld_exported_symbols_list=no]) LDFLAGS="$save_LDFLAGS" ]) + AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], + [lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD + echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD + $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&AS_MESSAGE_LOG_FD + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + ]) 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 + 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? + # 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' ;; @@ -967,7 +1025,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' fi - if test "$DSYMUTIL" != ":"; then + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= @@ -987,11 +1045,19 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], _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)='' + if test "$lt_cv_ld_force_load" = "yes"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + _LT_TAGVAR(whole_archive_flag_spec, $1)='' + fi _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" - if test "$GCC" = "yes"; then - output_verbose_link_cmd=echo + 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=func_echo_all _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}" @@ -1007,203 +1073,142 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], fi ]) -# _LT_SYS_MODULE_PATH_AIX -# ----------------------- +# _LT_SYS_MODULE_PATH_AIX([TAGNAME]) +# ---------------------------------- # 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. +# Store the results from the different compilers for each TAGNAME. +# Allow to override them for all tags through lt_cv_aix_libpath. 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 +if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], + [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ + lt_aix_libpath_sed='[ + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }]' + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`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 "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi],[]) + if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" + fi + ]) + aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) +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 +[m4_divert_text([M4SH-INIT], [$1 +])])# _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. +# Find how we can fake an echo command that does not interpret backslash. +# In particular, with Autoconf 2.60 or later we add some code to the start +# of the generated configure script which will find a shell with a builtin +# printf (which we can use as an echo command). 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! - : +[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +AC_MSG_CHECKING([how to print strings]) +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' 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 + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$[]1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' 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 +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} - 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 +case "$ECHO" in + printf*) AC_MSG_RESULT([printf]) ;; + print*) AC_MSG_RESULT([print -r]) ;; + *) AC_MSG_RESULT([cat]) ;; +esac -# 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 +m4_ifdef([_AS_DETECT_SUGGESTED], +[_AS_DETECT_SUGGESTED([ + test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO + ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test "X`printf %s $ECHO`" = "X$ECHO" \ + || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) -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_DECL([], [ECHO], [1], [An echo program that protects backslashes]) ])# _LT_PROG_ECHO_BACKSLASH +# _LT_WITH_SYSROOT +# ---------------- +AC_DEFUN([_LT_WITH_SYSROOT], +[AC_MSG_CHECKING([for sysroot]) +AC_ARG_WITH([sysroot], +[ --with-sysroot[=DIR] Search for dependent libraries within DIR + (or the compiler's sysroot if not specified).], +[], [with_sysroot=no]) + +dnl lt_sysroot will always be passed unquoted. We quote it here +dnl in case the user passed a directory name. +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + AC_MSG_RESULT([${with_sysroot}]) + AC_MSG_ERROR([The sysroot must be an absolute path.]) + ;; +esac + + AC_MSG_RESULT([${lt_sysroot:-no}]) +_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl +[dependent libraries, and in which our libraries should be installed.])]) + # _LT_ENABLE_LOCK # --------------- m4_defun([_LT_ENABLE_LOCK], @@ -1232,7 +1237,7 @@ ia64-*-hpux*) ;; *-*-irix6*) # Find out which ABI we are using. - echo '[#]line __oline__ "configure"' > conftest.$ac_ext + echo '[#]line '$LINENO' "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 @@ -1350,14 +1355,47 @@ need_locks="$enable_libtool_lock" ])# _LT_ENABLE_LOCK +# _LT_PROG_AR +# ----------- +m4_defun([_LT_PROG_AR], +[AC_CHECK_TOOLS(AR, [ar], false) +: ${AR=ar} +: ${AR_FLAGS=cru} +_LT_DECL([], [AR], [1], [The archiver]) +_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) + +AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], + [lt_cv_ar_at_file=no + AC_COMPILE_IFELSE([AC_LANG_PROGRAM], + [echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' + AC_TRY_EVAL([lt_ar_try]) + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + AC_TRY_EVAL([lt_ar_try]) + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a + ]) + ]) + +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= +else + archiver_list_spec=$lt_cv_ar_at_file +fi +_LT_DECL([], [archiver_list_spec], [1], + [How to feed a file listing to the archiver]) +])# _LT_PROG_AR + + # _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]) +[_LT_PROG_AR AC_CHECK_TOOL(STRIP, strip, :) test -z "$STRIP" && STRIP=: @@ -1384,10 +1422,19 @@ if test -n "$RANLIB"; then esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi + +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac _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_DECL([], [lock_old_archive_extraction], [0], + [Whether to use a lock for old archive extraction]) ])# _LT_CMD_OLD_ARCHIVE @@ -1412,15 +1459,15 @@ AC_CACHE_CHECK([$1], [$2], -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 echo "\"\$as_me:$LINENO: $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 + echo "$as_me:$LINENO: \$? = $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 + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/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 @@ -1460,7 +1507,7 @@ AC_CACHE_CHECK([$1], [$2], 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 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then $2=yes @@ -1512,7 +1559,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl lt_cv_sys_max_cmd_len=-1; ;; - cygwin* | mingw*) + 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, @@ -1523,6 +1570,11 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl lt_cv_sys_max_cmd_len=8192; ;; + mint*) + # On MiNT this can take a long time and run out of memory. + 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. @@ -1587,8 +1639,8 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl # 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 && + while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ + = "X$teststring$teststring"; } >/dev/null 2>&1 && test $i != 17 # 1/2 MB should be enough do i=`expr $i + 1` @@ -1639,7 +1691,7 @@ 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" +[#line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -1680,11 +1732,13 @@ else # endif #endif -#ifdef __cplusplus -extern "C" void exit (int); +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); #endif -void fnord() { int i=42;} +int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); @@ -1693,13 +1747,17 @@ int main () if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } /* dlclose (self); */ } else puts (dlerror ()); - exit (status); + return status; }] _LT_EOF if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then @@ -1738,7 +1796,7 @@ else lt_cv_dlopen_self=yes ;; - mingw* | pw32*) + mingw* | pw32* | cegcc*) lt_cv_dlopen="LoadLibrary" lt_cv_dlopen_libs= ;; @@ -1869,16 +1927,16 @@ AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], -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 echo "\"\$as_me:$LINENO: $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 + echo "$as_me:$LINENO: \$? = $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 + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/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 @@ -2035,7 +2093,9 @@ 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 +m4_require([_LT_CHECK_SHELL_FEATURES])dnl AC_MSG_CHECKING([dynamic linker characteristics]) m4_if([$1], [], [ @@ -2044,16 +2104,23 @@ if test "$GCC" = yes; then 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 + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) # 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 + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac # 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= @@ -2066,7 +2133,7 @@ if test "$GCC" = yes; then 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 ' + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS=" "; FS="/|\n";} { lt_foo=""; lt_count=0; @@ -2086,7 +2153,13 @@ BEGIN {RS=" "; FS="/|\n";} { 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` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi]) @@ -2174,7 +2247,7 @@ amigaos*) 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' + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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 ;; @@ -2199,14 +2272,15 @@ bsdi[[45]]*) # libtool to hard-code these into programs ;; -cygwin* | mingw* | pw32*) +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*) + case $GCC,$cc_basename in + yes,*) + # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ @@ -2227,36 +2301,83 @@ cygwin* | mingw* | pw32*) 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" +m4_if([$1], [],[ + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; - mingw*) + 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 + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then + # It is most probably a Windows format PATH. + 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 + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # 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 + dynamic_linker='Win32 link.exe' ;; *) + # Assume MSVC wrapper library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' ;; esac - dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; @@ -2300,14 +2421,7 @@ freebsd* | dragonfly*) *) objformat=elf ;; esac fi - # Handle Gentoo/FreeBSD as it was Linux - case $host_vendor in - gentoo) - version_type=linux ;; - *) - version_type=freebsd-$objformat ;; - esac - + 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}' @@ -2318,12 +2432,6 @@ freebsd* | dragonfly*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; - linux) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - need_lib_prefix=no - need_version=no - ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in @@ -2356,6 +2464,19 @@ gnu*) hardcode_into_libs=yes ;; +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + 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=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + 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. @@ -2398,8 +2519,10 @@ hpux9* | hpux10* | hpux11*) soname_spec='${libname}${release}${shared_ext}$major' ;; esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 ;; interix[[3-9]]*) @@ -2457,7 +2580,7 @@ linux*oldld* | linux*aout* | linux*coff*) ;; # This must be Linux ELF. -linux* | k*bsd*-gnu) +linux* | k*bsd*-gnu | kopensolaris*-gnu) version_type=linux need_lib_prefix=no need_version=no @@ -2466,26 +2589,35 @@ linux* | k*bsd*-gnu) 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 + AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], + [lt_cv_shlibpath_overrides_runpath=no + 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], + [lt_cv_shlibpath_overrides_runpath=yes])]) + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir + ]) + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # 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 + # Add ABI-specific directories to the system library path. + sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" + # 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" + 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;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" + fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -2668,7 +2800,7 @@ tpf*) version_type=linux need_lib_prefix=no need_version=no - library_name_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + 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 @@ -2692,7 +2824,7 @@ 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 @@ -2717,6 +2849,8 @@ _LT_DECL([], [library_names_spec], [1], 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([], [install_override_mode], [1], + [Permission mode override for installation of shared libraries]) _LT_DECL([], [postinstall_cmds], [2], [Command to use after installation of a shared archive]) _LT_DECL([], [postuninstall_cmds], [2], @@ -2829,6 +2963,7 @@ AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PROG_ECHO_BACKSLASH])dnl AC_ARG_WITH([gnu-ld], [AS_HELP_STRING([--with-gnu-ld], @@ -2950,6 +3085,11 @@ case $reload_flag in esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; darwin*) if test "$GCC" = yes; then reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' @@ -2958,8 +3098,8 @@ case $host_os in fi ;; esac -_LT_DECL([], [reload_flag], [1], [How to create reloadable object files])dnl -_LT_DECL([], [reload_cmds], [2])dnl +_LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl +_LT_TAGDECL([], [reload_cmds], [2])dnl ])# _LT_CMD_RELOAD @@ -2969,6 +3109,7 @@ _LT_DECL([], [reload_cmds], [2])dnl # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_MAGIC_METHOD], [m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) AC_CACHE_CHECK([how to recognize dependent libraries], lt_cv_deplibs_check_method, [lt_cv_file_magic_cmd='$MAGIC_CMD' @@ -3010,15 +3151,23 @@ 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 + # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. + if ( test "$lt_cv_nm_interface" = "BSD nm" && 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)?' + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' 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 ;; @@ -3043,6 +3192,10 @@ gnu*) lt_cv_deplibs_check_method=pass_all ;; +haiku*) + lt_cv_deplibs_check_method=pass_all + ;; + hpux10.20* | hpux11*) lt_cv_file_magic_cmd=/usr/bin/file case $host_cpu in @@ -3051,11 +3204,11 @@ hpux10.20* | hpux11*) 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_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? 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_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 @@ -3077,7 +3230,7 @@ irix5* | irix6* | nonstopux*) ;; # This must be Linux ELF. -linux* | k*bsd*-gnu) +linux* | k*bsd*-gnu | kopensolaris*-gnu) lt_cv_deplibs_check_method=pass_all ;; @@ -3155,6 +3308,21 @@ tpf*) ;; esac ]) + +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` + fi + ;; + esac +fi + 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 @@ -3162,7 +3330,11 @@ 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"]) + [Command to use when deplibs_check_method = "file_magic"]) +_LT_DECL([], [file_magic_glob], [1], + [How to find potential files when deplibs_check_method = "file_magic"]) +_LT_DECL([], [want_nocaseglob], [1], + [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) ])# _LT_CHECK_MAGIC_METHOD @@ -3219,7 +3391,19 @@ 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"], :) + if test -n "$DUMPBIN"; then : + # Let the user override the test. + else + AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi AC_SUBST([DUMPBIN]) if test "$DUMPBIN" != ":"; then NM="$DUMPBIN" @@ -3232,13 +3416,13 @@ _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 echo "\"\$as_me:$LINENO: $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 echo "\"\$as_me:$LINENO: $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) + (eval echo "\"\$as_me:$LINENO: 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" @@ -3253,20 +3437,81 @@ dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_PROG_NM], []) dnl AC_DEFUN([AC_PROG_NM], []) +# _LT_CHECK_SHAREDLIB_FROM_LINKLIB +# -------------------------------- +# how to determine the name of the shared library +# associated with a specific link library. +# -- PORTME fill in with the dynamic library characteristics +m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], +[m4_require([_LT_DECL_EGREP]) +m4_require([_LT_DECL_OBJDUMP]) +m4_require([_LT_DECL_DLLTOOL]) +AC_CACHE_CHECK([how to associate runtime and link libraries], +lt_cv_sharedlib_from_linklib_cmd, +[lt_cv_sharedlib_from_linklib_cmd='unknown' -# 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") +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib + ;; + *) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback + ;; + esac + ;; +*) + # fallback: assume linklib IS sharedlib + lt_cv_sharedlib_from_linklib_cmd="$ECHO" + ;; +esac +]) +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO + +_LT_DECL([], [sharedlib_from_linklib_cmd], [1], + [Command to associate shared and link libraries]) +])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB + + +# _LT_PATH_MANIFEST_TOOL +# ---------------------- +# locate the manifest tool +m4_defun([_LT_PATH_MANIFEST_TOOL], +[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], + [lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&AS_MESSAGE_LOG_FD + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest*]) +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi +_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl +])# _LT_PATH_MANIFEST_TOOL + + +# LT_LIB_M +# -------- +# check for math library +AC_DEFUN([LT_LIB_M], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +LIBM= +case $host in +*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-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") @@ -3289,7 +3534,12 @@ m4_defun([_LT_COMPILER_NO_RTTI], _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' + case $cc_basename in + nvcc*) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; + *) + _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; + esac _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], lt_cv_prog_compiler_rtti_exceptions, @@ -3306,6 +3556,7 @@ _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], m4_defun([_LT_CMD_GLOBAL_SYMBOLS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([LT_PATH_NM])dnl AC_REQUIRE([LT_PATH_LD])dnl m4_require([_LT_DECL_SED])dnl @@ -3330,7 +3581,7 @@ case $host_os in aix*) symcode='[[BCDT]]' ;; -cygwin* | mingw* | pw32*) +cygwin* | mingw* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) @@ -3373,8 +3624,8 @@ esac 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'" +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= @@ -3410,6 +3661,7 @@ for ac_symprfx in "" "_"; do else lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no @@ -3431,7 +3683,7 @@ _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 + 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" @@ -3443,6 +3695,18 @@ _LT_EOF if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT@&t@_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT@&t@_DLSYM_CONST +#else +# define LT@&t@_DLSYM_CONST const +#endif + #ifdef __cplusplus extern "C" { #endif @@ -3454,7 +3718,7 @@ _LT_EOF cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ -const struct { +LT@&t@_DLSYM_CONST struct { const char *name; void *address; } @@ -3480,15 +3744,15 @@ static const void *lt_preloaded_setup() { _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" + lt_globsym_save_LIBS=$LIBS + lt_globsym_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" + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD fi @@ -3521,6 +3785,13 @@ else AC_MSG_RESULT(ok) fi +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then + nm_file_list_spec='@' +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], @@ -3531,6 +3802,8 @@ _LT_DECL([global_symbol_to_c_name_address], _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_DECL([], [nm_file_list_spec], [1], + [Specify filename containing input files for $NM]) ]) # _LT_CMD_GLOBAL_SYMBOLS @@ -3542,7 +3815,6 @@ _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 @@ -3576,7 +3848,7 @@ m4_if([$1], [CXX], [ beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; - mingw* | cygwin* | os2* | pw32*) + 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 @@ -3593,6 +3865,11 @@ m4_if([$1], [CXX], [ # DJGPP does not support shared libraries at all _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. @@ -3603,10 +3880,11 @@ m4_if([$1], [CXX], [ fi ;; hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. + # 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*|ia64*) + hppa*64*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' @@ -3641,6 +3919,12 @@ m4_if([$1], [CXX], [ ;; esac ;; + 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). + m4_if([$1], [GCJ], [], + [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + ;; dgux*) case $cc_basename in ec++*) @@ -3697,19 +3981,26 @@ m4_if([$1], [CXX], [ ;; esac ;; - linux* | k*bsd*-gnu) + 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' ;; - icpc* | ecpc* ) - # Intel C++ + 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,' @@ -3723,8 +4014,8 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; - xlc* | xlC*) - # IBM XL 8.0 on PPC + xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) + # IBM XL 8.0, 9.0 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' @@ -3786,7 +4077,7 @@ m4_if([$1], [CXX], [ ;; solaris*) case $cc_basename in - CC*) + CC* | sunCC*) # 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' @@ -3875,7 +4166,7 @@ m4_if([$1], [CXX], [ # PIC is the default for these OSes. ;; - mingw* | cygwin* | pw32* | os2*) + 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 @@ -3890,11 +4181,18 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + _LT_TAGVAR(lt_prog_compiler_static, $1)= + ;; + hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. + # 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*|ia64*) + hppa*64*) # +Z the default ;; *) @@ -3931,6 +4229,13 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Xcompiler -fPIC' + ;; + esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in @@ -3944,7 +4249,7 @@ m4_if([$1], [CXX], [ fi ;; - mingw* | cygwin* | pw32* | os2*) + 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], [], @@ -3973,14 +4278,34 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; - linux* | k*bsd*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu) case $cc_basename in - icc* | ecc* | ifort*) + # 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' ;; - pgcc* | pgf77* | pgf90* | pgf95*) + # 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' + ;; + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' @@ -3992,25 +4317,25 @@ m4_if([$1], [CXX], [ # 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 + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene _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 + *Sun\ F* | *Sun*Fortran*) + # 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)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='' ;; - *Sun\ F*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker + *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)='' + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; esac ;; @@ -4042,7 +4367,7 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' case $cc_basename in - f77* | f90* | f95*) + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; *) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; @@ -4099,9 +4424,11 @@ case $host_os in _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]) + +AC_CACHE_CHECK([for $compiler option to produce PIC], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], + [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) +_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) # # Check to make sure the PIC flag actually works. @@ -4120,6 +4447,8 @@ fi _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], [Additional compiler flags for building library objects]) +_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], + [How to pass a linker flag through the compiler]) # # Check to make sure the static flag actually works. # @@ -4140,6 +4469,7 @@ _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], m4_defun([_LT_LINKER_SHLIBS], [AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_DECL_SED])dnl @@ -4148,27 +4478,35 @@ 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' + _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] 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 + # Also, AIX nm treats weak defined symbols like other global defined + # symbols, whereas GNU nm marks them as "W". 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' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([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*) - _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' - ;; + ;; + cygwin* | mingw* | cegcc*) + case $cc_basename in + cl*) ;; + *) + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] + ;; + esac + ;; *) _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)= @@ -4213,7 +4551,7 @@ dnl Note also adjust exclude_expsyms for C++ above. extract_expsyms_cmds= case $host_os in - cygwin* | mingw* | pw32*) + 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++. @@ -4231,7 +4569,33 @@ dnl Note also adjust exclude_expsyms for C++ above. esac _LT_TAGVAR(ld_shlibs, $1)=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; + *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' @@ -4249,6 +4613,7 @@ dnl Note also adjust exclude_expsyms for C++ above. 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 ... @@ -4264,11 +4629,12 @@ dnl Note also adjust exclude_expsyms for C++ above. _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 +*** Warning: the GNU linker, at least up to release 2.19, 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. +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. _LT_EOF fi @@ -4300,14 +4666,16 @@ _LT_EOF fi ;; - cygwin* | mingw* | pw32*) + 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(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' _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' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' + _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] 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' @@ -4325,6 +4693,11 @@ _LT_EOF fi ;; + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no @@ -4340,7 +4713,7 @@ _LT_EOF _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) + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test "$host_os" = linux-dietlibc; then case $cc_basename in @@ -4350,15 +4723,16 @@ _LT_EOF if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test "$tmp_diet" = no then - tmp_addflag= + tmp_addflag=' $pic_flag' 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' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$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' + pgf77* | pgf90* | pgf95* | pgfortran*) + # 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; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; @@ -4366,13 +4740,20 @@ _LT_EOF tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; - xl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) + lf95*) # Lahey Fortran 8.1 + _LT_TAGVAR(whole_archive_flag_spec, $1)= + tmp_sharedflag='--shared' ;; + xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(compiler_needs_object, $1)=yes + ;; 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(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 @@ -4388,17 +4769,17 @@ _LT_EOF fi case $cc_basename in - xlf*) + xlf* | bgf* | bgxlf* | mpixlf*) # 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' + _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_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' + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac @@ -4412,8 +4793,8 @@ _LT_EOF _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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; @@ -4431,8 +4812,8 @@ _LT_EOF _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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $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 @@ -4478,8 +4859,8 @@ _LT_EOF *) 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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $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 @@ -4519,8 +4900,10 @@ _LT_EOF 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 + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". 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' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([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 @@ -4597,6 +4980,7 @@ _LT_EOF 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 @@ -4606,9 +4990,9 @@ _LT_EOF _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_SYS_MODULE_PATH_AIX([$1]) _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" + _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 func_echo_all "${wl}${allow_undefined_flag}"; 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' @@ -4617,14 +5001,19 @@ _LT_EOF else # Determine the default libpath from the value encoded in an # empty executable. - _LT_SYS_MODULE_PATH_AIX + _LT_SYS_MODULE_PATH_AIX([$1]) _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' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi _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' @@ -4651,25 +5040,68 @@ _LT_EOF _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; - cygwin* | mingw* | pw32*) + 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 + case $cc_basename in + cl*) + # Native MSVC + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # 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 $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _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' + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + _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 `func_echo_all "$deplibs" | $SED '\''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(enable_shared_with_static_runtimes, $1)=yes + ;; + esac ;; darwin* | rhapsody*) @@ -4707,7 +5139,7 @@ _LT_EOF # 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(archive_cmds, $1)='$CC -shared $pic_flag -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 @@ -4715,7 +5147,7 @@ _LT_EOF 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' + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${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 @@ -4730,8 +5162,8 @@ _LT_EOF ;; 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' + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${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 @@ -4749,16 +5181,16 @@ _LT_EOF ;; hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then + if test "$GCC" = yes && test "$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 ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else @@ -4770,7 +5202,14 @@ _LT_EOF _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' + m4_if($1, [], [ + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + _LT_LINKER_OPTION([if $CC understands -b], + _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], + [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_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 @@ -4798,19 +5237,34 @@ _LT_EOF 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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${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" + # This should be the same for all languages, so no per-tag cache variable. + AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], + [lt_cv_irix_exported_symbol], + [save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + AC_LINK_IFELSE( + [AC_LANG_SOURCE( + [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], + [C++], [[int foo (void) { return 0; }]], + [Fortran 77], [[ + subroutine foo + end]], + [Fortran], [[ + subroutine foo + end]])])], + [lt_cv_irix_exported_symbol=yes], + [lt_cv_irix_exported_symbol=no]) + LDFLAGS="$save_LDFLAGS"]) + if test "$lt_cv_irix_exported_symbol" = yes; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi 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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -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" && func_echo_all "-set_version $verstring"` -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' @@ -4872,17 +5326,17 @@ _LT_EOF _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(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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -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' @@ -4892,13 +5346,13 @@ _LT_EOF 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(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${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_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -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' + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' @@ -4911,9 +5365,9 @@ _LT_EOF _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_cmds, $1)='$CC -shared $pic_flag ${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' + $CC -shared $pic_flag ${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"*) @@ -5089,36 +5543,38 @@ x|xyes) # 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)]) + AC_CACHE_CHECK([whether -lc should be explicitly linked in], + [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), + [$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_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no + else + lt_cv_[]_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* + ]) + _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) ;; esac fi @@ -5183,8 +5639,6 @@ _LT_TAGDECL([], [inherit_rpath], [0], 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], @@ -5195,6 +5649,8 @@ _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([], [postlink_cmds], [2], + [Commands necessary for finishing linking programs]) _LT_TAGDECL([], [file_list_spec], [1], [Specify filename containing input files]) dnl FIXME: Not yet implemented @@ -5288,37 +5744,22 @@ 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_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl +m4_require([_LT_PATH_MANIFEST_TOOL])dnl +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 AC_LANG_PUSH(C++) _LT_TAGVAR(archive_cmds_need_lc, $1)=no @@ -5340,6 +5781,8 @@ _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(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no @@ -5371,6 +5814,7 @@ if test "$_lt_caught_CXX_error" != yes; then # Allow CC to be a program name with arguments. lt_save_CC=$CC + lt_save_CFLAGS=$CFLAGS lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX @@ -5388,6 +5832,7 @@ if test "$_lt_caught_CXX_error" != yes; then fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} + CFLAGS=$CXXFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) @@ -5409,8 +5854,8 @@ if test "$_lt_caught_CXX_error" != yes; then # 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(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -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' @@ -5442,7 +5887,7 @@ if test "$_lt_caught_CXX_error" != yes; then # 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"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else GXX=no @@ -5540,6 +5985,7 @@ if test "$_lt_caught_CXX_error" != yes; then 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. @@ -5550,10 +5996,10 @@ if test "$_lt_caught_CXX_error" != yes; then _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_SYS_MODULE_PATH_AIX([$1]) _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" + _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 func_echo_all "${wl}${allow_undefined_flag}"; 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' @@ -5562,14 +6008,19 @@ if test "$_lt_caught_CXX_error" != yes; then else # Determine the default libpath from the value encoded in an # empty executable. - _LT_SYS_MODULE_PATH_AIX + _LT_SYS_MODULE_PATH_AIX([$1]) _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' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' + fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes # This is similar to how AIX traditionally builds its shared # libraries. @@ -5598,29 +6049,76 @@ if test "$_lt_caught_CXX_error" != yes; then esac ;; - cygwin* | mingw* | pw32*) - # _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 - ;; + cygwin* | mingw* | pw32* | cegcc*) + case $GXX,$cc_basename in + ,cl* | no,cl*) + # Native MSVC + # 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 + _LT_TAGVAR(always_export_symbols, $1)=yes + _LT_TAGVAR(file_list_spec, $1)='@' + # 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 $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + # Don't use ranlib + _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' + _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # g++ + # _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(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _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 + ;; + esac + ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; @@ -5662,6 +6160,11 @@ if test "$_lt_caught_CXX_error" != yes; then gnu*) ;; + haiku*) + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(link_all_deplibs, $1)=yes + ;; + hpux9*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: @@ -5686,11 +6189,11 @@ if test "$_lt_caught_CXX_error" != yes; then # 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' + 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; func_echo_all "$list"' ;; *) 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' + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${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 @@ -5751,7 +6254,7 @@ if test "$_lt_caught_CXX_error" != yes; then # 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' + 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; func_echo_all "$list"' ;; *) if test "$GXX" = yes; then @@ -5761,10 +6264,10 @@ if test "$_lt_caught_CXX_error" != yes; then _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 $pic_flag ${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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi @@ -5794,7 +6297,7 @@ if test "$_lt_caught_CXX_error" != yes; then 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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is @@ -5805,9 +6308,9 @@ if test "$_lt_caught_CXX_error" != yes; then *) 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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' fi fi _LT_TAGVAR(link_all_deplibs, $1)=yes @@ -5818,7 +6321,7 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(inherit_rpath, $1)=yes ;; - linux* | k*bsd*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler @@ -5836,7 +6339,7 @@ if test "$_lt_caught_CXX_error" != yes; then # 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' + 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; func_echo_all "$list"' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' @@ -5873,26 +6376,26 @@ if test "$_lt_caught_CXX_error" != yes; then pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in - *pgCC\ [[1-5]]* | *pgcpp\ [[1-5]]*) + *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`"' + compile_command="$compile_command `find $tpldir -name \*.o | sort | $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`~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $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' + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $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' + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' ;; - *) # Version 6 will use weak symbols + *) # Version 6 and above 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' ;; @@ -5900,7 +6403,7 @@ if test "$_lt_caught_CXX_error" != yes; then _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' + _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' ;; cxx*) # Compaq C++ @@ -5919,9 +6422,9 @@ if test "$_lt_caught_CXX_error" != yes; then # 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' + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$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; func_echo_all "X$list" | $Xsed' ;; - xl*) + xl* | mpixl* | bgxl*) # 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' @@ -5941,13 +6444,13 @@ if test "$_lt_caught_CXX_error" != yes; then _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(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$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' + output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is @@ -6016,7 +6519,7 @@ if test "$_lt_caught_CXX_error" != yes; then _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 + output_verbose_link_cmd=func_echo_all else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -6051,15 +6554,15 @@ if test "$_lt_caught_CXX_error" != yes; then 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(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -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_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -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~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ $RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' ;; @@ -6075,17 +6578,17 @@ if test "$_lt_caught_CXX_error" != yes; then # 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' + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$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; func_echo_all "$list"' ;; *) 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}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${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' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' ;; esac @@ -6095,7 +6598,7 @@ if test "$_lt_caught_CXX_error" != yes; then # 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"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # FIXME: insert proper C++ library support @@ -6131,7 +6634,7 @@ if test "$_lt_caught_CXX_error" != yes; then solaris*) case $cc_basename in - CC*) + CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' @@ -6152,7 +6655,7 @@ if test "$_lt_caught_CXX_error" != yes; then esac _LT_TAGVAR(link_all_deplibs, $1)=yes - output_verbose_link_cmd='echo' + output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is @@ -6172,14 +6675,14 @@ if test "$_lt_caught_CXX_error" != yes; then 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_cmds, $1)='$CC -shared $pic_flag -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' + $CC -shared $pic_flag -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"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # g++ 2.7 appears to require `-G' NOT `-shared' on this # platform. @@ -6190,7 +6693,7 @@ if test "$_lt_caught_CXX_error" != yes; then # 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"' + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' @@ -6244,6 +6747,10 @@ if test "$_lt_caught_CXX_error" != yes; then 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(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ + '"$_LT_TAGVAR(old_archive_cmds, $1)" + _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ + '"$_LT_TAGVAR(reload_cmds, $1)" ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' @@ -6299,6 +6806,7 @@ if test "$_lt_caught_CXX_error" != yes; then fi # test -n "$compiler" CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC @@ -6313,6 +6821,29 @@ AC_LANG_POP ])# _LT_LANG_CXX_CONFIG +# _LT_FUNC_STRIPNAME_CNF +# ---------------------- +# func_stripname_cnf 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). +# +# This function is identical to the (non-XSI) version of func_stripname, +# except this one can be used by m4 code that may be executed by configure, +# rather than the libtool script. +m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl +AC_REQUIRE([_LT_DECL_SED]) +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) +func_stripname_cnf () +{ + case ${2} in + .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname_cnf +])# _LT_FUNC_STRIPNAME_CNF + # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose @@ -6321,6 +6852,7 @@ AC_LANG_POP # objects, libraries and library flags. m4_defun([_LT_SYS_HIDDEN_LIBDEPS], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl +AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl # Dependencies to place before and after the object being linked: _LT_TAGVAR(predep_objects, $1)= _LT_TAGVAR(postdep_objects, $1)= @@ -6371,6 +6903,13 @@ public class foo { }; _LT_EOF ]) + +_lt_libdeps_save_CFLAGS=$CFLAGS +case "$CC $CFLAGS " in #( +*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; +*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; +esac + dnl Parse the compiler output and extract the necessary dnl objects, libraries and library flags. if AC_TRY_EVAL(ac_compile); then @@ -6382,7 +6921,7 @@ if AC_TRY_EVAL(ac_compile); then pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do - case $p in + case ${prev}${p} in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. @@ -6391,13 +6930,22 @@ if AC_TRY_EVAL(ac_compile); then test $p = "-R"; then prev=$p continue - else - prev= fi + # Expand the sysroot to ease extracting the directories later. + if test -z "$prev"; then + case $p in + -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; + -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; + -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; + esac + fi + case $p in + =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; + esac if test "$pre_test_object_deps_done" = no; then - case $p in - -L* | -R*) + case ${prev} 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. @@ -6417,8 +6965,10 @@ if AC_TRY_EVAL(ac_compile); then _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" fi fi + prev= ;; + *.lto.$objext) ;; # Ignore GCC LTO objects *.$objext) # This assumes that the test object file only shows up # once in the compiler output. @@ -6454,6 +7004,7 @@ else fi $RM -f confest.$objext +CFLAGS=$_lt_libdeps_save_CFLAGS # PORTME: override above test on systems where it is broken m4_if([$1], [CXX], @@ -6490,7 +7041,7 @@ linux*) solaris*) case $cc_basename in - CC*) + CC* | sunCC*) # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as @@ -6534,32 +7085,16 @@ _LT_TAGDECL([], [compiler_lib_search_path], [1], ])# _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) +[AC_LANG_PUSH(Fortran 77) +if test -z "$F77" || test "X$F77" = "Xno"; then + _lt_disable_F77=yes +fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= @@ -6578,6 +7113,8 @@ _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(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no @@ -6617,7 +7154,9 @@ if test "$_lt_disable_F77" != yes; then # Allow CC to be a program name with arguments. lt_save_CC="$CC" lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS CC=${F77-"f77"} + CFLAGS=$FFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) @@ -6671,38 +7210,24 @@ if test "$_lt_disable_F77" != yes; then GCC=$lt_save_GCC CC="$lt_save_CC" + CFLAGS="$lt_save_CFLAGS" 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) +[AC_LANG_PUSH(Fortran) + +if test -z "$FC" || test "X$FC" = "Xno"; then + _lt_disable_FC=yes +fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= @@ -6721,6 +7246,8 @@ _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(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no @@ -6760,7 +7287,9 @@ if test "$_lt_disable_FC" != yes; then # Allow CC to be a program name with arguments. lt_save_CC="$CC" lt_save_GCC=$GCC + lt_save_CFLAGS=$CFLAGS CC=${FC-"f95"} + CFLAGS=$FCFLAGS compiler=$CC GCC=$ac_cv_fc_compiler_gnu @@ -6816,7 +7345,8 @@ if test "$_lt_disable_FC" != yes; then fi # test -n "$compiler" GCC=$lt_save_GCC - CC="$lt_save_CC" + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS fi # test "$_lt_disable_FC" != yes AC_LANG_POP @@ -6853,10 +7383,12 @@ _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. -lt_save_CC="$CC" +lt_save_CC=$CC +lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GCJ-"gcj"} +CFLAGS=$GCJFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)="$LD" @@ -6866,6 +7398,8 @@ _LT_CC_BASENAME([$compiler]) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds +_LT_TAGVAR(reload_flag, $1)=$reload_flag +_LT_TAGVAR(reload_cmds, $1)=$reload_cmds ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change @@ -6885,7 +7419,8 @@ fi AC_LANG_RESTORE GCC=$lt_save_GCC -CC="$lt_save_CC" +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GCJ_CONFIG @@ -6920,9 +7455,11 @@ _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC="$CC" +lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC= CC=${RC-"windres"} +CFLAGS= compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) @@ -6935,7 +7472,8 @@ fi GCC=$lt_save_GCC AC_LANG_RESTORE -CC="$lt_save_CC" +CC=$lt_save_CC +CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_RC_CONFIG @@ -6983,6 +7521,27 @@ 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_DLLTOOL +# ---------------- +# Ensure DLLTOOL variable is set. +m4_defun([_LT_DECL_DLLTOOL], +[AC_CHECK_TOOL(DLLTOOL, dlltool, false) +test -z "$DLLTOOL" && DLLTOOL=dlltool +_LT_DECL([], [DLLTOOL], [1], [DLL creation program]) +AC_SUBST([DLLTOOL]) +]) + # _LT_DECL_SED # ------------ # Check for a fully-functional sed program, that truncates @@ -7075,8 +7634,8 @@ m4_defun([_LT_CHECK_SHELL_FEATURES], # Try some XSI features xsi_shell=no ( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,, \ + test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ + = c,a/b,b/c, \ && eval 'test $(( 1 + 1 )) -eq 2 \ && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ && xsi_shell=yes @@ -7115,208 +7674,162 @@ _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=$(( $[*] )) -} +# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) +# ------------------------------------------------------ +# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and +# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. +m4_defun([_LT_PROG_FUNCTION_REPLACE], +[dnl { +sed -e '/^$1 ()$/,/^} # $1 /c\ +$1 ()\ +{\ +m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) +} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: +]) -# 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" +# _LT_PROG_REPLACE_SHELLFNS +# ------------------------- +# Replace existing portable implementations of several shell functions with +# equivalent extended shell implementations where those features are available.. +m4_defun([_LT_PROG_REPLACE_SHELLFNS], +[if test x"$xsi_shell" = xyes; then + _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl + case ${1} in + */*) func_dirname_result="${1%/*}${2}" ;; + * ) func_dirname_result="${3}" ;; + esac]) + + _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl + func_basename_result="${1##*/}"]) + + _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl + case ${1} in + */*) func_dirname_result="${1%/*}${2}" ;; + * ) func_dirname_result="${3}" ;; + esac + func_basename_result="${1##*/}"]) -# 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 -} + _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl + # 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_basename file -func_basename () -{ - func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"` -} + _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl + func_split_long_opt_name=${1%%=*} + func_split_long_opt_arg=${1#*=}]) -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. + _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl + func_split_short_opt_arg=${1#??} + func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) -# 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 -} + _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl + case ${1} in + *.lo) func_lo2o_result=${1%.lo}.${objext} ;; + *) func_lo2o_result=${1} ;; + esac]) -# sed scripts: -my_sed_long_opt='1s/^\(-[[^=]]*\)=.*/\1/;q' -my_sed_long_arg='1s/^-[[^=]]*=//' + _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) -# 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"` -} + _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) -# func_xform libobj-or-source -func_xform () -{ - func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[[^.]]*$/.lo/'` -} + _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) +fi -# func_arith arithmetic-term... -func_arith () -{ - func_arith_result=`expr "$[@]"` -} +if test x"$lt_shell_append" = xyes; then + _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) -# 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_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl + func_quote_for_eval "${2}" +dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ + eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) -_LT_EOF -esac + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi -case $lt_shell_append in - yes) - cat << \_LT_EOF >> "$cfgfile" +if test x"$_lt_function_replace_fail" = x":"; then + AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) +fi +]) -# func_append var value -# Append VALUE to the end of shell variable VAR. -func_append () -{ - eval "$[1]+=\$[2]" -} -_LT_EOF +# _LT_PATH_CONVERSION_FUNCTIONS +# ----------------------------- +# Determine which file name conversion functions should be used by +# func_to_host_file (and, implicitly, by func_to_host_path). These are needed +# for certain cross-compile configurations and native mingw. +m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_REQUIRE([AC_CANONICAL_BUILD])dnl +AC_MSG_CHECKING([how to convert $build file names to $host format]) +AC_CACHE_VAL(lt_cv_to_host_file_cmd, +[case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac ;; - *) - 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 + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac ;; - esac + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac +]) +to_host_file_cmd=$lt_cv_to_host_file_cmd +AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) +_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], + [0], [convert $build file names to $host format])dnl + +AC_MSG_CHECKING([how to convert $build file names to toolchain format]) +AC_CACHE_VAL(lt_cv_to_tool_file_cmd, +[#assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac ]) +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) +_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], + [0], [convert $build files to toolchain format])dnl +])# _LT_PATH_CONVERSION_FUNCTIONS diff --git a/config/ltmain.sh b/config/ltmain.sh index 7b6c74f..aa5624c 100755 --- a/config/ltmain.sh +++ b/config/ltmain.sh @@ -1,9 +1,9 @@ -# Generated from ltmain.m4sh. -# ltmain.sh (GNU libtool) 2.2.4 +# libtool (GNU libtool) 2.4 # Written by Gordon Matzigkeit , 1996 -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007 2008 Free Software Foundation, Inc. +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, +# 2007, 2008, 2009, 2010 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. @@ -32,50 +32,56 @@ # # 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 +# --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 +# --no-quiet, --no-silent +# print informational messages (default) +# --tag=TAG use configuration variables from tag TAG +# -v, --verbose print more informational messages than default +# --no-verbose don't print the extra informational messages +# --version print version information +# -h, --help, --help-all print short, long, or detailed 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 +# 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. +# MODE-ARGS vary depending on the MODE. When passed as first option, +# `--mode=MODE' may be abbreviated as `MODE' or a unique abbreviation of that. # 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.4 -# automake: $automake_version -# autoconf: $autoconf_version +# host-triplet: $host +# shell: $SHELL +# compiler: $LTCC +# compiler flags: $LTCFLAGS +# linker: $LD (gnu? $with_gnu_ld) +# $progname: (GNU libtool) 2.4 +# automake: $automake_version +# autoconf: $autoconf_version # # Report bugs to . +# GNU libtool home page: . +# General help using GNU software: . -PROGRAM=ltmain.sh +PROGRAM=libtool PACKAGE=libtool -VERSION=2.2.4 +VERSION=2.4 TIMESTAMP="" -package_revision=1.2976 +package_revision=1.3293 # Be Bourne compatible if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then @@ -91,10 +97,15 @@ fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' +} + # 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 @@ -107,24 +118,33 @@ do lt_safe_locale=\"$lt_var=C; \$lt_safe_locale\" fi" done +LC_ALL=C +LANGUAGE=C +export LANGUAGE LC_ALL $lt_unset CDPATH +# 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" : ${CP="cp -f"} -: ${ECHO="echo"} -: ${EGREP="/usr/bin/grep -E"} -: ${FGREP="/usr/bin/grep -F"} -: ${GREP="/usr/bin/grep"} +test "${ECHO+set}" = set || ECHO=${as_echo-'printf %s\n'} +: ${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="/opt/local/bin/gsed"} +: ${SED="/bin/sed"} : ${SHELL="${CONFIG_SHELL-/bin/sh}"} : ${Xsed="$SED -e 1s/^X//"} @@ -144,6 +164,27 @@ IFS=" $lt_nl" dirname="s,/[^/]*$,," basename="s,^.*/,," +# 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 () +{ + func_dirname_result=`$ECHO "${1}" | $SED "$dirname"` + if test "X$func_dirname_result" = "X${1}"; then + func_dirname_result="${3}" + else + func_dirname_result="$func_dirname_result${2}" + fi +} # func_dirname may be replaced by extended shell implementation + + +# func_basename file +func_basename () +{ + func_basename_result=`$ECHO "${1}" | $SED "$basename"` +} # func_basename may be replaced by extended shell implementation + + # func_dirname_and_basename file append nondir_replacement # perform func_basename and func_dirname in a single function # call: @@ -158,33 +199,183 @@ basename="s,^.*/,," # 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"` + # Extract subdirectory from the argument. + func_dirname_result=`$ECHO "${1}" | $SED -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 "${1}" | $SED -e "$basename"` +} # func_dirname_and_basename may be replaced by extended shell implementation + + +# 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 "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; + *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + esac +} # func_stripname may be replaced by extended shell implementation + + +# These SED scripts presuppose an absolute path with a trailing slash. +pathcar='s,^/\([^/]*\).*$,\1,' +pathcdr='s,^/[^/]*,,' +removedotparts=':dotsl + s@/\./@/@g + t dotsl + s,/\.$,/,' +collapseslashes='s@/\{1,\}@/@g' +finalslash='s,/*$,/,' + +# func_normal_abspath PATH +# Remove doubled-up and trailing slashes, "." path components, +# and cancel out any ".." path components in PATH after making +# it an absolute path. +# value returned in "$func_normal_abspath_result" +func_normal_abspath () +{ + # Start from root dir and reassemble the path. + func_normal_abspath_result= + func_normal_abspath_tpath=$1 + func_normal_abspath_altnamespace= + case $func_normal_abspath_tpath in + "") + # Empty path, that just means $cwd. + func_stripname '' '/' "`pwd`" + func_normal_abspath_result=$func_stripname_result + return + ;; + # The next three entries are used to spot a run of precisely + # two leading slashes without using negated character classes; + # we take advantage of case's first-match behaviour. + ///*) + # Unusual form of absolute path, do nothing. + ;; + //*) + # Not necessarily an ordinary path; POSIX reserves leading '//' + # and for example Cygwin uses it to access remote file shares + # over CIFS/SMB, so we conserve a leading double slash if found. + func_normal_abspath_altnamespace=/ + ;; + /*) + # Absolute path, do nothing. + ;; + *) + # Relative path, prepend $cwd. + func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath + ;; + esac + # Cancel out all the simple stuff to save iterations. We also want + # the path to end with a slash for ease of parsing, so make sure + # there is one (and only one) here. + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$removedotparts" -e "$collapseslashes" -e "$finalslash"` + while :; do + # Processed it all yet? + if test "$func_normal_abspath_tpath" = / ; then + # If we ascended to the root using ".." the result may be empty now. + if test -z "$func_normal_abspath_result" ; then + func_normal_abspath_result=/ + fi + break + fi + func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$pathcar"` + func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ + -e "$pathcdr"` + # Figure out what to do with it + case $func_normal_abspath_tcomponent in + "") + # Trailing empty path component, ignore it. + ;; + ..) + # Parent dir; strip last assembled component from result. + func_dirname "$func_normal_abspath_result" + func_normal_abspath_result=$func_dirname_result + ;; + *) + # Actual path component, append it. + func_normal_abspath_result=$func_normal_abspath_result/$func_normal_abspath_tcomponent + ;; + esac + done + # Restore leading double-slash if one was found on entry. + func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result } -# Generated shell functions inserted here. +# func_relative_path SRCDIR DSTDIR +# generates a relative path from SRCDIR to DSTDIR, with a trailing +# slash if non-empty, suitable for immediately appending a filename +# without needing to append a separator. +# value returned in "$func_relative_path_result" +func_relative_path () +{ + func_relative_path_result= + func_normal_abspath "$1" + func_relative_path_tlibdir=$func_normal_abspath_result + func_normal_abspath "$2" + func_relative_path_tbindir=$func_normal_abspath_result + + # Ascend the tree starting from libdir + while :; do + # check if we have found a prefix of bindir + case $func_relative_path_tbindir in + $func_relative_path_tlibdir) + # found an exact match + func_relative_path_tcancelled= + break + ;; + $func_relative_path_tlibdir*) + # found a matching prefix + func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" + func_relative_path_tcancelled=$func_stripname_result + if test -z "$func_relative_path_result"; then + func_relative_path_result=. + fi + break + ;; + *) + func_dirname $func_relative_path_tlibdir + func_relative_path_tlibdir=${func_dirname_result} + if test "x$func_relative_path_tlibdir" = x ; then + # Have to descend all the way to the root! + func_relative_path_result=../$func_relative_path_result + func_relative_path_tcancelled=$func_relative_path_tbindir + break + fi + func_relative_path_result=../$func_relative_path_result + ;; + esac + done -# 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" + # Now calculate path; take care to avoid doubling-up slashes. + func_stripname '' '/' "$func_relative_path_result" + func_relative_path_result=$func_stripname_result + func_stripname '/' '/' "$func_relative_path_tcancelled" + if test "x$func_stripname_result" != x ; then + func_relative_path_result=${func_relative_path_result}/${func_stripname_result} + fi + + # Normalisation. If bindir is libdir, return empty string, + # else relative path ending with a slash; either way, target + # file name can be directly appended. + if test ! -z "$func_relative_path_result"; then + func_stripname './' '' "$func_relative_path_result/" + func_relative_path_result=$func_stripname_result + fi +} # 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 @@ -215,6 +406,15 @@ sed_quote_subst='s/\([`"$\\]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\(["`\\]\)/\\\1/g' +# Sed substitution that turns a string into a regex matching for the +# string literally. +sed_make_literal_regex='s,[].[^$\\*\/],\\&,g' + +# Sed substitution that converts a w32 file name or path +# which contains forward slashes, into one that contains +# (escaped) backslashes. A very naive implementation. +lt_sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|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. @@ -243,7 +443,7 @@ opt_warning=: # name if it has been set yet. func_echo () { - $ECHO "$progname${mode+: }$mode: $*" + $ECHO "$progname: ${opt_mode+$opt_mode: }$*" } # func_verbose arg... @@ -258,18 +458,25 @@ func_verbose () : } +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "$*" +} + # func_error arg... # Echo program name prefixed message to standard error. func_error () { - $ECHO "$progname${mode+: }$mode: "${1+"$@"} 1>&2 + $ECHO "$progname: ${opt_mode+$opt_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 + $opt_warning && $ECHO "$progname: ${opt_mode+$opt_mode: }warning: "${1+"$@"} 1>&2 # bash bug again: : @@ -326,9 +533,9 @@ func_mkdir_p () 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"` + my_directory_path=`$ECHO "$my_directory_path" | $SED -e "$dirname"` done - my_dir_list=`$ECHO "X$my_dir_list" | $Xsed -e 's,:*$,,'` + my_dir_list=`$ECHO "$my_dir_list" | $SED 's,:*$,,'` save_mkdir_p_IFS="$IFS"; IFS=':' for my_dir in $my_dir_list; do @@ -378,7 +585,7 @@ func_mktempdir () func_fatal_error "cannot create temporary directory \`$my_tmpdir'" fi - $ECHO "X$my_tmpdir" | $Xsed + $ECHO "$my_tmpdir" } @@ -392,7 +599,7 @@ 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=`$ECHO "$1" | $SED "$sed_quote_subst"` ;; *) func_quote_for_eval_unquoted_result="$1" ;; esac @@ -419,7 +626,7 @@ func_quote_for_expand () { case $1 in *[\\\`\"]*) - my_arg=`$ECHO "X$1" | $Xsed \ + my_arg=`$ECHO "$1" | $SED \ -e "$double_quote_subst" -e "$sed_double_backslash"` ;; *) my_arg="$1" ;; @@ -488,15 +695,39 @@ func_show_eval_locale () fi } - - +# func_tr_sh +# Turn $1 into a string suitable for a shell variable name. +# Result is stored in $func_tr_sh_result. All characters +# not in the set a-zA-Z0-9_ are replaced with '_'. Further, +# if $1 begins with a digit, a '_' is prepended as well. +func_tr_sh () +{ + case $1 in + [0-9]* | *[!a-zA-Z0-9_]*) + func_tr_sh_result=`$ECHO "$1" | $SED 's/^\([0-9]\)/_\1/; s/[^a-zA-Z0-9_]/_/g'` + ;; + * ) + func_tr_sh_result=$1 + ;; + esac +} # func_version # Echo version message to standard output and exit. func_version () { - $SED -n '/^# '$PROGRAM' (GNU /,/# warranty; / { + $opt_debug + + $SED -n '/(C)/!b go + :more + /\./!{ + N + s/\n# / / + b more + } + :go + /^# '$PROGRAM' (GNU /,/# warranty; / { s/^# // s/^# *$// s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/ @@ -509,22 +740,28 @@ func_version () # Echo short help message to standard output and exit. func_usage () { - $SED -n '/^# Usage:/,/# -h/ { + $opt_debug + + $SED -n '/^# Usage:/,/^# *.*--help/ { s/^# // s/^# *$// s/\$progname/'$progname'/ p }' < "$progpath" - $ECHO + echo $ECHO "run \`$progname --help | more' for full usage" exit $? } -# func_help -# Echo long help message to standard output and exit. +# func_help [NOEXIT] +# Echo long help message to standard output and exit, +# unless 'noexit' is passed as argument. func_help () { + $opt_debug + $SED -n '/^# Usage:/,/# Report bugs to/ { + :print s/^# // s/^# *$// s*\$progname*'$progname'* @@ -537,8 +774,15 @@ func_help () s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/ s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/ p - }' < "$progpath" - exit $? + d + } + /^# .* home page:/b print + /^# General help using/b print + ' < "$progpath" + ret=$? + if test -z "$1"; then + exit $ret + fi } # func_missing_arg argname @@ -546,70 +790,106 @@ func_help () # exit_cmd. func_missing_arg () { - func_error "missing argument for $1" + $opt_debug + + func_error "missing argument for $1." exit_cmd=exit } -exit_cmd=: +# func_split_short_opt shortopt +# Set func_split_short_opt_name and func_split_short_opt_arg shell +# variables after splitting SHORTOPT after the 2nd character. +func_split_short_opt () +{ + my_sed_short_opt='1s/^\(..\).*$/\1/;q' + my_sed_short_rest='1s/^..\(.*\)$/\1/;q' + func_split_short_opt_name=`$ECHO "$1" | $SED "$my_sed_short_opt"` + func_split_short_opt_arg=`$ECHO "$1" | $SED "$my_sed_short_rest"` +} # func_split_short_opt may be replaced by extended shell implementation + + +# func_split_long_opt longopt +# Set func_split_long_opt_name and func_split_long_opt_arg shell +# variables after splitting LONGOPT at the `=' sign. +func_split_long_opt () +{ + my_sed_long_opt='1s/^\(--[^=]*\)=.*/\1/;q' + my_sed_long_arg='1s/^--[^=]*=//' + + func_split_long_opt_name=`$ECHO "$1" | $SED "$my_sed_long_opt"` + func_split_long_opt_arg=`$ECHO "$1" | $SED "$my_sed_long_arg"` +} # func_split_long_opt may be replaced by extended shell implementation + +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 -# Same for EGREP, and just to be sure, do LTCC as well -if test "x$EGREP" = x ; then - EGREP=egrep -fi -if test "x$LTCC" = x ; then - LTCC=${CC-gcc} -fi -if test "X$1" = X--fallback-echo; then - # used as fallback echo - shift - cat </dev/null || echo $max_cmd_len` +} # func_len may be replaced by extended shell implementation + + +# func_lo2o object +func_lo2o () +{ + func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"` +} # func_lo2o may be replaced by extended shell implementation + + +# func_xform libobj-or-source +func_xform () +{ + func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'` +} # func_xform may be replaced by extended shell implementation + + # func_fatal_configuration arg... # Echo program name prefixed message to standard error, followed by # a configuration failure hint, and exit. @@ -643,16 +923,16 @@ func_config () # Display the features supported by this script. func_features () { - $ECHO "host: $host" + echo "host: $host" if test "$build_libtool_libs" = yes; then - $ECHO "enable shared libraries" + echo "enable shared libraries" else - $ECHO "disable shared libraries" + echo "disable shared libraries" fi if test "$build_old_libs" = yes; then - $ECHO "enable static libraries" + echo "enable static libraries" else - $ECHO "disable static libraries" + echo "disable static libraries" fi exit $? @@ -699,133 +979,6 @@ func_enable_tag () 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*) - # 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. @@ -862,46 +1015,223 @@ _LT_EOF } -## ----------- ## -## Main. ## -## ----------- ## +# 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 -$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." +# Option defaults: +opt_debug=: +opt_dry_run=false +opt_config=false +opt_preserve_dup_deps=false +opt_features=false +opt_finish=false +opt_help=false +opt_help_all=false +opt_silent=: +opt_verbose=: +opt_silent=false +opt_verbose=false - # Darwin sucks - eval std_shrext=\"$shrext_cmds\" +# Parse options once, thoroughly. This comes as soon as possible in the +# script to make things like `--version' happen as quickly as we can. +{ + # this just eases exit handling + while test $# -gt 0; do + opt="$1" + shift + case $opt in + --debug|-x) opt_debug='set -x' + func_echo "enabling shell trace mode" + $opt_debug + ;; + --dry-run|--dryrun|-n) + opt_dry_run=: + ;; + --config) + opt_config=: +func_config + ;; + --dlopen|-dlopen) + optarg="$1" + opt_dlopen="${opt_dlopen+$opt_dlopen +}$optarg" + shift + ;; + --preserve-dup-deps) + opt_preserve_dup_deps=: + ;; + --features) + opt_features=: +func_features + ;; + --finish) + opt_finish=: +set dummy --mode finish ${1+"$@"}; shift + ;; + --help) + opt_help=: + ;; + --help-all) + opt_help_all=: +opt_help=': help-all' + ;; + --mode) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_mode="$optarg" +case $optarg 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 + shift + ;; + --no-silent|--no-quiet) + opt_silent=false +func_append preserve_args " $opt" + ;; + --no-verbose) + opt_verbose=false +func_append preserve_args " $opt" + ;; + --silent|--quiet) + opt_silent=: +func_append preserve_args " $opt" + opt_verbose=false + ;; + --verbose|-v) + opt_verbose=: +func_append preserve_args " $opt" +opt_silent=false + ;; + --tag) + test $# = 0 && func_missing_arg $opt && break + optarg="$1" + opt_tag="$optarg" +func_append preserve_args " $opt $optarg" +func_enable_tag "$optarg" + shift + ;; + -\?|-h) func_usage ;; + --help) func_help ;; + --version) func_version ;; - # 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 + # Separate optargs to long options: + --*=*) + func_split_long_opt "$opt" + set dummy "$func_split_long_opt_name" "$func_split_long_opt_arg" ${1+"$@"} + shift + ;; + + # Separate non-argument short options: + -\?*|-h*|-n*|-v*) + func_split_short_opt "$opt" + set dummy "$func_split_short_opt_name" "-$func_split_short_opt_arg" ${1+"$@"} + shift + ;; + + --) break ;; + -*) func_fatal_help "unrecognized option \`$opt'" ;; + *) set dummy "$opt" ${1+"$@"}; shift; break ;; + esac + done + + # Validate options: + + # save first non-option argument + if test "$#" -gt 0; then + nonopt="$opt" + shift fi - # Change the help message to a mode-specific one. - generic_help="$help" - help="Try \`$progname --help --mode=$mode' for more information." + # preserve --debug + test "$opt_debug" = : || func_append preserve_args " --debug" + + 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_preserve_dup_deps + ;; + esac + + $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 + + # Darwin sucks + eval std_shrext=\"$shrext_cmds\" + + # Only execute mode is allowed to have -dlopen flags. + if test -n "$opt_dlopen" && test "$opt_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=$opt_mode' for more information." + } + + + # Bail if the options were screwed + $exit_cmd $EXIT_FAILURE } + + +## ----------- ## +## Main. ## +## ----------- ## + # 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 () { - $SED -e 4q "$1" 2>/dev/null \ - | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 + test -f "$1" && + $SED -e 4q "$1" 2>/dev/null \ + | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 } # func_lalib_unsafe_p file @@ -914,7 +1244,7 @@ func_lalib_p () func_lalib_unsafe_p () { lalib_p=no - if test -r "$1" && exec 5<&0 <"$1"; then + 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 @@ -956,12 +1286,9 @@ func_ltwrapper_executable_p () # 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_dirname_and_basename "$1" "" "." + func_stripname '' '.exe' "$func_basename_result" + func_ltwrapper_scriptname_result="$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper" } # func_ltwrapper_p file @@ -1007,6 +1334,37 @@ func_source () } +# func_resolve_sysroot PATH +# Replace a leading = in PATH with a sysroot. Store the result into +# func_resolve_sysroot_result +func_resolve_sysroot () +{ + func_resolve_sysroot_result=$1 + case $func_resolve_sysroot_result in + =*) + func_stripname '=' '' "$func_resolve_sysroot_result" + func_resolve_sysroot_result=$lt_sysroot$func_stripname_result + ;; + esac +} + +# func_replace_sysroot PATH +# If PATH begins with the sysroot, replace it with = and +# store the result into func_replace_sysroot_result. +func_replace_sysroot () +{ + case "$lt_sysroot:$1" in + ?*:"$lt_sysroot"*) + func_stripname "$lt_sysroot" '' "$1" + func_replace_sysroot_result="=$func_stripname_result" + ;; + *) + # Including no sysroot. + func_replace_sysroot_result=$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. @@ -1019,13 +1377,15 @@ func_infer_tag () 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" + func_append_quoted CC_quoted "$arg" done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` 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` "*) ;; + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) @@ -1036,11 +1396,13 @@ func_infer_tag () 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" + func_append_quoted CC_quoted "$arg" done + CC_expanded=`func_echo_all $CC` + CC_quoted_expanded=`func_echo_all $CC_quoted` case "$@ " in - " $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*) + " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ + " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) # The compiler in the base compile command matches # the one in the tagged configuration. # Assume this is the tagged configuration we want. @@ -1065,43 +1427,523 @@ func_infer_tag () } - -# 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 () + +# 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 </dev/null` + if test "$?" -eq 0 && test -n "${func_convert_core_file_wine_to_w32_tmp}"; then + func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | + $SED -e "$lt_sed_naive_backslashify"` + else + func_convert_core_file_wine_to_w32_result= + fi + fi +} +# end: func_convert_core_file_wine_to_w32 + + +# func_convert_core_path_wine_to_w32 ARG +# Helper function used by path conversion functions when $build is *nix, and +# $host is mingw, cygwin, or some other w32 environment. Relies on a correctly +# configured wine environment available, with the winepath program in $build's +# $PATH. Assumes ARG has no leading or trailing path separator characters. +# +# ARG is path to be converted from $build format to win32. +# Result is available in $func_convert_core_path_wine_to_w32_result. +# Unconvertible file (directory) names in ARG are skipped; if no directory names +# are convertible, then the result may be empty. +func_convert_core_path_wine_to_w32 () +{ + $opt_debug + # unfortunately, winepath doesn't convert paths, only file names + func_convert_core_path_wine_to_w32_result="" + if test -n "$1"; then + oldIFS=$IFS + IFS=: + for func_convert_core_path_wine_to_w32_f in $1; do + IFS=$oldIFS + func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" + if test -n "$func_convert_core_file_wine_to_w32_result" ; then + if test -z "$func_convert_core_path_wine_to_w32_result"; then + func_convert_core_path_wine_to_w32_result="$func_convert_core_file_wine_to_w32_result" + else + func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" + fi + fi + done + IFS=$oldIFS + fi +} +# end: func_convert_core_path_wine_to_w32 + + +# func_cygpath ARGS... +# Wrapper around calling the cygpath program via LT_CYGPATH. This is used when +# when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) +# $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or +# (2), returns the Cygwin file name or path in func_cygpath_result (input +# file name or path is assumed to be in w32 format, as previously converted +# from $build's *nix or MSYS format). In case (3), returns the w32 file name +# or path in func_cygpath_result (input file name or path is assumed to be in +# Cygwin format). Returns an empty string on error. +# +# ARGS are passed to cygpath, with the last one being the file name or path to +# be converted. +# +# Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH +# environment variable; do not put it in $PATH. +func_cygpath () +{ + $opt_debug + if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then + func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` + if test "$?" -ne 0; then + # on failure, ensure result is empty + func_cygpath_result= + fi + else + func_cygpath_result= + func_error "LT_CYGPATH is empty or specifies non-existent file: \`$LT_CYGPATH'" + fi +} +#end: func_cygpath + + +# func_convert_core_msys_to_w32 ARG +# Convert file name or path ARG from MSYS format to w32 format. Return +# result in func_convert_core_msys_to_w32_result. +func_convert_core_msys_to_w32 () +{ + $opt_debug + # awkward: cmd appends spaces to result + func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | + $SED -e 's/[ ]*$//' -e "$lt_sed_naive_backslashify"` +} +#end: func_convert_core_msys_to_w32 + + +# func_convert_file_check ARG1 ARG2 +# Verify that ARG1 (a file name in $build format) was converted to $host +# format in ARG2. Otherwise, emit an error message, but continue (resetting +# func_to_host_file_result to ARG1). +func_convert_file_check () +{ + $opt_debug + if test -z "$2" && test -n "$1" ; then + func_error "Could not determine host file name corresponding to" + func_error " \`$1'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback: + func_to_host_file_result="$1" + fi +} +# end func_convert_file_check + + +# func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH +# Verify that FROM_PATH (a path in $build format) was converted to $host +# format in TO_PATH. Otherwise, emit an error message, but continue, resetting +# func_to_host_file_result to a simplistic fallback value (see below). +func_convert_path_check () +{ + $opt_debug + if test -z "$4" && test -n "$3"; then + func_error "Could not determine the host path corresponding to" + func_error " \`$3'" + func_error "Continuing, but uninstalled executables may not work." + # Fallback. This is a deliberately simplistic "conversion" and + # should not be "improved". See libtool.info. + if test "x$1" != "x$2"; then + lt_replace_pathsep_chars="s|$1|$2|g" + func_to_host_path_result=`echo "$3" | + $SED -e "$lt_replace_pathsep_chars"` + else + func_to_host_path_result="$3" + fi + fi +} +# end func_convert_path_check + + +# func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG +# Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT +# and appending REPL if ORIG matches BACKPAT. +func_convert_path_front_back_pathsep () +{ + $opt_debug + case $4 in + $1 ) func_to_host_path_result="$3$func_to_host_path_result" + ;; + esac + case $4 in + $2 ) func_append func_to_host_path_result "$3" + ;; + esac +} +# end func_convert_path_front_back_pathsep + + +################################################## +# $build to $host FILE NAME CONVERSION FUNCTIONS # +################################################## +# invoked via `$to_host_file_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# Result will be available in $func_to_host_file_result. + + +# func_to_host_file ARG +# Converts the file name ARG from $build format to $host format. Return result +# in func_to_host_file_result. +func_to_host_file () +{ + $opt_debug + $to_host_file_cmd "$1" +} +# end func_to_host_file + + +# func_to_tool_file ARG LAZY +# converts the file name ARG from $build format to toolchain format. Return +# result in func_to_tool_file_result. If the conversion in use is listed +# in (the comma separated) LAZY, no conversion takes place. +func_to_tool_file () +{ + $opt_debug + case ,$2, in + *,"$to_tool_file_cmd",*) + func_to_tool_file_result=$1 + ;; + *) + $to_tool_file_cmd "$1" + func_to_tool_file_result=$func_to_host_file_result + ;; + esac +} +# end func_to_tool_file + + +# func_convert_file_noop ARG +# Copy ARG to func_to_host_file_result. +func_convert_file_noop () +{ + func_to_host_file_result="$1" +} +# end func_convert_file_noop + + +# func_convert_file_msys_to_w32 ARG +# Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_file_result. +func_convert_file_msys_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_to_host_file_result="$func_convert_core_msys_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_w32 + + +# func_convert_file_cygwin_to_w32 ARG +# Convert file name ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_file_cygwin_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # because $build is cygwin, we call "the" cygpath in $PATH; no need to use + # LT_CYGPATH in this case. + func_to_host_file_result=`cygpath -m "$1"` + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_cygwin_to_w32 + + +# func_convert_file_nix_to_w32 ARG +# Convert file name ARG from *nix to w32 format. Requires a wine environment +# and a working winepath. Returns result in func_to_host_file_result. +func_convert_file_nix_to_w32 () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_file_wine_to_w32 "$1" + func_to_host_file_result="$func_convert_core_file_wine_to_w32_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_w32 + + +# func_convert_file_msys_to_cygwin ARG +# Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. +# Returns result in func_to_host_file_result. +func_convert_file_msys_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + func_convert_core_msys_to_w32 "$1" + func_cygpath -u "$func_convert_core_msys_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_msys_to_cygwin + + +# func_convert_file_nix_to_cygwin ARG +# Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed +# in a wine environment, working winepath, and LT_CYGPATH set. Returns result +# in func_to_host_file_result. +func_convert_file_nix_to_cygwin () +{ + $opt_debug + func_to_host_file_result="$1" + if test -n "$1"; then + # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. + func_convert_core_file_wine_to_w32 "$1" + func_cygpath -u "$func_convert_core_file_wine_to_w32_result" + func_to_host_file_result="$func_cygpath_result" + fi + func_convert_file_check "$1" "$func_to_host_file_result" +} +# end func_convert_file_nix_to_cygwin + + +############################################# +# $build to $host PATH CONVERSION FUNCTIONS # +############################################# +# invoked via `$to_host_path_cmd ARG' +# +# In each case, ARG is the path to be converted from $build to $host format. +# The result will be available in $func_to_host_path_result. +# +# 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. +# +# All path conversion functions are named using the following convention: +# file name conversion function : func_convert_file_X_to_Y () +# path conversion function : func_convert_path_X_to_Y () +# where, for any given $build/$host combination the 'X_to_Y' value is the +# same. If conversion functions are added for new $build/$host combinations, +# the two new functions must follow this pattern, or func_init_to_host_path_cmd +# will break. + + +# func_init_to_host_path_cmd +# Ensures that function "pointer" variable $to_host_path_cmd is set to the +# appropriate value, based on the value of $to_host_file_cmd. +to_host_path_cmd= +func_init_to_host_path_cmd () +{ + $opt_debug + if test -z "$to_host_path_cmd"; then + func_stripname 'func_convert_file_' '' "$to_host_file_cmd" + to_host_path_cmd="func_convert_path_${func_stripname_result}" + fi +} + + +# func_to_host_path ARG +# Converts the path ARG from $build format to $host format. Return result +# in func_to_host_path_result. +func_to_host_path () +{ + $opt_debug + func_init_to_host_path_cmd + $to_host_path_cmd "$1" +} +# end func_to_host_path + + +# func_convert_path_noop ARG +# Copy ARG to func_to_host_path_result. +func_convert_path_noop () +{ + func_to_host_path_result="$1" +} +# end func_convert_path_noop + + +# func_convert_path_msys_to_w32 ARG +# Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic +# conversion to w32 is not available inside the cwrapper. Returns result in +# func_to_host_path_result. +func_convert_path_msys_to_w32 () +{ + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # 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_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" + func_to_host_path_result="$func_convert_core_msys_to_w32_result" + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_msys_to_w32 + + +# func_convert_path_cygwin_to_w32 ARG +# Convert path ARG from Cygwin to w32 format. Returns result in +# func_to_host_file_result. +func_convert_path_cygwin_to_w32 () { - write_libobj=${1} - if test "$build_libtool_libs" = yes; then - write_lobj=\'${2}\' - else - write_lobj=none - fi + $opt_debug + func_to_host_path_result="$1" + if test -n "$1"; then + # See func_convert_path_msys_to_w32: + func_stripname : : "$1" + func_to_host_path_tmp1=$func_stripname_result + func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` + func_convert_path_check : ";" \ + "$func_to_host_path_tmp1" "$func_to_host_path_result" + func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" + fi +} +# end func_convert_path_cygwin_to_w32 - if test "$build_old_libs" = yes; then - write_oldobj=\'${3}\' - else - write_oldobj=none - fi - $opt_dry_run || { - cat >${write_libobj}T < "$lockfile" fi $opt_dry_run || $RM $removelist - removelist="$removelist $lockfile" + func_append 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_to_tool_file "$srcfile" func_convert_file_msys_to_w32 + srcfile=$func_to_tool_file_result func_quote_for_eval "$srcfile" qsrcfile=$func_quote_for_eval_result @@ -1355,7 +2194,7 @@ compiler." if test -z "$output_obj"; then # Place PIC objects in $objdir - command="$command -o $lobj" + func_append command " -o $lobj" fi func_show_eval_locale "$command" \ @@ -1402,11 +2241,11 @@ compiler." command="$base_compile $qsrcfile $pic_flag" fi if test "$compiler_c_o" = yes; then - command="$command -o $obj" + func_append command " -o $obj" fi # Suppress compiler output if we already did a PIC compilation. - command="$command$suppress_output" + func_append command "$suppress_output" func_show_eval_locale "$command" \ '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' @@ -1451,13 +2290,13 @@ compiler." } $opt_help || { -test "$mode" = compile && func_mode_compile ${1+"$@"} + test "$opt_mode" = compile && func_mode_compile ${1+"$@"} } func_mode_help () { # We need to display help for each of the modes. - case $mode in + case $opt_mode in "") # Generic help is extracted from the usage comments # at the start of this file. @@ -1488,10 +2327,11 @@ 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 + -prefer-pic try to build PIC objects only + -prefer-non-pic try to build 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 + -Wc,FLAG pass FLAG directly to the compiler COMPILE-COMMAND is a command to be used in creating a \`standard' object file from the given SOURCEFILE. @@ -1544,7 +2384,7 @@ 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 + -inst-prefix-dir 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)." @@ -1564,6 +2404,8 @@ 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 + -bindir BINDIR specify path to binaries directory (for systems where + libraries must be found in the PATH setting at runtime) -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) @@ -1592,6 +2434,11 @@ The following components of LINK-COMMAND are treated specially: -version-info CURRENT[:REVISION[:AGE]] specify library version info [each variable defaults to 0] -weak LIBNAME declare that the target provides the LIBNAME interface + -Wc,FLAG + -Xcompiler FLAG pass linker-specific FLAG directly to the compiler + -Wl,FLAG + -Xlinker FLAG pass linker-specific FLAG directly to the linker + -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) All other options (arguments beginning with \`-') are ignored. @@ -1625,18 +2472,44 @@ Otherwise, only FILE itself is deleted using RM." ;; *) - func_fatal_help "invalid operation mode \`$mode'" + func_fatal_help "invalid operation mode \`$opt_mode'" ;; esac - $ECHO + 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 +# Now that we've collected a possible --mode arg, show help if necessary +if $opt_help; then + if test "$opt_help" = :; then + func_mode_help + else + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + func_mode_help + done + } | sed -n '1p; 2,$s/^Usage:/ or: /p' + { + func_help noexit + for opt_mode in compile link execute install finish uninstall clean; do + echo + func_mode_help + done + } | + sed '1d + /^When reporting/,/^Report/{ + H + d + } + $x + /information about other modes/d + /more detailed .*MODE/d + s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' + fi + exit $? +fi # func_mode_execute arg... @@ -1649,13 +2522,16 @@ func_mode_execute () func_fatal_help "you must specify a COMMAND" # Handle -dlopen flags immediately. - for file in $execute_dlfiles; do + for file in $opt_dlopen; do test -f "$file" \ || func_fatal_help "\`$file' is not a file" dir= case $file in *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + # 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" @@ -1677,7 +2553,7 @@ func_mode_execute () dir="$func_dirname_result" if test -f "$dir/$objdir/$dlname"; then - dir="$dir/$objdir" + func_append dir "/$objdir" else if test ! -f "$dir/$dlname"; then func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" @@ -1718,7 +2594,7 @@ func_mode_execute () for file do case $file in - -*) ;; + -* | *.la | *.lo ) ;; *) # Do a test to see if this is really a libtool program. if func_ltwrapper_script_p "$file"; then @@ -1734,8 +2610,7 @@ func_mode_execute () ;; esac # Quote arguments (to preserve shell metacharacters). - func_quote_for_eval "$file" - args="$args $func_quote_for_eval_result" + func_append_quoted args "$file" done if test "X$opt_dry_run" = Xfalse; then @@ -1760,29 +2635,66 @@ func_mode_execute () # Display what would be done. if test -n "$shlibpath_var"; then eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" - $ECHO "export $shlibpath_var" + echo "export $shlibpath_var" fi $ECHO "$cmd$args" exit $EXIT_SUCCESS fi } -test "$mode" = execute && func_mode_execute ${1+"$@"} +test "$opt_mode" = execute && func_mode_execute ${1+"$@"} # func_mode_finish arg... func_mode_finish () { $opt_debug - libdirs="$nonopt" + libs= + libdirs= admincmds= - if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then - for dir - do - libdirs="$libdirs $dir" - done + for opt in "$nonopt" ${1+"$@"} + do + if test -d "$opt"; then + func_append libdirs " $opt" + elif test -f "$opt"; then + if func_lalib_unsafe_p "$opt"; then + func_append libs " $opt" + else + func_warning "\`$opt' is not a valid libtool archive" + fi + + else + func_fatal_error "invalid argument \`$opt'" + fi + done + + if test -n "$libs"; then + if test -n "$lt_sysroot"; then + sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` + sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" + else + sysroot_cmd= + fi + + # Remove sysroot references + if $opt_dry_run; then + for lib in $libs; do + echo "removing references to $lt_sysroot and \`=' prefixes from $lib" + done + else + tmpdir=`func_mktempdir` + for lib in $libs; do + sed -e "${sysroot_cmd} s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ + > $tmpdir/tmp-la + mv -f $tmpdir/tmp-la $lib + done + ${RM}r "$tmpdir" + fi + fi + + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. @@ -1792,7 +2704,7 @@ func_mode_finish () if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" - $opt_dry_run || eval "$cmds" || admincmds="$admincmds + $opt_dry_run || eval "$cmds" || func_append admincmds " $cmds" fi done @@ -1801,53 +2713,55 @@ func_mode_finish () # 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\" + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then + 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 " - 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 + 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 "----------------------------------------------------------------------" + fi exit $EXIT_SUCCESS } -test "$mode" = finish && func_mode_finish ${1+"$@"} +test "$opt_mode" = finish && func_mode_finish ${1+"$@"} # func_mode_install arg... @@ -1858,7 +2772,7 @@ func_mode_install () # 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 + case $nonopt in *shtool*) :;; *) false;; esac; then # Aesthetically quote it. func_quote_for_eval "$nonopt" install_prog="$func_quote_for_eval_result " @@ -1872,7 +2786,12 @@ func_mode_install () # 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" + func_append install_prog "$func_quote_for_eval_result" + install_shared_prog=$install_prog + case " $install_prog " in + *[\\\ /]cp\ *) install_cp=: ;; + *) install_cp=false ;; + esac # We need to accept at least all the BSD install flags. dest= @@ -1882,10 +2801,12 @@ func_mode_install () install_type= isdir=no stripme= + no_mode=: for arg do + arg2= if test -n "$dest"; then - files="$files $dest" + func_append files " $dest" dest=$arg continue fi @@ -1893,10 +2814,9 @@ func_mode_install () case $arg in -d) isdir=yes ;; -f) - case " $install_prog " in - *[\\\ /]cp\ *) ;; - *) prev=$arg ;; - esac + if $install_cp; then :; else + prev=$arg + fi ;; -g | -m | -o) prev=$arg @@ -1910,6 +2830,10 @@ func_mode_install () *) # If the previous option needed an argument, then skip it. if test -n "$prev"; then + if test "x$prev" = x-m && test -n "$install_override_mode"; then + arg2=$install_override_mode + no_mode=false + fi prev= else dest=$arg @@ -1920,7 +2844,11 @@ func_mode_install () # Aesthetically quote the argument. func_quote_for_eval "$arg" - install_prog="$install_prog $func_quote_for_eval_result" + func_append install_prog " $func_quote_for_eval_result" + if test -n "$arg2"; then + func_quote_for_eval "$arg2" + fi + func_append install_shared_prog " $func_quote_for_eval_result" done test -z "$install_prog" && \ @@ -1929,6 +2857,13 @@ func_mode_install () test -n "$prev" && \ func_fatal_help "the \`$prev' option requires an argument" + if test -n "$install_override_mode" && $no_mode; then + if $install_cp; then :; else + func_quote_for_eval "$install_override_mode" + func_append install_shared_prog " -m $func_quote_for_eval_result" + fi + fi + if test -z "$files"; then if test -z "$dest"; then func_fatal_help "no file or destination specified" @@ -1983,10 +2918,13 @@ func_mode_install () case $file in *.$libext) # Do the static libraries later. - staticlibs="$staticlibs $file" + func_append staticlibs " $file" ;; *.la) + func_resolve_sysroot "$file" + file=$func_resolve_sysroot_result + # 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" @@ -2000,23 +2938,23 @@ func_mode_install () if test "X$destdir" = "X$libdir"; then case "$current_libdirs " in *" $libdir "*) ;; - *) current_libdirs="$current_libdirs $libdir" ;; + *) func_append current_libdirs " $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; - *) future_libdirs="$future_libdirs $libdir" ;; + *) func_append future_libdirs " $libdir" ;; esac fi func_dirname "$file" "/" "" dir="$func_dirname_result" - dir="$dir$objdir" + func_append 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\$%%"` + inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that @@ -2029,9 +2967,9 @@ func_mode_install () 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%"` + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` else - relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%%"` + relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` fi func_warning "relinking \`$file'" @@ -2049,11 +2987,11 @@ func_mode_install () test -n "$relink_command" && srcname="$realname"T # Install the shared library and build the symlinks. - func_show_eval "$install_prog $dir/$srcname $destdir/$realname" \ + func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ 'exit $?' tstripme="$stripme" case $host_os in - cygwin* | mingw* | pw32*) + cygwin* | mingw* | pw32* | cegcc*) case $realname in *.dll.a) tstripme="" @@ -2089,7 +3027,7 @@ func_mode_install () func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' # Maybe install the static library, too. - test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" + test -n "$old_library" && func_append staticlibs " $dir/$old_library" ;; *.lo) @@ -2159,7 +3097,7 @@ func_mode_install () # Do a test to see if this is really a libtool program. case $host in - *cygwin*|*mingw*) + *cygwin* | *mingw*) if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" wrapper=$func_ltwrapper_scriptname_result @@ -2189,7 +3127,7 @@ func_mode_install () if test -f "$lib"; then func_source "$lib" fi - libfile="$libdir/"`$ECHO "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test + libfile="$libdir/"`$ECHO "$lib" | $SED '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 @@ -2208,7 +3146,7 @@ func_mode_install () file="$func_basename_result" outputname="$tmpdir/$file" # Replace the output file specification. - relink_command=`$ECHO "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'` + relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` $opt_silent || { func_quote_for_expand "$relink_command" @@ -2227,7 +3165,7 @@ func_mode_install () } else # Install the binary that we compiled earlier. - file=`$ECHO "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"` + file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` fi fi @@ -2286,7 +3224,7 @@ func_mode_install () fi } -test "$mode" = install && func_mode_install ${1+"$@"} +test "$opt_mode" = install && func_mode_install ${1+"$@"} # func_generate_dlsyms outputname originator pic_p @@ -2329,6 +3267,22 @@ func_generate_dlsyms () extern \"C\" { #endif +#if defined(__GNUC__) && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) +#pragma GCC diagnostic ignored \"-Wstrict-prototypes\" +#endif + +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + /* External symbol declarations for the compiler. */\ " @@ -2338,10 +3292,11 @@ extern \"C\" { $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` + progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$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'" + func_to_tool_file "$progfile" func_convert_file_msys_to_w32 + func_verbose "extracting global C symbols from \`$func_to_tool_file_result'" + $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then @@ -2365,7 +3320,7 @@ extern \"C\" { $RM $export_symbols eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in - *cygwin* | *mingw* ) + *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; @@ -2377,7 +3332,7 @@ extern \"C\" { eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' case $host in - *cygwin | *mingw* ) + *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; @@ -2390,10 +3345,52 @@ extern \"C\" { 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'" - } + case $host in + *cygwin* | *mingw* | *cegcc* ) + # if an import library, we need to obtain dlname + if func_win32_import_lib_p "$dlprefile"; then + func_tr_sh "$dlprefile" + eval "curr_lafile=\$libfile_$func_tr_sh_result" + dlprefile_dlbasename="" + if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then + # Use subshell, to avoid clobbering current variable values + dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` + if test -n "$dlprefile_dlname" ; then + func_basename "$dlprefile_dlname" + dlprefile_dlbasename="$func_basename_result" + else + # no lafile. user explicitly requested -dlpreopen . + $sharedlib_from_linklib_cmd "$dlprefile" + dlprefile_dlbasename=$sharedlib_from_linklib_result + fi + fi + $opt_dry_run || { + if test -n "$dlprefile_dlbasename" ; then + eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' + else + func_warning "Could not compute DLL name from $name" + eval '$ECHO ": $name " >> "$nlist"' + fi + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | + $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" + } + else # not an import lib + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + fi + ;; + *) + $opt_dry_run || { + eval '$ECHO ": $name " >> "$nlist"' + func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 + eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" + } + ;; + esac done $opt_dry_run || { @@ -2421,36 +3418,19 @@ extern \"C\" { if test -f "$nlist"S; then eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' else - $ECHO '/* NONE */' >> "$output_objdir/$my_dlsyms" + echo '/* NONE */' >> "$output_objdir/$my_dlsyms" fi - $ECHO >> "$output_objdir/$my_dlsyms" "\ + 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* ) - $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 +extern LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[]; -$lt_dlsym_const lt_dlsymlist +LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[] = {\ { \"$my_originator\", (void *) 0 }," @@ -2463,7 +3443,7 @@ lt_${my_prefix}_LTX_preloaded_symbols[] = eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" ;; esac - $ECHO >> "$output_objdir/$my_dlsyms" "\ + echo >> "$output_objdir/$my_dlsyms" "\ {0, (void *) 0} }; @@ -2506,7 +3486,7 @@ static const void *lt_preloaded_setup() { for arg in $LTCFLAGS; do case $arg in -pie | -fpie | -fPIE) ;; - *) symtab_cflags="$symtab_cflags $arg" ;; + *) func_append symtab_cflags " $arg" ;; esac done @@ -2519,18 +3499,18 @@ static const void *lt_preloaded_setup() { # Transform the symbol file into the correct name. symfileobj="$output_objdir/${my_outputname}S.$objext" case $host in - *cygwin* | *mingw* ) + *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%"` + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "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%"` + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "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%"` + compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` ;; esac ;; @@ -2544,8 +3524,8 @@ static const void *lt_preloaded_setup() { # 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@%%"` + compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` + finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` fi } @@ -2555,6 +3535,7 @@ static const void *lt_preloaded_setup() { # 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. +# Despite the name, also deal with 64 bit binaries. func_win32_libid () { $opt_debug @@ -2565,9 +3546,11 @@ func_win32_libid () win32_libid_type="x86 archive import" ;; *ar\ archive*) # could be an import, or static + # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. 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 | + $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then + func_to_tool_file "$1" func_convert_file_msys_to_w32 + win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | $SED -n -e ' 1,100{ / I /{ @@ -2596,6 +3579,131 @@ func_win32_libid () $ECHO "$win32_libid_type" } +# func_cygming_dll_for_implib ARG +# +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib () +{ + $opt_debug + sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` +} + +# func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs +# +# The is the core of a fallback implementation of a +# platform-specific function to extract the name of the +# DLL associated with the specified import library LIBNAME. +# +# SECTION_NAME is either .idata$6 or .idata$7, depending +# on the platform and compiler that created the implib. +# +# Echos the name of the DLL associated with the +# specified import library. +func_cygming_dll_for_implib_fallback_core () +{ + $opt_debug + match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` + $OBJDUMP -s --section "$1" "$2" 2>/dev/null | + $SED '/^Contents of section '"$match_literal"':/{ + # Place marker at beginning of archive member dllname section + s/.*/====MARK====/ + p + d + } + # These lines can sometimes be longer than 43 characters, but + # are always uninteresting + /:[ ]*file format pe[i]\{,1\}-/d + /^In archive [^:]*:/d + # Ensure marker is printed + /^====MARK====/p + # Remove all lines with less than 43 characters + /^.\{43\}/!d + # From remaining lines, remove first 43 characters + s/^.\{43\}//' | + $SED -n ' + # Join marker and all lines until next marker into a single line + /^====MARK====/ b para + H + $ b para + b + :para + x + s/\n//g + # Remove the marker + s/^====MARK====// + # Remove trailing dots and whitespace + s/[\. \t]*$// + # Print + /./p' | + # we now have a list, one entry per line, of the stringified + # contents of the appropriate section of all members of the + # archive which possess that section. Heuristic: eliminate + # all those which have a first or second character that is + # a '.' (that is, objdump's representation of an unprintable + # character.) This should work for all archives with less than + # 0x302f exports -- but will fail for DLLs whose name actually + # begins with a literal '.' or a single character followed by + # a '.'. + # + # Of those that remain, print the first one. + $SED -e '/^\./d;/^.\./d;q' +} + +# func_cygming_gnu_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is a GNU/binutils-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_gnu_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` + test -n "$func_cygming_gnu_implib_tmp" +} + +# func_cygming_ms_implib_p ARG +# This predicate returns with zero status (TRUE) if +# ARG is an MS-style import library. Returns +# with nonzero status (FALSE) otherwise. +func_cygming_ms_implib_p () +{ + $opt_debug + func_to_tool_file "$1" func_convert_file_msys_to_w32 + func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` + test -n "$func_cygming_ms_implib_tmp" +} + +# func_cygming_dll_for_implib_fallback ARG +# Platform-specific function to extract the +# name of the DLL associated with the specified +# import library ARG. +# +# This fallback implementation is for use when $DLLTOOL +# does not support the --identify-strict option. +# Invoked by eval'ing the libtool variable +# $sharedlib_from_linklib_cmd +# Result is available in the variable +# $sharedlib_from_linklib_result +func_cygming_dll_for_implib_fallback () +{ + $opt_debug + if func_cygming_gnu_implib_p "$1" ; then + # binutils import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` + elif func_cygming_ms_implib_p "$1" ; then + # ms-generated import library + sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` + else + # unknown + sharedlib_from_linklib_result="" + fi +} # func_extract_an_archive dir oldlib @@ -2604,7 +3712,18 @@ 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 test "$lock_old_archive_extraction" = yes; then + lockfile=$f_ex_an_ar_oldlib.lock + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do + func_echo "Waiting for $lockfile to be removed" + sleep 2 + done + fi + func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ + 'stat=$?; rm -f "$lockfile"; exit $stat' + if test "$lock_old_archive_extraction" = yes; then + $opt_dry_run || rm -f "$lockfile" + fi if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then : else @@ -2675,7 +3794,7 @@ func_extract_archives () darwin_file= darwin_files= for darwin_file in $darwin_filelist; do - darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP` + darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` $LIPO -create -output "$darwin_file" $darwin_files done # $darwin_filelist $RM -rf unfat-$$ @@ -2690,34 +3809,30 @@ func_extract_archives () func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac - my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` + my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` done func_extract_archives_result="$my_oldobjs" } - -# func_emit_wrapper arg +# func_emit_wrapper [arg=no] # -# emit a libtool wrapper script on stdout -# don't directly open a file because we may want to +# 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 variable +# func_mode_link because it depends on a number of variables # set therein. # -# arg is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR +# 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 '.lib' directory. This is a cygwin/mingw-specific +# 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 + func_emit_wrapper_arg1=${1-no} $ECHO "\ #! $SHELL @@ -2733,7 +3848,6 @@ func_emit_wrapper () # 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 @@ -2764,31 +3878,132 @@ if test \"\$libtool_install_magic\" = \"$magic\"; then 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\ + file=\"\$0\"" + + qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` + $ECHO "\ + +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + ECHO=\"$qECHO\" + fi + +# Very basic option parsing. These options are (a) specific to +# the libtool wrapper, (b) are identical between the wrapper +# /script/ and the wrapper /executable/ which is used only on +# windows platforms, and (c) all begin with the string "--lt-" +# (application programs are unlikely to have options which match +# this pattern). +# +# There are only two supported options: --lt-debug and +# --lt-dump-script. There is, deliberately, no --lt-help. +# +# The first argument to this parsing function should be the +# script's $0 value, followed by "$@". +lt_option_debug= +func_parse_lt_options () +{ + lt_script_arg0=\$0 + shift + for lt_opt + do + case \"\$lt_opt\" in + --lt-debug) lt_option_debug=1 ;; + --lt-dump-script) + lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` + test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. + lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` + cat \"\$lt_dump_D/\$lt_dump_F\" + exit 0 + ;; + --lt-*) + \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 + exit 1 + ;; + esac + done + + # Print the debug banner immediately: + if test -n \"\$lt_option_debug\"; then + echo \"${outputname}:${output}:\${LINENO}: libtool wrapper (GNU $PACKAGE$TIMESTAMP) $VERSION\" 1>&2 + fi +} + +# Used when --lt-debug. Prints its arguments to stdout +# (redirection is the responsibility of the caller) +func_lt_dump_args () +{ + lt_dump_args_N=1; + for lt_arg + do + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[\$lt_dump_args_N]: \$lt_arg\" + lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` + done +} + +# Core function for launching the target application +func_exec_program_core () +{ " - $ECHO "\ + case $host in + # Backslashes separate directories on plain windows + *-*-mingw | *-*-os2* | *-cegcc*) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir\\\\\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} +" + ;; + + *) + $ECHO "\ + if test -n \"\$lt_option_debug\"; then + \$ECHO \"${outputname}:${output}:\${LINENO}: newargv[0]: \$progdir/\$program\" 1>&2 + func_lt_dump_args \${1+\"\$@\"} 1>&2 + fi + exec \"\$progdir/\$program\" \${1+\"\$@\"} +" + ;; + esac + $ECHO "\ + \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 + exit 1 +} + +# A function to encapsulate launching the target application +# Strips options in the --lt-* namespace from \$@ and +# launches target application with the remaining arguments. +func_exec_program () +{ + for lt_wr_arg + do + case \$lt_wr_arg in + --lt-*) ;; + *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; + esac + shift + done + func_exec_program_core \${1+\"\$@\"} +} + + # Parse options + func_parse_lt_options \"\$0\" \${1+\"\$@\"} # Find the directory that this script lives in. - thisdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` + thisdir=\`\$ECHO \"\$file\" | $SED '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'\` + file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` while test -n \"\$file\"; do - destdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\` + destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` # If there was a directory component, then change thisdir. if test \"x\$destdir\" != \"x\$file\"; then @@ -2798,8 +4013,8 @@ else esac fi - file=\`\$ECHO \"X\$file\" | \$Xsed -e 's%^.*/%%'\` - file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` + file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` + file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` done # Usually 'no', except on cygwin/mingw when embedded into @@ -2812,7 +4027,7 @@ else fi # remove .libs from thisdir case \"\$thisdir\" in - *[\\\\/]$objdir ) thisdir=\`\$ECHO \"X\$thisdir\" | \$Xsed -e 's%[\\\\/][^\\\\/]*$%%'\` ;; + *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; $objdir ) thisdir=. ;; esac fi @@ -2867,6 +4082,18 @@ else if test -f \"\$progdir/\$program\"; then" + # fixup the dll searchpath if we need to. + # + # Fix the DLL searchpath if we need to. Do this before prepending + # to shlibpath, because on Windows, both are PATH and uninstalled + # libraries must come first. + if test -n "$dllsearchpath"; then + $ECHO "\ + # Add the dll search path components to the executable PATH + PATH=$dllsearchpath:\$PATH +" + fi + # Export our shlibpath_var if we have one. if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then $ECHO "\ @@ -2875,53 +4102,28 @@ else # 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/::*\$//'\` + $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED '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*) - $ECHO "\ - exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} -" - ;; - - *) - $ECHO "\ - exec \"\$progdir/\$program\" \${1+\"\$@\"} -" - ;; - esac - $ECHO "\ - \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 - exit 1 + # Run the actual program with our arguments. + func_exec_program \${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 + \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 exit 1 fi fi\ " } -# end: func_emit_wrapper + # func_emit_cwrapperexe_src # emit the source code for a wrapper executable on stdout @@ -2939,20 +4141,18 @@ func_emit_cwrapperexe_src () This wrapper executable should never be moved out of the build directory. If it is, it will not operate correctly. - - Currently, it simply execs the wrapper *script* "$SHELL $output", - but could eventually absorb all of the scripts functionality and - exec $objdir/$outputname directly. */ EOF cat <<"EOF" +#ifdef _MSC_VER +# define _CRT_SECURE_NO_DEPRECATE 1 +#endif #include #include #ifdef _MSC_VER # include # include # include -# define setmode _setmode #else # include # include @@ -2969,6 +4169,44 @@ EOF #include #include +/* declarations of non-ANSI functions */ +#if defined(__MINGW32__) +# ifdef __STRICT_ANSI__ +int _putenv (const char *); +# endif +#elif defined(__CYGWIN__) +# ifdef __STRICT_ANSI__ +char *realpath (const char *, char *); +int putenv (char *); +int setenv (const char *, const char *, int); +# endif +/* #elif defined (other platforms) ... */ +#endif + +/* portability defines, excluding path handling macros */ +#if defined(_MSC_VER) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +# define S_IXUSR _S_IEXEC +# ifndef _INTPTR_T_DEFINED +# define _INTPTR_T_DEFINED +# define intptr_t int +# endif +#elif defined(__MINGW32__) +# define setmode _setmode +# define stat _stat +# define chmod _chmod +# define getcwd _getcwd +# define putenv _putenv +#elif defined(__CYGWIN__) +# define HAVE_SETENV +# define FOPEN_WB "wb" +/* #elif defined (other platforms) ... */ +#endif + #if defined(PATH_MAX) # define LT_PATHMAX PATH_MAX #elif defined(MAXPATHLEN) @@ -2984,14 +4222,7 @@ EOF # 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 - +/* path handling portability macros */ #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' @@ -3022,10 +4253,6 @@ EOF # 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 @@ -3038,22 +4265,13 @@ EOF 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); -} +#if defined(LT_DEBUGWRAPPER) +static int lt_debug = 1; #else -# define LTWRAPPER_DEBUGPRINTF(args) +static int lt_debug = 0; #endif -const char *program_name = NULL; +const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ void *xmalloc (size_t num); char *xstrdup (const char *string); @@ -3063,37 +4281,88 @@ 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_debugprintf (const char *file, int line, const char *fmt, ...); +void lt_fatal (const char *file, int line, const char *message, ...); +static const char *nonnull (const char *s); +static const char *nonempty (const char *s); +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_update_exe_path (const char *name, const char *value); +void lt_update_lib_path (const char *name, const char *value); +char **prepare_spawn (char **argv); +void lt_dump_script (FILE *f); +EOF -static const char *script_text = + cat </dev/null || echo $SHELL` - case $lt_newargv0 in - *.exe | *.EXE) ;; - *) lt_newargv0=$lt_newargv0.exe ;; - esac - ;; - * ) lt_newargv0=$SHELL ;; - esac - fi - - cat < 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) +{ + lt_debugprintf (__FILE__, __LINE__, + "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", + nonnull (name), nonnull (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 + case $host_os in + mingw*) + cat <<"EOF" + +/* Prepares an argument vector before calling spawn(). + Note that spawn() does not by itself call the command interpreter + (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : + ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + GetVersionEx(&v); + v.dwPlatformId == VER_PLATFORM_WIN32_NT; + }) ? "cmd.exe" : "command.com"). + Instead it simply concatenates the arguments, separated by ' ', and calls + CreateProcess(). We must quote the arguments since Win32 CreateProcess() + interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a + special way: + - Space and tab are interpreted as delimiters. They are not treated as + delimiters if they are surrounded by double quotes: "...". + - Unescaped double quotes are removed from the input. Their only effect is + that within double quotes, space and tab are treated like normal + characters. + - Backslashes not followed by double quotes are not special. + - But 2*n+1 backslashes followed by a double quote become + n backslashes followed by a double quote (n >= 0): + \" -> " + \\\" -> \" + \\\\\" -> \\" + */ +#define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +#define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" +char ** +prepare_spawn (char **argv) +{ + size_t argc; + char **new_argv; + size_t i; + + /* Count number of arguments. */ + for (argc = 0; argv[argc] != NULL; argc++) + ; + + /* Allocate new argument vector. */ + new_argv = XMALLOC (char *, argc + 1); + + /* Put quoted arguments into the new argument vector. */ + for (i = 0; i < argc; i++) + { + const char *string = argv[i]; + + if (string[0] == '\0') + new_argv[i] = xstrdup ("\"\""); + else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) + { + int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); + size_t length; + unsigned int backslashes; + const char *s; + char *quoted_string; + char *p; + + length = 0; + backslashes = 0; + if (quote_around) + length++; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + length += backslashes + 1; + length++; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + length += backslashes + 1; + + quoted_string = XMALLOC (char, length + 1); + + p = quoted_string; + backslashes = 0; + if (quote_around) + *p++ = '"'; + for (s = string; *s != '\0'; s++) + { + char c = *s; + if (c == '"') + { + unsigned int j; + for (j = backslashes + 1; j > 0; j--) + *p++ = '\\'; + } + *p++ = c; + if (c == '\\') + backslashes++; + else + backslashes = 0; + } + if (quote_around) + { + unsigned int j; + for (j = backslashes; j > 0; j--) + *p++ = '\\'; + *p++ = '"'; + } + *p = '\0'; + + new_argv[i] = quoted_string; + } + else + new_argv[i] = (char *) string; + } + new_argv[argc] = NULL; + + return new_argv; +} +EOF + ;; + esac + + cat <<"EOF" +void lt_dump_script (FILE* f) +{ +EOF + func_emit_wrapper yes | + $SED -e 's/\([\\"]\)/\\\1/g' \ + -e 's/^/ fputs ("/' -e 's/$/\\n", f);/' + + cat <<"EOF" +} EOF } # end: func_emit_cwrapperexe_src +# func_win32_import_lib_p ARG +# True if ARG is an import lib, as indicated by $file_magic_cmd +func_win32_import_lib_p () +{ + $opt_debug + case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in + *import*) : ;; + *) false ;; + esac +} + # func_mode_link arg... func_mode_link () { $opt_debug case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) + *-*-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 @@ -3561,6 +5121,7 @@ func_mode_link () new_inherited_linker_flags= avoid_version=no + bindir= dlfiles= dlprefiles= dlself=no @@ -3653,6 +5214,11 @@ func_mode_link () esac case $prev in + bindir) + bindir="$arg" + prev= + continue + ;; dlfiles|dlprefiles) if test "$preload" = no; then # Add the symbol object into the linking commands. @@ -3684,9 +5250,9 @@ func_mode_link () ;; *) if test "$prev" = dlfiles; then - dlfiles="$dlfiles $arg" + func_append dlfiles " $arg" else - dlprefiles="$dlprefiles $arg" + func_append dlprefiles " $arg" fi prev= continue @@ -3710,7 +5276,7 @@ func_mode_link () *-*-darwin*) case "$deplibs " in *" $qarg.ltframework "*) ;; - *) deplibs="$deplibs $qarg.ltframework" # this is fixed later + *) func_append deplibs " $qarg.ltframework" # this is fixed later ;; esac ;; @@ -3729,7 +5295,7 @@ func_mode_link () moreargs= for fil in `cat "$save_arg"` do -# moreargs="$moreargs $fil" +# func_append moreargs " $fil" arg=$fil # A libtool-controlled object. @@ -3758,7 +5324,7 @@ func_mode_link () if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - dlfiles="$dlfiles $pic_object" + func_append dlfiles " $pic_object" prev= continue else @@ -3770,7 +5336,7 @@ func_mode_link () # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. - dlprefiles="$dlprefiles $pic_object" + func_append dlprefiles " $pic_object" prev= fi @@ -3840,12 +5406,12 @@ func_mode_link () if test "$prev" = rpath; then case "$rpath " in *" $arg "*) ;; - *) rpath="$rpath $arg" ;; + *) func_append rpath " $arg" ;; esac else case "$xrpath " in *" $arg "*) ;; - *) xrpath="$xrpath $arg" ;; + *) func_append xrpath " $arg" ;; esac fi prev= @@ -3857,28 +5423,28 @@ func_mode_link () continue ;; weak) - weak_libs="$weak_libs $arg" + func_append weak_libs " $arg" prev= continue ;; xcclinker) - linker_flags="$linker_flags $qarg" - compiler_flags="$compiler_flags $qarg" + func_append linker_flags " $qarg" + func_append compiler_flags " $qarg" prev= func_append compile_command " $qarg" func_append finalize_command " $qarg" continue ;; xcompiler) - compiler_flags="$compiler_flags $qarg" + func_append 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" + func_append linker_flags " $qarg" + func_append compiler_flags " $wl$qarg" prev= func_append compile_command " $wl$qarg" func_append finalize_command " $wl$qarg" @@ -3914,6 +5480,11 @@ func_mode_link () continue ;; + -bindir) + prev=bindir + continue + ;; + -dlopen) prev=dlfiles continue @@ -3964,8 +5535,16 @@ func_mode_link () ;; -L*) - func_stripname '-L' '' "$arg" - dir=$func_stripname_result + func_stripname "-L" '' "$arg" + if test -z "$func_stripname_result"; 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 + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; @@ -3977,22 +5556,30 @@ func_mode_link () ;; esac case "$deplibs " in - *" -L$dir "*) ;; + *" -L$dir "* | *" $arg "*) + # Will only happen for absolute or sysroot arguments + ;; *) - deplibs="$deplibs -L$dir" - lib_search_path="$lib_search_path $dir" + # Preserve sysroot, but never include relative directories + case $dir in + [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; + *) func_append deplibs " -L$dir" ;; + esac + func_append lib_search_path " $dir" ;; esac case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) - testbindir=`$ECHO "X$dir" | $Xsed -e 's*/lib$*/bin*'` + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) + testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; - *) dllsearchpath="$dllsearchpath:$dir";; + ::) dllsearchpath=$dir;; + *) func_append dllsearchpath ":$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; esac ;; esac @@ -4002,7 +5589,7 @@ func_mode_link () -l*) if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) # These systems don't actually have a C or math library (as such) continue ;; @@ -4016,7 +5603,7 @@ func_mode_link () ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C and math libraries are in the System framework - deplibs="$deplibs System.ltframework" + func_append deplibs " System.ltframework" continue ;; *-*-sco3.2v5* | *-*-sco5v6*) @@ -4036,7 +5623,7 @@ func_mode_link () ;; esac fi - deplibs="$deplibs $arg" + func_append deplibs " $arg" continue ;; @@ -4048,8 +5635,8 @@ func_mode_link () # 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" + -model|-arch|-isysroot|--sysroot) + func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" prev=xcompiler @@ -4057,12 +5644,12 @@ func_mode_link () ;; -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) - compiler_flags="$compiler_flags $arg" + func_append 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" ;; + * ) func_append new_inherited_linker_flags " $arg" ;; esac continue ;; @@ -4079,7 +5666,7 @@ func_mode_link () -no-install) case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin*) + *-*-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" @@ -4129,13 +5716,17 @@ func_mode_link () # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; + =*) + func_stripname '=' '' "$dir" + dir=$lt_sysroot$func_stripname_result + ;; *) func_fatal_error "only absolute run-paths are allowed" ;; esac case "$xrpath " in *" $dir "*) ;; - *) xrpath="$xrpath $dir" ;; + *) func_append xrpath " $dir" ;; esac continue ;; @@ -4188,8 +5779,8 @@ func_mode_link () 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" + func_append arg " $func_quote_for_eval_result" + func_append compiler_flags " $func_quote_for_eval_result" done IFS="$save_ifs" func_stripname ' ' '' "$arg" @@ -4204,9 +5795,9 @@ func_mode_link () 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" + func_append arg " $wl$func_quote_for_eval_result" + func_append compiler_flags " $wl$func_quote_for_eval_result" + func_append linker_flags " $func_quote_for_eval_result" done IFS="$save_ifs" func_stripname ' ' '' "$arg" @@ -4234,23 +5825,27 @@ func_mode_link () 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 + # Flags to be passed through unchanged, with rationale: + # -64, -mips[0-9] enable 64-bit mode for the SGI compiler + # -r[0-9][0-9]* specify processor for the SGI compiler + # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler + # +DA*, +DD* enable 64-bit mode for the HP compiler + # -q* compiler args for the IBM compiler + # -m*, -t[45]*, -txscale* architecture-specific flags for GCC + # -F/path path to uninstalled frameworks, gcc on darwin + # -p, -pg, --coverage, -fprofile-* profiling flags for GCC + # @file GCC response files + # -tp=* Portland pgcc target processor selection + # --sysroot=* for sysroot support + # -O*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ - -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*) + -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ + -O*|-flto*|-fwhopr*|-fuse-linker-plugin) 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" + func_append compiler_flags " $arg" continue ;; @@ -4262,7 +5857,7 @@ func_mode_link () *.$objext) # A standard object. - objs="$objs $arg" + func_append objs " $arg" ;; *.lo) @@ -4293,7 +5888,7 @@ func_mode_link () if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then - dlfiles="$dlfiles $pic_object" + func_append dlfiles " $pic_object" prev= continue else @@ -4305,7 +5900,7 @@ func_mode_link () # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. - dlprefiles="$dlprefiles $pic_object" + func_append dlprefiles " $pic_object" prev= fi @@ -4350,24 +5945,25 @@ func_mode_link () *.$libext) # An archive. - deplibs="$deplibs $arg" - old_deplibs="$old_deplibs $arg" + func_append deplibs " $arg" + func_append old_deplibs " $arg" continue ;; *.la) # A libtool-controlled library. + func_resolve_sysroot "$arg" if test "$prev" = dlfiles; then # This library was specified with -dlopen. - dlfiles="$dlfiles $arg" + func_append dlfiles " $func_resolve_sysroot_result" prev= elif test "$prev" = dlprefiles; then # The library was specified with -dlpreopen. - dlprefiles="$dlprefiles $arg" + func_append dlprefiles " $func_resolve_sysroot_result" prev= else - deplibs="$deplibs $arg" + func_append deplibs " $func_resolve_sysroot_result" fi continue ;; @@ -4405,7 +6001,7 @@ func_mode_link () 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\'\` + eval shlib_search_path=\`\$ECHO \"\${$shlibpath_var}\" \| \$SED \'s/:/ /g\'\` else shlib_search_path= fi @@ -4414,6 +6010,8 @@ func_mode_link () func_dirname "$output" "/" "" output_objdir="$func_dirname_result$objdir" + func_to_tool_file "$output_objdir/" + tool_output_objdir=$func_to_tool_file_result # Create the object directory. func_mkdir_p "$output_objdir" @@ -4434,12 +6032,12 @@ func_mode_link () # 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 + if $opt_preserve_dup_deps ; then case "$libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi - libs="$libs $deplib" + func_append libs " $deplib" done if test "$linkmode" = lib; then @@ -4452,9 +6050,9 @@ func_mode_link () 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" ;; + *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; esac - pre_post_deps="$pre_post_deps $pre_post_dep" + func_append pre_post_deps " $pre_post_dep" done fi pre_post_deps= @@ -4521,17 +6119,19 @@ func_mode_link () for lib in $dlprefiles; do # Ignore non-libtool-libs dependency_libs= + func_resolve_sysroot "$lib" case $lib in - *.la) func_source "$lib" ;; + *.la) func_source "$func_resolve_sysroot_result" ;; 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"` + func_basename "$deplib" + deplib_base=$func_basename_result case " $weak_libs " in *" $deplib_base "*) ;; - *) deplibs="$deplibs $deplib" ;; + *) func_append deplibs " $deplib" ;; esac done done @@ -4552,11 +6152,11 @@ func_mode_link () compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else - compiler_flags="$compiler_flags $deplib" + func_append compiler_flags " $deplib" if test "$linkmode" = lib ; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; - * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi @@ -4641,7 +6241,7 @@ func_mode_link () if test "$linkmode" = lib ; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; - * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;; + * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi @@ -4654,7 +6254,8 @@ func_mode_link () test "$pass" = conv && continue newdependency_libs="$deplib $newdependency_libs" func_stripname '-L' '' "$deplib" - newlib_search_path="$newlib_search_path $func_stripname_result" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" ;; prog) if test "$pass" = conv; then @@ -4668,7 +6269,8 @@ func_mode_link () finalize_deplibs="$deplib $finalize_deplibs" fi func_stripname '-L' '' "$deplib" - newlib_search_path="$newlib_search_path $func_stripname_result" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" ;; *) func_warning "\`-L' is ignored for archives/objects" @@ -4679,17 +6281,21 @@ func_mode_link () -R*) if test "$pass" = link; then func_stripname '-R' '' "$deplib" - dir=$func_stripname_result + func_resolve_sysroot "$func_stripname_result" + dir=$func_resolve_sysroot_result # Make sure the xrpath contains only unique directories. case "$xrpath " in *" $dir "*) ;; - *) xrpath="$xrpath $dir" ;; + *) func_append xrpath " $dir" ;; esac fi deplibs="$deplib $deplibs" continue ;; - *.la) lib="$deplib" ;; + *.la) + func_resolve_sysroot "$deplib" + lib=$func_resolve_sysroot_result + ;; *.$libext) if test "$pass" = conv; then deplibs="$deplib $deplibs" @@ -4707,7 +6313,7 @@ func_mode_link () 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 \ + if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then valid_a_lib=yes fi @@ -4717,15 +6323,15 @@ func_mode_link () ;; esac if test "$valid_a_lib" != yes; then - $ECHO + 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." + 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 $ECHO "*** Warning: Linking the shared library $output against the" $ECHO "*** static library $deplib is not portable!" deplibs="$deplib $deplibs" @@ -4752,11 +6358,11 @@ func_mode_link () 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" + func_append newdlprefiles " $deplib" compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else - newdlfiles="$newdlfiles $deplib" + func_append newdlfiles " $deplib" fi fi continue @@ -4798,20 +6404,20 @@ func_mode_link () # 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'` + tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED '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";; + *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; esac done fi - dependency_libs=`$ECHO "X $dependency_libs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'` + dependency_libs=`$ECHO " $dependency_libs" | $SED '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" + test -n "$dlopen" && func_append dlfiles " $dlopen" + test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" fi if test "$pass" = conv; then @@ -4822,20 +6428,20 @@ func_mode_link () 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" + func_append convenience " $ladir/$objdir/$old_library" + func_append old_convenience " $ladir/$objdir/$old_library" elif test "$linkmode" != prog && test "$linkmode" != lib; then func_fatal_error "\`$lib' is not a convenience library" fi tmp_libs= for deplib in $dependency_libs; do deplibs="$deplib $deplibs" - if $opt_duplicate_deps ; then + if $opt_preserve_dup_deps ; then case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi - tmp_libs="$tmp_libs $deplib" + func_append tmp_libs " $deplib" done continue fi # $pass = conv @@ -4843,9 +6449,15 @@ func_mode_link () # Get the name of the library we link against. linklib= - for l in $old_library $library_names; do - linklib="$l" - done + if test -n "$old_library" && + { test "$prefer_static_libs" = yes || + test "$prefer_static_libs,$installed" = "built,no"; }; then + linklib=$old_library + else + for l in $old_library $library_names; do + linklib="$l" + done + fi if test -z "$linklib"; then func_fatal_error "cannot find name of link library for \`$lib'" fi @@ -4862,9 +6474,9 @@ func_mode_link () # 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" + func_append dlprefiles " $lib $dependency_libs" else - newdlfiles="$newdlfiles $lib" + func_append newdlfiles " $lib" fi continue fi # $pass = dlopen @@ -4886,14 +6498,14 @@ func_mode_link () # 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 + if test ! -f "$lt_sysroot$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" + dir="$lt_sysroot$libdir" + absdir="$lt_sysroot$libdir" fi test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes else @@ -4901,12 +6513,12 @@ func_mode_link () dir="$ladir" absdir="$abs_ladir" # Remove this search path later - notinst_path="$notinst_path $abs_ladir" + func_append notinst_path " $abs_ladir" else dir="$ladir/$objdir" absdir="$abs_ladir/$objdir" # Remove this search path later - notinst_path="$notinst_path $abs_ladir" + func_append notinst_path " $abs_ladir" fi fi # $installed = yes func_stripname 'lib' '.la' "$laname" @@ -4917,20 +6529,46 @@ func_mode_link () 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 + case "$host" in + # special handling for platforms with PE-DLLs. + *cygwin* | *mingw* | *cegcc* ) + # Linker will automatically link against shared library if both + # static and shared are present. Therefore, ensure we extract + # symbols from the import library if a shared library is present + # (otherwise, the dlopen module name will be incorrect). We do + # this by putting the import library name into $newdlprefiles. + # We recover the dlopen module name by 'saving' the la file + # name in a special purpose variable, and (later) extracting the + # dlname from the la file. + if test -n "$dlname"; then + func_tr_sh "$dir/$linklib" + eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" + func_append newdlprefiles " $dir/$linklib" + else + func_append 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" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + fi + ;; + * ) + # Prefer using a static library (so that no silly _DYNAMIC symbols + # are required to link). + if test -n "$old_library"; then + func_append 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" && \ + func_append dlpreconveniencelibs " $dir/$old_library" + # Otherwise, use the dlname, so that lt_dlopen finds it. + elif test -n "$dlname"; then + func_append newdlprefiles " $dir/$dlname" + else + func_append newdlprefiles " $dir/$linklib" + fi + ;; + esac fi # $pass = dlpreopen if test -z "$libdir"; then @@ -4948,7 +6586,7 @@ func_mode_link () if test "$linkmode" = prog && test "$pass" != link; then - newlib_search_path="$newlib_search_path $ladir" + func_append newlib_search_path " $ladir" deplibs="$lib $deplibs" linkalldeplibs=no @@ -4961,7 +6599,8 @@ func_mode_link () for deplib in $dependency_libs; do case $deplib in -L*) func_stripname '-L' '' "$deplib" - newlib_search_path="$newlib_search_path $func_stripname_result" + func_resolve_sysroot "$func_stripname_result" + func_append newlib_search_path " $func_resolve_sysroot_result" ;; esac # Need to link against all dependency_libs? @@ -4972,12 +6611,12 @@ func_mode_link () # or/and link against static libraries newdependency_libs="$deplib $newdependency_libs" fi - if $opt_duplicate_deps ; then + if $opt_preserve_dup_deps ; then case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi - tmp_libs="$tmp_libs $deplib" + func_append tmp_libs " $deplib" done # for deplib continue fi # $linkmode = prog... @@ -4992,7 +6631,7 @@ func_mode_link () # Make sure the rpath contains only unique directories. case "$temp_rpath:" in *"$absdir:"*) ;; - *) temp_rpath="$temp_rpath$absdir:" ;; + *) func_append temp_rpath "$absdir:" ;; esac fi @@ -5004,7 +6643,7 @@ func_mode_link () *) case "$compile_rpath " in *" $absdir "*) ;; - *) compile_rpath="$compile_rpath $absdir" + *) func_append compile_rpath " $absdir" ;; esac ;; esac @@ -5013,7 +6652,7 @@ func_mode_link () *) case "$finalize_rpath " in *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" + *) func_append finalize_rpath " $libdir" ;; esac ;; esac @@ -5036,14 +6675,14 @@ func_mode_link () if test -n "$library_names" && { test "$use_static_libs" = no || test -z "$old_library"; }; then case $host in - *cygwin* | *mingw*) + *cygwin* | *mingw* | *cegcc*) # No point in relinking DLLs because paths are not encoded - notinst_deplibs="$notinst_deplibs $lib" + func_append notinst_deplibs " $lib" need_relink=no ;; *) if test "$installed" = no; then - notinst_deplibs="$notinst_deplibs $lib" + func_append notinst_deplibs " $lib" need_relink=yes fi ;; @@ -5060,7 +6699,7 @@ func_mode_link () fi done if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then - $ECHO + echo if test "$linkmode" = prog; then $ECHO "*** Warning: Linking the executable $output against the loadable module" else @@ -5078,7 +6717,7 @@ func_mode_link () *) case "$compile_rpath " in *" $absdir "*) ;; - *) compile_rpath="$compile_rpath $absdir" + *) func_append compile_rpath " $absdir" ;; esac ;; esac @@ -5087,7 +6726,7 @@ func_mode_link () *) case "$finalize_rpath " in *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" + *) func_append finalize_rpath " $libdir" ;; esac ;; esac @@ -5106,7 +6745,7 @@ func_mode_link () elif test -n "$soname_spec"; then # bleh windows case $host in - *cygwin* | mingw*) + *cygwin* | mingw* | *cegcc*) func_arith $current - $age major=$func_arith_result versuffix="-$major" @@ -5141,7 +6780,7 @@ func_mode_link () linklib=$newlib fi # test -n "$old_archive_from_expsyms_cmds" - if test "$linkmode" = prog || test "$mode" != relink; then + if test "$linkmode" = prog || test "$opt_mode" != relink; then add_shlibpath= add_dir= add= @@ -5163,9 +6802,9 @@ func_mode_link () 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" + 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 @@ -5197,7 +6836,7 @@ func_mode_link () if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) - add_dir="$add_dir -L$inst_prefix_dir$libdir" + func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi @@ -5219,7 +6858,7 @@ func_mode_link () if test -n "$add_shlibpath"; then case :$compile_shlibpath: in *":$add_shlibpath:"*) ;; - *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; + *) func_append compile_shlibpath "$add_shlibpath:" ;; esac fi if test "$linkmode" = prog; then @@ -5233,13 +6872,13 @@ func_mode_link () test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; - *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; + *) func_append finalize_shlibpath "$libdir:" ;; esac fi fi fi - if test "$linkmode" = prog || test "$mode" = relink; then + if test "$linkmode" = prog || test "$opt_mode" = relink; then add_shlibpath= add_dir= add= @@ -5253,7 +6892,7 @@ func_mode_link () elif test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; - *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; + *) func_append finalize_shlibpath "$libdir:" ;; esac add="-l$name" elif test "$hardcode_automatic" = yes; then @@ -5270,7 +6909,7 @@ func_mode_link () if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) - add_dir="$add_dir -L$inst_prefix_dir$libdir" + func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi @@ -5305,21 +6944,21 @@ func_mode_link () # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. - $ECHO + 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." + 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." + 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." + 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 @@ -5347,37 +6986,46 @@ func_mode_link () temp_xrpath=$func_stripname_result case " $xrpath " in *" $temp_xrpath "*) ;; - *) xrpath="$xrpath $temp_xrpath";; + *) func_append xrpath " $temp_xrpath";; esac;; - *) temp_deplibs="$temp_deplibs $libdir";; + *) func_append temp_deplibs " $libdir";; esac done dependency_libs="$temp_deplibs" fi - newlib_search_path="$newlib_search_path $absdir" + func_append 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 $deplib in + -L*) func_stripname '-L' '' "$deplib" + func_resolve_sysroot "$func_stripname_result";; + *) func_resolve_sysroot "$deplib" ;; + esac + if $opt_preserve_dup_deps ; then case "$tmp_libs " in - *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; + *" $func_resolve_sysroot_result "*) + func_append specialdeplibs " $func_resolve_sysroot_result" ;; esac fi - tmp_libs="$tmp_libs $deplib" + func_append tmp_libs " $func_resolve_sysroot_result" 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_resolve_sysroot "$deplib" + deplib=$func_resolve_sysroot_result func_dirname "$deplib" "" "." - dir="$func_dirname_result" + dir=$func_dirname_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; @@ -5404,8 +7052,8 @@ func_mode_link () 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}" + func_append compiler_flags " ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}" + func_append linker_flags " -dylib_file ${darwin_install_name}:${depdepl}" path= fi fi @@ -5438,7 +7086,7 @@ func_mode_link () 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'` + compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` fi fi dependency_libs="$newdependency_libs" @@ -5455,7 +7103,7 @@ func_mode_link () for dir in $newlib_search_path; do case "$lib_search_path " in *" $dir "*) ;; - *) lib_search_path="$lib_search_path $dir" ;; + *) func_append lib_search_path " $dir" ;; esac done newlib_search_path= @@ -5513,10 +7161,10 @@ func_mode_link () -L*) case " $tmp_libs " in *" $deplib "*) ;; - *) tmp_libs="$tmp_libs $deplib" ;; + *) func_append tmp_libs " $deplib" ;; esac ;; - *) tmp_libs="$tmp_libs $deplib" ;; + *) func_append tmp_libs " $deplib" ;; esac done eval $var=\"$tmp_libs\" @@ -5532,7 +7180,7 @@ func_mode_link () ;; esac if test -n "$i" ; then - tmp_libs="$tmp_libs $i" + func_append tmp_libs " $i" fi done dependency_libs=$tmp_libs @@ -5573,7 +7221,7 @@ func_mode_link () # Now set the variables for building old libraries. build_libtool_libs=no oldlibs="$output" - objs="$objs$old_deplibs" + func_append objs "$old_deplibs" ;; lib) @@ -5606,10 +7254,10 @@ func_mode_link () 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 $ECHO "*** Warning: Linking the shared library $output against the non-libtool" $ECHO "*** objects $objs is not portable!" - libobjs="$libobjs $objs" + func_append libobjs " $objs" fi fi @@ -5674,7 +7322,7 @@ func_mode_link () age="$number_minor" revision="$number_revision" ;; - freebsd-aout|freebsd-elf|sunos) + freebsd-aout|freebsd-elf|qnx|sunos) current="$number_major" revision="$number_minor" age="0" @@ -5807,7 +7455,7 @@ func_mode_link () done # Make executables depend on our current version. - verstring="$verstring:${current}.0" + func_append verstring ":${current}.0" ;; qnx) @@ -5875,17 +7523,17 @@ func_mode_link () fi func_generate_dlsyms "$libname" "$libname" "yes" - libobjs="$libobjs $symfileobj" + func_append libobjs " $symfileobj" test "X$libobjs" = "X " && libobjs= - if test "$mode" != relink; then + if test "$opt_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) + *.$objext | *.gcno) ;; $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) if test "X$precious_files_regex" != "X"; then @@ -5894,7 +7542,7 @@ func_mode_link () continue fi fi - removelist="$removelist $p" + func_append removelist " $p" ;; *) ;; esac @@ -5905,27 +7553,28 @@ func_mode_link () # 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" + func_append oldlibs " $output_objdir/$libname.$libext" # Transform .lo files to .o files. - oldobjs="$objs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP` + oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; $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"` + # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` + # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` + # dependency_libs=`$ECHO "$dependency_libs " | $SED "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" + func_replace_sysroot "$libdir" + func_append temp_xrpath " -R$func_replace_sysroot_result" case "$finalize_rpath " in *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" ;; + *) func_append finalize_rpath " $libdir" ;; esac done if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then @@ -5939,7 +7588,7 @@ func_mode_link () for lib in $old_dlfiles; do case " $dlprefiles $dlfiles " in *" $lib "*) ;; - *) dlfiles="$dlfiles $lib" ;; + *) func_append dlfiles " $lib" ;; esac done @@ -5949,19 +7598,19 @@ func_mode_link () for lib in $old_dlprefiles; do case "$dlprefiles " in *" $lib "*) ;; - *) dlprefiles="$dlprefiles $lib" ;; + *) func_append dlprefiles " $lib" ;; esac done if test "$build_libtool_libs" = yes; then if test -n "$rpath"; then case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*) + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) # 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" + func_append deplibs " System.ltframework" ;; *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. @@ -5978,7 +7627,7 @@ func_mode_link () *) # Add libc to deplibs on all other systems if necessary. if test "$build_libtool_need_lc" = "yes"; then - deplibs="$deplibs -lc" + func_append deplibs " -lc" fi ;; esac @@ -6027,7 +7676,7 @@ EOF if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $i "*) - newdeplibs="$newdeplibs $i" + func_append newdeplibs " $i" i="" ;; esac @@ -6038,21 +7687,21 @@ EOF set dummy $deplib_matches; shift deplib_match=$1 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then - newdeplibs="$newdeplibs $i" + func_append newdeplibs " $i" else droppeddeps=yes - $ECHO + echo $ECHO "*** Warning: dynamic linker does not accept needed library $i." - $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 I believe you do not have" - $ECHO "*** because a test_compile did reveal that the linker did not use it for" - $ECHO "*** its dynamic dependency list that programs get resolved with at runtime." + 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 I believe you do not have" + echo "*** because a test_compile did reveal that the linker did not use it for" + echo "*** its dynamic dependency list that programs get resolved with at runtime." fi fi ;; *) - newdeplibs="$newdeplibs $i" + func_append newdeplibs " $i" ;; esac done @@ -6070,7 +7719,7 @@ EOF if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $i "*) - newdeplibs="$newdeplibs $i" + func_append newdeplibs " $i" i="" ;; esac @@ -6081,29 +7730,29 @@ EOF set dummy $deplib_matches; shift deplib_match=$1 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then - newdeplibs="$newdeplibs $i" + func_append newdeplibs " $i" else droppeddeps=yes - $ECHO + echo $ECHO "*** Warning: dynamic linker does not accept needed library $i." - $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 a test_compile did reveal that the linker did not use this one" - $ECHO "*** as a dynamic dependency that programs can get resolved with at runtime." + 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 a test_compile did reveal that the linker did not use this one" + echo "*** as a dynamic dependency that programs can get resolved with at runtime." fi fi else droppeddeps=yes - $ECHO + echo $ECHO "*** Warning! Library $i is needed by this library but I was not able to" - $ECHO "*** make it link in! You will probably need to install it or some" - $ECHO "*** library that it depends on before this library will be fully" - $ECHO "*** functional. Installing it before continuing would be even better." + echo "*** make it link in! You will probably need to install it or some" + echo "*** library that it depends on before this library will be fully" + echo "*** functional. Installing it before continuing would be even better." fi ;; *) - newdeplibs="$newdeplibs $i" + func_append newdeplibs " $i" ;; esac done @@ -6120,15 +7769,27 @@ EOF if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $a_deplib "*) - newdeplibs="$newdeplibs $a_deplib" + func_append newdeplibs " $a_deplib" a_deplib="" ;; esac fi if test -n "$a_deplib" ; then libname=`eval "\\$ECHO \"$libname_spec\""` + if test -n "$file_magic_glob"; then + libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob` + else + libnameglob=$libname + fi + test "$want_nocaseglob" = yes && nocaseglob=`shopt -p nocaseglob` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do - potential_libs=`ls $i/$libname[.-]* 2>/dev/null` + if test "$want_nocaseglob" = yes; then + shopt -s nocaseglob + potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` + $nocaseglob + else + potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` + fi for potent_lib in $potential_libs; do # Follow soft links. if ls -lLd "$potent_lib" 2>/dev/null | @@ -6145,13 +7806,13 @@ EOF potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` case $potliblink in [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; - *) potlib=`$ECHO "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";; + *) potlib=`$ECHO "$potlib" | $SED '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" + func_append newdeplibs " $a_deplib" a_deplib="" break 2 fi @@ -6160,12 +7821,12 @@ EOF fi if test -n "$a_deplib" ; then droppeddeps=yes - $ECHO + 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" + 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 @@ -6176,7 +7837,7 @@ EOF ;; *) # Add a -L argument. - newdeplibs="$newdeplibs $a_deplib" + func_append newdeplibs " $a_deplib" ;; esac done # Gone through all deplibs. @@ -6192,7 +7853,7 @@ EOF if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $a_deplib "*) - newdeplibs="$newdeplibs $a_deplib" + func_append newdeplibs " $a_deplib" a_deplib="" ;; esac @@ -6203,9 +7864,9 @@ EOF 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 | \ + if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ $EGREP "$match_pattern_regex" > /dev/null; then - newdeplibs="$newdeplibs $a_deplib" + func_append newdeplibs " $a_deplib" a_deplib="" break 2 fi @@ -6214,12 +7875,12 @@ EOF fi if test -n "$a_deplib" ; then droppeddeps=yes - $ECHO + 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" + 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 @@ -6230,32 +7891,32 @@ EOF ;; *) # Add a -L argument. - newdeplibs="$newdeplibs $a_deplib" + func_append 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'` + tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; 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,,"` + tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s,$i,,"` done fi - if $ECHO "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' | - $GREP . >/dev/null; then - $ECHO + case $tmp_deplibs in + *[!\ \ ]*) + echo if test "X$deplibs_check_method" = "Xnone"; then - $ECHO "*** Warning: inter-library dependencies are not supported in this platform." + echo "*** Warning: inter-library dependencies are not supported in this platform." else - $ECHO "*** Warning: inter-library dependencies are not known to be supported." + echo "*** Warning: inter-library dependencies are not known to be supported." fi - $ECHO "*** All declared inter-library dependencies are being dropped." + echo "*** All declared inter-library dependencies are being dropped." droppeddeps=yes - fi + ;; + esac ;; esac versuffix=$versuffix_save @@ -6267,23 +7928,23 @@ EOF 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 /'` + newdeplibs=`$ECHO " $newdeplibs" | $SED '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 + 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." + 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." + 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" @@ -6293,16 +7954,16 @@ EOF 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." + 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." + 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 @@ -6319,9 +7980,9 @@ EOF # 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'` + newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac @@ -6334,7 +7995,7 @@ EOF *) case " $deplibs " in *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; + func_append new_libs " -L$path/$objdir" ;; esac ;; esac @@ -6344,10 +8005,10 @@ EOF -L*) case " $new_libs " in *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; + *) func_append new_libs " $deplib" ;; esac ;; - *) new_libs="$new_libs $deplib" ;; + *) func_append new_libs " $deplib" ;; esac done deplibs="$new_libs" @@ -6364,10 +8025,12 @@ EOF hardcode_libdirs= dep_rpath= rpath="$finalize_rpath" - test "$mode" != relink && rpath="$compile_rpath$rpath" + test "$opt_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 + func_replace_sysroot "$libdir" + libdir=$func_replace_sysroot_result if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else @@ -6376,18 +8039,18 @@ EOF *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" - dep_rpath="$dep_rpath $flag" + func_append dep_rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; - *) perm_rpath="$perm_rpath $libdir" ;; + *) func_apped perm_rpath " $libdir" ;; esac fi done @@ -6405,7 +8068,7 @@ EOF # We should set the runpath_var. rpath= for dir in $perm_rpath; do - rpath="$rpath$dir:" + func_append rpath "$dir:" done eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" fi @@ -6413,7 +8076,7 @@ EOF fi shlibpath="$finalize_shlibpath" - test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" + test "$opt_mode" != relink && shlibpath="$compile_shlibpath$shlibpath" if test -n "$shlibpath"; then eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" fi @@ -6439,23 +8102,23 @@ EOF linknames= for link do - linknames="$linknames $link" + func_append linknames " $link" done # Use standard objects if they are pic - test -z "$pic_flag" && libobjs=`$ECHO "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` + test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$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" + func_append delfiles " $export_symbols" fi orig_export_symbols= case $host_os in - cygwin* | mingw*) + 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 @@ -6481,13 +8144,45 @@ EOF $opt_dry_run || $RM $export_symbols cmds=$export_symbols_cmds save_ifs="$IFS"; IFS='~' - for cmd in $cmds; do + for cmd1 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 + # Take the normal branch if the nm_file_list_spec branch + # doesn't work or if tool conversion is not needed. + case $nm_file_list_spec~$to_tool_file_cmd in + *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) + try_normal_branch=yes + eval cmd=\"$cmd1\" + func_len " $cmd" + len=$func_len_result + ;; + *) + try_normal_branch=no + ;; + esac + if test "$try_normal_branch" = yes \ + && { test "$len" -lt "$max_cmd_len" \ + || test "$max_cmd_len" -le -1; } + then + func_show_eval "$cmd" 'exit $?' + skipped_export=false + elif test -n "$nm_file_list_spec"; then + func_basename "$output" + output_la=$func_basename_result + save_libobjs=$libobjs + save_output=$output + output=${output_objdir}/${output_la}.nm + func_to_tool_file "$output" + libobjs=$nm_file_list_spec$func_to_tool_file_result + func_append delfiles " $output" + func_verbose "creating $NM input file list: $output" + for obj in $save_libobjs; do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > "$output" + eval cmd=\"$cmd1\" func_show_eval "$cmd" 'exit $?' + output=$save_output + libobjs=$save_libobjs skipped_export=false else # The command line is too long to execute in one step. @@ -6509,7 +8204,7 @@ EOF 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"' + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then @@ -6521,7 +8216,7 @@ EOF # 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" + func_append 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 @@ -6531,7 +8226,7 @@ EOF case " $convenience " in *" $test_deplib "*) ;; *) - tmp_deplibs="$tmp_deplibs $test_deplib" + func_append tmp_deplibs " $test_deplib" ;; esac done @@ -6551,21 +8246,21 @@ EOF test "X$libobjs" = "X " && libobjs= else gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + func_append generated " $gentop" func_extract_archives $gentop $convenience - libobjs="$libobjs $func_extract_archives_result" + func_append 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" + func_append linker_flags " $flag" fi # Make a backup of the uninstalled library when relinking - if test "$mode" = relink; then + if test "$opt_mode" = relink; then $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? fi @@ -6610,7 +8305,8 @@ EOF save_libobjs=$libobjs fi save_output=$output - output_la=`$ECHO "X$output" | $Xsed -e "$basename"` + func_basename "$output" + output_la=$func_basename_result # Clear the reloadable object creation command queue and # initialize k to one. @@ -6623,13 +8319,16 @@ EOF 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 + echo 'INPUT (' > $output for obj in $save_libobjs do - $ECHO "$obj" >> $output + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output done - $ECHO ')' >> $output - delfiles="$delfiles $output" + echo ')' >> $output + func_append delfiles " $output" + func_to_tool_file "$output" + output=$func_to_tool_file_result 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" @@ -6643,10 +8342,12 @@ EOF fi for obj do - $ECHO "$obj" >> $output + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" >> $output done - delfiles="$delfiles $output" - output=$firstobj\"$file_list_spec$output\" + func_append delfiles " $output" + func_to_tool_file "$output" + output=$firstobj\"$file_list_spec$func_to_tool_file_result\" else if test -n "$save_libobjs"; then func_verbose "creating reloadable object files..." @@ -6670,17 +8371,19 @@ EOF # 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\" + reload_objs=$objlist + eval concat_cmds=\"$reload_cmds\" 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\" + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$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 + objlist=" $obj" func_len " $last_robj" func_arith $len0 + $func_len_result len=$func_arith_result @@ -6690,11 +8393,12 @@ EOF # 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\" + reload_objs="$objlist $last_robj" + eval concat_cmds=\"\${concat_cmds}$reload_cmds\" if test -n "$last_robj"; then eval concat_cmds=\"\${concat_cmds}~\$RM $last_robj\" fi - delfiles="$delfiles $output" + func_append delfiles " $output" else output= @@ -6728,7 +8432,7 @@ EOF lt_exit=$? # Restore the uninstalled library and exit - if test "$mode" = relink; then + if test "$opt_mode" = relink; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) @@ -6749,7 +8453,7 @@ EOF 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"' + $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test -n "$orig_export_symbols"; then @@ -6761,7 +8465,7 @@ EOF # 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" + func_append 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 @@ -6802,10 +8506,10 @@ EOF # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + func_append generated " $gentop" func_extract_archives $gentop $dlprefiles - libobjs="$libobjs $func_extract_archives_result" + func_append libobjs " $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= fi @@ -6821,7 +8525,7 @@ EOF lt_exit=$? # Restore the uninstalled library and exit - if test "$mode" = relink; then + if test "$opt_mode" = relink; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) @@ -6833,7 +8537,7 @@ EOF IFS="$save_ifs" # Restore the uninstalled library and exit - if test "$mode" = relink; then + if test "$opt_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 @@ -6914,18 +8618,21 @@ EOF 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'` + reload_conv_objs=$reload_objs\ `$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` else gentop="$output_objdir/${obj}x" - generated="$generated $gentop" + func_append generated " $gentop" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi + # If we're not building shared, we need to use non_pic_objs + test "$build_libtool_libs" != yes && libobjs="$non_pic_objects" + # 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 + reload_objs="$objs$old_deplibs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.${libext}$/d; /\.lib$/d; $lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test output="$obj" func_execute_cmds "$reload_cmds" 'exit $?' @@ -6985,8 +8692,8 @@ EOF 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 /'` + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` ;; esac @@ -6997,14 +8704,14 @@ EOF 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" + func_append compile_command " ${wl}-bind_at_load" + func_append 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'` + compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` + finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac @@ -7018,7 +8725,7 @@ EOF *) case " $compile_deplibs " in *" -L$path/$objdir "*) - new_libs="$new_libs -L$path/$objdir" ;; + func_append new_libs " -L$path/$objdir" ;; esac ;; esac @@ -7028,17 +8735,17 @@ EOF -L*) case " $new_libs " in *" $deplib "*) ;; - *) new_libs="$new_libs $deplib" ;; + *) func_append new_libs " $deplib" ;; esac ;; - *) new_libs="$new_libs $deplib" ;; + *) func_append new_libs " $deplib" ;; esac done compile_deplibs="$new_libs" - compile_command="$compile_command $compile_deplibs" - finalize_command="$finalize_command $finalize_deplibs" + func_append compile_command " $compile_deplibs" + func_append finalize_command " $finalize_deplibs" if test -n "$rpath$xrpath"; then # If the user specified any rpath flags, then add them. @@ -7046,7 +8753,7 @@ EOF # This is the magic to use -rpath. case "$finalize_rpath " in *" $libdir "*) ;; - *) finalize_rpath="$finalize_rpath $libdir" ;; + *) func_append finalize_rpath " $libdir" ;; esac done fi @@ -7065,30 +8772,32 @@ EOF *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" - rpath="$rpath $flag" + func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; - *) perm_rpath="$perm_rpath $libdir" ;; + *) func_append perm_rpath " $libdir" ;; esac fi case $host in - *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; - *) dllsearchpath="$dllsearchpath:$libdir";; + ::) dllsearchpath=$libdir;; + *) func_append dllsearchpath ":$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; - *) dllsearchpath="$dllsearchpath:$testbindir";; + ::) dllsearchpath=$testbindir;; + *) func_append dllsearchpath ":$testbindir";; esac ;; esac @@ -7114,18 +8823,18 @@ EOF *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) - hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" + func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" - rpath="$rpath $flag" + func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$finalize_perm_rpath " in *" $libdir "*) ;; - *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; + *) func_append finalize_perm_rpath " $libdir" ;; esac fi done @@ -7139,8 +8848,8 @@ EOF 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` + compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` + finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` fi func_generate_dlsyms "$outputname" "@PROGRAM@" "no" @@ -7152,6 +8861,10 @@ EOF wrappers_required=yes case $host in + *cegcc* | *mingw32ce*) + # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. + wrappers_required=no + ;; *cygwin* | *mingw* ) if test "$build_libtool_libs" != yes; then wrappers_required=no @@ -7165,13 +8878,19 @@ EOF esac if test "$wrappers_required" = no; then # Replace the output file specification. - compile_command=`$ECHO "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` + compile_command=`$ECHO "$compile_command" | $SED '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=$?' + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + # Delete the generated files. if test -f "$output_objdir/${outputname}S.${objext}"; then func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"' @@ -7194,7 +8913,7 @@ EOF # We should set the runpath_var. rpath= for dir in $perm_rpath; do - rpath="$rpath$dir:" + func_append rpath "$dir:" done compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi @@ -7202,7 +8921,7 @@ EOF # We should set the runpath_var. rpath= for dir in $finalize_perm_rpath; do - rpath="$rpath$dir:" + func_append rpath "$dir:" done finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi @@ -7212,11 +8931,18 @@ EOF # 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'` + link_command=`$ECHO "$link_command" | $SED '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 $?' + + if test -n "$postlink_cmds"; then + func_to_tool_file "$output" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + exit $EXIT_SUCCESS fi @@ -7231,7 +8957,7 @@ EOF 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'` + relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` else # fast_install is set to needless relink_command= @@ -7243,13 +8969,19 @@ EOF fi # Replace the output file specification. - link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` + link_command=`$ECHO "$link_command" | $SED '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 $?' + if test -n "$postlink_cmds"; then + func_to_tool_file "$output_objdir/$outputname" + postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` + func_execute_cmds "$postlink_cmds" 'exit $?' + fi + # Now create the wrapper script. func_verbose "creating $output" @@ -7267,18 +8999,7 @@ EOF 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"` + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` fi # Only actually do things if not in dry run mode. @@ -7309,11 +9030,10 @@ EOF func_emit_cwrapperexe_src > $cwrappersource - # 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. + # 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 @@ -7359,7 +9079,7 @@ EOF else oldobjs="$old_deplibs $non_pic_objects" if test "$preload" = yes && test -f "$symfileobj"; then - oldobjs="$oldobjs $symfileobj" + func_append oldobjs " $symfileobj" fi fi addlibs="$old_convenience" @@ -7367,10 +9087,10 @@ EOF if test -n "$addlibs"; then gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + func_append generated " $gentop" func_extract_archives $gentop $addlibs - oldobjs="$oldobjs $func_extract_archives_result" + func_append oldobjs " $func_extract_archives_result" fi # Do each command in the archive commands. @@ -7381,10 +9101,10 @@ EOF # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + func_append generated " $gentop" func_extract_archives $gentop $dlprefiles - oldobjs="$oldobjs $func_extract_archives_result" + func_append oldobjs " $func_extract_archives_result" fi # POSIX demands no paths to be encoded in archives. We have @@ -7400,9 +9120,9 @@ EOF done | sort | sort -uc >/dev/null 2>&1); then : else - $ECHO "copying selected object files to avoid basename conflicts..." + echo "copying selected object files to avoid basename conflicts..." gentop="$output_objdir/${outputname}x" - generated="$generated $gentop" + func_append generated " $gentop" func_mkdir_p "$gentop" save_oldobjs=$oldobjs oldobjs= @@ -7426,9 +9146,9 @@ EOF esac done func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" - oldobjs="$oldobjs $gentop/$newobj" + func_append oldobjs " $gentop/$newobj" ;; - *) oldobjs="$oldobjs $obj" ;; + *) func_append oldobjs " $obj" ;; esac done fi @@ -7438,6 +9158,16 @@ EOF len=$func_len_result if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then cmds=$old_archive_cmds + elif test -n "$archiver_list_spec"; then + func_verbose "using command file archive linking..." + for obj in $oldobjs + do + func_to_tool_file "$obj" + $ECHO "$func_to_tool_file_result" + done > $output_objdir/$libname.libcmd + func_to_tool_file "$output_objdir/$libname.libcmd" + oldobjs=" $archiver_list_spec$func_to_tool_file_result" + 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..." @@ -7511,7 +9241,7 @@ EOF 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"` + relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` if test "$hardcode_automatic" = yes ; then relink_command= fi @@ -7534,53 +9264,19 @@ EOF eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` test -z "$libdir" && \ func_fatal_error "\`$deplib' is not a valid libtool archive" - if test "x$EGREP" = x ; then - EGREP=egrep - fi - # We do not want portage's install root ($D) present. Check only for - # this if the .la is being installed. - if test "$installed" = yes && test "$D"; then - eval mynewdependency_lib=`echo "$libdir/$name" |sed -e "s:$D:/:g" -e 's:/\+:/:g'` - else - mynewdependency_lib="$libdir/$name" - fi - # Do not add duplicates - if test "$mynewdependency_lib"; then - my_little_ninja_foo_1=`echo $newdependency_libs |$EGREP -e "$mynewdependency_lib"` - if test -z "$my_little_ninja_foo_1"; then - newdependency_libs="$newdependency_libs $mynewdependency_lib" - fi - fi + func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" ;; - *) - if test "$installed" = yes; then - # Rather use S=WORKDIR if our version of portage supports it. - # This is because some ebuild (gcc) do not use $S as buildroot. - if test "$PWORKDIR"; then - S="$PWORKDIR" - fi - # We do not want portage's build root ($S) present. - my_little_ninja_foo_2=`echo $deplib |$EGREP -e "$S"` - # We do not want portage's install root ($D) present. - my_little_ninja_foo_3=`echo $deplib |$EGREP -e "$D"` - if test -n "$my_little_ninja_foo_2" && test "$S"; then - mynewdependency_lib="" - elif test -n "$my_little_ninja_foo_3" && test "$D"; then - eval mynewdependency_lib=`echo "$deplib" |sed -e "s:$D:/:g" -e 's:/\+:/:g'` - else - mynewdependency_lib="$deplib" - fi - else - mynewdependency_lib="$deplib" - fi - # Do not add duplicates - if test "$mynewdependency_lib"; then - my_little_ninja_foo_4=`echo $newdependency_libs |$EGREP -e "$mynewdependency_lib"` - if test -z "$my_little_ninja_foo_4"; then - newdependency_libs="$newdependency_libs $mynewdependency_lib" - fi - fi + -L*) + func_stripname -L '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -L$func_replace_sysroot_result" + ;; + -R*) + func_stripname -R '' "$deplib" + func_replace_sysroot "$func_stripname_result" + func_append newdependency_libs " -R$func_replace_sysroot_result" ;; + *) func_append newdependency_libs " $deplib" ;; esac done dependency_libs="$newdependency_libs" @@ -7594,9 +9290,9 @@ EOF 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" + func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" ;; - *) newdlfiles="$newdlfiles $lib" ;; + *) func_append newdlfiles " $lib" ;; esac done dlfiles="$newdlfiles" @@ -7613,7 +9309,7 @@ EOF 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" + func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" ;; esac done @@ -7625,7 +9321,7 @@ EOF [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac - newdlfiles="$newdlfiles $abs" + func_append newdlfiles " $abs" done dlfiles="$newdlfiles" newdlprefiles= @@ -7634,20 +9330,34 @@ EOF [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac - newdlprefiles="$newdlprefiles $abs" + func_append newdlprefiles " $abs" done dlprefiles="$newdlprefiles" fi $RM $output # place dlname in correct position for cygwin + # In fact, it would be nice if we could use this code for all target + # systems that can't hard-code library paths into their executables + # and that have no shared library path variable independent of PATH, + # but it turns out we can't easily determine that from inspecting + # libtool variables, so we have to hard-code the OSs to which it + # applies here; at the moment, that means platforms that use the PE + # object format with DLL files. See the long comment at the top of + # tests/bindir.at for full details. tdlname=$dlname case $host,$output,$installed,$module,$dlname in - *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;; + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) + # If a -bindir argument was supplied, place the dll there. + if test "x$bindir" != x ; + then + func_relative_path "$install_libdir" "$bindir" + tdlname=$func_relative_path_result$dlname + else + # Otherwise fall back on heuristic. + tdlname=../bin/$dlname + fi + ;; esac - # Do not add duplicates - if test "$installed" = yes && test "$D"; then - install_libdir=`echo "$install_libdir" |sed -e "s:$D:/:g" -e 's:/\+:/:g'` - fi $ECHO > $output "\ # $outputname - a libtool library file # Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION @@ -7705,7 +9415,7 @@ relink_command=\"$relink_command\"" exit $EXIT_SUCCESS } -{ test "$mode" = link || test "$mode" = relink; } && +{ test "$opt_mode" = link || test "$opt_mode" = relink; } && func_mode_link ${1+"$@"} @@ -7725,9 +9435,9 @@ func_mode_uninstall () for arg do case $arg in - -f) RM="$RM $arg"; rmforce=yes ;; - -*) RM="$RM $arg" ;; - *) files="$files $arg" ;; + -f) func_append RM " $arg"; rmforce=yes ;; + -*) func_append RM " $arg" ;; + *) func_append files " $arg" ;; esac done @@ -7736,24 +9446,23 @@ func_mode_uninstall () rmdirs= - origobjdir="$objdir" for file in $files; do func_dirname "$file" "" "." dir="$func_dirname_result" if test "X$dir" = X.; then - objdir="$origobjdir" + odir="$objdir" else - objdir="$dir/$origobjdir" + odir="$dir/$objdir" fi func_basename "$file" name="$func_basename_result" - test "$mode" = uninstall && objdir="$dir" + test "$opt_mode" = uninstall && odir="$dir" - # Remember objdir for removal later, being careful to avoid duplicates - if test "$mode" = clean; then + # Remember odir for removal later, being careful to avoid duplicates + if test "$opt_mode" = clean; then case " $rmdirs " in - *" $objdir "*) ;; - *) rmdirs="$rmdirs $objdir" ;; + *" $odir "*) ;; + *) func_append rmdirs " $odir" ;; esac fi @@ -7779,18 +9488,17 @@ func_mode_uninstall () # Delete the libtool libraries and symlinks. for n in $library_names; do - rmfiles="$rmfiles $objdir/$n" + func_append rmfiles " $odir/$n" done - test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" + test -n "$old_library" && func_append rmfiles " $odir/$old_library" - case "$mode" in + case "$opt_mode" in clean) - case " $library_names " in - # " " in the beginning catches empty $dlname + case " $library_names " in *" $dlname "*) ;; - *) rmfiles="$rmfiles $objdir/$dlname" ;; + *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; esac - test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" + test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" ;; uninstall) if test -n "$library_names"; then @@ -7818,19 +9526,19 @@ func_mode_uninstall () # 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" + func_append 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" + func_append rmfiles " $dir/$non_pic_object" fi fi ;; *) - if test "$mode" = clean ; then + if test "$opt_mode" = clean ; then noexename=$name case $file in *.exe) @@ -7840,7 +9548,7 @@ func_mode_uninstall () noexename=$func_stripname_result # $file with .exe has already been added to rmfiles, # add $file without .exe - rmfiles="$rmfiles $file" + func_append rmfiles " $file" ;; esac # Do a test to see if this is a libtool program. @@ -7849,7 +9557,7 @@ func_mode_uninstall () func_ltwrapper_scriptname "$file" relink_command= func_source $func_ltwrapper_scriptname_result - rmfiles="$rmfiles $func_ltwrapper_scriptname_result" + func_append rmfiles " $func_ltwrapper_scriptname_result" else relink_command= func_source $dir/$noexename @@ -7857,12 +9565,12 @@ func_mode_uninstall () # 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}" + func_append rmfiles " $odir/$name $odir/${name}S.${objext}" if test "$fast_install" = yes && test -n "$relink_command"; then - rmfiles="$rmfiles $objdir/lt-$name" + func_append rmfiles " $odir/lt-$name" fi if test "X$noexename" != "X$name" ; then - rmfiles="$rmfiles $objdir/lt-${noexename}.c" + func_append rmfiles " $odir/lt-${noexename}.c" fi fi fi @@ -7870,7 +9578,6 @@ func_mode_uninstall () 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 @@ -7882,16 +9589,16 @@ func_mode_uninstall () exit $exit_status } -{ test "$mode" = uninstall || test "$mode" = clean; } && +{ test "$opt_mode" = uninstall || test "$opt_mode" = clean; } && func_mode_uninstall ${1+"$@"} -test -z "$mode" && { +test -z "$opt_mode" && { help="$generic_help" func_fatal_help "you must specify a MODE" } test -z "$exec_cmd" && \ - func_fatal_help "invalid operation mode \`$mode'" + func_fatal_help "invalid operation mode \`$opt_mode'" if test -n "$exec_cmd"; then eval exec "$exec_cmd" diff --git a/config/ltoptions.m4 b/config/ltoptions.m4 index e970119..17cfd51 100644 --- a/config/ltoptions.m4 +++ b/config/ltoptions.m4 @@ -1,13 +1,14 @@ # Helper functions for option handling. -*- Autoconf -*- # -# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. +# Copyright (C) 2004, 2005, 2007, 2008, 2009 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 +# serial 7 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) @@ -125,7 +126,7 @@ LT_OPTION_DEFINE([LT_INIT], [win32-dll], [enable_win32_dll=yes case $host in -*-*-cygwin* | *-*-mingw* | *-*-pw32*) +*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) AC_CHECK_TOOL(AS, as, false) AC_CHECK_TOOL(DLLTOOL, dlltool, false) AC_CHECK_TOOL(OBJDUMP, objdump, false) @@ -133,13 +134,13 @@ case $host in esac test -z "$AS" && AS=as -_LT_DECL([], [AS], [0], [Assembler program])dnl +_LT_DECL([], [AS], [1], [Assembler program])dnl test -z "$DLLTOOL" && DLLTOOL=dlltool -_LT_DECL([], [DLLTOOL], [0], [DLL creation program])dnl +_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl test -z "$OBJDUMP" && OBJDUMP=objdump -_LT_DECL([], [OBJDUMP], [0], [Object dumper program])dnl +_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl ])# win32-dll AU_DEFUN([AC_LIBTOOL_WIN32_DLL], diff --git a/config/ltsugar.m4 b/config/ltsugar.m4 index 0d258e0..9000a05 100644 --- a/config/ltsugar.m4 +++ b/config/ltsugar.m4 @@ -1,13 +1,13 @@ # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- # -# Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc. -# Written by Gary V. Vaughan, 2004 +# 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 5 ltsugar.m4 +# 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])]) @@ -63,14 +63,14 @@ m4_define([lt_append], # 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([$2], [], [], - [m4_if([$4], [], [], - [lt_join(m4_quote(m4_default([$1], [[, ]])), - lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_prefix, [$2], - [m4_foreach(_Lt_suffix, lt_car([m4_shiftn(3, $@)]), - [_Lt_prefix[]$3[]_Lt_suffix ])])))))])])dnl -]) +[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]) diff --git a/config/ltversion.m4 b/config/ltversion.m4 index 45cb155..9c7b5d4 100644 --- a/config/ltversion.m4 +++ b/config/ltversion.m4 @@ -7,17 +7,17 @@ # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. -# Generated from ltversion.in. +# @configure_input@ -# serial 2976 ltversion.m4 +# serial 3293 ltversion.m4 # This file is part of GNU Libtool -m4_define([LT_PACKAGE_VERSION], [2.2.4]) -m4_define([LT_PACKAGE_REVISION], [1.2976]) +m4_define([LT_PACKAGE_VERSION], [2.4]) +m4_define([LT_PACKAGE_REVISION], [1.3293]) AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.2.4' -macro_revision='1.2976' +[macro_version='2.4' +macro_revision='1.3293' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) diff --git a/config/lt~obsolete.m4 b/config/lt~obsolete.m4 index 637bb20..c573da9 100644 --- a/config/lt~obsolete.m4 +++ b/config/lt~obsolete.m4 @@ -1,13 +1,13 @@ # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- # -# Copyright (C) 2004, 2005, 2007 Free Software Foundation, Inc. +# Copyright (C) 2004, 2005, 2007, 2009 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 +# serial 5 lt~obsolete.m4 # These exist entirely to fool aclocal when bootstrapping libtool. # @@ -77,7 +77,6 @@ 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])]) @@ -90,3 +89,10 @@ 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])]) +m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) +m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) +m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) +m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) +m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) +m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) +m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) diff --git a/configure b/configure index 01b7e5d..a8b2b55 100755 --- a/configure +++ b/configure @@ -1,18 +1,22 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.63. +# Generated by GNU Autoconf 2.68. +# # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 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. ## -## --------------------- ## +## -------------------- ## +## 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 +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 @@ -20,23 +24,15 @@ if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else - case `(set -o) 2>/dev/null` in - *posix*) set -o posix ;; + 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 @@ -44,7 +40,13 @@ export as_nl 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 +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else @@ -55,7 +57,7 @@ else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; - case $arg in + case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; @@ -78,13 +80,6 @@ if test "${PATH_SEPARATOR+set}" != set; then } 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 @@ -94,15 +89,16 @@ fi IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. -case $0 in +as_myself= +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 + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done IFS=$as_save_IFS ;; @@ -114,12 +110,16 @@ if test "x$as_myself" = x; then 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; } + 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 +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' @@ -131,330 +131,314 @@ 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 - +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH if test "x$CONFIG_SHELL" = x; then - if (eval ":") 2>/dev/null; then - as_have_required=yes + as_bourne_compatible="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 - as_have_required=no + case \`(set -o) 2>/dev/null\` in #( + *posix*) : + set -o posix ;; #( + *) : + ;; +esac 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 -} +" + as_required="as_fn_return () { (exit \$1); } +as_fn_success () { as_fn_return 0; } +as_fn_failure () { as_fn_return 1; } +as_fn_ret_success () { return 0; } +as_fn_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 - : +as_fn_success || { exitcode=1; echo as_fn_success failed.; } +as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } +as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } +as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } +if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : + +else + exitcode=1; echo positional parameters were not saved. +fi +test x\$exitcode = x0 || exit 1" + as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO + as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO + eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && + test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 +test \$(( 1 + 1 )) = 2 || exit 1 + + test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( + ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO + PATH=/empty FPATH=/empty; export PATH FPATH + test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ + || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" + if (eval "$as_required") 2>/dev/null; then : + as_have_required=yes else - exitcode=1 - echo positional parameters were not saved. + as_have_required=no fi + if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : -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 + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_found=false 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 + as_found=: + case $as_dir in #( /*) for as_base in sh bash ksh sh5; do - as_candidate_shells="$as_candidate_shells $as_dir/$as_base" + # Try only shells that exist, to save several forks. + as_shell=$as_dir/$as_base + if { test -f "$as_shell" || test -f "$as_shell.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : + CONFIG_SHELL=$as_shell as_have_required=yes + if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : + break 2 +fi +fi done;; esac + as_found=false done +$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && + { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : + CONFIG_SHELL=$SHELL as_have_required=yes +fi; } 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. + if test "x$CONFIG_SHELL" != x; then : + # We cannot yet assume a decent shell, so we have to provide a + # neutralization value for shells without unset; and this also + # works around shells that cannot unset nonexistent variables. + # Preserve -v and -x to the replacement shell. + BASH_ENV=/dev/null + ENV=/dev/null + (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV + export CONFIG_SHELL + case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; + esac + exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} 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 + if test x$as_have_required = xno; then : + $as_echo "$0: This script requires a shell more modern than all" + $as_echo "$0: the shells that I found on your system." + if test x${ZSH_VERSION+set} = xset ; then + $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" + $as_echo "$0: be upgraded to zsh 4.3.4 or later." + else + $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, +$0: including any error possibly output before this +$0: message. Then install a modern shell, or manually run +$0: the script under such a shell if you do have one." + fi + exit 1 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 +SHELL=${CONFIG_SHELL-/bin/sh} +export SHELL +# Unset more variables known to interfere with behavior of common tools. +CLICOLOR_FORCE= GREP_OPTIONS= +unset CLICOLOR_FORCE GREP_OPTIONS +## --------------------- ## +## M4sh Shell Functions. ## +## --------------------- ## +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset - 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 - +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status -fi +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit -fi +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + 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_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith -(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 -} +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error -exitcode=0 -if as_func_success; then - : +if expr a : '\(a\)' >/dev/null 2>&1 && + test "X`expr 00001 : '.*\(...\)'`" = X001; then + as_expr=expr else - exitcode=1 - echo as_func_success failed. -fi - -if as_func_failure; then - exitcode=1 - echo as_func_failure succeeded. + as_expr=false fi -if as_func_ret_success; then - : +if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then + as_basename=basename else - exitcode=1 - echo as_func_ret_success failed. -fi - -if as_func_ret_failure; then - exitcode=1 - echo as_func_ret_failure succeeded. + as_basename=false fi -if ( set x; as_func_ret_success y && test x = \"\$1\" ); then - : +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname else - exitcode=1 - echo positional parameters were not saved. + as_dirname=false 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_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'` +# 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_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. :-) + as_lineno_1=$LINENO as_lineno_1a=$LINENO + as_lineno_2=$LINENO as_lineno_2a=$LINENO + eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && + test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { + # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= @@ -471,8 +455,7 @@ test \$exitcode = 0") || { 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; }; } + { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_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 @@ -482,29 +465,18 @@ test \$exitcode = 0") || { 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 +case `echo -n x` in #((((( -n*) - case `echo 'x\c'` in + case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. - *) ECHO_C='\c';; + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; 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 @@ -534,7 +506,7 @@ 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=: + as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false @@ -553,10 +525,10 @@ else if test -d "$1"; then test -d "$1/."; else - case $1 in + case $1 in #( -*)set "./$1";; esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in + case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' @@ -569,161 +541,14 @@ 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 +test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. -# hostname on some systems (SVR3.2, Linux) returns a bogus exit status, +# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` @@ -738,7 +563,6 @@ cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= -SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME= @@ -746,6 +570,7 @@ PACKAGE_TARNAME= PACKAGE_VERSION= PACKAGE_STRING= PACKAGE_BUGREPORT= +PACKAGE_URL= ac_unique_file="common-src/amanda.h" # Factoring default headers for most tests. @@ -809,6 +634,8 @@ LIBCURL LIBCURL_CPPFLAGS _libcurl_config READLINE_LIBS +PKG_CONFIG_LIBDIR +PKG_CONFIG_PATH PKG_CONFIG GLIB_MKENUMS GOBJECT_QUERY @@ -822,7 +649,10 @@ OTOOL LIPO NMEDIT DSYMUTIL -lt_ECHO +MANIFEST_TOOL +ac_ct_AR +DLLTOOL +OBJDUMP LN_S NM ac_ct_DUMPBIN @@ -840,6 +670,7 @@ PS_ARGUMENT PS LPRFLAG LPR +UNAME UMOUNT MOUNT MTX @@ -1639,6 +1470,7 @@ bindir program_transform_name prefix exec_prefix +PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION @@ -1734,6 +1566,7 @@ enable_shared enable_static with_pic enable_fast_install +with_sysroot enable_libtool_lock enable_static_binary enable_glibtest @@ -1768,7 +1601,9 @@ GLIB_LIBS GLIB_GENMARSHAL GOBJECT_QUERY GLIB_MKENUMS -PKG_CONFIG' +PKG_CONFIG +PKG_CONFIG_PATH +PKG_CONFIG_LIBDIR' # Initialize some variables set by options. @@ -1831,8 +1666,9 @@ do fi case $ac_option in - *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; - *) ac_optarg=yes ;; + *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; + *=) ac_optarg= ;; + *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. @@ -1877,8 +1713,7 @@ do 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; }; } + as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -1904,8 +1739,7 @@ do 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; }; } + as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -2109,8 +1943,7 @@ do 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; }; } + as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -2126,8 +1959,7 @@ do 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; }; } + as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in @@ -2157,17 +1989,17 @@ do | --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; }; } + -*) as_fn_error $? "unrecognized option: \`$ac_option' +Try \`$0 --help' for more information" ;; *=*) 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; }; } + case $ac_envvar in #( + '' | [0-9]* | *[!_$as_cr_alnum]* ) + as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; + esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; @@ -2176,7 +2008,7 @@ Try \`$0 --help' for more information." >&2 $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} + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac @@ -2184,15 +2016,13 @@ 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; }; } + as_fn_error $? "missing argument to $ac_option" 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; }; } ;; + fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi @@ -2215,8 +2045,7 @@ do [\\/$]* | ?:[\\/]* ) 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; }; } + as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' @@ -2230,8 +2059,8 @@ target=$target_alias 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 + $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 @@ -2246,11 +2075,9 @@ 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; }; } + as_fn_error $? "working directory cannot be determined" 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; }; } + as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. @@ -2289,13 +2116,11 @@ else 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; }; } + as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 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; }; } + cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then @@ -2335,7 +2160,7 @@ Configuration: --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 + -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 @@ -2549,6 +2374,8 @@ Optional Packages: --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-sysroot=DIR Search for dependent libraries within DIR + (or the compiler's sysroot if not specified). --with-readline require readline support (for amrecover) --without-readline don't search for readline --with-libcurl=PREFIX look for the curl library in PREFIX/lib and headers @@ -2560,7 +2387,7 @@ Some influential environment variables: 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 + CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor GNUPLOT Location of the 'gnuplot' binary @@ -2569,28 +2396,38 @@ Some influential environment variables: GNUTAR Location of the GNU 'tar' binary STAR Location of the 'star' binary SUNTAR Location of the 'suntar' binary - YACC The `Yet Another C Compiler' implementation to use. Defaults to - the first program found out of: `bison -y', `byacc', `yacc'. + YACC The `Yet Another Compiler Compiler' implementation to use. + Defaults to the first program found out of: `bison -y', `byacc', + `yacc'. YFLAGS The list of arguments that will be passed by default to $YACC. This script will default YFLAGS to the empty string to avoid a default value of `-d' given by some make applications. MTX Path to the 'mtx' binary MOUNT Path to the 'mount' binary UMOUNT Path to the 'umount' binary - GLIB_CFLAGS CFLAGS to build with glib; disables use of pkg-config - GLIB_LIBS libraries to build with glib; disables use of pkg-config + GLIB_CFLAGS CFLAGS to build with glib; disables use of pkg-config; must + specify all GLIB_ vars + GLIB_LIBS libraries to build with glib; disables use of pkg-config; must + specify all GLIB_vars GLIB_GENMARSHAL - genmarshal binary to use with glib; disables use of pkg-config + genmarshal binary to use with glib; disables use of pkg-config; + must specify all GLIB_ vars GOBJECT_QUERY gobject_query binary to use with glib; disables use of - pkg-config + pkg-config; must specify all GLIB_ vars GLIB_MKENUMS - mkenums binary to use with glib; disables use of pkg-config + mkenums binary to use with glib; disables use of pkg-config; + must specify all GLIB_ vars PKG_CONFIG path to pkg-config utility + PKG_CONFIG_PATH + directories to add to pkg-config's search path + PKG_CONFIG_LIBDIR + path overriding pkg-config's built-in search path 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 the package provider. _ACEOF ac_status=$? fi @@ -2654,21 +2491,707 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF configure -generated by GNU Autoconf 2.63 +generated by GNU Autoconf 2.68 -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +Copyright (C) 2010 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 + +## ------------------------ ## +## Autoconf initialization. ## +## ------------------------ ## + +# ac_fn_c_try_compile LINENO +# -------------------------- +# Try to compile conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + 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:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compile") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + test -z "$ac_c_werror_flag" || + test ! -s conftest.err + } && test -s conftest.$ac_objext; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_compile + +# ac_fn_c_try_cpp LINENO +# ---------------------- +# Try to preprocess conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_cpp () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + 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:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } > conftest.i && { + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || + test ! -s conftest.err + }; then : + ac_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_cpp + +# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists, giving a warning if it cannot be compiled using +# the include files in INCLUDES and setting the cache variable VAR +# accordingly. +ac_fn_c_check_header_mongrel () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if eval \${$3+:} false; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +else + # Is the header compilable? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 +$as_echo_n "checking $2 usability... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_header_compiler=yes +else + ac_header_compiler=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 +$as_echo "$ac_header_compiler" >&6; } + +# Is the header present? +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 +$as_echo_n "checking $2 presence... " >&6; } +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <$2> +_ACEOF +if ac_fn_c_try_cpp "$LINENO"; then : + ac_header_preproc=yes +else + ac_header_preproc=no +fi +rm -f conftest.err conftest.i conftest.$ac_ext +{ $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 +$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} + ;; + no:yes:* ) + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 +$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 +$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 +$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 +$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 +$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} + ;; +esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=\$ac_header_compiler" +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +fi + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_mongrel + +# ac_fn_c_try_run LINENO +# ---------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes +# that executables *can* be run. +ac_fn_c_try_run () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + 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:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { 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:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then : + ac_retval=0 +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 + + ac_retval=$ac_status +fi + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_run + +# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES +# ------------------------------------------------------- +# Tests whether HEADER exists and can be compiled using the include files in +# INCLUDES, setting the cache variable VAR accordingly. +ac_fn_c_check_header_compile () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +#include <$2> +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_header_compile + +# ac_fn_c_try_link LINENO +# ----------------------- +# Try to link conftest.$ac_ext, and return whether this succeeded. +ac_fn_c_try_link () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + 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:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>conftest.err + ac_status=$? + if test -s conftest.err; then + grep -v '^ *+' conftest.err >conftest.er1 + cat conftest.er1 >&5 + mv -f conftest.er1 conftest.err + fi + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && { + 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_retval=0 +else + $as_echo "$as_me: failed program was:" >&5 +sed 's/^/| /' conftest.$ac_ext >&5 + + ac_retval=1 +fi + # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information + # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would + # interfere with the next link command; also delete a directory that is + # left behind by Apple's compiler. We do this before executing the actions. + rm -rf conftest.dSYM conftest_ipa8_conftest.oo + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + as_fn_set_status $ac_retval + +} # ac_fn_c_try_link + +# ac_fn_c_check_type LINENO TYPE VAR INCLUDES +# ------------------------------------------- +# Tests whether TYPE exists after having included INCLUDES, setting cache +# variable VAR accordingly. +ac_fn_c_check_type () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval "$3=no" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof ($2)) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +if (sizeof (($2))) + return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + +else + eval "$3=yes" +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 +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_type + +# ac_fn_c_check_func LINENO FUNC VAR +# ---------------------------------- +# Tests whether FUNC exists, setting the cache variable VAR accordingly +ac_fn_c_check_func () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 +$as_echo_n "checking for $2... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +/* Define $2 to an innocuous variant, in case declares $2. + For example, HP-UX 11i declares gettimeofday. */ +#define $2 innocuous_$2 + +/* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $2 (); below. + Prefer to if __STDC__ is defined, since + exists even on freestanding compilers. */ + +#ifdef __STDC__ +# include +#else +# include +#endif + +#undef $2 + +/* 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 $2 (); +/* 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_$2 || defined __stub___$2 +choke me +#endif + +int +main () +{ +return $2 (); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_func + +# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES +# -------------------------------------------- +# Tries to find the compile-time value of EXPR in a program that includes +# INCLUDES, setting VAR accordingly. Returns whether the value could be +# computed +ac_fn_c_compute_int () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + if test "$cross_compiling" = yes; then + # Depending upon the size, compute the lo and hi bounds. +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) >= 0)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_lo=0 ac_mid=0 + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) <= $ac_mid)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=$ac_mid; break +else + as_fn_arith $ac_mid + 1 && ac_lo=$as_val + if test $ac_lo -le $ac_mid; then + ac_lo= ac_hi= + break + fi + as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) < 0)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=-1 ac_mid=-1 + while :; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) >= $ac_mid)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_lo=$ac_mid; break +else + as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val + if test $ac_mid -le $ac_hi; then + ac_lo= ac_hi= + break + fi + as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + done +else + ac_lo= ac_hi= +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +# Binary search between lo and hi bounds. +while test "x$ac_lo" != "x$ac_hi"; do + as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +static int test_array [1 - 2 * !(($2) <= $ac_mid)]; +test_array [0] = 0 + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_hi=$ac_mid +else + as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +done +case $ac_lo in #(( +?*) eval "$3=\$ac_lo"; ac_retval=0 ;; +'') ac_retval=1 ;; +esac + else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +static long int longval () { return $2; } +static unsigned long int ulongval () { return $2; } +#include +#include +int +main () +{ + + FILE *f = fopen ("conftest.val", "w"); + if (! f) + return 1; + if (($2) < 0) + { + long int i = longval (); + if (i != ($2)) + return 1; + fprintf (f, "%ld", i); + } + else + { + unsigned long int i = ulongval (); + if (i != ($2)) + return 1; + fprintf (f, "%lu", i); + } + /* Do not output a trailing newline, as this causes \r\n confusion + on some platforms. */ + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + echo >>conftest.val; read $3 &5 +$as_echo_n "checking whether $as_decl_name is declared... " >&6; } +if eval \${$3+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$4 +int +main () +{ +#ifndef $as_decl_name +#ifdef __cplusplus + (void) $as_decl_use; +#else + (void) $as_decl_name; +#endif +#endif + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$3=yes" +else + eval "$3=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$3 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_decl + +# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES +# ---------------------------------------------------- +# Tries to find if the field MEMBER exists in type AGGR, after including +# INCLUDES, setting cache variable VAR accordingly. +ac_fn_c_check_member () +{ + as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 +$as_echo_n "checking for $2.$3... " >&6; } +if eval \${$4+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$5 +int +main () +{ +static $2 ac_aggr; +if (ac_aggr.$3) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$4=yes" +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$5 +int +main () +{ +static $2 ac_aggr; +if (sizeof ac_aggr.$3) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$4=yes" +else + eval "$4=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$4 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno + +} # ac_fn_c_check_member 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 $as_me, which was -generated by GNU Autoconf 2.63. Invocation command line was +generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ @@ -2704,8 +3227,8 @@ for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - $as_echo "PATH: $as_dir" -done + $as_echo "PATH: $as_dir" + done IFS=$as_save_IFS } >&5 @@ -2742,9 +3265,9 @@ do ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in - 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; + 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) - ac_configure_args1="$ac_configure_args1 '$ac_arg'" + as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else @@ -2760,13 +3283,13 @@ do -* ) ac_must_keep_next=true ;; esac fi - ac_configure_args="$ac_configure_args '$ac_arg'" + as_fn_append 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; } +{ ac_configure_args0=; unset ac_configure_args0;} +{ ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there @@ -2778,11 +3301,9 @@ trap 'exit_status=$? { echo - cat <<\_ASBOX -## ---------------- ## + $as_echo "## ---------------- ## ## Cache variables. ## -## ---------------- ## -_ASBOX +## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( @@ -2791,13 +3312,13 @@ _ASBOX 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 + *_cv_*) { $as_echo "$as_me:${as_lineno-$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 ;; + *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done @@ -2816,11 +3337,9 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; ) echo - cat <<\_ASBOX -## ----------------- ## + $as_echo "## ----------------- ## ## Output variables. ## -## ----------------- ## -_ASBOX +## ----------------- ##" echo for ac_var in $ac_subst_vars do @@ -2833,11 +3352,9 @@ _ASBOX echo if test -n "$ac_subst_files"; then - cat <<\_ASBOX -## ------------------- ## + $as_echo "## ------------------- ## ## File substitutions. ## -## ------------------- ## -_ASBOX +## ------------------- ##" echo for ac_var in $ac_subst_files do @@ -2851,11 +3368,9 @@ _ASBOX fi if test -s confdefs.h; then - cat <<\_ASBOX -## ----------- ## + $as_echo "## ----------- ## ## confdefs.h. ## -## ----------- ## -_ASBOX +## ----------- ##" echo cat confdefs.h echo @@ -2869,46 +3384,53 @@ _ASBOX exit $exit_status ' 0 for ac_signal in 1 2 13 15; do - trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal + trap 'ac_signal='$ac_signal'; as_fn_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 +$as_echo "/* confdefs.h */" > 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 +cat >>confdefs.h <<_ACEOF +#define PACKAGE_URL "$PACKAGE_URL" +_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 + # We do not want a PATH search for config.site. + case $CONFIG_SITE in #(( + -*) ac_site_file1=./$CONFIG_SITE;; + */*) ac_site_file1=$CONFIG_SITE;; + *) ac_site_file1=./$CONFIG_SITE;; + esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site @@ -2919,19 +3441,23 @@ 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 + if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then + { $as_echo "$as_me:${as_lineno-$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" + . "$ac_site_file" \ + || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "failed to load site script $ac_site_file +See \`config.log' for more details" "$LINENO" 5; } 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 + # Some versions of bash will fail to source /dev/null (special files + # actually), so we avoid doing that. DJGPP emulates it as a regular file. + if test /dev/null != "$cache_file" && test -f "$cache_file"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; @@ -2939,7 +3465,7 @@ $as_echo "$as_me: loading cache $cache_file" >&6;} esac fi else - { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi @@ -2995,11 +3521,11 @@ for ac_var in $ac_precious_vars; do 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:${as_lineno-$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:${as_lineno-$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=: ;; ,);; @@ -3009,17 +3535,17 @@ $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 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:${as_lineno-$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:${as_lineno-$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:${as_lineno-$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:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac @@ -3031,35 +3557,20 @@ $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. - *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; + *) as_fn_append 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:${as_lineno-$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:${as_lineno-$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; }; } + as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi - - - - - - - - - - - - - - - - +## -------------------- ## +## Main body of script. ## +## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' @@ -3086,9 +3597,7 @@ for ac_dir in config "$srcdir"/config; do fi done if test -z "$ac_aux_dir"; then - { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5 -$as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "cannot find install-sh, install.sh, or shtool in config \"$srcdir\"/config" "$LINENO" 5 fi # These three variables are undocumented and unsupported, @@ -3103,35 +3612,27 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # 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_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 -{ $as_echo "$as_me:$LINENO: checking build system type" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } -if test "${ac_cv_build+set}" = set; then +if ${ac_cv_build+:} false; 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; }; } + as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 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; }; } + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5 +{ $as_echo "$as_me:${as_lineno-$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; }; };; +*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' @@ -3147,28 +3648,24 @@ 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 "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } -if test "${ac_cv_host+set}" = set; then +if ${ac_cv_host+:} false; 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; }; } + as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5 +{ $as_echo "$as_me:${as_lineno-$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; }; };; +*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' @@ -3203,9 +3700,9 @@ PACKAGE=amanda # Extract the first word of "grep", so it can be a program name with args. set dummy grep; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then +if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else case $GREP in @@ -3218,14 +3715,14 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GREP="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS test -z "$ac_cv_path_GREP" && ac_cv_path_GREP="grep" @@ -3234,10 +3731,10 @@ esac fi GREP=$ac_cv_path_GREP if test -n "$GREP"; then - { $as_echo "$as_me:$LINENO: result: $GREP" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 $as_echo "$GREP" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -3255,9 +3752,9 @@ _ACEOF # Extract the first word of "svn", so it can be a program name with args. set dummy svn; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_SVN+set}" = set; then +if ${ac_cv_path_SVN+:} false; then : $as_echo_n "(cached) " >&6 else case $SVN in @@ -3270,14 +3767,14 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_SVN="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; @@ -3285,15 +3782,15 @@ esac fi SVN=$ac_cv_path_SVN if test -n "$SVN"; then - { $as_echo "$as_me:$LINENO: result: $SVN" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SVN" >&5 $as_echo "$SVN" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - { $as_echo "$as_me:$LINENO: checking Subversion revision information" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking Subversion revision information" >&5 $as_echo_n "checking Subversion revision information... " >&6; } if test -d $srcdir/.svn -a -n "$SVN" && (cd $srcdir > /dev/null ; $SVN info . ) > conftemp.svn; then SVN_REV=`$GREP Revision: conftemp.svn|cut -d: -f 2|cut -c2-` @@ -3306,17 +3803,17 @@ $as_echo_n "checking Subversion revision information... " >&6; } echo '#define BUILT_BRANCH "'$SVN_BRANCH'"' ) > common-src/svn-info.h - { $as_echo "$as_me:$LINENO: result: updated" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: updated" >&5 $as_echo "updated" >&6; } else # Makefiles will be upset if the file doesn't exist, so double-check if test -f common-src/svn-info.h; then : # all good - { $as_echo "$as_me:$LINENO: result: not changed" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: not changed" >&5 $as_echo "not changed" >&6; } else echo '/* no information available */' > common-src/svn-info.h - { $as_echo "$as_me:$LINENO: result: not available" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: not available" >&5 $as_echo "not available" >&6; } fi fi @@ -3329,9 +3826,9 @@ $as_echo "not available" >&6; } # Extract the first word of "git", so it can be a program name with args. set dummy git; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GIT+set}" = set; then +if ${ac_cv_path_GIT+:} false; then : $as_echo_n "(cached) " >&6 else case $GIT in @@ -3344,14 +3841,14 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GIT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; @@ -3359,27 +3856,27 @@ esac fi GIT=$ac_cv_path_GIT if test -n "$GIT"; then - { $as_echo "$as_me:$LINENO: result: $GIT" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GIT" >&5 $as_echo "$GIT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - { $as_echo "$as_me:$LINENO: checking git revision information" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking git revision information" >&5 $as_echo_n "checking git revision information... " >&6; } if test -d $srcdir/.git -a -n "$GIT"; then GIT_SHA1=`(cd $srcdir > /dev/null ; $GIT rev-parse HEAD | cut -c -8 )` if test -n "$GIT_SHA1"; then - { $as_echo "$as_me:$LINENO: result: $GIT_SHA1" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GIT_SHA1" >&5 $as_echo "$GIT_SHA1" >&6; } else - { $as_echo "$as_me:$LINENO: result: 'git rev-parse HEAD' failed" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: 'git rev-parse HEAD' failed" >&5 $as_echo "'git rev-parse HEAD' failed" >&6; } fi else - { $as_echo "$as_me:$LINENO: result: not available" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: not available" >&5 $as_echo "not available" >&6; } fi @@ -3394,7 +3891,7 @@ $as_echo "not available" >&6; } VERSION=`cat $srcdir/VERSION` fi fi - { $as_echo "$as_me:$LINENO: \"version: $VERSION\"" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: \"version: $VERSION\"" >&5 $as_echo "$as_me: \"version: $VERSION\"" >&6;} am__api_version='1.11' @@ -3413,10 +3910,10 @@ am__api_version='1.11' # 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 "$as_me:${as_lineno-$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 +if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -3424,11 +3921,11 @@ 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/* | \ + # 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\\/* | \ + ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. @@ -3465,7 +3962,7 @@ case $as_dir/ in ;; esac -done + done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir @@ -3481,7 +3978,7 @@ fi INSTALL=$ac_install_sh fi fi -{ $as_echo "$as_me:$LINENO: result: $INSTALL" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. @@ -3492,7 +3989,7 @@ 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 "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # Just in case sleep 1 @@ -3503,15 +4000,11 @@ 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; }; };; + as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; 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; }; };; + as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; esac # Do `set' in a subshell so we don't clobber the current shell's @@ -3533,11 +4026,8 @@ if ( # 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; }; } + as_fn_error $? "ls -t appears to fail. Make sure there is not a broken +alias in your environment" "$LINENO" 5 fi test "$2" = conftest.file @@ -3546,13 +4036,10 @@ 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; }; } + as_fn_error $? "newly created file is older than distributed files! +Check your system clock" "$LINENO" 5 fi -{ $as_echo "$as_me:$LINENO: result: yes" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" @@ -3580,7 +4067,7 @@ 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:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi @@ -3601,9 +4088,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_STRIP+set}" = set; then +if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then @@ -3614,24 +4101,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -3641,9 +4128,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then +if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then @@ -3654,24 +4141,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -3680,7 +4167,7 @@ fi 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:${as_lineno-$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 @@ -3693,10 +4180,10 @@ fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" -{ $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5 +{ $as_echo "$as_me:${as_lineno-$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 + if ${ac_cv_path_mkdir+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -3704,7 +4191,7 @@ 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_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 #( @@ -3716,11 +4203,12 @@ do esac done done -done + done IFS=$as_save_IFS fi + test -d ./--version && rmdir ./--version if test "${ac_cv_path_mkdir+set}" = set; then MKDIR_P="$ac_cv_path_mkdir -p" else @@ -3728,11 +4216,10 @@ fi # 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 "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } @@ -3746,9 +4233,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AWK+set}" = set; then +if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then @@ -3759,24 +4246,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -3784,11 +4271,11 @@ fi test -n "$AWK" && break done -{ $as_echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 +{ $as_echo "$as_me:${as_lineno-$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 +if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF @@ -3796,7 +4283,7 @@ SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF -# GNU make sometimes prints "make[1]: Entering...", which would confuse us. +# 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;; @@ -3806,11 +4293,11 @@ 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 "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi @@ -3830,9 +4317,7 @@ if test "`cd $srcdir && pwd`" != "`pwd`"; then 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; }; } + as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi fi @@ -3978,9 +4463,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -3991,24 +4476,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -4018,9 +4503,9 @@ 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 "$as_me:${as_lineno-$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 +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -4031,24 +4516,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -4057,7 +4542,7 @@ fi 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:${as_lineno-$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 @@ -4071,9 +4556,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -4084,24 +4569,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -4111,9 +4596,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -4125,18 +4610,18 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then @@ -4155,10 +4640,10 @@ fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then - { $as_echo "$as_me:$LINENO: result: $CC" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -4170,9 +4655,9 @@ if test -z "$CC"; then 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -4183,24 +4668,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -4214,9 +4699,9 @@ if test -z "$CC"; then 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 "$as_me:${as_lineno-$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 +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -4227,24 +4712,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -4257,7 +4742,7 @@ done 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:${as_lineno-$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 @@ -4268,57 +4753,37 @@ fi fi -test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 +test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$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; }; }; } +as_fn_error $? "no acceptable C compiler found in \$PATH +See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. -$as_echo "$as_me:$LINENO: checking for C compiler version" >&5 +$as_echo "$as_me:${as_lineno-$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" +for ac_option in --version -v -V -qversion; do + { { ac_try="$ac_compiler $ac_option >&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 +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_compiler $ac_option >&5") 2>conftest.err 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); } + if test -s conftest.err; then + sed '10a\ +... rest of stderr output deleted ... + 10q' conftest.err >conftest.er1 + cat conftest.er1 >&5 + fi + rm -f conftest.er1 conftest.err + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +done -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -4334,8 +4799,8 @@ 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; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 +$as_echo_n "checking whether the C compiler works... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: @@ -4351,17 +4816,17 @@ do done rm -f $ac_rmfiles -if { (ac_try="$ac_link_default" +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_try_echo="\"\$as_me:${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; 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, @@ -4378,7 +4843,7 @@ do # certainly right. break;; *.* ) - if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; + if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi @@ -4397,84 +4862,41 @@ 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 +if test -z "$ac_file"; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +$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:${as_lineno-$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; }; }; } +as_fn_error 77 "C compiler cannot create executables +See \`config.log' for more details" "$LINENO" 5; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } fi - +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 +$as_echo_n "checking for C compiler default output file name... " >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 +$as_echo "$ac_file" >&6; } 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 "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } -if { (ac_try="$ac_link" +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_try_echo="\"\$as_me:${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; 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 @@ -4489,32 +4911,83 @@ for ac_file in conftest.exe conftest conftest.*; do esac done else - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 + { { $as_echo "$as_me:${as_lineno-$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; }; }; } +as_fn_error $? "cannot compute suffix of executables: cannot compile and link +See \`config.log' for more details" "$LINENO" 5; } fi - -rm -f conftest$ac_cv_exeext -{ $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 +rm -f conftest conftest$ac_cv_exeext +{ $as_echo "$as_me:${as_lineno-$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 +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +FILE *f = fopen ("conftest.out", "w"); + return ferror (f) || fclose (f) != 0; + + ; + return 0; +} +_ACEOF +ac_clean_files="$ac_clean_files conftest.out" +# Check that the compiler produces executables we can run. If not, either +# the compiler is broken, or we cross compile. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 +$as_echo_n "checking whether we are cross compiling... " >&6; } +if test "$cross_compiling" != yes; then + { { 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:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_link") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if { ac_try='./conftest$ac_cv_exeext' + { { case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$ac_try") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + cross_compiling=no + else + if test "$cross_compiling" = maybe; then + cross_compiling=yes + else + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error $? "cannot run C compiled programs. +If you meant to cross compile, use \`--host'. +See \`config.log' for more details" "$LINENO" 5; } + fi + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 +$as_echo "$cross_compiling" >&6; } + +rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out +ac_clean_files=$ac_clean_files_save +{ $as_echo "$as_me:${as_lineno-$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 +if ${ac_cv_objext+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -4526,17 +4999,17 @@ main () } _ACEOF rm -f conftest.o conftest.obj -if { (ac_try="$ac_compile" +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_try_echo="\"\$as_me:${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in @@ -4549,31 +5022,23 @@ 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:${as_lineno-$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; }; }; } +as_fn_error $? "cannot compute suffix of object files: cannot compile +See \`config.log' for more details" "$LINENO" 5; } fi - rm -f conftest.$ac_cv_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 +{ $as_echo "$as_me:${as_lineno-$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 "$as_me:${as_lineno-$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 +if ${ac_cv_c_compiler_gnu+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -4587,37 +5052,16 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_compiler_gnu=no + 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 "$as_me:${as_lineno-$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 @@ -4626,20 +5070,16 @@ else fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS -{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 +{ $as_echo "$as_me:${as_lineno-$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 +if ${ac_cv_prog_cc_g+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -4650,35 +5090,11 @@ 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 +if ac_fn_c_try_compile "$LINENO"; 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 + CFLAGS="" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -4689,36 +5105,12 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : - ac_c_werror_flag=$ac_save_c_werror_flag +else + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -4729,42 +5121,17 @@ 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 +if ac_fn_c_try_compile "$LINENO"; 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 "$as_me:${as_lineno-$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 @@ -4781,18 +5148,14 @@ else CFLAGS= fi fi -{ $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 +{ $as_echo "$as_me:${as_lineno-$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 +if ${ac_cv_prog_cc_c89+:} false; 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 +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -4849,32 +5212,9 @@ 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 + if ac_fn_c_try_compile "$LINENO"; 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 @@ -4885,17 +5225,19 @@ fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) - { $as_echo "$as_me:$LINENO: result: none needed" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) - { $as_echo "$as_me:$LINENO: result: unsupported" >&5 + { $as_echo "$as_me:${as_lineno-$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 "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac +if test "x$ac_cv_prog_cc_c89" != xno; then : +fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' @@ -4914,7 +5256,7 @@ am__doit: .PHONY: am__doit END # If we don't find an include directive, just comment out the code. -{ $as_echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 $as_echo_n "checking for style of include used by $am_make... " >&6; } am__include="#" am__quote= @@ -4942,12 +5284,12 @@ if test "$am__include" = "#"; then fi -{ $as_echo "$as_me:$LINENO: result: $_am_result" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 $as_echo "$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. -if test "${enable_dependency_tracking+set}" = set; then +if test "${enable_dependency_tracking+set}" = set; then : enableval=$enable_dependency_tracking; fi @@ -4967,9 +5309,9 @@ fi depcc="$CC" am_compiler_list= -{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } -if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then +if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then @@ -5077,7 +5419,7 @@ else fi fi -{ $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type @@ -5095,9 +5437,9 @@ 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 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_RANLIB+set}" = set; then +if ${ac_cv_prog_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$RANLIB"; then @@ -5108,24 +5450,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 $as_echo "$RANLIB" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -5135,9 +5477,9 @@ 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 "$as_me:${as_lineno-$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 +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_RANLIB"; then @@ -5148,24 +5490,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 $as_echo "$ac_ct_RANLIB" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -5174,7 +5516,7 @@ fi 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:${as_lineno-$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 @@ -5185,22 +5527,18 @@ else fi if test "x$CC" != xcc; then - { $as_echo "$as_me:$LINENO: checking whether $CC and cc understand -c and -o together" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; } else - { $as_echo "$as_me:$LINENO: checking whether cc understands -c and -o together" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5 $as_echo_n "checking whether cc understands -c and -o together... " >&6; } fi set dummy $CC; ac_cc=`$as_echo "$2" | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` -if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -5216,63 +5554,63 @@ _ACEOF # existing .o file with -o, though they will create one. ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' rm -f conftest2.* -if { (case "(($ac_try" in +if { { 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_echo="\"\$as_me:${as_lineno-$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); } && - test -f conftest2.$ac_objext && { (case "(($ac_try" in + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && + test -f conftest2.$ac_objext && { { 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_echo="\"\$as_me:${as_lineno-$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); }; + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then eval ac_cv_prog_cc_${ac_cc}_c_o=yes if test "x$CC" != xcc; then # Test first that cc exists at all. if { ac_try='cc -c conftest.$ac_ext >&5' - { (case "(($ac_try" in + { { 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_echo="\"\$as_me:${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5' rm -f conftest2.* - if { (case "(($ac_try" in + if { { 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_echo="\"\$as_me:${as_lineno-$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); } && - test -f conftest2.$ac_objext && { (case "(($ac_try" in + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && + test -f conftest2.$ac_objext && { { 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_echo="\"\$as_me:${as_lineno-$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); }; + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then # cc works too. : @@ -5289,15 +5627,13 @@ rm -f core conftest* fi if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } -cat >>confdefs.h <<\_ACEOF -#define NO_MINUS_C_MINUS_O 1 -_ACEOF +$as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h fi @@ -5322,14 +5658,14 @@ 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 "$as_me:${as_lineno-$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 + if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded @@ -5344,11 +5680,7 @@ do # 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include @@ -5357,78 +5689,34 @@ cat >>conftest.$ac_ext <<_ACEOF #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 +if ac_fn_c_try_cpp "$LINENO"; then : +else # Broken: fails on valid input. continue fi - -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* 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 +if ac_fn_c_try_cpp "$LINENO"; 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 +rm -f conftest.err conftest.i 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 +rm -f conftest.i conftest.err conftest.$ac_ext +if $ac_preproc_ok; then : break fi @@ -5440,7 +5728,7 @@ fi else ac_cv_prog_CPP=$CPP fi -{ $as_echo "$as_me:$LINENO: result: $CPP" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes @@ -5451,11 +5739,7 @@ do # 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include @@ -5464,87 +5748,40 @@ cat >>conftest.$ac_ext <<_ACEOF #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 +if ac_fn_c_try_cpp "$LINENO"; then : +else # Broken: fails on valid input. continue fi - -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* 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 +if ac_fn_c_try_cpp "$LINENO"; 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 +rm -f conftest.err conftest.i 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 - : +rm -f conftest.i 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:${as_lineno-$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; }; }; } +as_fn_error $? "C preprocessor \"$CPP\" fails sanity check +See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c @@ -5554,9 +5791,9 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $ ac_compiler_gnu=$ac_cv_c_compiler_gnu -{ $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then +if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then @@ -5567,7 +5804,7 @@ 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_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 @@ -5587,7 +5824,7 @@ case `"$ac_path_GREP" --version 2>&1` in $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` + as_fn_arith $ac_count + 1 && ac_count=$as_val 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" @@ -5602,26 +5839,24 @@ esac $ac_path_GREP_found && break 3 done 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; }; } + as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 +{ $as_echo "$as_me:${as_lineno-$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 "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then +if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 @@ -5635,7 +5870,7 @@ 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_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 @@ -5655,7 +5890,7 @@ case `"$ac_path_EGREP" --version 2>&1` in $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` + as_fn_arith $ac_count + 1 && ac_count=$as_val 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" @@ -5670,12 +5905,10 @@ esac $ac_path_EGREP_found && break 3 done 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; }; } + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP @@ -5683,21 +5916,17 @@ fi fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" -{ $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5 +{ $as_echo "$as_me:${as_lineno-$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 +if ${ac_cv_header_stdc+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -5712,48 +5941,23 @@ 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 +if ac_fn_c_try_compile "$LINENO"; 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 + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "memchr" >/dev/null 2>&1; then - : + $EGREP "memchr" >/dev/null 2>&1; then : + else ac_cv_header_stdc=no fi @@ -5763,18 +5967,14 @@ 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "free" >/dev/null 2>&1; then - : + $EGREP "free" >/dev/null 2>&1; then : + else ac_cv_header_stdc=no fi @@ -5784,14 +5984,10 @@ 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 + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -5818,118 +6014,33 @@ main () 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 +if ac_fn_c_try_run "$LINENO"; then : -( exit $ac_status ) -ac_cv_header_stdc=no +else + 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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 +{ $as_echo "$as_me:${as_lineno-$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 +$as_echo "#define STDC_HEADERS 1" >>confdefs.h 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 +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -5942,134 +6053,8 @@ done - if test "${ac_cv_header_minix_config_h+set}" = set; then - { $as_echo "$as_me:$LINENO: checking for minix/config.h" >&5 -$as_echo_n "checking for minix/config.h... " >&6; } -if test "${ac_cv_header_minix_config_h+set}" = set; then - $as_echo_n "(cached) " >&6 -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5 -$as_echo "$ac_cv_header_minix_config_h" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking minix/config.h usability" >&5 -$as_echo_n "checking minix/config.h 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 -_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 minix/config.h presence" >&5 -$as_echo_n "checking minix/config.h 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 -_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: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: minix/config.h: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: minix/config.h: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: minix/config.h: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: minix/config.h: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: minix/config.h: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: minix/config.h: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: minix/config.h: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: minix/config.h: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: minix/config.h: in the future, the compiler will take precedence" >&2;} - - ;; -esac -{ $as_echo "$as_me:$LINENO: checking for minix/config.h" >&5 -$as_echo_n "checking for minix/config.h... " >&6; } -if test "${ac_cv_header_minix_config_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_header_minix_config_h=$ac_header_preproc -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_minix_config_h" >&5 -$as_echo "$ac_cv_header_minix_config_h" >&6; } - -fi -if test "x$ac_cv_header_minix_config_h" = x""yes; then + ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" +if test "x$ac_cv_header_minix_config_h" = xyes; then : MINIX=yes else MINIX= @@ -6078,44 +6063,31 @@ fi if test "$MINIX" = yes; then -cat >>confdefs.h <<\_ACEOF -#define _POSIX_SOURCE 1 -_ACEOF +$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define _POSIX_1_SOURCE 2 -_ACEOF +$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define _MINIX 1 -_ACEOF +$as_echo "#define _MINIX 1" >>confdefs.h fi case "$host_os" in hpux*) -cat >>confdefs.h <<\_ACEOF -#define _XOPEN_SOURCE 500 -_ACEOF +$as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h ;; esac - - { $as_echo "$as_me:$LINENO: checking whether it is safe to define __EXTENSIONS__" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } -if test "${ac_cv_safe_to_define___extensions__+set}" = set; then +if ${ac_cv_safe_to_define___extensions__+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ # define __EXTENSIONS__ 1 @@ -6128,57 +6100,25 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_safe_to_define___extensions__=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_safe_to_define___extensions__=no + ac_cv_safe_to_define___extensions__=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_safe_to_define___extensions__" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } test $ac_cv_safe_to_define___extensions__ = yes && - cat >>confdefs.h <<\_ACEOF -#define __EXTENSIONS__ 1 -_ACEOF - - cat >>confdefs.h <<\_ACEOF -#define _ALL_SOURCE 1 -_ACEOF + $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h - cat >>confdefs.h <<\_ACEOF -#define _GNU_SOURCE 1 -_ACEOF + $as_echo "#define _ALL_SOURCE 1" >>confdefs.h - cat >>confdefs.h <<\_ACEOF -#define _POSIX_PTHREAD_SEMANTICS 1 -_ACEOF + $as_echo "#define _GNU_SOURCE 1" >>confdefs.h - cat >>confdefs.h <<\_ACEOF -#define _TANDEM_SOURCE 1 -_ACEOF + $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h + $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h @@ -6187,17 +6127,13 @@ _ACEOF -{ $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; } -if test "${ac_cv_sys_largefile_source+set}" = set; then +if ${ac_cv_sys_largefile_source+:} false; then : $as_echo_n "(cached) " >&6 else while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* for off_t */ #include @@ -6210,43 +6146,12 @@ int (*fp) (FILE *, off_t, int) = fseeko; 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_sys_largefile_source=no; break -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 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _LARGEFILE_SOURCE 1 #include /* for off_t */ @@ -6260,43 +6165,16 @@ int (*fp) (FILE *, off_t, int) = fseeko; 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_sys_largefile_source=1; break -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext ac_cv_sys_largefile_source=unknown break done fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5 $as_echo "$ac_cv_sys_largefile_source" >&6; } case $ac_cv_sys_largefile_source in #( no | unknown) ;; @@ -6313,9 +6191,7 @@ rm -rf conftest* # If you want fseeko and ftello with glibc, upgrade to a fixed glibc. if test $ac_cv_sys_largefile_source != unknown; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_FSEEKO 1 -_ACEOF +$as_echo "#define HAVE_FSEEKO 1" >>confdefs.h fi @@ -6325,7 +6201,7 @@ fi # Check whether --enable-threads was given. -if test "${enable_threads+set}" = set; then +if test "${enable_threads+set}" = set; then : enableval=$enable_threads; gl_use_threads=$enableval else if test -n "$gl_use_threads_default"; then @@ -6457,23 +6333,28 @@ fi - - LIBC_FATAL_STDERR_=1 export LIBC_FATAL_STDERR_ +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define size_t unsigned int +_ACEOF + +fi + # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! -{ $as_echo "$as_me:$LINENO: checking for working alloca.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 $as_echo_n "checking for working alloca.h... " >&6; } -if test "${ac_cv_working_alloca_h+set}" = set; then +if ${ac_cv_working_alloca_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -6485,59 +6366,28 @@ char *p = (char *) alloca (2 * sizeof (int)); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_working_alloca_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_working_alloca_h=no + ac_cv_working_alloca_h=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 $as_echo "$ac_cv_working_alloca_h" >&6; } if test $ac_cv_working_alloca_h = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_ALLOCA_H 1 -_ACEOF +$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h fi -{ $as_echo "$as_me:$LINENO: checking for alloca" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 $as_echo_n "checking for alloca... " >&6; } -if test "${ac_cv_func_alloca_works+set}" = set; then +if ${ac_cv_func_alloca_works+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __GNUC__ # define alloca __builtin_alloca @@ -6553,7 +6403,7 @@ cat >>conftest.$ac_ext <<_ACEOF #pragma alloca # else # ifndef alloca /* predefined by HP cc +Olibcalls */ -char *alloca (); +void *alloca (size_t); # endif # endif # endif @@ -6569,47 +6419,20 @@ char *p = (char *) alloca (1); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_func_alloca_works=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_alloca_works=no + ac_cv_func_alloca_works=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 $as_echo "$ac_cv_func_alloca_works" >&6; } if test $ac_cv_func_alloca_works = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_ALLOCA 1 -_ACEOF +$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h else # The SVR3 libPW and SVR4 libucb both contain incompatible functions @@ -6623,21 +6446,15 @@ else ALLOCA=\${LIBOBJDIR}alloca.$ac_objext -cat >>confdefs.h <<\_ACEOF -#define C_ALLOCA 1 -_ACEOF +$as_echo "#define C_ALLOCA 1" >>confdefs.h -{ $as_echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } -if test "${ac_cv_os_cray+set}" = set; then +if ${ac_cv_os_cray+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined CRAY && ! defined CRAY2 webecray @@ -6647,7 +6464,7 @@ wenotbecray _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "webecray" >/dev/null 2>&1; then + $EGREP "webecray" >/dev/null 2>&1; then : ac_cv_os_cray=yes else ac_cv_os_cray=no @@ -6655,101 +6472,13 @@ fi rm -f conftest* fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 $as_echo "$ac_cv_os_cray" >&6; } if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define CRAY_STACKSEG_END $ac_func @@ -6761,19 +6490,15 @@ fi done fi -{ $as_echo "$as_me:$LINENO: checking stack direction for C alloca" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 $as_echo_n "checking stack direction for C alloca... " >&6; } -if test "${ac_cv_c_stack_direction+set}" = set; then +if ${ac_cv_c_stack_direction+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : ac_cv_c_stack_direction=0 else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int @@ -6796,46 +6521,18 @@ main () return find_stack_direction () < 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 +if ac_fn_c_try_run "$LINENO"; then : ac_cv_c_stack_direction=1 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_c_stack_direction=-1 + ac_cv_c_stack_direction=-1 fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 $as_echo "$ac_cv_c_stack_direction" >&6; } - cat >>confdefs.h <<_ACEOF #define STACK_DIRECTION $ac_cv_c_stack_direction _ACEOF @@ -6853,144 +6550,11 @@ fi - -for ac_header in $gl_header_list -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;} - - ;; -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 + for ac_header in $gl_header_list +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -7005,10 +6569,9 @@ done - - { $as_echo "$as_me:$LINENO: checking whether the preprocessor supports include_next" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; } -if test "${gl_cv_have_include_next+set}" = set; then +if ${gl_cv_have_include_next+:} false; then : $as_echo_n "(cached) " >&6 else rm -rf conftestd1a conftestd1b conftestd2 @@ -7040,72 +6603,32 @@ EOF EOF gl_save_CPPFLAGS="$CPPFLAGS" CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2" - cat >conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ #include _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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_have_include_next=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2" - cat >conftest.$ac_ext <<_ACEOF + CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ #include _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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_have_include_next=buggy else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_have_include_next=no + gl_cv_have_include_next=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext CPPFLAGS="$gl_save_CPPFLAGS" rm -rf conftestd1a conftestd1b conftestd2 fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_have_include_next" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5 $as_echo "$gl_cv_have_include_next" >&6; } PRAGMA_SYSTEM_HEADER= if test $gl_cv_have_include_next = yes; then @@ -7127,18 +6650,14 @@ $as_echo "$gl_cv_have_include_next" >&6; } -{ $as_echo "$as_me:$LINENO: checking for inline" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 $as_echo_n "checking for inline... " >&6; } -if test "${ac_cv_c_inline+set}" = set; then +if ${ac_cv_c_inline+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; @@ -7147,41 +6666,17 @@ $ac_kw foo_t foo () {return 0; } #endif _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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_inline=$ac_kw -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 test "$ac_cv_c_inline" != no && break done fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 $as_echo "$ac_cv_c_inline" >&6; } - case $ac_cv_c_inline in inline | yes) ;; *) @@ -7197,19 +6692,15 @@ _ACEOF ;; esac -{ $as_echo "$as_me:$LINENO: checking for C/C++ restrict keyword" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5 $as_echo_n "checking for C/C++ restrict keyword... " >&6; } -if test "${ac_cv_c_restrict+set}" = set; then +if ${ac_cv_c_restrict+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_restrict=no # The order here caters to the fact that C++ does not require restrict. for ac_kw in __restrict __restrict__ _Restrict restrict; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ typedef int * int_ptr; int foo (int_ptr $ac_kw ip) { @@ -7226,46 +6717,20 @@ int s[1]; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_c_restrict=$ac_kw -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 test "$ac_cv_c_restrict" != no && break done fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_restrict" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5 $as_echo "$ac_cv_c_restrict" >&6; } - case $ac_cv_c_restrict in restrict) ;; - no) cat >>confdefs.h <<\_ACEOF -#define restrict /**/ -_ACEOF + no) $as_echo "#define restrict /**/" >>confdefs.h ;; *) cat >>confdefs.h <<_ACEOF #define restrict $ac_cv_c_restrict @@ -7310,48 +6775,40 @@ _ACEOF REPLACE_WCWIDTH=0; - { $as_echo "$as_me:$LINENO: checking whether uses 'inline' correctly" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether uses 'inline' correctly" >&5 $as_echo_n "checking whether uses 'inline' correctly... " >&6; } -if test "${gl_cv_header_wchar_h_correct_inline+set}" = set; then +if ${gl_cv_header_wchar_h_correct_inline+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_header_wchar_h_correct_inline=yes - cat >conftest.$ac_ext <<_ACEOF - - /* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#define wcstod renamed_wcstod + + #define wcstod renamed_wcstod #include extern int zero (void); int main () { return zero(); } _ACEOF - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then mv conftest.$ac_objext conftest1.$ac_objext - cat >conftest.$ac_ext <<_ACEOF - - /* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#define wcstod renamed_wcstod + + #define wcstod renamed_wcstod #include int zero (void) { return 0; } _ACEOF - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then mv conftest.$ac_objext conftest2.$ac_objext if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then : @@ -7363,19 +6820,10 @@ _ACEOF rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_wchar_h_correct_inline" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5 $as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; } if test $gl_cv_header_wchar_h_correct_inline = no; then - { { $as_echo "$as_me:$LINENO: error: cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS). -This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in -C99 mode. You have four options: - - Add the flag -fgnu89-inline to CC and reconfigure, or - - Fix your include files, using parts of - , or - - Use a gcc version older than 4.3, or - - Don't use the flags -std=c99 or -std=gnu99. -Configuration aborted." >&5 -$as_echo "$as_me: error: cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS). + as_fn_error $? " cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS). This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in C99 mode. You have four options: - Add the flag -fgnu89-inline to CC and reconfigure, or @@ -7383,108 +6831,18 @@ C99 mode. You have four options: , or - Use a gcc version older than 4.3, or - Don't use the flags -std=c99 or -std=gnu99. -Configuration aborted." >&2;} - { (exit 1); exit 1; }; } +Configuration aborted." "$LINENO" 5 fi - -for ac_func in $gl_func_list -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in $gl_func_list +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF @@ -7497,17 +6855,12 @@ done - - { $as_echo "$as_me:$LINENO: checking for nl_langinfo and CODESET" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } -if test "${am_cv_langinfo_codeset+set}" = set; then +if ${am_cv_langinfo_codeset+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -7518,64 +6871,33 @@ char* cs = nl_langinfo(CODESET); 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 ac_fn_c_try_link "$LINENO"; then : am_cv_langinfo_codeset=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - am_cv_langinfo_codeset=no + am_cv_langinfo_codeset=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $am_cv_langinfo_codeset" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5 $as_echo "$am_cv_langinfo_codeset" >&6; } if test $am_cv_langinfo_codeset = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_LANGINFO_CODESET 1 -_ACEOF +$as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h fi - { $as_echo "$as_me:$LINENO: checking for a traditional french locale" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5 $as_echo_n "checking for a traditional french locale... " >&6; } -if test "${gt_cv_locale_fr+set}" = set; then +if ${gt_cv_locale_fr+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -7622,11 +6944,11 @@ int main () { } _ACEOF - if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest$ac_exeext; then # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because # otherwise on MacOS X 10.3.5 the LC_TIME=C from the beginning of the # configure script would override the LC_ALL setting. Likewise for @@ -7662,7 +6984,7 @@ _ACEOF rm -fr conftest* fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_locale_fr" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5 $as_echo "$gt_cv_locale_fr" >&6; } LOCALE_FR=$gt_cv_locale_fr @@ -7775,17 +7097,13 @@ $as_echo "$gt_cv_locale_fr" >&6; } - { $as_echo "$as_me:$LINENO: checking if environ is properly declared" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5 $as_echo_n "checking if environ is properly declared... " >&6; } - if test "${gt_cv_var_environ_declaration+set}" = set; then + if ${gt_cv_var_environ_declaration+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include extern struct { int foo; } environ; @@ -7797,42 +7115,19 @@ environ.foo = 1; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then +if ac_fn_c_try_compile "$LINENO"; then : gt_cv_var_environ_declaration=no else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_var_environ_declaration=yes + gt_cv_var_environ_declaration=yes fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - { $as_echo "$as_me:$LINENO: result: $gt_cv_var_environ_declaration" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5 $as_echo "$gt_cv_var_environ_declaration" >&6; } if test $gt_cv_var_environ_declaration = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_ENVIRON_DECL 1 -_ACEOF +$as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h fi @@ -7848,18 +7143,13 @@ _ACEOF - - { $as_echo "$as_me:$LINENO: checking for complete errno.h" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5 $as_echo_n "checking for complete errno.h... " >&6; } -if test "${gl_cv_header_errno_h_complete+set}" = set; then +if ${gl_cv_header_errno_h_complete+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -7896,7 +7186,7 @@ booboo _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "booboo" >/dev/null 2>&1; then + $EGREP "booboo" >/dev/null 2>&1; then : gl_cv_header_errno_h_complete=no else gl_cv_header_errno_h_complete=yes @@ -7905,7 +7195,7 @@ rm -f conftest* fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_errno_h_complete" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5 $as_echo "$gl_cv_header_errno_h_complete" >&6; } if test $gl_cv_header_errno_h_complete = yes; then ERRNO_H='' @@ -7925,18 +7215,14 @@ $as_echo "$gl_cv_header_errno_h_complete" >&6; } if test $gl_cv_have_include_next = yes; then gl_cv_next_errno_h='<'errno.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_errno_h+set}" = set; then +if ${gl_cv_next_errno_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_errno_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -7957,7 +7243,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_errno_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5 $as_echo "$gl_cv_next_errno_h" >&6; } fi NEXT_ERRNO_H=$gl_cv_next_errno_h @@ -7978,17 +7264,13 @@ $as_echo "$gl_cv_next_errno_h" >&6; } if test -n "$ERRNO_H"; then - { $as_echo "$as_me:$LINENO: checking for EMULTIHOP value" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5 $as_echo_n "checking for EMULTIHOP value... " >&6; } -if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then +if ${gl_cv_header_errno_h_EMULTIHOP+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -7998,7 +7280,7 @@ yes _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then + $EGREP "yes" >/dev/null 2>&1; then : gl_cv_header_errno_h_EMULTIHOP=yes else gl_cv_header_errno_h_EMULTIHOP=no @@ -8006,11 +7288,7 @@ fi rm -f conftest* if test $gl_cv_header_errno_h_EMULTIHOP = no; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _XOPEN_SOURCE_EXTENDED 1 @@ -8021,370 +7299,27 @@ yes _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then + $EGREP "yes" >/dev/null 2>&1; then : gl_cv_header_errno_h_EMULTIHOP=hidden fi rm -f conftest* if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EMULTIHOP) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EMULTIHOP) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EMULTIHOP) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EMULTIHOP) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" " #define _XOPEN_SOURCE_EXTENDED 1 #include /* The following two lines are a workaround against an autoconf-2.52 bug. */ #include #include +"; then : -int -main () -{ -static int test_array [1 - 2 * !((EMULTIHOP) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) gl_cv_header_errno_h_EMULTIHOP=$ac_lo;; -'') ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -static long int longval () { return EMULTIHOP; } -static unsigned long int ulongval () { return EMULTIHOP; } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if ((EMULTIHOP) < 0) - { - long int i = longval (); - if (i != (EMULTIHOP)) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != (EMULTIHOP)) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - - ; - 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 - gl_cv_header_errno_h_EMULTIHOP=`cat conftest.val` -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 - -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 -rm -f conftest.val fi fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_errno_h_EMULTIHOP" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; } case $gl_cv_header_errno_h_EMULTIHOP in yes | no) @@ -8400,17 +7335,13 @@ $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; } if test -n "$ERRNO_H"; then - { $as_echo "$as_me:$LINENO: checking for ENOLINK value" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5 $as_echo_n "checking for ENOLINK value... " >&6; } -if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then +if ${gl_cv_header_errno_h_ENOLINK+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -8420,7 +7351,7 @@ yes _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then + $EGREP "yes" >/dev/null 2>&1; then : gl_cv_header_errno_h_ENOLINK=yes else gl_cv_header_errno_h_ENOLINK=no @@ -8428,11 +7359,7 @@ fi rm -f conftest* if test $gl_cv_header_errno_h_ENOLINK = no; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _XOPEN_SOURCE_EXTENDED 1 @@ -8443,370 +7370,27 @@ yes _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then + $EGREP "yes" >/dev/null 2>&1; then : gl_cv_header_errno_h_ENOLINK=hidden fi rm -f conftest* if test $gl_cv_header_errno_h_ENOLINK = hidden; then - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((ENOLINK) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((ENOLINK) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((ENOLINK) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((ENOLINK) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" " #define _XOPEN_SOURCE_EXTENDED 1 #include /* The following two lines are a workaround against an autoconf-2.52 bug. */ #include #include +"; then : -int -main () -{ -static int test_array [1 - 2 * !((ENOLINK) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) gl_cv_header_errno_h_ENOLINK=$ac_lo;; -'') ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -static long int longval () { return ENOLINK; } -static unsigned long int ulongval () { return ENOLINK; } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if ((ENOLINK) < 0) - { - long int i = longval (); - if (i != (ENOLINK)) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != (ENOLINK)) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - - ; - 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 - gl_cv_header_errno_h_ENOLINK=`cat conftest.val` -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 - -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 -rm -f conftest.val fi fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_errno_h_ENOLINK" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; } case $gl_cv_header_errno_h_ENOLINK in yes | no) @@ -8822,17 +7406,13 @@ $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; } if test -n "$ERRNO_H"; then - { $as_echo "$as_me:$LINENO: checking for EOVERFLOW value" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5 $as_echo_n "checking for EOVERFLOW value... " >&6; } -if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then +if ${gl_cv_header_errno_h_EOVERFLOW+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -8842,7 +7422,7 @@ yes _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then + $EGREP "yes" >/dev/null 2>&1; then : gl_cv_header_errno_h_EOVERFLOW=yes else gl_cv_header_errno_h_EOVERFLOW=no @@ -8850,11 +7430,7 @@ fi rm -f conftest* if test $gl_cv_header_errno_h_EOVERFLOW = no; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _XOPEN_SOURCE_EXTENDED 1 @@ -8865,370 +7441,27 @@ yes _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "yes" >/dev/null 2>&1; then + $EGREP "yes" >/dev/null 2>&1; then : gl_cv_header_errno_h_EOVERFLOW=hidden fi rm -f conftest* if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" " #define _XOPEN_SOURCE_EXTENDED 1 #include /* The following two lines are a workaround against an autoconf-2.52 bug. */ #include #include +"; then : -int -main () -{ -static int test_array [1 - 2 * !((EOVERFLOW) >= 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +fi -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EOVERFLOW) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EOVERFLOW) < 0)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EOVERFLOW) >= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -int -main () -{ -static int test_array [1 - 2 * !((EOVERFLOW) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) gl_cv_header_errno_h_EOVERFLOW=$ac_lo;; -'') ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#define _XOPEN_SOURCE_EXTENDED 1 -#include -/* The following two lines are a workaround against an autoconf-2.52 bug. */ -#include -#include - -static long int longval () { return EOVERFLOW; } -static unsigned long int ulongval () { return EOVERFLOW; } -#include -#include -int -main () -{ - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if ((EOVERFLOW) < 0) - { - long int i = longval (); - if (i != (EOVERFLOW)) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != (EOVERFLOW)) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - - ; - 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 - gl_cv_header_errno_h_EOVERFLOW=`cat conftest.val` -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 + fi + fi 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 -rm -f conftest.val - fi - fi - -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_errno_h_EOVERFLOW" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; } case $gl_cv_header_errno_h_EOVERFLOW in yes | no) @@ -9249,7 +7482,6 @@ $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; } - GNULIB_DPRINTF=0; GNULIB_FCLOSE=0; GNULIB_FFLUSH=0; @@ -9339,17 +7571,13 @@ $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; } - { $as_echo "$as_me:$LINENO: checking for fseeko" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fseeko" >&5 $as_echo_n "checking for fseeko... " >&6; } -if test "${gl_cv_func_fseeko+set}" = set; then +if ${gl_cv_func_fseeko+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -9361,54 +7589,25 @@ fseeko (stdin, 0, 0); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_func_fseeko=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_fseeko=no + gl_cv_func_fseeko=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_fseeko" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fseeko" >&5 $as_echo "$gl_cv_func_fseeko" >&6; } - { $as_echo "$as_me:$LINENO: checking whether stdin defaults to large file offsets" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdin defaults to large file offsets" >&5 $as_echo_n "checking whether stdin defaults to large file offsets... " >&6; } -if test "${gl_cv_var_stdin_large_offset+set}" = set; then +if ${gl_cv_var_stdin_large_offset+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -9427,40 +7626,15 @@ 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_var_stdin_large_offset=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_var_stdin_large_offset=no + gl_cv_var_stdin_large_offset=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_var_stdin_large_offset" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var_stdin_large_offset" >&5 $as_echo "$gl_cv_var_stdin_large_offset" >&6; } @@ -9479,10 +7653,6 @@ $as_echo "$gl_cv_var_stdin_large_offset" >&6; } - - - - @@ -9516,18 +7686,13 @@ $as_echo "$gl_cv_var_stdin_large_offset" >&6; } - - { $as_echo "$as_me:$LINENO: checking whether is self-contained" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether is self-contained" >&5 $as_echo_n "checking whether is self-contained... " >&6; } -if test "${gl_cv_header_sys_socket_h_selfcontained+set}" = set; then +if ${gl_cv_header_sys_socket_h_selfcontained+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -9538,151 +7703,36 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_header_sys_socket_h_selfcontained=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_header_sys_socket_h_selfcontained=no + gl_cv_header_sys_socket_h_selfcontained=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_sys_socket_h_selfcontained" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_selfcontained" >&5 $as_echo "$gl_cv_header_sys_socket_h_selfcontained" >&6; } if test $gl_cv_header_sys_socket_h_selfcontained = yes; then - -for ac_func in shutdown -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in shutdown +do : + ac_fn_c_check_func "$LINENO" "shutdown" "ac_cv_func_shutdown" +if test "x$ac_cv_func_shutdown" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SHUTDOWN 1 _ACEOF fi done if test $ac_cv_func_shutdown = yes; then - { $as_echo "$as_me:$LINENO: checking whether defines the SHUT_* macros" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether defines the SHUT_* macros" >&5 $as_echo_n "checking whether defines the SHUT_* macros... " >&6; } -if test "${gl_cv_header_sys_socket_h_shut+set}" = set; then +if ${gl_cv_header_sys_socket_h_shut+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -9693,36 +7743,15 @@ int a[] = { SHUT_RD, SHUT_WR, SHUT_RDWR }; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_header_sys_socket_h_shut=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_header_sys_socket_h_shut=no + gl_cv_header_sys_socket_h_shut=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_sys_socket_h_shut" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_shut" >&5 $as_echo "$gl_cv_header_sys_socket_h_shut" >&6; } if test $gl_cv_header_sys_socket_h_shut = no; then SYS_SOCKET_H='sys/socket.h' @@ -9746,18 +7775,14 @@ $as_echo "$gl_cv_header_sys_socket_h_shut" >&6; } if test $gl_cv_have_include_next = yes; then gl_cv_next_sys_socket_h='<'sys/socket.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_sys_socket_h+set}" = set; then +if ${gl_cv_next_sys_socket_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_sys_socket_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -9778,7 +7803,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_sys_socket_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_socket_h" >&5 $as_echo "$gl_cv_next_sys_socket_h" >&6; } fi NEXT_SYS_SOCKET_H=$gl_cv_next_sys_socket_h @@ -9799,146 +7824,12 @@ $as_echo "$gl_cv_next_sys_socket_h" >&6; } HAVE_WS2TCPIP_H=0 else HAVE_SYS_SOCKET_H=0 - -for ac_header in ws2tcpip.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;} - - ;; -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 + for ac_header in ws2tcpip.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default" +if test "x$ac_cv_header_ws2tcpip_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_WS2TCPIP_H 1 _ACEOF fi @@ -9954,19 +7845,7 @@ done - { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5 -$as_echo_n "checking for struct sockaddr_storage... " >&6; } -if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_struct_sockaddr_storage=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" " /* sys/types.h is not needed according to POSIX, but the sys/socket.h in i386-unknown-freebsd4.10 and powerpc-apple-darwin5.5 required it. */ @@ -9978,41 +7857,16 @@ cat >>conftest.$ac_ext <<_ACEOF #include #endif +" +if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then : -int -main () -{ -if (sizeof (struct sockaddr_storage)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_STORAGE 1 _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + +fi +ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" " /* sys/types.h is not needed according to POSIX, but the sys/socket.h in i386-unknown-freebsd4.10 and powerpc-apple-darwin5.5 required it. */ @@ -10024,451 +7878,100 @@ cat >>conftest.$ac_ext <<_ACEOF #include #endif +" +if test "x$ac_cv_type_sa_family_t" = xyes; then : -int -main () -{ -if (sizeof ((struct sockaddr_storage))) - return 0; - ; - return 0; -} +cat >>confdefs.h <<_ACEOF +#define HAVE_SA_FAMILY_T 1 _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_type_struct_sockaddr_storage=yes + fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + if test $ac_cv_type_struct_sockaddr_storage = no; then + HAVE_STRUCT_SOCKADDR_STORAGE=0 + fi + if test $ac_cv_type_sa_family_t = no; then + HAVE_SA_FAMILY_T=0 + fi -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5 -$as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; } -if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_SOCKADDR_STORAGE 1 -_ACEOF + : + + + + if test $ac_cv_header_sys_socket_h != yes; then + for ac_header in winsock2.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default" +if test "x$ac_cv_header_winsock2_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_WINSOCK2_H 1 +_ACEOF + fi -{ $as_echo "$as_me:$LINENO: checking for sa_family_t" >&5 -$as_echo_n "checking for sa_family_t... " >&6; } -if test "${ac_cv_type_sa_family_t+set}" = set; then + +done + + fi + if test "$ac_cv_header_winsock2_h" = yes; then + HAVE_WINSOCK2_H=1 + UNISTD_H_HAVE_WINSOCK2_H=1 + SYS_IOCTL_H_HAVE_WINSOCK2_H=1 + else + HAVE_WINSOCK2_H=0 + fi + + + + + for gl_func in socket connect accept bind getpeername getsockname getsockopt listen recv send recvfrom sendto setsockopt shutdown accept4; do + as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 +$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } +if eval \${$as_gl_Symbol+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_type_sa_family_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - /* sys/types.h is not needed according to POSIX, but the - sys/socket.h in i386-unknown-freebsd4.10 and - powerpc-apple-darwin5.5 required it. */ +/* Some systems require prerequisite headers. */ #include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_WS2TCPIP_H -#include +#if !defined __GLIBC__ && HAVE_SYS_TIME_H +# include #endif - +#include int main () { -if (sizeof (sa_family_t)) - return 0; +#undef $gl_func + (void) $gl_func; ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - /* sys/types.h is not needed according to POSIX, but the - sys/socket.h in i386-unknown-freebsd4.10 and - powerpc-apple-darwin5.5 required it. */ -#include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_WS2TCPIP_H -#include -#endif - - -int -main () -{ -if (sizeof ((sa_family_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_sa_family_t=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_sa_family_t" >&5 -$as_echo "$ac_cv_type_sa_family_t" >&6; } -if test "x$ac_cv_type_sa_family_t" = x""yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_SA_FAMILY_T 1 -_ACEOF - - -fi - - if test $ac_cv_type_struct_sockaddr_storage = no; then - HAVE_STRUCT_SOCKADDR_STORAGE=0 - fi - if test $ac_cv_type_sa_family_t = no; then - HAVE_SA_FAMILY_T=0 - fi - - - - - : - - - - - - if test $ac_cv_header_sys_socket_h != yes; then - -for ac_header in winsock2.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;} - - ;; -esac -{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 -$as_echo_n "checking for $ac_header... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - eval "$as_ac_Header=\$ac_header_preproc" -fi -ac_res=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - -fi -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - fi - if test "$ac_cv_header_winsock2_h" = yes; then - HAVE_WINSOCK2_H=1 - UNISTD_H_HAVE_WINSOCK2_H=1 - SYS_IOCTL_H_HAVE_WINSOCK2_H=1 - else - HAVE_WINSOCK2_H=0 - fi - - - - - - - - - - - - - - - - - - - - for gl_func in socket connect accept bind getpeername getsockname getsockopt listen recv send recvfrom sendto setsockopt shutdown accept4; do - as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 -$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; 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. */ - -/* Some systems require prerequisite headers. */ -#include -#if !defined __GLIBC__ && HAVE_SYS_TIME_H -# include -#endif -#include - -int -main () -{ -#undef $gl_func - (void) $gl_func; - ; - 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done @@ -10488,7 +7991,6 @@ fi - : @@ -10510,18 +8012,14 @@ fi if test $gl_cv_have_include_next = yes; then gl_cv_next_netdb_h='<'netdb.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_netdb_h+set}" = set; then +if ${gl_cv_next_netdb_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_netdb_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -10542,7 +8040,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_netdb_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netdb_h" >&5 $as_echo "$gl_cv_next_netdb_h" >&6; } fi NEXT_NETDB_H=$gl_cv_next_netdb_h @@ -10566,22 +8064,14 @@ $as_echo "$gl_cv_next_netdb_h" >&6; } - - - - - for gl_func in getaddrinfo freeaddrinfo gai_strerror getnameinfo; do + for gl_func in getaddrinfo freeaddrinfo gai_strerror getnameinfo; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -10593,65 +8083,36 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done HOSTENT_LIB= gl_saved_libs="$LIBS" - { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5 $as_echo_n "checking for library containing gethostbyname... " >&6; } -if test "${ac_cv_search_gethostbyname+set}" = set; then +if ${ac_cv_search_gethostbyname+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -10676,54 +8137,27 @@ for ac_lib in '' nsl network net; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_gethostbyname=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_gethostbyname+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_gethostbyname+:} false; then : break fi done -if test "${ac_cv_search_gethostbyname+set}" = set; then - : +if ${ac_cv_search_gethostbyname+:} false; then : + else ac_cv_search_gethostbyname=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5 $as_echo "$ac_cv_search_gethostbyname" >&6; } ac_res=$ac_cv_search_gethostbyname -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" if test "$ac_cv_search_gethostbyname" != "none required"; then HOSTENT_LIB="$ac_cv_search_gethostbyname" @@ -10732,119 +8166,25 @@ fi LIBS="$gl_saved_libs" if test -z "$HOSTENT_LIB"; then - -for ac_func in gethostbyname -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in gethostbyname +do : + ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" +if test "x$ac_cv_func_gethostbyname" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETHOSTBYNAME 1 _ACEOF else - { $as_echo "$as_me:$LINENO: checking for gethostbyname in winsock2.h and -lws2_32" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in winsock2.h and -lws2_32" >&5 $as_echo_n "checking for gethostbyname in winsock2.h and -lws2_32... " >&6; } -if test "${gl_cv_w32_gethostbyname+set}" = set; then +if ${gl_cv_w32_gethostbyname+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_w32_gethostbyname=no gl_save_LIBS="$LIBS" LIBS="$LIBS -lws2_32" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_WINSOCK2_H @@ -10860,42 +8200,15 @@ gethostbyname(NULL); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_w32_gethostbyname=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS="$gl_save_LIBS" fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_w32_gethostbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_gethostbyname" >&5 $as_echo "$gl_cv_w32_gethostbyname" >&6; } if test "$gl_cv_w32_gethostbyname" = "yes"; then HOSTENT_LIB="-lws2_32" @@ -10910,17 +8223,13 @@ done SERVENT_LIB= gl_saved_libs="$LIBS" - { $as_echo "$as_me:$LINENO: checking for library containing getservbyname" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getservbyname" >&5 $as_echo_n "checking for library containing getservbyname... " >&6; } -if test "${ac_cv_search_getservbyname+set}" = set; then +if ${ac_cv_search_getservbyname+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -10945,54 +8254,27 @@ for ac_lib in '' socket network net; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_getservbyname=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_getservbyname+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_getservbyname+:} false; then : break fi done -if test "${ac_cv_search_getservbyname+set}" = set; then - : +if ${ac_cv_search_getservbyname+:} false; then : + else ac_cv_search_getservbyname=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_getservbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getservbyname" >&5 $as_echo "$ac_cv_search_getservbyname" >&6; } ac_res=$ac_cv_search_getservbyname -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" if test "$ac_cv_search_getservbyname" != "none required"; then SERVENT_LIB="$ac_cv_search_getservbyname" @@ -11001,119 +8283,25 @@ fi LIBS="$gl_saved_libs" if test -z "$SERVENT_LIB"; then - -for ac_func in getservbyname -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in getservbyname +do : + ac_fn_c_check_func "$LINENO" "getservbyname" "ac_cv_func_getservbyname" +if test "x$ac_cv_func_getservbyname" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETSERVBYNAME 1 _ACEOF else - { $as_echo "$as_me:$LINENO: checking for getservbyname in winsock2.h and -lws2_32" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getservbyname in winsock2.h and -lws2_32" >&5 $as_echo_n "checking for getservbyname in winsock2.h and -lws2_32... " >&6; } -if test "${gl_cv_w32_getservbyname+set}" = set; then +if ${gl_cv_w32_getservbyname+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_w32_getservbyname=no gl_save_LIBS="$LIBS" LIBS="$LIBS -lws2_32" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_WINSOCK2_H @@ -11129,42 +8317,15 @@ getservbyname(NULL,NULL); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_w32_getservbyname=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS="$gl_save_LIBS" fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_w32_getservbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_getservbyname" >&5 $as_echo "$gl_cv_w32_getservbyname" >&6; } if test "$gl_cv_w32_getservbyname" = "yes"; then SERVENT_LIB="-lws2_32" @@ -11184,7 +8345,6 @@ done - : @@ -11192,16 +8352,12 @@ done - { $as_echo "$as_me:$LINENO: checking for IPv4 sockets" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv4 sockets" >&5 $as_echo_n "checking for IPv4 sockets... " >&6; } - if test "${gl_cv_socket_ipv4+set}" = set; then + if ${gl_cv_socket_ipv4+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #ifdef HAVE_SYS_SOCKET_H @@ -11222,55 +8378,28 @@ int x = AF_INET; struct in_addr y; struct sockaddr_in z; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_socket_ipv4=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_socket_ipv4=no + gl_cv_socket_ipv4=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - { $as_echo "$as_me:$LINENO: result: $gl_cv_socket_ipv4" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socket_ipv4" >&5 $as_echo "$gl_cv_socket_ipv4" >&6; } if test $gl_cv_socket_ipv4 = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_IPV4 1 -_ACEOF +$as_echo "#define HAVE_IPV4 1" >>confdefs.h fi - { $as_echo "$as_me:$LINENO: checking for IPv6 sockets" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 sockets" >&5 $as_echo_n "checking for IPv6 sockets... " >&6; } - if test "${gl_cv_socket_ipv6+set}" = set; then + if ${gl_cv_socket_ipv6+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #ifdef HAVE_SYS_SOCKET_H @@ -11294,42 +8423,19 @@ int x = AF_INET6; struct in6_addr y; struct sockaddr_in6 z; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_socket_ipv6=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_socket_ipv6=no + gl_cv_socket_ipv6=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - { $as_echo "$as_me:$LINENO: result: $gl_cv_socket_ipv6" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socket_ipv6" >&5 $as_echo "$gl_cv_socket_ipv6" >&6; } if test $gl_cv_socket_ipv6 = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_IPV6 1 -_ACEOF +$as_echo "#define HAVE_IPV6 1" >>confdefs.h fi @@ -11341,17 +8447,13 @@ _ACEOF gl_save_LIBS=$LIBS - { $as_echo "$as_me:$LINENO: checking for library containing inet_ntop" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5 $as_echo_n "checking for library containing inet_ntop... " >&6; } -if test "${ac_cv_search_inet_ntop+set}" = set; then +if ${ac_cv_search_inet_ntop+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -11376,54 +8478,27 @@ for ac_lib in '' nsl; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_inet_ntop=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_inet_ntop+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inet_ntop+:} false; then : break fi done -if test "${ac_cv_search_inet_ntop+set}" = set; then - : +if ${ac_cv_search_inet_ntop+:} false; then : + else ac_cv_search_inet_ntop=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_inet_ntop" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5 $as_echo "$ac_cv_search_inet_ntop" >&6; } ac_res=$ac_cv_search_inet_ntop -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" else @@ -11435,113 +8510,23 @@ else + for ac_func in inet_ntop +do : + ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" +if test "x$ac_cv_func_inet_ntop" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_INET_NTOP 1 +_ACEOF -for ac_func in inet_ntop -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ + gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext" -#ifdef __STDC__ -# include -#else -# include -#endif +fi +done -#undef $ac_func -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -else - - gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext" - -fi -done - - -fi +fi LIBS=$gl_save_LIBS INET_NTOP_LIB= @@ -11552,76 +8537,18 @@ fi - { $as_echo "$as_me:$LINENO: checking whether inet_ntop is declared" >&5 -$as_echo_n "checking whether inet_ntop is declared... " >&6; } -if test "${ac_cv_have_decl_inet_ntop+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 - -int -main () -{ -#ifndef inet_ntop - (void) inet_ntop; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_inet_ntop=yes + ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include +" +if test "x$ac_cv_have_decl_inet_ntop" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_inet_ntop=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_inet_ntop" >&5 -$as_echo "$ac_cv_have_decl_inet_ntop" >&6; } -if test "x$ac_cv_have_decl_inet_ntop" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_INET_NTOP 1 +#define HAVE_DECL_INET_NTOP $ac_have_decl _ACEOF - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_INET_NTOP 0 -_ACEOF - - -fi - - if test $ac_cv_have_decl_inet_ntop = no; then HAVE_DECL_INET_NTOP=0 fi @@ -11642,7 +8569,6 @@ fi - : @@ -11654,18 +8580,14 @@ fi if test $gl_cv_have_include_next = yes; then gl_cv_next_getopt_h='<'getopt.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_getopt_h+set}" = set; then +if ${gl_cv_next_getopt_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_getopt_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -11686,7 +8608,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_getopt_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5 $as_echo "$gl_cv_next_getopt_h" >&6; } fi NEXT_GETOPT_H=$gl_cv_next_getopt_h @@ -11719,146 +8641,12 @@ $as_echo "$gl_cv_next_getopt_h" >&6; } gl_replace_getopt= if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then - -for ac_header in getopt.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;} - - ;; -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 + for ac_header in getopt.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default" +if test "x$ac_cv_header_getopt_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_GETOPT_H 1 _ACEOF else @@ -11870,102 +8658,12 @@ done fi if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then - -for ac_func in getopt_long_only -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in getopt_long_only +do : + ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only" +if test "x$ac_cv_func_getopt_long_only" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETOPT_LONG_ONLY 1 _ACEOF else @@ -11976,156 +8674,45 @@ done fi if test -z "$gl_replace_getopt"; then - { $as_echo "$as_me:$LINENO: checking whether optreset is declared" >&5 -$as_echo_n "checking whether optreset is declared... " >&6; } -if test "${ac_cv_have_decl_optreset+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 - -int -main () -{ -#ifndef optreset - (void) optreset; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_optreset=yes + ac_fn_c_check_decl "$LINENO" "optreset" "ac_cv_have_decl_optreset" "#include +" +if test "x$ac_cv_have_decl_optreset" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_optreset=no + ac_have_decl=0 fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_optreset" >&5 -$as_echo "$ac_cv_have_decl_optreset" >&6; } -if test "x$ac_cv_have_decl_optreset" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_OPTRESET 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_OPTRESET 0 +#define HAVE_DECL_OPTRESET $ac_have_decl _ACEOF +if test $ac_have_decl = 1; then : -{ $as_echo "$as_me:$LINENO: checking whether getopt_clip is declared" >&5 -$as_echo_n "checking whether getopt_clip is declared... " >&6; } -if test "${ac_cv_have_decl_getopt_clip+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 - -int -main () -{ -#ifndef getopt_clip - (void) getopt_clip; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_getopt_clip=yes + ac_fn_c_check_decl "$LINENO" "getopt_clip" "ac_cv_have_decl_getopt_clip" "#include +" +if test "x$ac_cv_have_decl_getopt_clip" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_getopt_clip=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_getopt_clip" >&5 -$as_echo "$ac_cv_have_decl_getopt_clip" >&6; } -if test "x$ac_cv_have_decl_getopt_clip" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETOPT_CLIP 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETOPT_CLIP 0 +#define HAVE_DECL_GETOPT_CLIP $ac_have_decl _ACEOF fi - - -fi - - fi if test -z "$gl_replace_getopt"; then - { $as_echo "$as_me:$LINENO: checking whether getopt is POSIX compatible" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; } -if test "${gl_cv_func_getopt_posix+set}" = set; then +if ${gl_cv_func_getopt_posix+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : case "$host_os" in mingw*) gl_cv_func_getopt_posix="guessing no";; darwin* | aix*) gl_cv_func_getopt_posix="guessing no";; @@ -12133,11 +8720,7 @@ else esac else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -12231,45 +8814,18 @@ main () } _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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_getopt_posix=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_getopt_posix=no + gl_cv_func_getopt_posix=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_getopt_posix" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5 $as_echo "$gl_cv_func_getopt_posix" >&6; } case "$gl_cv_func_getopt_posix" in *no) gl_replace_getopt=yes ;; @@ -12277,9 +8833,9 @@ $as_echo "$gl_cv_func_getopt_posix" >&6; } fi if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then - { $as_echo "$as_me:$LINENO: checking for working GNU getopt function" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5 $as_echo_n "checking for working GNU getopt function... " >&6; } -if test "${gl_cv_func_getopt_gnu+set}" = set; then +if ${gl_cv_func_getopt_gnu+:} false; then : $as_echo_n "(cached) " >&6 else # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the @@ -12296,7 +8852,7 @@ else esac POSIXLY_CORRECT=1 export POSIXLY_CORRECT - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : case $host_os:$ac_cv_have_decl_optreset in *-gnu*:* | mingw*:*) gl_cv_func_getopt_gnu=no;; *:yes) gl_cv_func_getopt_gnu=no;; @@ -12304,11 +8860,7 @@ else esac else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -12370,50 +8922,23 @@ main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_getopt_gnu=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_getopt_gnu=no + gl_cv_func_getopt_gnu=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - case $gl_had_POSIXLY_CORRECT in exported) ;; - yes) $as_unset POSIXLY_CORRECT || test "${POSIXLY_CORRECT+set}" != set || { POSIXLY_CORRECT=; export POSIXLY_CORRECT; }; POSIXLY_CORRECT=1 ;; - *) $as_unset POSIXLY_CORRECT || test "${POSIXLY_CORRECT+set}" != set || { POSIXLY_CORRECT=; export POSIXLY_CORRECT; } ;; + yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;; + *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;; esac fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_getopt_gnu" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5 $as_echo "$gl_cv_func_getopt_gnu" >&6; } if test "$gl_cv_func_getopt_gnu" = "no"; then gl_replace_getopt=yes @@ -12421,90 +8946,30 @@ $as_echo "$gl_cv_func_getopt_gnu" >&6; } fi - { $as_echo "$as_me:$LINENO: checking whether getenv is declared" >&5 -$as_echo_n "checking whether getenv is declared... " >&6; } -if test "${ac_cv_have_decl_getenv+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -#ifndef getenv - (void) getenv; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_getenv=yes + ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default" +if test "x$ac_cv_have_decl_getenv" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_getenv=no + ac_have_decl=0 fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_getenv" >&5 -$as_echo "$ac_cv_have_decl_getenv" >&6; } -if test "x$ac_cv_have_decl_getenv" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETENV 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETENV 0 +#define HAVE_DECL_GETENV $ac_have_decl _ACEOF -fi - - - - if test -n "$gl_replace_getopt"; then + if test -n "$gl_replace_getopt"; then : GETOPT_H=getopt.h -cat >>confdefs.h <<\_ACEOF -#define __GETOPT_PREFIX rpl_ -_ACEOF +$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h @@ -12544,7 +9009,6 @@ fi - GNULIB_GETTIMEOFDAY=0; HAVE_GETTIMEOFDAY=1; HAVE_STRUCT_TIMEVAL=1; @@ -12560,7 +9024,6 @@ fi - : @@ -12582,18 +9045,14 @@ fi if test $gl_cv_have_include_next = yes; then gl_cv_next_sys_time_h='<'sys/time.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_sys_time_h+set}" = set; then +if ${gl_cv_next_sys_time_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_sys_time_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -12614,7 +9073,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_sys_time_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5 $as_echo "$gl_cv_next_sys_time_h" >&6; } fi NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h @@ -12635,16 +9094,12 @@ $as_echo "$gl_cv_next_sys_time_h" >&6; } HAVE_SYS_TIME_H=0 fi - { $as_echo "$as_me:$LINENO: checking for struct timeval" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5 $as_echo_n "checking for struct timeval... " >&6; } -if test "${gl_cv_sys_struct_timeval+set}" = set; then +if ${gl_cv_sys_struct_timeval+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if HAVE_SYS_TIME_H #include @@ -12659,54 +9114,28 @@ static struct timeval x; x.tv_sec = x.tv_usec; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_sys_struct_timeval=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_sys_struct_timeval=no + gl_cv_sys_struct_timeval=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_sys_struct_timeval" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5 $as_echo "$gl_cv_sys_struct_timeval" >&6; } if test $gl_cv_sys_struct_timeval != yes; then HAVE_STRUCT_TIMEVAL=0 fi - - for gl_func in gettimeofday; do + for gl_func in gettimeofday; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if HAVE_SYS_TIME_H @@ -12723,48 +9152,23 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done @@ -12777,7 +9181,6 @@ fi - GNULIB_NL_LANGINFO=0; HAVE_NL_LANGINFO=1; REPLACE_NL_LANGINFO=0; @@ -12789,20 +9192,15 @@ fi - - { $as_echo "$as_me:$LINENO: checking for working fcntl.h" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5 $as_echo_n "checking for working fcntl.h... " >&6; } -if test "${gl_cv_header_working_fcntl_h+set}" = set; then +if ${gl_cv_header_working_fcntl_h+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : gl_cv_header_working_fcntl_h=cross-compiling else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -12851,49 +9249,22 @@ main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_header_working_fcntl_h=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -case $? in #( + case $? in #( 32) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #( 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #( 96) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #( *) gl_cv_header_working_fcntl_h='no';; esac fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_working_fcntl_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5 $as_echo "$gl_cv_header_working_fcntl_h" >&6; } case $gl_cv_header_working_fcntl_h in #( @@ -12917,87 +9288,25 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking whether getc_unlocked is declared" >&5 -$as_echo_n "checking whether getc_unlocked is declared... " >&6; } -if test "${ac_cv_have_decl_getc_unlocked+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -#ifndef getc_unlocked - (void) getc_unlocked; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_getc_unlocked=yes + ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default" +if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_getc_unlocked=no + ac_have_decl=0 fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_getc_unlocked" >&5 -$as_echo "$ac_cv_have_decl_getc_unlocked" >&6; } -if test "x$ac_cv_have_decl_getc_unlocked" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETC_UNLOCKED 1 +#define HAVE_DECL_GETC_UNLOCKED $ac_have_decl _ACEOF -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETC_UNLOCKED 0 -_ACEOF - -fi - - - - - { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C Library 2.1 or newer" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library 2.1 or newer" >&5 $as_echo_n "checking whether we are using the GNU C Library 2.1 or newer... " >&6; } -if test "${ac_cv_gnu_library_2_1+set}" = set; then +if ${ac_cv_gnu_library_2_1+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -13009,7 +9318,7 @@ cat >>conftest.$ac_ext <<_ACEOF _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Lucky GNU user" >/dev/null 2>&1; then + $EGREP "Lucky GNU user" >/dev/null 2>&1; then : ac_cv_gnu_library_2_1=yes else ac_cv_gnu_library_2_1=no @@ -13019,7 +9328,7 @@ rm -f conftest* fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_gnu_library_2_1" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5 $as_echo "$ac_cv_gnu_library_2_1" >&6; } GLIBC21="$ac_cv_gnu_library_2_1" @@ -13043,7 +9352,7 @@ $as_echo "$ac_cv_gnu_library_2_1" >&6; } # Check whether --with-gnu-ld was given. -if test "${with_gnu_ld+set}" = set; then +if test "${with_gnu_ld+set}" = set; then : withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes else with_gnu_ld=no @@ -13065,7 +9374,7 @@ 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 GCC" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5 $as_echo_n "checking for ld used by GCC... " >&6; } case $host in *-*-mingw*) @@ -13095,13 +9404,13 @@ $as_echo_n "checking for ld used by GCC... " >&6; } ;; esac elif test "$with_gnu_ld" = yes; then - { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5 + { $as_echo "$as_me:${as_lineno-$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 "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi -if test "${acl_cv_path_LD+set}" = set; then +if ${acl_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then @@ -13129,18 +9438,16 @@ fi LD="$acl_cv_path_LD" if test -n "$LD"; then - { $as_echo "$as_me:$LINENO: result: $LD" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 $as_echo "$LD" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$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 +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } -if test "${acl_cv_prog_gnu_ld+set}" = set; then +if ${acl_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU ld's only accept -v. @@ -13151,16 +9458,16 @@ case `$LD -v 2>&1 &5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5 $as_echo "$acl_cv_prog_gnu_ld" >&6; } with_gnu_ld=$acl_cv_prog_gnu_ld - { $as_echo "$as_me:$LINENO: checking for shared library run path origin" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5 $as_echo_n "checking for shared library run path origin... " >&6; } -if test "${acl_cv_rpath+set}" = set; then +if ${acl_cv_rpath+:} false; then : $as_echo_n "(cached) " >&6 else @@ -13171,7 +9478,7 @@ else acl_cv_rpath=done fi -{ $as_echo "$as_me:$LINENO: result: $acl_cv_rpath" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5 $as_echo "$acl_cv_rpath" >&6; } wl="$acl_cv_wl" libext="$acl_cv_libext" @@ -13181,7 +9488,7 @@ $as_echo "$acl_cv_rpath" >&6; } hardcode_direct="$acl_cv_hardcode_direct" hardcode_minus_L="$acl_cv_hardcode_minus_L" # Check whether --enable-rpath was given. -if test "${enable_rpath+set}" = set; then +if test "${enable_rpath+set}" = set; then : enableval=$enable_rpath; : else enable_rpath=yes @@ -13215,17 +9522,13 @@ fi LIBMULTITHREAD= LTLIBMULTITHREAD= if test "$gl_use_threads" != no; then - { $as_echo "$as_me:$LINENO: checking whether imported symbols can be declared weak" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether imported symbols can be declared weak" >&5 $as_echo_n "checking whether imported symbols can be declared weak... " >&6; } -if test "${gl_cv_have_weak+set}" = set; then +if ${gl_cv_have_weak+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_have_weak=no - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ extern void xyzzy (); #pragma weak xyzzy @@ -13237,45 +9540,14 @@ xyzzy(); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_have_weak=maybe -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext if test $gl_cv_have_weak = maybe; then - if test "$cross_compiling" = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __ELF__ Extensible Linking Format @@ -13283,7 +9555,7 @@ cat >>conftest.$ac_ext <<_ACEOF _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Extensible Linking Format" >/dev/null 2>&1; then + $EGREP "Extensible Linking Format" >/dev/null 2>&1; then : gl_cv_have_weak="guessing yes" else gl_cv_have_weak="guessing no" @@ -13292,11 +9564,7 @@ rm -f conftest* else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -13306,178 +9574,25 @@ int main () return (fputs == NULL); } _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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_have_weak=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_have_weak=no + gl_cv_have_weak=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_have_weak" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_weak" >&5 $as_echo "$gl_cv_have_weak" >&6; } if test "$gl_use_threads" = yes || test "$gl_use_threads" = posix; then # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that # it groks . It's added above, in gl_THREADLIB_EARLY_BODY. - if test "${ac_cv_header_pthread_h+set}" = set; then - { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5 -$as_echo_n "checking for pthread.h... " >&6; } -if test "${ac_cv_header_pthread_h+set}" = set; then - $as_echo_n "(cached) " >&6 -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5 -$as_echo "$ac_cv_header_pthread_h" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5 -$as_echo_n "checking pthread.h 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 -_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 pthread.h presence" >&5 -$as_echo_n "checking pthread.h 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 -_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: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: pthread.h: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: pthread.h: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: pthread.h: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: pthread.h: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;} - - ;; -esac -{ $as_echo "$as_me:$LINENO: checking for pthread.h" >&5 -$as_echo_n "checking for pthread.h... " >&6; } -if test "${ac_cv_header_pthread_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_header_pthread_h=$ac_header_preproc -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5 -$as_echo "$ac_cv_header_pthread_h" >&6; } - -fi -if test "x$ac_cv_header_pthread_h" = x""yes; then + ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default" +if test "x$ac_cv_header_pthread_h" = xyes; then : gl_have_pthread_h=yes else gl_have_pthread_h=no @@ -13492,11 +9607,7 @@ fi # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist # in libc. IRIX 6.5 has the first one in both libc and libpthread, but # the second one only in libpthread, and lock.c needs it. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -13508,55 +9619,24 @@ pthread_mutex_lock((pthread_mutex_t*)0); 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 ac_fn_c_try_link "$LINENO"; then : gl_have_pthread=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext # Test for libpthread by looking for pthread_kill. (Not pthread_self, # since it is defined as a macro on OSF/1.) if test -n "$gl_have_pthread"; then # The program links fine without libpthread. But it may actually # need to link with libpthread in order to create multiple threads. - { $as_echo "$as_me:$LINENO: checking for pthread_kill in -lpthread" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; } -if test "${ac_cv_lib_pthread_pthread_kill+set}" = set; then +if ${ac_cv_lib_pthread_pthread_kill+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lpthread $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -13574,43 +9654,18 @@ return pthread_kill (); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_pthread_pthread_kill=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_pthread_pthread_kill=no + ac_cv_lib_pthread_pthread_kill=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_kill" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; } -if test "x$ac_cv_lib_pthread_pthread_kill" = x""yes; then +if test "x$ac_cv_lib_pthread_pthread_kill" = xyes; then : LIBMULTITHREAD=-lpthread LTLIBMULTITHREAD=-lpthread # On Solaris and HP-UX, most pthread functions exist also in libc. # Therefore pthread_in_use() needs to actually try to create a @@ -13619,9 +9674,7 @@ if test "x$ac_cv_lib_pthread_pthread_kill" = x""yes; then case "$host_os" in solaris* | hpux*) -cat >>confdefs.h <<\_ACEOF -#define PTHREAD_IN_USE_DETECTION_HARD 1 -_ACEOF +$as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h esac @@ -13629,18 +9682,14 @@ fi else # Some library is needed. Try libpthread and libc_r. - { $as_echo "$as_me:$LINENO: checking for pthread_kill in -lpthread" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; } -if test "${ac_cv_lib_pthread_pthread_kill+set}" = set; then +if ${ac_cv_lib_pthread_pthread_kill+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lpthread $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -13658,43 +9707,18 @@ return pthread_kill (); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_pthread_pthread_kill=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_pthread_pthread_kill=no + ac_cv_lib_pthread_pthread_kill=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_kill" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; } -if test "x$ac_cv_lib_pthread_pthread_kill" = x""yes; then +if test "x$ac_cv_lib_pthread_pthread_kill" = xyes; then : gl_have_pthread=yes LIBTHREAD=-lpthread LTLIBTHREAD=-lpthread LIBMULTITHREAD=-lpthread LTLIBMULTITHREAD=-lpthread @@ -13702,18 +9726,14 @@ fi if test -z "$gl_have_pthread"; then # For FreeBSD 4. - { $as_echo "$as_me:$LINENO: checking for pthread_kill in -lc_r" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lc_r" >&5 $as_echo_n "checking for pthread_kill in -lc_r... " >&6; } -if test "${ac_cv_lib_c_r_pthread_kill+set}" = set; then +if ${ac_cv_lib_c_r_pthread_kill+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lc_r $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -13731,43 +9751,18 @@ return pthread_kill (); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_c_r_pthread_kill=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_c_r_pthread_kill=no + ac_cv_lib_c_r_pthread_kill=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_c_r_pthread_kill" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_kill" >&5 $as_echo "$ac_cv_lib_c_r_pthread_kill" >&6; } -if test "x$ac_cv_lib_c_r_pthread_kill" = x""yes; then +if test "x$ac_cv_lib_c_r_pthread_kill" = xyes; then : gl_have_pthread=yes LIBTHREAD=-lc_r LTLIBTHREAD=-lc_r LIBMULTITHREAD=-lc_r LTLIBMULTITHREAD=-lc_r @@ -13778,16 +9773,12 @@ fi if test -n "$gl_have_pthread"; then gl_threads_api=posix -cat >>confdefs.h <<\_ACEOF -#define USE_POSIX_THREADS 1 -_ACEOF +$as_echo "#define USE_POSIX_THREADS 1" >>confdefs.h if test -n "$LIBMULTITHREAD" || test -n "$LTLIBMULTITHREAD"; then if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then -cat >>confdefs.h <<\_ACEOF -#define USE_POSIX_THREADS_WEAK 1 -_ACEOF +$as_echo "#define USE_POSIX_THREADS_WEAK 1" >>confdefs.h LIBTHREAD= LTLIBTHREAD= @@ -13801,11 +9792,7 @@ _ACEOF gl_have_solaristhread= gl_save_LIBS="$LIBS" LIBS="$LIBS -lthread" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -13819,38 +9806,11 @@ thr_self(); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : gl_have_solaristhread=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS="$gl_save_LIBS" if test -n "$gl_have_solaristhread"; then gl_threads_api=solaris @@ -13859,15 +9819,11 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ LIBMULTITHREAD="$LIBTHREAD" LTLIBMULTITHREAD="$LTLIBTHREAD" -cat >>confdefs.h <<\_ACEOF -#define USE_SOLARIS_THREADS 1 -_ACEOF +$as_echo "#define USE_SOLARIS_THREADS 1" >>confdefs.h if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then -cat >>confdefs.h <<\_ACEOF -#define USE_SOLARIS_THREADS_WEAK 1 -_ACEOF +$as_echo "#define USE_SOLARIS_THREADS_WEAK 1" >>confdefs.h LIBTHREAD= LTLIBTHREAD= @@ -13882,9 +9838,9 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking how to link with libpth" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libpth" >&5 $as_echo_n "checking how to link with libpth... " >&6; } -if test "${ac_cv_libpth_libs+set}" = set; then +if ${ac_cv_libpth_libs+:} false; then : $as_echo_n "(cached) " >&6 else @@ -13906,7 +9862,7 @@ else # Check whether --with-libpth-prefix was given. -if test "${with_libpth_prefix+set}" = set; then +if test "${with_libpth_prefix+set}" = set; then : withval=$with_libpth_prefix; if test "X$withval" = "Xno"; then use_additional=no @@ -14272,7 +10228,7 @@ fi ac_cv_libpth_cppflags="$INCPTH" fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_libpth_libs" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libpth_libs" >&5 $as_echo "$ac_cv_libpth_libs" >&6; } LIBPTH="$ac_cv_libpth_libs" LTLIBPTH="$ac_cv_libpth_ltlibs" @@ -14309,11 +10265,7 @@ $as_echo "$ac_cv_libpth_libs" >&6; } gl_have_pth= gl_save_LIBS="$LIBS" LIBS="$LIBS -lpth" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -14324,38 +10276,11 @@ pth_self(); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : gl_have_pth=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS="$gl_save_LIBS" if test -n "$gl_have_pth"; then gl_threads_api=pth @@ -14364,16 +10289,12 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ LIBMULTITHREAD="$LIBTHREAD" LTLIBMULTITHREAD="$LTLIBTHREAD" -cat >>confdefs.h <<\_ACEOF -#define USE_PTH_THREADS 1 -_ACEOF +$as_echo "#define USE_PTH_THREADS 1" >>confdefs.h if test -n "$LIBMULTITHREAD" || test -n "$LTLIBMULTITHREAD"; then if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then -cat >>confdefs.h <<\_ACEOF -#define USE_PTH_THREADS_WEAK 1 -_ACEOF +$as_echo "#define USE_PTH_THREADS_WEAK 1" >>confdefs.h LIBTHREAD= LTLIBTHREAD= @@ -14392,17 +10313,15 @@ _ACEOF }; then gl_threads_api=win32 -cat >>confdefs.h <<\_ACEOF -#define USE_WIN32_THREADS 1 -_ACEOF +$as_echo "#define USE_WIN32_THREADS 1" >>confdefs.h fi fi fi fi - { $as_echo "$as_me:$LINENO: checking for multithread API to use" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for multithread API to use" >&5 $as_echo_n "checking for multithread API to use... " >&6; } - { $as_echo "$as_me:$LINENO: result: $gl_threads_api" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_threads_api" >&5 $as_echo "$gl_threads_api" >&6; } @@ -14452,30 +10371,25 @@ $as_echo "$gl_threads_api" >&6; } - -{ $as_echo "$as_me:$LINENO: checking whether lstat dereferences a symlink specified with a trailing slash" >&5 -$as_echo_n "checking whether lstat dereferences a symlink specified with a trailing slash... " >&6; } -if test "${ac_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5 +$as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; } +if ${ac_cv_func_lstat_dereferences_slashed_symlink+:} false; then : $as_echo_n "(cached) " >&6 else rm -f conftest.sym conftest.file echo >conftest.file if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : ac_cv_func_lstat_dereferences_slashed_symlink=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int main () { struct stat sbuf; - /* Linux will dereference the symlink and fail. + /* Linux will dereference the symlink and fail, as required by POSIX. That is better in the sense that it means we will not have to compile and use the lstat wrapper. */ return lstat ("conftest.sym/", &sbuf) == 0; @@ -14483,42 +10397,15 @@ struct stat sbuf; 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 +if ac_fn_c_try_run "$LINENO"; then : ac_cv_func_lstat_dereferences_slashed_symlink=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_func_lstat_dereferences_slashed_symlink=no + ac_cv_func_lstat_dereferences_slashed_symlink=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - else # If the `ln -s' command failed, then we probably don't even # have an lstat function. @@ -14527,7 +10414,7 @@ fi rm -f conftest.sym conftest.file fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5 $as_echo "$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; } test $ac_cv_func_lstat_dereferences_slashed_symlink = yes && @@ -14537,7 +10424,7 @@ cat >>confdefs.h <<_ACEOF _ACEOF -if test $ac_cv_func_lstat_dereferences_slashed_symlink = no; then +if test "x$ac_cv_func_lstat_dereferences_slashed_symlink" = xno; then @@ -14611,17 +10498,13 @@ fi REPLACE_UNSETENV=0; - { $as_echo "$as_me:$LINENO: checking whether malloc, realloc, calloc are POSIX compliant" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5 $as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; } -if test "${gl_cv_func_malloc_posix+set}" = set; then +if ${gl_cv_func_malloc_posix+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -14635,50 +10518,25 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_func_malloc_posix=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_malloc_posix=no + gl_cv_func_malloc_posix=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_malloc_posix" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5 $as_echo "$gl_cv_func_malloc_posix" >&6; } - { $as_echo "$as_me:$LINENO: checking for mbstate_t" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5 $as_echo_n "checking for mbstate_t... " >&6; } -if test "${ac_cv_type_mbstate_t+set}" = set; then +if ${ac_cv_type_mbstate_t+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default # include @@ -14690,47 +10548,22 @@ mbstate_t x; return sizeof x; 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_type_mbstate_t=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_mbstate_t=no + ac_cv_type_mbstate_t=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_mbstate_t" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5 $as_echo "$ac_cv_type_mbstate_t" >&6; } if test $ac_cv_type_mbstate_t = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_MBSTATE_T 1 -_ACEOF +$as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h else -cat >>confdefs.h <<\_ACEOF -#define mbstate_t int -_ACEOF +$as_echo "#define mbstate_t int" >>confdefs.h fi @@ -14747,19 +10580,13 @@ _ACEOF - - - { $as_echo "$as_me:$LINENO: checking for a traditional japanese locale" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5 $as_echo_n "checking for a traditional japanese locale... " >&6; } -if test "${gt_cv_locale_ja+set}" = set; then +if ${gt_cv_locale_ja+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -14810,11 +10637,11 @@ int main () } _ACEOF - if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest$ac_exeext; then # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because # otherwise on MacOS X 10.3.5 the LC_TIME=C from the beginning of the # configure script would override the LC_ALL setting. Likewise for @@ -14855,7 +10682,7 @@ _ACEOF rm -fr conftest* fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_locale_ja" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5 $as_echo "$gt_cv_locale_ja" >&6; } LOCALE_JA=$gt_cv_locale_ja @@ -14863,17 +10690,13 @@ $as_echo "$gt_cv_locale_ja" >&6; } - { $as_echo "$as_me:$LINENO: checking for a transitional chinese locale" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5 $as_echo_n "checking for a transitional chinese locale... " >&6; } -if test "${gt_cv_locale_zh_CN+set}" = set; then +if ${gt_cv_locale_zh_CN+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -14925,11 +10748,11 @@ int main () } _ACEOF - if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest$ac_exeext; then # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because # otherwise on MacOS X 10.3.5 the LC_TIME=C from the beginning of the # configure script would override the LC_ALL setting. Likewise for @@ -14954,24 +10777,20 @@ _ACEOF rm -fr conftest* fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_locale_zh_CN" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5 $as_echo "$gt_cv_locale_zh_CN" >&6; } LOCALE_ZH_CN=$gt_cv_locale_zh_CN - { $as_echo "$as_me:$LINENO: checking for a french Unicode locale" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5 $as_echo_n "checking for a french Unicode locale... " >&6; } -if test "${gt_cv_locale_fr_utf8+set}" = set; then +if ${gt_cv_locale_fr_utf8+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -15025,11 +10844,11 @@ int main () { } _ACEOF - if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest$ac_exeext; then # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because # otherwise on MacOS X 10.3.5 the LC_TIME=C from the beginning of the # configure script would override the LC_ALL setting. Likewise for @@ -15055,7 +10874,7 @@ _ACEOF rm -fr conftest* fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_locale_fr_utf8" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5 $as_echo "$gt_cv_locale_fr_utf8" >&6; } LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8 @@ -15071,8 +10890,6 @@ $as_echo "$gt_cv_locale_fr_utf8" >&6; } - - GNULIB_MEMCHR=0; GNULIB_MEMMEM=0; GNULIB_MEMPCPY=0; @@ -15151,96 +10968,11 @@ $as_echo "$gt_cv_locale_fr_utf8" >&6; } - # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is # irrelevant for anonymous mappings. - { $as_echo "$as_me:$LINENO: checking for mmap" >&5 -$as_echo_n "checking for mmap... " >&6; } -if test "${ac_cv_func_mmap+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 mmap to an innocuous variant, in case declares mmap. - For example, HP-UX 11i declares gettimeofday. */ -#define mmap innocuous_mmap - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char mmap (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef mmap - -/* 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 mmap (); -/* 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_mmap || defined __stub___mmap -choke me -#endif - -int -main () -{ -return mmap (); - ; - 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_mmap=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_mmap=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_mmap" >&5 -$as_echo "$ac_cv_func_mmap" >&6; } -if test "x$ac_cv_func_mmap" = x""yes; then + ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap" +if test "x$ac_cv_func_mmap" = xyes; then : gl_have_mmap=yes else gl_have_mmap=no @@ -15250,13 +10982,9 @@ fi # Try to allow MAP_ANONYMOUS. gl_have_mmap_anonymous=no if test $gl_have_mmap = yes; then - { $as_echo "$as_me:$LINENO: checking for MAP_ANONYMOUS" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; } - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -15266,17 +10994,13 @@ cat >>conftest.$ac_ext <<_ACEOF _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "I cant identify this map." >/dev/null 2>&1; then + $EGREP "I cant identify this map." >/dev/null 2>&1; then : gl_have_mmap_anonymous=yes fi rm -f conftest* if test $gl_have_mmap_anonymous != yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -15286,24 +11010,20 @@ cat >>conftest.$ac_ext <<_ACEOF _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "I cant identify this map." >/dev/null 2>&1; then + $EGREP "I cant identify this map." >/dev/null 2>&1; then : -cat >>confdefs.h <<\_ACEOF -#define MAP_ANONYMOUS MAP_ANON -_ACEOF +$as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h gl_have_mmap_anonymous=yes fi rm -f conftest* fi - { $as_echo "$as_me:$LINENO: result: $gl_have_mmap_anonymous" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5 $as_echo "$gl_have_mmap_anonymous" >&6; } if test $gl_have_mmap_anonymous = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_MAP_ANONYMOUS 1 -_ACEOF +$as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h fi fi @@ -15339,19 +11059,15 @@ _ACEOF # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737 # http://sourceware.org/bugzilla/show_bug.cgi?id=10162 # Assume that memchr works on platforms that lack mprotect. - { $as_echo "$as_me:$LINENO: checking whether memchr works" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5 $as_echo_n "checking whether memchr works... " >&6; } -if test "${gl_cv_func_memchr_works+set}" = set; then +if ${gl_cv_func_memchr_works+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : gl_cv_func_memchr_works="guessing no" else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -15403,44 +11119,17 @@ main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_memchr_works=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_memchr_works=no + gl_cv_func_memchr_works=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_memchr_works" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5 $as_echo "$gl_cv_func_memchr_works" >&6; } if test "$gl_cv_func_memchr_works" != yes; then REPLACE_MEMCHR=1 @@ -15460,146 +11149,12 @@ $as_echo "$gl_cv_func_memchr_works" >&6; } gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext" - -for ac_header in bp-sym.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;} - - ;; -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 + for ac_header in bp-sym.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default" +if test "x$ac_cv_header_bp_sym_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_BP_SYM_H 1 _ACEOF fi @@ -15611,11 +11166,7 @@ done gl_cv_c_multiarch=no - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __APPLE_CC__ not a universal capable compiler @@ -15623,24 +11174,7 @@ cat >>conftest.$ac_ext <<_ACEOF typedef int dummy; _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 +if ac_fn_c_try_compile "$LINENO"; then : arch= prev= @@ -15663,19 +11197,11 @@ $as_echo "$ac_try_echo") >&5 fi done -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 if test $gl_cv_c_multiarch = yes; then -cat >>confdefs.h <<\_ACEOF -#define AA_APPLE_UNIVERSAL_BUILD 1 -_ACEOF +$as_echo "#define AA_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h APPLE_UNIVERSAL_BUILD=1 else @@ -15688,17 +11214,12 @@ _ACEOF - -{ $as_echo "$as_me:$LINENO: checking for external symbol _system_configuration" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for external symbol _system_configuration" >&5 $as_echo_n "checking for external symbol _system_configuration... " >&6; } -if test "${gl_cv_var__system_configuration+set}" = set; then +if ${gl_cv_var__system_configuration+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -15711,47 +11232,20 @@ double x = _system_configuration.physmem; 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_var__system_configuration=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_var__system_configuration=no + gl_cv_var__system_configuration=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_var__system_configuration" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var__system_configuration" >&5 $as_echo "$gl_cv_var__system_configuration" >&6; } if test $gl_cv_var__system_configuration = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE__SYSTEM_CONFIGURATION 1 -_ACEOF +$as_echo "#define HAVE__SYSTEM_CONFIGURATION 1" >>confdefs.h fi @@ -15777,20 +11271,12 @@ _ACEOF - - - - - { $as_echo "$as_me:$LINENO: checking for ssize_t" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5 $as_echo_n "checking for ssize_t... " >&6; } -if test "${gt_cv_ssize_t+set}" = set; then +if ${gt_cv_ssize_t+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -15802,127 +11288,42 @@ int x = sizeof (ssize_t *) + sizeof (ssize_t); 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 +if ac_fn_c_try_compile "$LINENO"; then : gt_cv_ssize_t=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_ssize_t=no + gt_cv_ssize_t=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_ssize_t" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5 $as_echo "$gt_cv_ssize_t" >&6; } if test $gt_cv_ssize_t = no; then -cat >>confdefs.h <<\_ACEOF -#define ssize_t int -_ACEOF +$as_echo "#define ssize_t int" >>confdefs.h fi - { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5 -$as_echo_n "checking whether snprintf is declared... " >&6; } -if test "${ac_cv_have_decl_snprintf+set}" = set; then - $as_echo_n "(cached) " >&6 + ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default" +if test "x$ac_cv_have_decl_snprintf" = xyes; then : + ac_have_decl=1 else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -#ifndef snprintf - (void) snprintf; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_snprintf=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_snprintf=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5 -$as_echo "$ac_cv_have_decl_snprintf" >&6; } -if test "x$ac_cv_have_decl_snprintf" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_SNPRINTF 1 +#define HAVE_DECL_SNPRINTF $ac_have_decl _ACEOF -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_SNPRINTF 0 -_ACEOF - -fi - - - - - { $as_echo "$as_me:$LINENO: checking whether system is Windows or MSDOS" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system is Windows or MSDOS" >&5 $as_echo_n "checking whether system is Windows or MSDOS... " >&6; } -if test "${ac_cv_win_or_dos+set}" = set; then +if ${ac_cv_win_or_dos+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -15936,52 +11337,27 @@ neither MSDOS nor Windows 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_win_or_dos=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_win_or_dos=no + ac_cv_win_or_dos=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_win_or_dos" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_win_or_dos" >&5 $as_echo "$ac_cv_win_or_dos" >&6; } if test x"$ac_cv_win_or_dos" = xyes; then ac_fs_accepts_drive_letter_prefix=1 ac_fs_backslash_is_file_name_separator=1 - { $as_echo "$as_me:$LINENO: checking whether drive letter can start relative path" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether drive letter can start relative path" >&5 $as_echo_n "checking whether drive letter can start relative path... " >&6; } -if test "${ac_cv_drive_letter_can_be_relative+set}" = set; then +if ${ac_cv_drive_letter_can_be_relative+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -15995,36 +11371,15 @@ drive letters are always absolute 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_drive_letter_can_be_relative=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_drive_letter_can_be_relative=no + ac_cv_drive_letter_can_be_relative=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_drive_letter_can_be_relative" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_drive_letter_can_be_relative" >&5 $as_echo "$ac_cv_drive_letter_can_be_relative" >&6; } if test x"$ac_cv_drive_letter_can_be_relative" = xyes; then ac_fs_drive_letter_can_be_relative=1 @@ -16046,7 +11401,6 @@ _ACEOF - cat >>confdefs.h <<_ACEOF #define FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR $ac_fs_backslash_is_file_name_separator _ACEOF @@ -16058,16 +11412,12 @@ cat >>confdefs.h <<_ACEOF _ACEOF -{ $as_echo "$as_me:$LINENO: checking for stdbool.h that conforms to C99" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; } -if test "${ac_cv_header_stdbool_h+set}" = set; then +if ${ac_cv_header_stdbool_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -16129,131 +11479,17 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdbool_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_header_stdbool_h=no + ac_cv_header_stdbool_h=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdbool_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 $as_echo "$ac_cv_header_stdbool_h" >&6; } - { $as_echo "$as_me:$LINENO: checking for _Bool" >&5 -$as_echo_n "checking for _Bool... " >&6; } -if test "${ac_cv_type__Bool+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type__Bool=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof (_Bool)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof ((_Bool))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type__Bool=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type__Bool" >&5 -$as_echo "$ac_cv_type__Bool" >&6; } -if test "x$ac_cv_type__Bool" = x""yes; then + ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" +if test "x$ac_cv_type__Bool" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE__BOOL 1 @@ -16264,9 +11500,7 @@ fi if test $ac_cv_header_stdbool_h = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_STDBOOL_H 1 -_ACEOF +$as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h fi @@ -16275,16 +11509,12 @@ _ACEOF STDDEF_H=''; - { $as_echo "$as_me:$LINENO: checking for wchar_t" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5 $as_echo_n "checking for wchar_t... " >&6; } -if test "${gt_cv_c_wchar_t+set}" = set; then +if ${gt_cv_c_wchar_t+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include wchar_t foo = (wchar_t)'\0'; @@ -16296,41 +11526,18 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gt_cv_c_wchar_t=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_c_wchar_t=no + gt_cv_c_wchar_t=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_c_wchar_t" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5 $as_echo "$gt_cv_c_wchar_t" >&6; } if test $gt_cv_c_wchar_t = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_WCHAR_T 1 -_ACEOF +$as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h fi @@ -16340,20 +11547,15 @@ _ACEOF - - { $as_echo "$as_me:$LINENO: checking for long long int" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5 $as_echo_n "checking for long long int... " >&6; } -if test "${ac_cv_type_long_long_int+set}" = set; then +if ${ac_cv_type_long_long_int+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* For now, do not test the preprocessor; as of 2007 there are too many + + /* For now, do not test the preprocessor; as of 2007 there are too many implementations with broken preprocessors. Perhaps this can be revisited in 2012. In the meantime, code should not expect #if to work with literals wider than 32 bits. */ @@ -16382,35 +11584,11 @@ main () } _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 test "$cross_compiling" = yes; then +if ac_fn_c_try_link "$LINENO"; then : + if test "$cross_compiling" = yes; then : ac_cv_type_long_long_int=yes else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #ifndef LLONG_MAX @@ -16436,77 +11614,39 @@ long long int n = 1; 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 +if ac_fn_c_try_run "$LINENO"; then : ac_cv_type_long_long_int=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_type_long_long_int=no + ac_cv_type_long_long_int=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_long_long_int=no + ac_cv_type_long_long_int=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5 $as_echo "$ac_cv_type_long_long_int" >&6; } if test $ac_cv_type_long_long_int = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_LONG_LONG_INT 1 -_ACEOF +$as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h fi - { $as_echo "$as_me:$LINENO: checking for unsigned long long int" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5 $as_echo_n "checking for unsigned long long int... " >&6; } -if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then +if ${ac_cv_type_unsigned_long_long_int+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* For now, do not test the preprocessor; as of 2007 there are too many + + /* For now, do not test the preprocessor; as of 2007 there are too many implementations with broken preprocessors. Perhaps this can be revisited in 2012. In the meantime, code should not expect #if to work with literals wider than 32 bits. */ @@ -16535,46 +11675,19 @@ main () } _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 ac_fn_c_try_link "$LINENO"; then : ac_cv_type_unsigned_long_long_int=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_unsigned_long_long_int=no + ac_cv_type_unsigned_long_long_int=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long_long_int" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; } if test $ac_cv_type_unsigned_long_long_int = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_UNSIGNED_LONG_LONG_INT 1 -_ACEOF +$as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h fi @@ -16589,11 +11702,9 @@ _ACEOF - - - { $as_echo "$as_me:$LINENO: checking whether C symbols are prefixed with underscore at the linker level" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C symbols are prefixed with underscore at the linker level" >&5 $as_echo_n "checking whether C symbols are prefixed with underscore at the linker level... " >&6; } -if test "${gl_cv_prog_as_underscore+set}" = set; then +if ${gl_cv_prog_as_underscore+:} false; then : $as_echo_n "(cached) " >&6 else cat > conftest.c <&5 + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 (eval $ac_try) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } >/dev/null 2>&1 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } >/dev/null 2>&1 if grep _foo conftest.s >/dev/null ; then gl_cv_prog_as_underscore=yes else @@ -16617,7 +11728,7 @@ EOF rm -f conftest* fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_prog_as_underscore" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_prog_as_underscore" >&5 $as_echo "$gl_cv_prog_as_underscore" >&6; } if test $gl_cv_prog_as_underscore = yes; then USER_LABEL_PREFIX=_ @@ -16650,9 +11761,6 @@ _ACEOF - - - @@ -16668,18 +11776,14 @@ _ACEOF if test $gl_cv_have_include_next = yes; then gl_cv_next_string_h='<'string.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_string_h+set}" = set; then +if ${gl_cv_next_string_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_string_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -16700,7 +11804,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_string_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5 $as_echo "$gl_cv_next_string_h" >&6; } fi NEXT_STRING_H=$gl_cv_next_string_h @@ -16718,35 +11822,14 @@ $as_echo "$gl_cv_next_string_h" >&6; } - - - - - - - - - - - - - - - - - - for gl_func in memmem mempcpy memrchr rawmemchr stpcpy stpncpy strchrnul strdup strncat strndup strnlen strpbrk strsep strcasestr strtok_r strsignal strverscmp; do + for gl_func in memmem mempcpy memrchr rawmemchr stpcpy stpncpy strchrnul strdup strncat strndup strnlen strpbrk strsep strcasestr strtok_r strsignal strverscmp; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -16759,61 +11842,32 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done -{ $as_echo "$as_me:$LINENO: checking whether stat file-mode macros are broken" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; } -if test "${ac_cv_header_stat_broken+set}" = set; then +if ${ac_cv_header_stat_broken+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -16835,41 +11889,18 @@ extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1]; #endif _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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stat_broken=no else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_header_stat_broken=yes + ac_cv_header_stat_broken=yes fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stat_broken" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5 $as_echo "$ac_cv_header_stat_broken" >&6; } if test $ac_cv_header_stat_broken = yes; then -cat >>confdefs.h <<\_ACEOF -#define STAT_MACROS_BROKEN 1 -_ACEOF +$as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h fi @@ -16878,17 +11909,16 @@ fi - # Check whether --enable-largefile was given. -if test "${enable_largefile+set}" = set; then +if test "${enable_largefile+set}" = set; then : enableval=$enable_largefile; fi if test "$enable_largefile" != no; then - { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 $as_echo_n "checking for special C compiler options needed for large files... " >&6; } -if test "${ac_cv_sys_largefile_CC+set}" = set; then +if ${ac_cv_sys_largefile_CC+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_sys_largefile_CC=no @@ -16897,11 +11927,7 @@ else while :; do # IRIX 6.2 and later do not support large files by default, # so use the C compiler's -n32 option if that helps. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. @@ -16920,60 +11946,14 @@ 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 + if ac_fn_c_try_compile "$LINENO"; then : break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - rm -f core conftest.err conftest.$ac_objext CC="$CC -n32" - 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 + if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_largefile_CC=' -n32'; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - rm -f core conftest.err conftest.$ac_objext break done @@ -16981,23 +11961,19 @@ rm -f core conftest.err conftest.$ac_objext rm -f conftest.$ac_ext fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 $as_echo "$ac_cv_sys_largefile_CC" >&6; } if test "$ac_cv_sys_largefile_CC" != no; then CC=$CC$ac_cv_sys_largefile_CC fi - { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } -if test "${ac_cv_sys_file_offset_bits+set}" = set; then +if ${ac_cv_sys_file_offset_bits+:} false; then : $as_echo_n "(cached) " >&6 else while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. @@ -17016,38 +11992,11 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_file_offset_bits=no; break -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 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _FILE_OFFSET_BITS 64 #include @@ -17067,38 +12016,15 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_file_offset_bits=64; break -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 ac_cv_sys_file_offset_bits=unknown break done fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 $as_echo "$ac_cv_sys_file_offset_bits" >&6; } case $ac_cv_sys_file_offset_bits in #( no | unknown) ;; @@ -17110,17 +12036,13 @@ _ACEOF esac rm -rf conftest* if test $ac_cv_sys_file_offset_bits = unknown; then - { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } -if test "${ac_cv_sys_large_files+set}" = set; then +if ${ac_cv_sys_large_files+:} false; then : $as_echo_n "(cached) " >&6 else while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* Check that off_t can represent 2**63 - 1 correctly. @@ -17139,38 +12061,11 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_large_files=no; break -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 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #define _LARGE_FILES 1 #include @@ -17190,38 +12085,15 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_sys_large_files=1; break -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 ac_cv_sys_large_files=unknown break done fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 $as_echo "$ac_cv_sys_large_files" >&6; } case $ac_cv_sys_large_files in #( no | unknown) ;; @@ -17257,23 +12129,18 @@ fi - : - { $as_echo "$as_me:$LINENO: checking for struct timespec in " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in " >&5 $as_echo_n "checking for struct timespec in ... " >&6; } -if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then +if ${gl_cv_sys_struct_timespec_in_time_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -17285,35 +12152,14 @@ static struct timespec x; x.tv_sec = x.tv_nsec; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_sys_struct_timespec_in_time_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_sys_struct_timespec_in_time_h=no + gl_cv_sys_struct_timespec_in_time_h=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_sys_struct_timespec_in_time_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; } TIME_H_DEFINES_STRUCT_TIMESPEC=0 @@ -17322,16 +12168,12 @@ $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; } if test $gl_cv_sys_struct_timespec_in_time_h = yes; then TIME_H_DEFINES_STRUCT_TIMESPEC=1 else - { $as_echo "$as_me:$LINENO: checking for struct timespec in " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in " >&5 $as_echo_n "checking for struct timespec in ... " >&6; } -if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then +if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -17343,49 +12185,24 @@ static struct timespec x; x.tv_sec = x.tv_nsec; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_sys_struct_timespec_in_sys_time_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_sys_struct_timespec_in_sys_time_h=no + gl_cv_sys_struct_timespec_in_sys_time_h=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; } if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1 else - { $as_echo "$as_me:$LINENO: checking for struct timespec in " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in " >&5 $as_echo_n "checking for struct timespec in ... " >&6; } -if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then +if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -17397,35 +12214,14 @@ static struct timespec x; x.tv_sec = x.tv_nsec; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_sys_struct_timespec_in_pthread_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_sys_struct_timespec_in_pthread_h=no + gl_cv_sys_struct_timespec_in_pthread_h=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; } if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1 @@ -17454,18 +12250,14 @@ $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; } if test $gl_cv_have_include_next = yes; then gl_cv_next_time_h='<'time.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_time_h+set}" = set; then +if ${gl_cv_next_time_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_time_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -17486,7 +12278,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_time_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5 $as_echo "$gl_cv_next_time_h" >&6; } fi NEXT_TIME_H=$gl_cv_next_time_h @@ -17515,18 +12307,12 @@ $as_echo "$gl_cv_next_time_h" >&6; } - - - { $as_echo "$as_me:$LINENO: checking for wint_t" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5 $as_echo_n "checking for wint_t... " >&6; } -if test "${gt_cv_c_wint_t+set}" = set; then +if ${gt_cv_c_wint_t+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include wint_t foo = (wchar_t)'\0'; @@ -17538,159 +12324,28 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gt_cv_c_wint_t=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_c_wint_t=no + gt_cv_c_wint_t=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_c_wint_t" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5 $as_echo "$gt_cv_c_wint_t" >&6; } if test $gt_cv_c_wint_t = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_WINT_T 1 -_ACEOF +$as_echo "#define HAVE_WINT_T 1" >>confdefs.h fi -{ $as_echo "$as_me:$LINENO: checking for size_t" >&5 -$as_echo_n "checking for size_t... " >&6; } -if test "${ac_cv_type_size_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_size_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof (size_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof ((size_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_size_t=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5 -$as_echo "$ac_cv_type_size_t" >&6; } -if test "x$ac_cv_type_size_t" = x""yes; then - : -else - -cat >>confdefs.h <<_ACEOF -#define size_t unsigned int -_ACEOF - -fi - - { $as_echo "$as_me:$LINENO: checking for inttypes.h" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 $as_echo_n "checking for inttypes.h... " >&6; } -if test "${gl_cv_header_inttypes_h+set}" = set; then +if ${gl_cv_header_inttypes_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -17702,35 +12357,14 @@ uintmax_t i = (uintmax_t) -1; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_header_inttypes_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_header_inttypes_h=no + gl_cv_header_inttypes_h=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_inttypes_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_inttypes_h" >&5 $as_echo "$gl_cv_header_inttypes_h" >&6; } if test $gl_cv_header_inttypes_h = yes; then @@ -17741,16 +12375,12 @@ _ACEOF fi - { $as_echo "$as_me:$LINENO: checking for stdint.h" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5 $as_echo_n "checking for stdint.h... " >&6; } -if test "${gl_cv_header_stdint_h+set}" = set; then +if ${gl_cv_header_stdint_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -17762,35 +12392,14 @@ uintmax_t i = (uintmax_t) -1; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_header_stdint_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_header_stdint_h=no + gl_cv_header_stdint_h=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_stdint_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_h" >&5 $as_echo "$gl_cv_header_stdint_h" >&6; } if test $gl_cv_header_stdint_h = yes; then @@ -17803,16 +12412,12 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking for intmax_t" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5 $as_echo_n "checking for intmax_t... " >&6; } -if test "${gt_cv_c_intmax_t+set}" = set; then +if ${gt_cv_c_intmax_t+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -17832,41 +12437,18 @@ intmax_t x = -1; return !x; 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 +if ac_fn_c_try_compile "$LINENO"; then : gt_cv_c_intmax_t=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_c_intmax_t=no + gt_cv_c_intmax_t=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_c_intmax_t" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_intmax_t" >&5 $as_echo "$gt_cv_c_intmax_t" >&6; } if test $gt_cv_c_intmax_t = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_INTMAX_T 1 -_ACEOF +$as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h else @@ -17882,13 +12464,13 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking whether snprintf returns a byte count as in C99" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf returns a byte count as in C99" >&5 $as_echo_n "checking whether snprintf returns a byte count as in C99... " >&6; } -if test "${gl_cv_func_snprintf_retval_c99+set}" = set; then +if ${gl_cv_func_snprintf_retval_c99+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : case "$host_os" in # Guess yes on glibc systems. @@ -17920,11 +12502,7 @@ else esac else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -17938,45 +12516,18 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_snprintf_retval_c99=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_snprintf_retval_c99=no + gl_cv_func_snprintf_retval_c99=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_snprintf_retval_c99" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_retval_c99" >&5 $as_echo "$gl_cv_func_snprintf_retval_c99" >&6; } @@ -17985,106 +12536,11 @@ $as_echo "$gl_cv_func_snprintf_retval_c99" >&6; } - - - - - - - -for ac_func in snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF @@ -18092,83 +12548,23 @@ _ACEOF fi done - { $as_echo "$as_me:$LINENO: checking whether _snprintf is declared" >&5 -$as_echo_n "checking whether _snprintf is declared... " >&6; } -if test "${ac_cv_have_decl__snprintf+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 - -int -main () -{ -#ifndef _snprintf - (void) _snprintf; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl__snprintf=yes + ac_fn_c_check_decl "$LINENO" "_snprintf" "ac_cv_have_decl__snprintf" "#include +" +if test "x$ac_cv_have_decl__snprintf" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl__snprintf=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl__snprintf" >&5 -$as_echo "$ac_cv_have_decl__snprintf" >&6; } -if test "x$ac_cv_have_decl__snprintf" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL__SNPRINTF 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL__SNPRINTF 0 +#define HAVE_DECL__SNPRINTF $ac_have_decl _ACEOF -fi - - - case "$gl_cv_func_snprintf_retval_c99" in *yes) -cat >>confdefs.h <<\_ACEOF -#define HAVE_SNPRINTF_RETVAL_C99 1 -_ACEOF +$as_echo "#define HAVE_SNPRINTF_RETVAL_C99 1" >>confdefs.h ;; esac @@ -18189,80 +12585,18 @@ _ACEOF - - - - { $as_echo "$as_me:$LINENO: checking whether iswblank is declared" >&5 -$as_echo_n "checking whether iswblank is declared... " >&6; } -if test "${ac_cv_have_decl_iswblank+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -#ifndef iswblank - (void) iswblank; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_iswblank=yes + ac_fn_c_check_decl "$LINENO" "iswblank" "ac_cv_have_decl_iswblank" "$ac_includes_default" +if test "x$ac_cv_have_decl_iswblank" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_iswblank=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_iswblank" >&5 -$as_echo "$ac_cv_have_decl_iswblank" >&6; } -if test "x$ac_cv_have_decl_iswblank" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_ISWBLANK 1 +#define HAVE_DECL_ISWBLANK $ac_have_decl _ACEOF -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_ISWBLANK 0 -_ACEOF - - -fi - - - - @@ -18302,17 +12636,13 @@ fi # Define an additional variable used in the Makefile substitution. if test $ac_cv_working_alloca_h = yes; then - { $as_echo "$as_me:$LINENO: checking for alloca as a compiler built-in" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5 $as_echo_n "checking for alloca as a compiler built-in... " >&6; } -if test "${gl_cv_rpl_alloca+set}" = set; then +if ${gl_cv_rpl_alloca+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined __GNUC__ || defined _AIX || defined _MSC_VER @@ -18321,7 +12651,7 @@ cat >>conftest.$ac_ext <<_ACEOF _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Need own alloca" >/dev/null 2>&1; then + $EGREP "Need own alloca" >/dev/null 2>&1; then : gl_cv_rpl_alloca=yes else gl_cv_rpl_alloca=no @@ -18330,13 +12660,11 @@ rm -f conftest* fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_rpl_alloca" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5 $as_echo "$gl_cv_rpl_alloca" >&6; } if test $gl_cv_rpl_alloca = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_ALLOCA 1 -_ACEOF +$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h ALLOCA_H=alloca.h else @@ -18380,18 +12708,14 @@ _ACEOF if test $gl_cv_have_include_next = yes; then gl_cv_next_arpa_inet_h='<'arpa/inet.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_arpa_inet_h+set}" = set; then +if ${gl_cv_next_arpa_inet_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_arpa_inet_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -18412,7 +12736,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_arpa_inet_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_arpa_inet_h" >&5 $as_echo "$gl_cv_next_arpa_inet_h" >&6; } fi NEXT_ARPA_INET_H=$gl_cv_next_arpa_inet_h @@ -18430,20 +12754,14 @@ $as_echo "$gl_cv_next_arpa_inet_h" >&6; } - - - for gl_func in inet_ntop inet_pton; do + for gl_func in inet_ntop inet_pton; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* On some systems, this header is not self-consistent. */ @@ -18461,93 +12779,26 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done - { $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; } - # Code from module base64: @@ -18576,13 +12827,13 @@ $as_echo "$MKDIR_P" >&6; } - { $as_echo "$as_me:$LINENO: checking whether btowc(0) is correct" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(0) is correct" >&5 $as_echo_n "checking whether btowc(0) is correct... " >&6; } -if test "${gl_cv_func_btowc_nul+set}" = set; then +if ${gl_cv_func_btowc_nul+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : case "$host_os" in # Guess no on Cygwin. @@ -18592,11 +12843,7 @@ else esac else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -18609,50 +12856,23 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_btowc_nul=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_btowc_nul=no + gl_cv_func_btowc_nul=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_btowc_nul" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_nul" >&5 $as_echo "$gl_cv_func_btowc_nul" >&6; } - { $as_echo "$as_me:$LINENO: checking whether btowc(EOF) is correct" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(EOF) is correct" >&5 $as_echo_n "checking whether btowc(EOF) is correct... " >&6; } -if test "${gl_cv_func_btowc_eof+set}" = set; then +if ${gl_cv_func_btowc_eof+:} false; then : $as_echo_n "(cached) " >&6 else @@ -18663,14 +12883,10 @@ else *) gl_cv_func_btowc_eof="guessing yes" ;; esac if test $LOCALE_FR != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -18687,46 +12903,19 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_btowc_eof=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_btowc_eof=no + gl_cv_func_btowc_eof=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_btowc_eof" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_eof" >&5 $as_echo "$gl_cv_func_btowc_eof" >&6; } case "$gl_cv_func_btowc_nul" in @@ -18764,9 +12953,7 @@ $as_echo "$gl_cv_func_btowc_eof" >&6; } -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_BTOWC 1 -_ACEOF +$as_echo "#define GNULIB_TEST_BTOWC 1" >>confdefs.h @@ -18782,9 +12969,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_ENVIRON 1 -_ACEOF +$as_echo "#define GNULIB_TEST_ENVIRON 1" >>confdefs.h @@ -18814,18 +12999,14 @@ _ACEOF if test $gl_cv_have_include_next = yes; then gl_cv_next_float_h='<'float.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_float_h+set}" = set; then +if ${gl_cv_next_float_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_float_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -18846,7 +13027,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_float_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5 $as_echo "$gl_cv_next_float_h" >&6; } fi NEXT_FLOAT_H=$gl_cv_next_float_h @@ -18922,9 +13103,7 @@ $as_echo "$gl_cv_next_float_h" >&6; } -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_FSEEKO 1 -_ACEOF +$as_echo "#define GNULIB_TEST_FSEEKO 1" >>confdefs.h @@ -18947,65 +13126,16 @@ _ACEOF - -for ac_header in sys/mount.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 + for ac_header in sys/mount.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/mount.h" "ac_cv_header_sys_mount_h" "$ac_includes_default #if HAVE_SYS_PARAM_H #include #endif - -#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 +" +if test "x$ac_cv_header_sys_mount_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_SYS_MOUNT_H 1 _ACEOF fi @@ -19014,7 +13144,7 @@ done -{ $as_echo "$as_me:$LINENO: checking how to get file system space usage" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to get file system space usage" >&5 $as_echo "$as_me: checking how to get file system space usage" >&6;} ac_fsusage_space=no @@ -19027,16 +13157,12 @@ ac_fsusage_space=no if test $ac_fsusage_space = no; then # glibc/{Hurd,kFreeBSD}, MacOS X >= 10.4, FreeBSD >= 5.0, NetBSD >= 3.0, # OpenBSD >= 4.4, AIX, HP-UX, IRIX, Solaris, Cygwin, Interix, BeOS. - { $as_echo "$as_me:$LINENO: checking for statvfs function (SVR4)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for statvfs function (SVR4)" >&5 $as_echo_n "checking for statvfs function (SVR4)... " >&6; } -if test "${fu_cv_sys_stat_statvfs+set}" = set; then +if ${fu_cv_sys_stat_statvfs+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #if defined __GLIBC__ && defined __linux__ @@ -19060,66 +13186,35 @@ struct statvfs fsd; statvfs (0, &fsd); 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 ac_fn_c_try_link "$LINENO"; then : fu_cv_sys_stat_statvfs=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fu_cv_sys_stat_statvfs=no + fu_cv_sys_stat_statvfs=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $fu_cv_sys_stat_statvfs" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $fu_cv_sys_stat_statvfs" >&5 $as_echo "$fu_cv_sys_stat_statvfs" >&6; } if test $fu_cv_sys_stat_statvfs = yes; then ac_fsusage_space=yes -cat >>confdefs.h <<\_ACEOF -#define STAT_STATVFS 1 -_ACEOF +$as_echo "#define STAT_STATVFS 1" >>confdefs.h fi fi if test $ac_fsusage_space = no; then # DEC Alpha running OSF/1 - { $as_echo "$as_me:$LINENO: checking for 3-argument statfs function (DEC OSF/1)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 3-argument statfs function (DEC OSF/1)" >&5 $as_echo_n "checking for 3-argument statfs function (DEC OSF/1)... " >&6; } - if test "${fu_cv_sys_stat_statfs3_osf1+set}" = set; then + if ${fu_cv_sys_stat_statfs3_osf1+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : fu_cv_sys_stat_statfs3_osf1=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -19133,52 +13228,23 @@ cat >>conftest.$ac_ext <<_ACEOF return statfs (".", &fsd, sizeof (struct statfs)) != 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 +if ac_fn_c_try_run "$LINENO"; then : fu_cv_sys_stat_statfs3_osf1=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -fu_cv_sys_stat_statfs3_osf1=no + fu_cv_sys_stat_statfs3_osf1=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi - { $as_echo "$as_me:$LINENO: result: $fu_cv_sys_stat_statfs3_osf1" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fu_cv_sys_stat_statfs3_osf1" >&5 $as_echo "$fu_cv_sys_stat_statfs3_osf1" >&6; } if test $fu_cv_sys_stat_statfs3_osf1 = yes; then ac_fsusage_space=yes -cat >>confdefs.h <<\_ACEOF -#define STAT_STATFS3_OSF1 1 -_ACEOF +$as_echo "#define STAT_STATFS3_OSF1 1" >>confdefs.h fi fi @@ -19190,19 +13256,15 @@ if test $ac_fsusage_space = no; then # (On IRIX you need to include , not only and # .) # (On Solaris, statfs has 4 arguments.) - { $as_echo "$as_me:$LINENO: checking for two-argument statfs with statfs.f_bsize member (AIX, 4.3BSD)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for two-argument statfs with statfs.f_bsize member (AIX, 4.3BSD)" >&5 $as_echo_n "checking for two-argument statfs with statfs.f_bsize member (AIX, 4.3BSD)... " >&6; } - if test "${fu_cv_sys_stat_statfs2_bsize+set}" = set; then + if ${fu_cv_sys_stat_statfs2_bsize+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : fu_cv_sys_stat_statfs2_bsize=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_SYS_PARAM_H @@ -19222,52 +13284,23 @@ cat >>conftest.$ac_ext <<_ACEOF return statfs (".", &fsd) != 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 +if ac_fn_c_try_run "$LINENO"; then : fu_cv_sys_stat_statfs2_bsize=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -fu_cv_sys_stat_statfs2_bsize=no + fu_cv_sys_stat_statfs2_bsize=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi - { $as_echo "$as_me:$LINENO: result: $fu_cv_sys_stat_statfs2_bsize" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fu_cv_sys_stat_statfs2_bsize" >&5 $as_echo "$fu_cv_sys_stat_statfs2_bsize" >&6; } if test $fu_cv_sys_stat_statfs2_bsize = yes; then ac_fsusage_space=yes -cat >>confdefs.h <<\_ACEOF -#define STAT_STATFS2_BSIZE 1 -_ACEOF +$as_echo "#define STAT_STATFS2_BSIZE 1" >>confdefs.h fi fi @@ -19275,19 +13308,15 @@ fi if test $ac_fsusage_space = no; then # SVR3 # (Solaris already handled above.) - { $as_echo "$as_me:$LINENO: checking for four-argument statfs (AIX-3.2.5, SVR3)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for four-argument statfs (AIX-3.2.5, SVR3)" >&5 $as_echo_n "checking for four-argument statfs (AIX-3.2.5, SVR3)... " >&6; } - if test "${fu_cv_sys_stat_statfs4+set}" = set; then + if ${fu_cv_sys_stat_statfs4+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : fu_cv_sys_stat_statfs4=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -19299,52 +13328,23 @@ cat >>conftest.$ac_ext <<_ACEOF return statfs (".", &fsd, sizeof fsd, 0) != 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 +if ac_fn_c_try_run "$LINENO"; then : fu_cv_sys_stat_statfs4=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -fu_cv_sys_stat_statfs4=no + fu_cv_sys_stat_statfs4=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi - { $as_echo "$as_me:$LINENO: result: $fu_cv_sys_stat_statfs4" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fu_cv_sys_stat_statfs4" >&5 $as_echo "$fu_cv_sys_stat_statfs4" >&6; } if test $fu_cv_sys_stat_statfs4 = yes; then ac_fsusage_space=yes -cat >>confdefs.h <<\_ACEOF -#define STAT_STATFS4 1 -_ACEOF +$as_echo "#define STAT_STATFS4 1" >>confdefs.h fi fi @@ -19355,19 +13355,15 @@ if test $ac_fsusage_space = no; then # (On AIX, you need to include , not only .) # (On Solaris, statfs has 4 arguments and 'struct statfs' is not declared in # .) - { $as_echo "$as_me:$LINENO: checking for two-argument statfs with statfs.f_fsize member (4.4BSD and NetBSD)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for two-argument statfs with statfs.f_fsize member (4.4BSD and NetBSD)" >&5 $as_echo_n "checking for two-argument statfs with statfs.f_fsize member (4.4BSD and NetBSD)... " >&6; } - if test "${fu_cv_sys_stat_statfs2_fsize+set}" = set; then + if ${fu_cv_sys_stat_statfs2_fsize+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : fu_cv_sys_stat_statfs2_fsize=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -19385,71 +13381,38 @@ cat >>conftest.$ac_ext <<_ACEOF return statfs (".", &fsd) != 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 +if ac_fn_c_try_run "$LINENO"; then : fu_cv_sys_stat_statfs2_fsize=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -fu_cv_sys_stat_statfs2_fsize=no + fu_cv_sys_stat_statfs2_fsize=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi - { $as_echo "$as_me:$LINENO: result: $fu_cv_sys_stat_statfs2_fsize" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fu_cv_sys_stat_statfs2_fsize" >&5 $as_echo "$fu_cv_sys_stat_statfs2_fsize" >&6; } if test $fu_cv_sys_stat_statfs2_fsize = yes; then ac_fsusage_space=yes -cat >>confdefs.h <<\_ACEOF -#define STAT_STATFS2_FSIZE 1 -_ACEOF +$as_echo "#define STAT_STATFS2_FSIZE 1" >>confdefs.h fi fi if test $ac_fsusage_space = no; then # Ultrix - { $as_echo "$as_me:$LINENO: checking for two-argument statfs with struct fs_data (Ultrix)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for two-argument statfs with struct fs_data (Ultrix)" >&5 $as_echo_n "checking for two-argument statfs with struct fs_data (Ultrix)... " >&6; } - if test "${fu_cv_sys_stat_fs_data+set}" = set; then + if ${fu_cv_sys_stat_fs_data+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : fu_cv_sys_stat_fs_data=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -19471,52 +13434,23 @@ cat >>conftest.$ac_ext <<_ACEOF return statfs (".", &fsd) != 1; } _ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then +if ac_fn_c_try_run "$LINENO"; then : fu_cv_sys_stat_fs_data=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -fu_cv_sys_stat_fs_data=no + fu_cv_sys_stat_fs_data=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi - { $as_echo "$as_me:$LINENO: result: $fu_cv_sys_stat_fs_data" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fu_cv_sys_stat_fs_data" >&5 $as_echo "$fu_cv_sys_stat_fs_data" >&6; } if test $fu_cv_sys_stat_fs_data = yes; then ac_fsusage_space=yes -cat >>confdefs.h <<\_ACEOF -#define STAT_STATFS2_FS_DATA 1 -_ACEOF +$as_echo "#define STAT_STATFS2_FS_DATA 1" >>confdefs.h fi fi @@ -19524,56 +13458,27 @@ fi if test $ac_fsusage_space = no; then # SVR2 # (AIX, HP-UX, OSF/1 already handled above.) - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* 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 +if ac_fn_c_try_cpp "$LINENO"; then : -cat >>confdefs.h <<\_ACEOF -#define STAT_READ_FILSYS 1 -_ACEOF +$as_echo "#define STAT_READ_FILSYS 1" >>confdefs.h ac_fsusage_space=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -f conftest.err conftest.$ac_ext +rm -f conftest.err conftest.i conftest.$ac_ext fi -if test $ac_fsusage_space = yes; then +if test $ac_fsusage_space = yes; then : gl_cv_fs_space=yes else gl_cv_fs_space=no fi - if test $gl_cv_fs_space = yes; then @@ -19586,147 +13491,11 @@ fi gl_LIBOBJS="$gl_LIBOBJS fsusage.$ac_objext" - - - - -for ac_header in dustat.h sys/fs/s5param.h sys/filsys.h sys/statfs.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;} - - ;; -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 + for ac_header in dustat.h sys/fs/s5param.h sys/filsys.h sys/statfs.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -19736,16 +13505,12 @@ fi done - { $as_echo "$as_me:$LINENO: checking for statfs that truncates block counts" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for statfs that truncates block counts" >&5 $as_echo_n "checking for statfs that truncates block counts... " >&6; } - if test "${fu_cv_sys_truncating_statfs+set}" = set; then + if ${fu_cv_sys_truncating_statfs+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if !defined(sun) && !defined(__sun) @@ -19762,43 +13527,20 @@ struct statfs t; long c = *(t.f_spare); 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 +if ac_fn_c_try_compile "$LINENO"; then : fu_cv_sys_truncating_statfs=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fu_cv_sys_truncating_statfs=no + fu_cv_sys_truncating_statfs=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi if test $fu_cv_sys_truncating_statfs = yes; then -cat >>confdefs.h <<\_ACEOF -#define STATFS_TRUNCATES_BLOCK_COUNTS 1 -_ACEOF +$as_echo "#define STATFS_TRUNCATES_BLOCK_COUNTS 1" >>confdefs.h fi - { $as_echo "$as_me:$LINENO: result: $fu_cv_sys_truncating_statfs" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $fu_cv_sys_truncating_statfs" >&5 $as_echo "$fu_cv_sys_truncating_statfs" >&6; } @@ -19812,17 +13554,13 @@ $as_echo "$fu_cv_sys_truncating_statfs" >&6; } - { $as_echo "$as_me:$LINENO: checking for ftello" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ftello" >&5 $as_echo_n "checking for ftello... " >&6; } -if test "${gl_cv_func_ftello+set}" = set; then +if ${gl_cv_func_ftello+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -19833,41 +13571,16 @@ ftello (stdin); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_func_ftello=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_ftello=no + gl_cv_func_ftello=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_ftello" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ftello" >&5 $as_echo "$gl_cv_func_ftello" >&6; } if test $gl_cv_func_ftello = no; then HAVE_FTELLO=0 @@ -19876,9 +13589,9 @@ $as_echo "$gl_cv_func_ftello" >&6; } REPLACE_FTELLO=1 else - { $as_echo "$as_me:$LINENO: checking whether ftello works" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ftello works" >&5 $as_echo_n "checking whether ftello works... " >&6; } -if test "${gl_cv_func_ftello_works+set}" = set; then +if ${gl_cv_func_ftello_works+:} false; then : $as_echo_n "(cached) " >&6 else @@ -19888,14 +13601,10 @@ else # Guess yes otherwise. *) gl_cv_func_ftello_works="guessing yes" ;; esac - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -19956,54 +13665,25 @@ main (void) 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_ftello_works=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_ftello_works=no + gl_cv_func_ftello_works=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_ftello_works" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ftello_works" >&5 $as_echo "$gl_cv_func_ftello_works" >&6; } case "$gl_cv_func_ftello_works" in *yes) ;; *) REPLACE_FTELLO=1 -cat >>confdefs.h <<\_ACEOF -#define FTELLO_BROKEN_AFTER_SWITCHING_FROM_READ_TO_WRITE 1 -_ACEOF +$as_echo "#define FTELLO_BROKEN_AFTER_SWITCHING_FROM_READ_TO_WRITE 1" >>confdefs.h ;; esac @@ -20031,9 +13711,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_FTELLO 1 -_ACEOF +$as_echo "#define GNULIB_TEST_FTELLO 1" >>confdefs.h @@ -20061,102 +13739,12 @@ _ACEOF gl_LIBOBJS="$gl_LIBOBJS ftruncate.$ac_objext" - -for ac_func in chsize -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in chsize +do : + ac_fn_c_check_func "$LINENO" "chsize" "ac_cv_func_chsize" +if test "x$ac_cv_func_chsize" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_CHSIZE 1 _ACEOF fi @@ -20171,21 +13759,14 @@ done # If someone lacks ftruncate, make configure fail, and request # a bug report to inform us about it. if test x"$SKIP_FTRUNCATE_CHECK" != xyes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: Your system lacks the ftruncate function. - Please report this, along with the output of \"uname -a\", to the - bug-coreutils@gnu.org mailing list. To continue past this point, - rerun configure with SKIP_FTRUNCATE_CHECK=yes. - E.g., ./configure SKIP_FTRUNCATE_CHECK=yes -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: Your system lacks the ftruncate function. +as_fn_error $? "Your system lacks the ftruncate function. Please report this, along with the output of \"uname -a\", to the bug-coreutils@gnu.org mailing list. To continue past this point, rerun configure with SKIP_FTRUNCATE_CHECK=yes. E.g., ./configure SKIP_FTRUNCATE_CHECK=yes -See \`config.log' for more details." >&2;} - { (exit 1); exit 1; }; }; } +See \`config.log' for more details" "$LINENO" 5; } fi esac fi @@ -20197,9 +13778,7 @@ See \`config.log' for more details." >&2;} -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_FTRUNCATE 1 -_ACEOF +$as_echo "#define GNULIB_TEST_FTRUNCATE 1" >>confdefs.h @@ -20207,22 +13786,18 @@ _ACEOF # Code from module full-write: # Code from module getaddrinfo: - { $as_echo "$as_me:$LINENO: checking how to do getaddrinfo, freeaddrinfo and getnameinfo" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to do getaddrinfo, freeaddrinfo and getnameinfo" >&5 $as_echo "$as_me: checking how to do getaddrinfo, freeaddrinfo and getnameinfo" >&6;} GETADDRINFO_LIB= gai_saved_LIBS="$LIBS" - { $as_echo "$as_me:$LINENO: checking for library containing getaddrinfo" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getaddrinfo" >&5 $as_echo_n "checking for library containing getaddrinfo... " >&6; } -if test "${ac_cv_search_getaddrinfo+set}" = set; then +if ${ac_cv_search_getaddrinfo+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -20247,54 +13822,27 @@ for ac_lib in '' socket network net; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_getaddrinfo=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_getaddrinfo+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_getaddrinfo+:} false; then : break fi done -if test "${ac_cv_search_getaddrinfo+set}" = set; then - : +if ${ac_cv_search_getaddrinfo+:} false; then : + else ac_cv_search_getaddrinfo=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_getaddrinfo" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getaddrinfo" >&5 $as_echo "$ac_cv_search_getaddrinfo" >&6; } ac_res=$ac_cv_search_getaddrinfo -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" if test "$ac_cv_search_getaddrinfo" != "none required"; then GETADDRINFO_LIB="$ac_cv_search_getaddrinfo" @@ -20303,17 +13851,13 @@ fi LIBS="$gai_saved_LIBS $GETADDRINFO_LIB" - { $as_echo "$as_me:$LINENO: checking for getaddrinfo" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5 $as_echo_n "checking for getaddrinfo... " >&6; } -if test "${gl_cv_func_getaddrinfo+set}" = set; then +if ${gl_cv_func_getaddrinfo+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -20333,56 +13877,27 @@ getaddrinfo("", "", NULL, NULL); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_func_getaddrinfo=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_getaddrinfo=no + gl_cv_func_getaddrinfo=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_getaddrinfo" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getaddrinfo" >&5 $as_echo "$gl_cv_func_getaddrinfo" >&6; } if test $gl_cv_func_getaddrinfo = no; then - { $as_echo "$as_me:$LINENO: checking for getaddrinfo in ws2tcpip.h and -lws2_32" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo in ws2tcpip.h and -lws2_32" >&5 $as_echo_n "checking for getaddrinfo in ws2tcpip.h and -lws2_32... " >&6; } -if test "${gl_cv_w32_getaddrinfo+set}" = set; then +if ${gl_cv_w32_getaddrinfo+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_w32_getaddrinfo=no am_save_LIBS="$LIBS" LIBS="$LIBS -lws2_32" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_WS2TCPIP_H @@ -20398,42 +13913,15 @@ getaddrinfo(NULL, NULL, NULL, NULL); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_w32_getaddrinfo=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS="$am_save_LIBS" fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_w32_getaddrinfo" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_getaddrinfo" >&5 $as_echo "$gl_cv_w32_getaddrinfo" >&6; } if test "$gl_cv_w32_getaddrinfo" = "yes"; then GETADDRINFO_LIB="-lws2_32" @@ -20455,17 +13943,13 @@ $as_echo "$gl_cv_w32_getaddrinfo" >&6; } # We can't use AC_REPLACE_FUNCS here because gai_strerror may be an # inline function declared in ws2tcpip.h, so we need to get that # header included somehow. - { $as_echo "$as_me:$LINENO: checking for gai_strerror (possibly via ws2tcpip.h)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gai_strerror (possibly via ws2tcpip.h)" >&5 $as_echo_n "checking for gai_strerror (possibly via ws2tcpip.h)... " >&6; } -if test "${gl_cv_func_gai_strerror+set}" = set; then +if ${gl_cv_func_gai_strerror+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -20488,40 +13972,15 @@ gai_strerror (NULL); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_func_gai_strerror=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_gai_strerror=no + gl_cv_func_gai_strerror=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_gai_strerror" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gai_strerror" >&5 $as_echo "$gl_cv_func_gai_strerror" >&6; } if test $gl_cv_func_gai_strerror = no; then @@ -20546,104 +14005,9 @@ $as_echo "$gl_cv_func_gai_strerror" >&6; } - { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5 -$as_echo_n "checking for struct sockaddr.sa_len... " >&6; } -if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -static struct sockaddr ac_aggr; -if (ac_aggr.sa_len) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_sockaddr_sa_len=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -static struct sockaddr ac_aggr; -if (sizeof ac_aggr.sa_len) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_member_struct_sockaddr_sa_len=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_member_struct_sockaddr_sa_len=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5 -$as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; } -if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then + ac_fn_c_check_member "$LINENO" "struct sockaddr" "sa_len" "ac_cv_member_struct_sockaddr_sa_len" "#include +" +if test "x$ac_cv_member_struct_sockaddr_sa_len" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_STRUCT_SOCKADDR_SA_LEN 1 @@ -20661,18 +14025,7 @@ fi - { $as_echo "$as_me:$LINENO: checking whether getaddrinfo is declared" >&5 -$as_echo_n "checking whether getaddrinfo is declared... " >&6; } -if test "${ac_cv_have_decl_getaddrinfo+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + ac_fn_c_check_decl "$LINENO" "getaddrinfo" "ac_cv_have_decl_getaddrinfo" " /* sys/types.h is not needed according to POSIX, but the sys/socket.h in i386-unknown-freebsd4.10 and powerpc-apple-darwin5.5 required it. */ @@ -20687,74 +14040,17 @@ cat >>conftest.$ac_ext <<_ACEOF #include #endif - -int -main () -{ -#ifndef getaddrinfo - (void) getaddrinfo; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_getaddrinfo=yes +" +if test "x$ac_cv_have_decl_getaddrinfo" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_getaddrinfo=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_getaddrinfo" >&5 -$as_echo "$ac_cv_have_decl_getaddrinfo" >&6; } -if test "x$ac_cv_have_decl_getaddrinfo" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETADDRINFO 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETADDRINFO 0 +#define HAVE_DECL_GETADDRINFO $ac_have_decl _ACEOF - - -fi -{ $as_echo "$as_me:$LINENO: checking whether freeaddrinfo is declared" >&5 -$as_echo_n "checking whether freeaddrinfo is declared... " >&6; } -if test "${ac_cv_have_decl_freeaddrinfo+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_fn_c_check_decl "$LINENO" "freeaddrinfo" "ac_cv_have_decl_freeaddrinfo" " /* sys/types.h is not needed according to POSIX, but the sys/socket.h in i386-unknown-freebsd4.10 and powerpc-apple-darwin5.5 required it. */ @@ -20769,74 +14065,17 @@ cat >>conftest.$ac_ext <<_ACEOF #include #endif - -int -main () -{ -#ifndef freeaddrinfo - (void) freeaddrinfo; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_freeaddrinfo=yes +" +if test "x$ac_cv_have_decl_freeaddrinfo" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_freeaddrinfo=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_freeaddrinfo" >&5 -$as_echo "$ac_cv_have_decl_freeaddrinfo" >&6; } -if test "x$ac_cv_have_decl_freeaddrinfo" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_FREEADDRINFO 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_FREEADDRINFO 0 -_ACEOF - - -fi -{ $as_echo "$as_me:$LINENO: checking whether gai_strerror is declared" >&5 -$as_echo_n "checking whether gai_strerror is declared... " >&6; } -if test "${ac_cv_have_decl_gai_strerror+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +#define HAVE_DECL_FREEADDRINFO $ac_have_decl _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - +ac_fn_c_check_decl "$LINENO" "gai_strerror" "ac_cv_have_decl_gai_strerror" " /* sys/types.h is not needed according to POSIX, but the sys/socket.h in i386-unknown-freebsd4.10 and powerpc-apple-darwin5.5 required it. */ @@ -20851,74 +14090,17 @@ cat >>conftest.$ac_ext <<_ACEOF #include #endif - -int -main () -{ -#ifndef gai_strerror - (void) gai_strerror; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_gai_strerror=yes +" +if test "x$ac_cv_have_decl_gai_strerror" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_gai_strerror=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_gai_strerror" >&5 -$as_echo "$ac_cv_have_decl_gai_strerror" >&6; } -if test "x$ac_cv_have_decl_gai_strerror" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GAI_STRERROR 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GAI_STRERROR 0 -_ACEOF - - -fi -{ $as_echo "$as_me:$LINENO: checking whether getnameinfo is declared" >&5 -$as_echo_n "checking whether getnameinfo is declared... " >&6; } -if test "${ac_cv_have_decl_getnameinfo+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +#define HAVE_DECL_GAI_STRERROR $ac_have_decl _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - +ac_fn_c_check_decl "$LINENO" "getnameinfo" "ac_cv_have_decl_getnameinfo" " /* sys/types.h is not needed according to POSIX, but the sys/socket.h in i386-unknown-freebsd4.10 and powerpc-apple-darwin5.5 required it. */ @@ -20933,64 +14115,17 @@ cat >>conftest.$ac_ext <<_ACEOF #include #endif - -int -main () -{ -#ifndef getnameinfo - (void) getnameinfo; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_getnameinfo=yes +" +if test "x$ac_cv_have_decl_getnameinfo" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_getnameinfo=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_getnameinfo" >&5 -$as_echo "$ac_cv_have_decl_getnameinfo" >&6; } -if test "x$ac_cv_have_decl_getnameinfo" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETNAMEINFO 1 +#define HAVE_DECL_GETNAMEINFO $ac_have_decl _ACEOF - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_GETNAMEINFO 0 -_ACEOF - - -fi - - if test $ac_cv_have_decl_getaddrinfo = no; then HAVE_DECL_GETADDRINFO=0 fi @@ -21004,65 +14139,7 @@ fi HAVE_DECL_GETNAMEINFO=0 fi - { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5 -$as_echo_n "checking for struct addrinfo... " >&6; } -if test "${ac_cv_type_struct_addrinfo+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_struct_addrinfo=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_NETDB_H -#include -#endif -#ifdef HAVE_WS2TCPIP_H -#include -#endif - - -int -main () -{ -if (sizeof (struct addrinfo)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + ac_fn_c_check_type "$LINENO" "struct addrinfo" "ac_cv_type_struct_addrinfo" " #include #ifdef HAVE_SYS_SOCKET_H #include @@ -21074,55 +14151,8 @@ cat >>conftest.$ac_ext <<_ACEOF #include #endif - -int -main () -{ -if (sizeof ((struct addrinfo))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_struct_addrinfo=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5 -$as_echo "$ac_cv_type_struct_addrinfo" >&6; } -if test "x$ac_cv_type_struct_addrinfo" = x""yes; then +" +if test "x$ac_cv_type_struct_addrinfo" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_STRUCT_ADDRINFO 1 @@ -21167,9 +14197,7 @@ fi -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_GETOPT_GNU 1 -_ACEOF +$as_echo "#define GNULIB_TEST_GETOPT_GNU 1" >>confdefs.h # Code from module getopt-posix: @@ -21178,15 +14206,13 @@ _ACEOF - if test -n "$gl_replace_getopt"; then + if test -n "$gl_replace_getopt"; then : GETOPT_H=getopt.h -cat >>confdefs.h <<\_ACEOF -#define __GETOPT_PREFIX rpl_ -_ACEOF +$as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h @@ -21225,7 +14251,6 @@ _ACEOF fi - # Code from module gettext-h: @@ -21256,248 +14281,24 @@ fi gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext" - -for ac_header in sys/timeb.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;} - - ;; -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 + for ac_header in sys/timeb.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_timeb_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_SYS_TIMEB_H 1 _ACEOF fi done - -for ac_func in _ftime -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in _ftime +do : + ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime" +if test "x$ac_cv_func__ftime" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE__FTIME 1 _ACEOF fi @@ -21508,19 +14309,15 @@ done - { $as_echo "$as_me:$LINENO: checking whether gettimeofday clobbers localtime buffer" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; } -if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then +if ${gl_cv_func_gettimeofday_clobber+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : gl_cv_func_gettimeofday_clobber=yes else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -21544,44 +14341,17 @@ main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_gettimeofday_clobber=no 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 ) -gl_cv_func_gettimeofday_clobber=yes + gl_cv_func_gettimeofday_clobber=yes fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_gettimeofday_clobber" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; } if test $gl_cv_func_gettimeofday_clobber = yes; then @@ -21598,248 +14368,24 @@ $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; } gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext" - -for ac_header in sys/timeb.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;} - - ;; -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 + for ac_header in sys/timeb.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_timeb_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_SYS_TIMEB_H 1 _ACEOF fi done - -for ac_func in _ftime -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in _ftime +do : + ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime" +if test "x$ac_cv_func__ftime" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE__FTIME 1 _ACEOF fi @@ -21847,33 +14393,23 @@ done -cat >>confdefs.h <<\_ACEOF -#define gmtime rpl_gmtime -_ACEOF +$as_echo "#define gmtime rpl_gmtime" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define localtime rpl_localtime -_ACEOF +$as_echo "#define localtime rpl_localtime" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1 -_ACEOF +$as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h fi - { $as_echo "$as_me:$LINENO: checking for gettimeofday with POSIX signature" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; } -if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then +if ${gl_cv_func_gettimeofday_posix_signature+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include struct timeval c; @@ -21896,34 +14432,10 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_func_gettimeofday_posix_signature=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int gettimeofday (struct timeval *restrict, struct timezone *restrict); @@ -21936,38 +14448,16 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_func_gettimeofday_posix_signature=almost else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_gettimeofday_posix_signature=no + gl_cv_func_gettimeofday_posix_signature=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_gettimeofday_posix_signature" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; } if test $gl_cv_func_gettimeofday_posix_signature = almost; then gl_gettimeofday_timezone='struct timezone' @@ -21984,252 +14474,28 @@ $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; } gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext" + for ac_header in sys/timeb.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default" +if test "x$ac_cv_header_sys_timeb_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SYS_TIMEB_H 1 +_ACEOF -for ac_header in sys/timeb.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> + +done + + for ac_func in _ftime +do : + ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime" +if test "x$ac_cv_func__ftime" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE__FTIME 1 _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;} - - ;; -esac -{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 -$as_echo_n "checking for $ac_header... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - eval "$as_ac_Header=\$ac_header_preproc" -fi -ac_res=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - -fi -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 -_ACEOF - -fi - -done - - -for ac_func in _ftime -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - -fi -done +done fi @@ -22247,9 +14513,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_GETTIMEOFDAY 1 -_ACEOF +$as_echo "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h @@ -22258,17 +14522,13 @@ _ACEOF HOSTENT_LIB= gl_saved_libs="$LIBS" - { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5 $as_echo_n "checking for library containing gethostbyname... " >&6; } -if test "${ac_cv_search_gethostbyname+set}" = set; then +if ${ac_cv_search_gethostbyname+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -22293,54 +14553,27 @@ for ac_lib in '' nsl network net; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_gethostbyname=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_gethostbyname+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_gethostbyname+:} false; then : break fi done -if test "${ac_cv_search_gethostbyname+set}" = set; then - : +if ${ac_cv_search_gethostbyname+:} false; then : + else ac_cv_search_gethostbyname=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5 $as_echo "$ac_cv_search_gethostbyname" >&6; } ac_res=$ac_cv_search_gethostbyname -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" if test "$ac_cv_search_gethostbyname" != "none required"; then HOSTENT_LIB="$ac_cv_search_gethostbyname" @@ -22349,119 +14582,25 @@ fi LIBS="$gl_saved_libs" if test -z "$HOSTENT_LIB"; then - -for ac_func in gethostbyname -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in gethostbyname +do : + ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" +if test "x$ac_cv_func_gethostbyname" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETHOSTBYNAME 1 _ACEOF else - { $as_echo "$as_me:$LINENO: checking for gethostbyname in winsock2.h and -lws2_32" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in winsock2.h and -lws2_32" >&5 $as_echo_n "checking for gethostbyname in winsock2.h and -lws2_32... " >&6; } -if test "${gl_cv_w32_gethostbyname+set}" = set; then +if ${gl_cv_w32_gethostbyname+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_w32_gethostbyname=no gl_save_LIBS="$LIBS" LIBS="$LIBS -lws2_32" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_WINSOCK2_H @@ -22477,42 +14616,15 @@ gethostbyname(NULL); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_w32_gethostbyname=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS="$gl_save_LIBS" fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_w32_gethostbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_gethostbyname" >&5 $as_echo "$gl_cv_w32_gethostbyname" >&6; } if test "$gl_cv_w32_gethostbyname" = "yes"; then HOSTENT_LIB="-lws2_32" @@ -22534,17 +14646,13 @@ done gl_save_LIBS=$LIBS - { $as_echo "$as_me:$LINENO: checking for library containing inet_ntop" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5 $as_echo_n "checking for library containing inet_ntop... " >&6; } -if test "${ac_cv_search_inet_ntop+set}" = set; then +if ${ac_cv_search_inet_ntop+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -22569,54 +14677,27 @@ for ac_lib in '' nsl; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_inet_ntop=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_inet_ntop+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inet_ntop+:} false; then : break fi done -if test "${ac_cv_search_inet_ntop+set}" = set; then - : +if ${ac_cv_search_inet_ntop+:} false; then : + else ac_cv_search_inet_ntop=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_inet_ntop" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5 $as_echo "$ac_cv_search_inet_ntop" >&6; } ac_res=$ac_cv_search_inet_ntop -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" else @@ -22628,102 +14709,12 @@ else - -for ac_func in inet_ntop -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in inet_ntop +do : + ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" +if test "x$ac_cv_func_inet_ntop" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_INET_NTOP 1 _ACEOF else @@ -22745,76 +14736,18 @@ fi - { $as_echo "$as_me:$LINENO: checking whether inet_ntop is declared" >&5 -$as_echo_n "checking whether inet_ntop is declared... " >&6; } -if test "${ac_cv_have_decl_inet_ntop+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 - -int -main () -{ -#ifndef inet_ntop - (void) inet_ntop; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_inet_ntop=yes + ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include +" +if test "x$ac_cv_have_decl_inet_ntop" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_inet_ntop=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_inet_ntop" >&5 -$as_echo "$ac_cv_have_decl_inet_ntop" >&6; } -if test "x$ac_cv_have_decl_inet_ntop" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_INET_NTOP 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_INET_NTOP 0 +#define HAVE_DECL_INET_NTOP $ac_have_decl _ACEOF - -fi - - if test $ac_cv_have_decl_inet_ntop = no; then HAVE_DECL_INET_NTOP=0 fi @@ -22837,17 +14770,13 @@ fi gl_save_LIBS=$LIBS - { $as_echo "$as_me:$LINENO: checking for library containing inet_pton" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5 $as_echo_n "checking for library containing inet_pton... " >&6; } -if test "${ac_cv_search_inet_pton+set}" = set; then +if ${ac_cv_search_inet_pton+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -22872,54 +14801,27 @@ for ac_lib in '' nsl; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_inet_pton=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_inet_pton+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_inet_pton+:} false; then : break fi done -if test "${ac_cv_search_inet_pton+set}" = set; then - : +if ${ac_cv_search_inet_pton+:} false; then : + else ac_cv_search_inet_pton=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_inet_pton" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5 $as_echo "$ac_cv_search_inet_pton" >&6; } ac_res=$ac_cv_search_inet_pton -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" else @@ -22931,102 +14833,12 @@ else - -for ac_func in inet_pton -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in inet_pton +do : + ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton" +if test "x$ac_cv_func_inet_pton" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_INET_PTON 1 _ACEOF else @@ -23048,76 +14860,18 @@ fi - { $as_echo "$as_me:$LINENO: checking whether inet_pton is declared" >&5 -$as_echo_n "checking whether inet_pton is declared... " >&6; } -if test "${ac_cv_have_decl_inet_pton+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 - -int -main () -{ -#ifndef inet_pton - (void) inet_pton; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_inet_pton=yes + ac_fn_c_check_decl "$LINENO" "inet_pton" "ac_cv_have_decl_inet_pton" "#include +" +if test "x$ac_cv_have_decl_inet_pton" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_inet_pton=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_inet_pton" >&5 -$as_echo "$ac_cv_have_decl_inet_pton" >&6; } -if test "x$ac_cv_have_decl_inet_pton" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_INET_PTON 1 -_ACEOF - - -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_INET_PTON 0 +#define HAVE_DECL_INET_PTON $ac_have_decl _ACEOF - -fi - - if test $ac_cv_have_decl_inet_pton = no; then HAVE_DECL_INET_PTON=0 fi @@ -23152,18 +14906,14 @@ fi if test $gl_cv_have_include_next = yes; then gl_cv_next_langinfo_h='<'langinfo.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_langinfo_h+set}" = set; then +if ${gl_cv_next_langinfo_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_langinfo_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -23184,7 +14934,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_langinfo_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_langinfo_h" >&5 $as_echo "$gl_cv_next_langinfo_h" >&6; } fi NEXT_LANGINFO_H=$gl_cv_next_langinfo_h @@ -23212,16 +14962,12 @@ $as_echo "$gl_cv_next_langinfo_h" >&6; } if test $ac_cv_header_langinfo_h = yes; then HAVE_LANGINFO_H=1 - { $as_echo "$as_me:$LINENO: checking whether langinfo.h defines CODESET" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines CODESET" >&5 $as_echo_n "checking whether langinfo.h defines CODESET... " >&6; } -if test "${gl_cv_header_langinfo_codeset+set}" = set; then +if ${gl_cv_header_langinfo_codeset+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int a = CODESET; @@ -23234,50 +14980,25 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_header_langinfo_codeset=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_header_langinfo_codeset=no + gl_cv_header_langinfo_codeset=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_langinfo_codeset" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_codeset" >&5 $as_echo "$gl_cv_header_langinfo_codeset" >&6; } if test $gl_cv_header_langinfo_codeset = yes; then HAVE_LANGINFO_CODESET=1 fi - { $as_echo "$as_me:$LINENO: checking whether langinfo.h defines ERA" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines ERA" >&5 $as_echo_n "checking whether langinfo.h defines ERA... " >&6; } -if test "${gl_cv_header_langinfo_era+set}" = set; then +if ${gl_cv_header_langinfo_era+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int a = ERA; @@ -23290,36 +15011,15 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_header_langinfo_era=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_header_langinfo_era=no + gl_cv_header_langinfo_era=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_langinfo_era" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_era" >&5 $as_echo "$gl_cv_header_langinfo_era" >&6; } if test $gl_cv_header_langinfo_era = yes; then HAVE_LANGINFO_ERA=1 @@ -23332,19 +15032,14 @@ $as_echo "$gl_cv_header_langinfo_era" >&6; } - - for gl_func in nl_langinfo; do + for gl_func in nl_langinfo; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -23357,48 +15052,23 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done @@ -23425,164 +15095,39 @@ fi if test "$gl_threads_api" = posix; then # OSF/1 4.0 and MacOS X 10.1 lack the pthread_rwlock_t type and the # pthread_rwlock_* functions. - { $as_echo "$as_me:$LINENO: checking for pthread_rwlock_t" >&5 -$as_echo_n "checking for pthread_rwlock_t... " >&6; } -if test "${ac_cv_type_pthread_rwlock_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_pthread_rwlock_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + ac_fn_c_check_type "$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include +" +if test "x$ac_cv_type_pthread_rwlock_t" = xyes; then : + +$as_echo "#define HAVE_PTHREAD_RWLOCK 1" >>confdefs.h + +fi + + # glibc defines PTHREAD_MUTEX_RECURSIVE as enum, not as a macro. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + #include int main () { -if (sizeof (pthread_rwlock_t)) - return 0; + +#if __FreeBSD__ == 4 +error "No, in FreeBSD 4.0 recursive mutexes actually don't work." +#else +int x = (int)PTHREAD_MUTEX_RECURSIVE; +return !x; +#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 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -if (sizeof ((pthread_rwlock_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_pthread_rwlock_t=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_pthread_rwlock_t" >&5 -$as_echo "$ac_cv_type_pthread_rwlock_t" >&6; } -if test "x$ac_cv_type_pthread_rwlock_t" = x""yes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_PTHREAD_RWLOCK 1 -_ACEOF - -fi - - # glibc defines PTHREAD_MUTEX_RECURSIVE as enum, not as a macro. - cat >conftest.$ac_ext <<_ACEOF - - /* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ - -#if __FreeBSD__ == 4 -error "No, in FreeBSD 4.0 recursive mutexes actually don't work." -#else -int x = (int)PTHREAD_MUTEX_RECURSIVE; -return !x; -#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 - -cat >>confdefs.h <<\_ACEOF -#define HAVE_PTHREAD_MUTEX_RECURSIVE 1 -_ACEOF - -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +if ac_fn_c_try_compile "$LINENO"; then : +$as_echo "#define HAVE_PTHREAD_MUTEX_RECURSIVE 1" >>confdefs.h fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi @@ -23593,17 +15138,13 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - { $as_echo "$as_me:$LINENO: checking whether lseek detects pipes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lseek detects pipes" >&5 $as_echo_n "checking whether lseek detects pipes... " >&6; } -if test "${gl_cv_func_lseek_pipe+set}" = set; then +if ${gl_cv_func_lseek_pipe+:} false; then : $as_echo_n "(cached) " >&6 else if test $cross_compiling = no; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include /* for off_t */ @@ -23620,27 +15161,7 @@ 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 ac_fn_c_try_link "$LINENO"; then : if test -s conftest$ac_exeext \ && ./conftest$ac_exeext < conftest.$ac_ext \ && test 1 = "`echo hi \ @@ -23650,21 +15171,12 @@ $as_echo "$ac_try_echo") >&5 gl_cv_func_lseek_pipe=no fi else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_lseek_pipe=no + gl_cv_func_lseek_pipe=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if ((defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__) || defined __BEOS__ @@ -23672,36 +15184,15 @@ cat >>conftest.$ac_ext <<_ACEOF Choke me. #endif _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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_func_lseek_pipe=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_func_lseek_pipe=no + gl_cv_func_lseek_pipe=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_lseek_pipe" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lseek_pipe" >&5 $as_echo "$gl_cv_func_lseek_pipe" >&6; } if test $gl_cv_func_lseek_pipe = no; then @@ -23718,9 +15209,7 @@ $as_echo "$gl_cv_func_lseek_pipe" >&6; } REPLACE_LSEEK=1 -cat >>confdefs.h <<\_ACEOF -#define LSEEK_PIPE_BROKEN 1 -_ACEOF +$as_echo "#define LSEEK_PIPE_BROKEN 1" >>confdefs.h fi @@ -23732,9 +15221,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_LSEEK 1 -_ACEOF +$as_echo "#define GNULIB_TEST_LSEEK 1" >>confdefs.h @@ -23766,174 +15253,34 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_LSTAT 1 -_ACEOF +$as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h # Code from module malloc-gnu: - -for ac_header in 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;} - - ;; -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 + for ac_header in stdlib.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default" +if test "x$ac_cv_header_stdlib_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_STDLIB_H 1 _ACEOF fi done -{ $as_echo "$as_me:$LINENO: checking for GNU libc compatible malloc" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5 $as_echo_n "checking for GNU libc compatible malloc... " >&6; } -if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then +if ${ac_cv_func_malloc_0_nonnull+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : ac_cv_func_malloc_0_nonnull=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include @@ -23949,55 +15296,24 @@ return ! malloc (0); 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 +if ac_fn_c_try_run "$LINENO"; then : ac_cv_func_malloc_0_nonnull=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_func_malloc_0_nonnull=no + ac_cv_func_malloc_0_nonnull=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_malloc_0_nonnull" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; } -if test $ac_cv_func_malloc_0_nonnull = yes; then +if test $ac_cv_func_malloc_0_nonnull = yes; then : -cat >>confdefs.h <<\_ACEOF -#define HAVE_MALLOC_GNU 1 -_ACEOF +$as_echo "#define HAVE_MALLOC_GNU 1" >>confdefs.h else - cat >>confdefs.h <<\_ACEOF -#define HAVE_MALLOC_GNU 0 -_ACEOF + $as_echo "#define HAVE_MALLOC_GNU 0" >>confdefs.h @@ -24018,7 +15334,6 @@ fi - cat >>confdefs.h <<_ACEOF #define GNULIB_MALLOC_GNU 1 _ACEOF @@ -24030,9 +15345,7 @@ _ACEOF if test $gl_cv_func_malloc_posix = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_MALLOC_POSIX 1 -_ACEOF +$as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h else @@ -24057,9 +15370,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_MALLOC_POSIX 1 -_ACEOF +$as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h @@ -24090,9 +15401,9 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking whether mbrtowc handles incomplete characters" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; } -if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then +if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then : $as_echo_n "(cached) " >&6 else @@ -24103,14 +15414,10 @@ else *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;; esac if test $LOCALE_JA != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -24132,54 +15439,27 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_mbrtowc_incomplete_state=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_mbrtowc_incomplete_state=no + gl_cv_func_mbrtowc_incomplete_state=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_incomplete_state" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; } - { $as_echo "$as_me:$LINENO: checking whether mbrtowc works as well as mbtowc" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; } -if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then +if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then : $as_echo_n "(cached) " >&6 else @@ -24190,14 +15470,10 @@ else *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;; esac if test $LOCALE_ZH_CN != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -24223,46 +15499,19 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_mbrtowc_sanitycheck=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_mbrtowc_sanitycheck=no + gl_cv_func_mbrtowc_sanitycheck=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_sanitycheck" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; } REPLACE_MBSTATE_T=0 @@ -24300,9 +15549,9 @@ $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; } - { $as_echo "$as_me:$LINENO: checking whether mbrtowc handles a NULL string argument" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5 $as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; } -if test "${gl_cv_func_mbrtowc_null_arg+set}" = set; then +if ${gl_cv_func_mbrtowc_null_arg+:} false; then : $as_echo_n "(cached) " >&6 else @@ -24313,14 +15562,10 @@ else *) gl_cv_func_mbrtowc_null_arg="guessing yes" ;; esac if test $LOCALE_FR_UTF8 != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -24344,55 +15589,28 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_mbrtowc_null_arg=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_mbrtowc_null_arg=no + gl_cv_func_mbrtowc_null_arg=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_null_arg" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg" >&5 $as_echo "$gl_cv_func_mbrtowc_null_arg" >&6; } - { $as_echo "$as_me:$LINENO: checking whether mbrtowc has a correct return value" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5 $as_echo_n "checking whether mbrtowc has a correct return value... " >&6; } -if test "${gl_cv_func_mbrtowc_retval+set}" = set; then +if ${gl_cv_func_mbrtowc_retval+:} false; then : $as_echo_n "(cached) " >&6 else @@ -24403,14 +15621,10 @@ else *) gl_cv_func_mbrtowc_retval="guessing yes" ;; esac if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -24451,54 +15665,27 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_mbrtowc_retval=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_mbrtowc_retval=no + gl_cv_func_mbrtowc_retval=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_retval" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5 $as_echo "$gl_cv_func_mbrtowc_retval" >&6; } - { $as_echo "$as_me:$LINENO: checking whether mbrtowc returns 0 when parsing a NUL character" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5 $as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; } -if test "${gl_cv_func_mbrtowc_nul_retval+set}" = set; then +if ${gl_cv_func_mbrtowc_nul_retval+:} false; then : $as_echo_n "(cached) " >&6 else @@ -24509,14 +15696,10 @@ else *) gl_cv_func_mbrtowc_nul_retval="guessing yes" ;; esac if test $LOCALE_ZH_CN != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -24537,54 +15720,25 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_mbrtowc_nul_retval=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_mbrtowc_nul_retval=no + gl_cv_func_mbrtowc_nul_retval=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_nul_retval" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; } case "$gl_cv_func_mbrtowc_null_arg" in *yes) ;; *) -cat >>confdefs.h <<\_ACEOF -#define MBRTOWC_NULL_ARG_BUG 1 -_ACEOF +$as_echo "#define MBRTOWC_NULL_ARG_BUG 1" >>confdefs.h REPLACE_MBRTOWC=1 ;; @@ -24592,9 +15746,7 @@ _ACEOF case "$gl_cv_func_mbrtowc_retval" in *yes) ;; *) -cat >>confdefs.h <<\_ACEOF -#define MBRTOWC_RETVAL_BUG 1 -_ACEOF +$as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h REPLACE_MBRTOWC=1 ;; @@ -24602,9 +15754,7 @@ _ACEOF case "$gl_cv_func_mbrtowc_nul_retval" in *yes) ;; *) -cat >>confdefs.h <<\_ACEOF -#define MBRTOWC_NUL_RETVAL_BUG 1 -_ACEOF +$as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h REPLACE_MBRTOWC=1 ;; @@ -24637,9 +15787,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_MBRTOWC 1 -_ACEOF +$as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h @@ -24670,9 +15818,9 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking whether mbrtowc handles incomplete characters" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; } -if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then +if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then : $as_echo_n "(cached) " >&6 else @@ -24683,14 +15831,10 @@ else *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;; esac if test $LOCALE_JA != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -24712,54 +15856,27 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_mbrtowc_incomplete_state=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_mbrtowc_incomplete_state=no + gl_cv_func_mbrtowc_incomplete_state=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_incomplete_state" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; } - { $as_echo "$as_me:$LINENO: checking whether mbrtowc works as well as mbtowc" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; } -if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then +if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then : $as_echo_n "(cached) " >&6 else @@ -24770,14 +15887,10 @@ else *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;; esac if test $LOCALE_ZH_CN != none; then - if test "$cross_compiling" = yes; then + 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -24803,46 +15916,19 @@ int main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_mbrtowc_sanitycheck=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_mbrtowc_sanitycheck=no + gl_cv_func_mbrtowc_sanitycheck=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_sanitycheck" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; } REPLACE_MBSTATE_T=0 @@ -24904,9 +15990,7 @@ $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; } -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_MBSINIT 1 -_ACEOF +$as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h @@ -24919,9 +16003,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_MEMCHR 1 -_ACEOF +$as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h @@ -24936,102 +16018,12 @@ _ACEOF - -for ac_func in mkdtemp -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in mkdtemp +do : + ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp" +if test "x$ac_cv_func_mkdtemp" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_MKDTEMP 1 _ACEOF else @@ -25055,9 +16047,7 @@ done -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_MKDTEMP 1 -_ACEOF +$as_echo "#define GNULIB_TEST_MKDTEMP 1" >>confdefs.h @@ -25088,18 +16078,14 @@ _ACEOF if test $gl_cv_have_include_next = yes; then gl_cv_next_netdb_h='<'netdb.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_netdb_h+set}" = set; then +if ${gl_cv_next_netdb_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_netdb_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -25120,7 +16106,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_netdb_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netdb_h" >&5 $as_echo "$gl_cv_next_netdb_h" >&6; } fi NEXT_NETDB_H=$gl_cv_next_netdb_h @@ -25144,22 +16130,14 @@ $as_echo "$gl_cv_next_netdb_h" >&6; } - - - - - for gl_func in getaddrinfo freeaddrinfo gai_strerror getnameinfo; do + for gl_func in getaddrinfo freeaddrinfo gai_strerror getnameinfo; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -25171,64 +16149,35 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done # Code from module netinet_in: - { $as_echo "$as_me:$LINENO: checking whether is self-contained" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether is self-contained" >&5 $as_echo_n "checking whether is self-contained... " >&6; } -if test "${gl_cv_header_netinet_in_h_selfcontained+set}" = set; then +if ${gl_cv_header_netinet_in_h_selfcontained+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -25239,181 +16188,26 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_header_netinet_in_h_selfcontained=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_header_netinet_in_h_selfcontained=no + gl_cv_header_netinet_in_h_selfcontained=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_netinet_in_h_selfcontained" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_netinet_in_h_selfcontained" >&5 $as_echo "$gl_cv_header_netinet_in_h_selfcontained" >&6; } if test $gl_cv_header_netinet_in_h_selfcontained = yes; then NETINET_IN_H='' else NETINET_IN_H='netinet/in.h' - -for ac_header in netinet/in.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;} - - ;; -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 + for ac_header in netinet/in.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default" +if test "x$ac_cv_header_netinet_in_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_NETINET_IN_H 1 _ACEOF fi @@ -25435,18 +16229,14 @@ done if test $gl_cv_have_include_next = yes; then gl_cv_next_netinet_in_h='<'netinet/in.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 $as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_netinet_in_h+set}" = set; then +if ${gl_cv_next_netinet_in_h+:} false; then : $as_echo_n "(cached) " >&6 else if test $ac_cv_header_netinet_in_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -25467,7 +16257,7 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_netinet_in_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netinet_in_h" >&5 $as_echo "$gl_cv_next_netinet_in_h" >&6; } fi NEXT_NETINET_IN_H=$gl_cv_next_netinet_in_h @@ -25492,48 +16282,6 @@ $as_echo "$gl_cv_next_netinet_in_h" >&6; } fi - { $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; } - # Code from module nl_langinfo: @@ -25552,9 +16300,7 @@ $as_echo "$MKDIR_P" >&6; } else REPLACE_NL_LANGINFO=1 -cat >>confdefs.h <<\_ACEOF -#define REPLACE_NL_LANGINFO 1 -_ACEOF +$as_echo "#define REPLACE_NL_LANGINFO 1" >>confdefs.h @@ -25588,9 +16334,7 @@ _ACEOF -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_NL_LANGINFO 1 -_ACEOF +$as_echo "#define GNULIB_TEST_NL_LANGINFO 1" >>confdefs.h @@ -25608,67 +16352,13 @@ _ACEOF # Prerequisites of lib/physmem.c. - - - - - - - -for ac_header in sys/pstat.h sys/sysmp.h sys/sysinfo.h \ + for ac_header in sys/pstat.h sys/sysmp.h sys/sysinfo.h \ machine/hal_sysinfo.h sys/table.h sys/param.h sys/systemcfg.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 +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default +" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -25677,66 +16367,17 @@ fi done - -for ac_header in sys/sysctl.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 + for ac_header in sys/sysctl.h +do : + ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "$ac_includes_default #if HAVE_SYS_PARAM_H # include #endif - -#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 +" +if test "x$ac_cv_header_sys_sysctl_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_SYS_SYSCTL_H 1 _ACEOF fi @@ -25744,105 +16385,11 @@ fi done - - - - - - -for ac_func in pstat_getstatic pstat_getdynamic sysmp getsysinfo sysctl table -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in pstat_getstatic pstat_getdynamic sysmp getsysinfo sysctl table +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF @@ -25864,7 +16411,7 @@ done # Check whether --with-included-regex was given. -if test "${with_included_regex+set}" = set; then +if test "${with_included_regex+set}" = set; then : withval=$with_included_regex; fi @@ -25877,19 +16424,15 @@ fi # following run test, then default to *not* using the included regex.c. # If cross compiling, assume the test would fail and use the included # regex.c. - { $as_echo "$as_me:$LINENO: checking for working re_compile_pattern" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working re_compile_pattern" >&5 $as_echo_n "checking for working re_compile_pattern... " >&6; } -if test "${gl_cv_func_re_compile_pattern_working+set}" = set; then +if ${gl_cv_func_re_compile_pattern_working+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : gl_cv_func_re_compile_pattern_working=no else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default #if HAVE_LOCALE_H @@ -26030,136 +16573,75 @@ static struct re_pattern_buffer regex; 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_func_re_compile_pattern_working=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_re_compile_pattern_working=no + gl_cv_func_re_compile_pattern_working=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_re_compile_pattern_working" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_re_compile_pattern_working" >&5 $as_echo "$gl_cv_func_re_compile_pattern_working" >&6; } case $gl_cv_func_re_compile_pattern_working in #( yes) ac_use_included_regex=no;; #( no) ac_use_included_regex=yes;; esac ;; - *) { { $as_echo "$as_me:$LINENO: error: Invalid value for --with-included-regex: $with_included_regex" >&5 -$as_echo "$as_me: error: Invalid value for --with-included-regex: $with_included_regex" >&2;} - { (exit 1); exit 1; }; } + *) as_fn_error $? "Invalid value for --with-included-regex: $with_included_regex" "$LINENO" 5 ;; esac if test $ac_use_included_regex = yes; then -cat >>confdefs.h <<\_ACEOF -#define _REGEX_LARGE_OFFSETS 1 -_ACEOF +$as_echo "#define _REGEX_LARGE_OFFSETS 1" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_syntax_options rpl_re_syntax_options -_ACEOF +$as_echo "#define re_syntax_options rpl_re_syntax_options" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_set_syntax rpl_re_set_syntax -_ACEOF +$as_echo "#define re_set_syntax rpl_re_set_syntax" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_compile_pattern rpl_re_compile_pattern -_ACEOF +$as_echo "#define re_compile_pattern rpl_re_compile_pattern" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_compile_fastmap rpl_re_compile_fastmap -_ACEOF +$as_echo "#define re_compile_fastmap rpl_re_compile_fastmap" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_search rpl_re_search -_ACEOF +$as_echo "#define re_search rpl_re_search" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_search_2 rpl_re_search_2 -_ACEOF +$as_echo "#define re_search_2 rpl_re_search_2" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_match rpl_re_match -_ACEOF +$as_echo "#define re_match rpl_re_match" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_match_2 rpl_re_match_2 -_ACEOF +$as_echo "#define re_match_2 rpl_re_match_2" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_set_registers rpl_re_set_registers -_ACEOF +$as_echo "#define re_set_registers rpl_re_set_registers" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_comp rpl_re_comp -_ACEOF +$as_echo "#define re_comp rpl_re_comp" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define re_exec rpl_re_exec -_ACEOF +$as_echo "#define re_exec rpl_re_exec" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define regcomp rpl_regcomp -_ACEOF +$as_echo "#define regcomp rpl_regcomp" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define regexec rpl_regexec -_ACEOF +$as_echo "#define regexec rpl_regexec" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define regerror rpl_regerror -_ACEOF +$as_echo "#define regerror rpl_regerror" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define regfree rpl_regfree -_ACEOF +$as_echo "#define regfree rpl_regfree" >>confdefs.h @@ -26176,146 +16658,12 @@ _ACEOF - -for ac_header in libintl.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;} - - ;; -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 + for ac_header in libintl.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default" +if test "x$ac_cv_header_libintl_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_LIBINTL_H 1 _ACEOF fi @@ -26335,77 +16683,19 @@ done - { $as_echo "$as_me:$LINENO: checking whether isblank is declared" >&5 -$as_echo_n "checking whether isblank is declared... " >&6; } -if test "${ac_cv_have_decl_isblank+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 - -int -main () -{ -#ifndef isblank - (void) isblank; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_isblank=yes + ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include +" +if test "x$ac_cv_have_decl_isblank" = xyes; then : + ac_have_decl=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_isblank=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + ac_have_decl=0 fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_isblank" >&5 -$as_echo "$ac_cv_have_decl_isblank" >&6; } -if test "x$ac_cv_have_decl_isblank" = x""yes; then cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_ISBLANK 1 +#define HAVE_DECL_ISBLANK $ac_have_decl _ACEOF -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_ISBLANK 0 -_ACEOF - - -fi - - - fi # Code from module safe-read: @@ -26448,17 +16738,13 @@ fi SERVENT_LIB= gl_saved_libs="$LIBS" - { $as_echo "$as_me:$LINENO: checking for library containing getservbyname" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getservbyname" >&5 $as_echo_n "checking for library containing getservbyname... " >&6; } -if test "${ac_cv_search_getservbyname+set}" = set; then +if ${ac_cv_search_getservbyname+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -26483,54 +16769,27 @@ for ac_lib in '' socket network net; do ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then + if ac_fn_c_try_link "$LINENO"; then : ac_cv_search_getservbyname=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_getservbyname+set}" = set; then +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_getservbyname+:} false; then : break fi done -if test "${ac_cv_search_getservbyname+set}" = set; then - : +if ${ac_cv_search_getservbyname+:} false; then : + else ac_cv_search_getservbyname=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_getservbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getservbyname" >&5 $as_echo "$ac_cv_search_getservbyname" >&6; } ac_res=$ac_cv_search_getservbyname -if test "$ac_res" != no; then +if test "$ac_res" != no; then : test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" if test "$ac_cv_search_getservbyname" != "none required"; then SERVENT_LIB="$ac_cv_search_getservbyname" @@ -26539,119 +16798,25 @@ fi LIBS="$gl_saved_libs" if test -z "$SERVENT_LIB"; then - -for ac_func in getservbyname -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_func in getservbyname +do : + ac_fn_c_check_func "$LINENO" "getservbyname" "ac_cv_func_getservbyname" +if test "x$ac_cv_func_getservbyname" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETSERVBYNAME 1 _ACEOF else - { $as_echo "$as_me:$LINENO: checking for getservbyname in winsock2.h and -lws2_32" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getservbyname in winsock2.h and -lws2_32" >&5 $as_echo_n "checking for getservbyname in winsock2.h and -lws2_32... " >&6; } -if test "${gl_cv_w32_getservbyname+set}" = set; then +if ${gl_cv_w32_getservbyname+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_w32_getservbyname=no gl_save_LIBS="$LIBS" LIBS="$LIBS -lws2_32" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_WINSOCK2_H @@ -26667,42 +16832,15 @@ getservbyname(NULL,NULL); 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 ac_fn_c_try_link "$LINENO"; then : gl_cv_w32_getservbyname=yes -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS="$gl_save_LIBS" fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_w32_getservbyname" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_getservbyname" >&5 $as_echo "$gl_cv_w32_getservbyname" >&6; } if test "$gl_cv_w32_getservbyname" = "yes"; then SERVENT_LIB="-lws2_32" @@ -26716,160 +16854,22 @@ done # Code from module size_max: - -for ac_header in stdint.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;} - - ;; -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 + for ac_header in stdint.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default" +if test "x$ac_cv_header_stdint_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_STDINT_H 1 _ACEOF fi done - { $as_echo "$as_me:$LINENO: checking for SIZE_MAX" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIZE_MAX" >&5 $as_echo_n "checking for SIZE_MAX... " >&6; } result= - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -26882,1631 +16882,594 @@ Found it _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "Found it" >/dev/null 2>&1; then + $EGREP "Found it" >/dev/null 2>&1; then : result=yes fi rm -f conftest* if test -z "$result"; then - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) * CHAR_BIT - 1" "size_t_bits_minus_1" "#include +#include "; then : + +else + size_t_bits_minus_1= +fi + + + if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) <= sizeof (unsigned int)" "fits_in_uint" "#include "; then : + +else + fits_in_uint= +fi + + + if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then + if test $fits_in_uint = 1; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include -#include + extern size_t foo; + extern unsigned long foo; + int main () { -static int test_array [1 - 2 * !((sizeof (size_t) * CHAR_BIT - 1) >= 0)]; -test_array [0] = 0 ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +if ac_fn_c_try_compile "$LINENO"; then : + fits_in_uint=0 +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $fits_in_uint = 1; then + result="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)" + else + result="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)" + fi + else + result='((size_t)~(size_t)0)' + fi + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $result" >&5 +$as_echo "$result" >&6; } + if test "$result" != yes; then + +cat >>confdefs.h <<_ACEOF +#define SIZE_MAX $result _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof (size_t) * CHAR_BIT - 1) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} + fi + + # Code from module snprintf: + + + gl_cv_func_snprintf_usable=no + for ac_func in snprintf +do : + ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf" +if test "x$ac_cv_func_snprintf" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SNPRINTF 1 _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_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` fi +done -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done + if test $ac_cv_func_snprintf = yes; then + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf respects a size of 1" >&5 +$as_echo_n "checking whether snprintf respects a size of 1... " >&6; } +if ${gl_cv_func_snprintf_size1+:} false; then : + $as_echo_n "(cached) " >&6 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + if test "$cross_compiling" = yes; then : + gl_cv_func_snprintf_size1="guessing yes" +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof (size_t) * CHAR_BIT - 1) < 0)]; -test_array [0] = 0 - ; - return 0; +#include +int main() +{ + static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' }; + snprintf (buf, 1, "%d", 12345); + return buf[1] != 'E'; } _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_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_snprintf_size1=yes +else + gl_cv_func_snprintf_size1=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi + + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_size1" >&5 +$as_echo "$gl_cv_func_snprintf_size1" >&6; } + + case "$gl_cv_func_snprintf_size1" in + *yes) + gl_cv_func_snprintf_usable=yes + ;; + esac + fi + if test $gl_cv_func_snprintf_usable = no; then + + + + + + + + + + + gl_LIBOBJS="$gl_LIBOBJS snprintf.$ac_objext" + + if test $ac_cv_func_snprintf = yes; then + REPLACE_SNPRINTF=1 + fi + : + + fi + + : + + + + + + if test $ac_cv_have_decl_snprintf = no; then + HAVE_DECL_SNPRINTF=0 + fi + + + + + GNULIB_SNPRINTF=1 + + + +$as_echo "#define GNULIB_TEST_SNPRINTF 1" >>confdefs.h + + + + # Code from module socklen: + ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include + #if HAVE_SYS_SOCKET_H + # include + #elif HAVE_WS2TCPIP_H + # include + #endif +" +if test "x$ac_cv_type_socklen_t" = xyes; then : + +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5 +$as_echo_n "checking for socklen_t equivalent... " >&6; } + if ${gl_cv_socklen_t_equiv+:} false; then : + $as_echo_n "(cached) " >&6 +else + # Systems have either "struct sockaddr *" or + # "void *" as the second argument to getpeername + gl_cv_socklen_t_equiv= + for arg2 in "struct sockaddr" void; do + for t in int size_t "unsigned int" "long int" "unsigned long int"; do + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include +#include + #include + + int getpeername (int, $arg2 *, $t *); int main () { -static int test_array [1 - 2 * !((sizeof (size_t) * CHAR_BIT - 1) >= $ac_mid)]; -test_array [0] = 0 - +$t len; + getpeername (0, 0, &len); ; 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_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_socklen_t_equiv="$t" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + test "$gl_cv_socklen_t_equiv" != "" && break + done + test "$gl_cv_socklen_t_equiv" != "" && break + done - ac_lo= ac_hi= fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi + if test "$gl_cv_socklen_t_equiv" = ""; then + as_fn_error $? "Cannot find a type to use in place of socklen_t" "$LINENO" 5 + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5 +$as_echo "$gl_cv_socklen_t_equiv" >&6; } -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +cat >>confdefs.h <<_ACEOF +#define socklen_t $gl_cv_socklen_t_equiv _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + +fi + + # Code from module ssize_t: + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5 +$as_echo_n "checking for ssize_t... " >&6; } +if ${gt_cv_ssize_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include +#include int main () { -static int test_array [1 - 2 * !((sizeof (size_t) * CHAR_BIT - 1) <= $ac_mid)]; -test_array [0] = 0 - +int x = sizeof (ssize_t *) + sizeof (ssize_t); + return !x; ; 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_hi=$ac_mid +if ac_fn_c_try_compile "$LINENO"; then : + gt_cv_ssize_t=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` + gt_cv_ssize_t=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) size_t_bits_minus_1=$ac_lo;; -'') size_t_bits_minus_1= ;; -esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5 +$as_echo "$gt_cv_ssize_t" >&6; } + if test $gt_cv_ssize_t = no; then + +$as_echo "#define ssize_t int" >>confdefs.h + + fi + + # Code from module stat: + + + + + : + + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5 +$as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; } +if ${gl_cv_func_stat_dir_slash+:} false; 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 + if test "$cross_compiling" = yes; then : + case $host_os in + mingw*) gl_cv_func_stat_dir_slash="guessing no";; + *) gl_cv_func_stat_dir_slash="guessing yes";; + esac +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#include -static long int longval () { return sizeof (size_t) * CHAR_BIT - 1; } -static unsigned long int ulongval () { return sizeof (size_t) * CHAR_BIT - 1; } -#include -#include +#include + int main () { - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if ((sizeof (size_t) * CHAR_BIT - 1) < 0) - { - long int i = longval (); - if (i != (sizeof (size_t) * CHAR_BIT - 1)) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != (sizeof (size_t) * CHAR_BIT - 1)) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - +struct stat st; return stat (".", &st) != stat ("./", &st); ; 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 - size_t_bits_minus_1=`cat conftest.val` +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_stat_dir_slash=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -size_t_bits_minus_1= + gl_cv_func_stat_dir_slash=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 +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -rm -f conftest.val - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5 +$as_echo "$gl_cv_func_stat_dir_slash" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5 +$as_echo_n "checking whether stat handles trailing slashes on files... " >&6; } +if ${gl_cv_func_stat_file_slash+:} false; then : + $as_echo_n "(cached) " >&6 +else + touch conftest.tmp + # Assume that if we have lstat, we can also check symlinks. + if test $ac_cv_func_lstat = yes; then + ln -s conftest.tmp conftest.lnk + fi + if test "$cross_compiling" = yes; then : + gl_cv_func_stat_file_slash="guessing no" +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include +#include + int main () { -static int test_array [1 - 2 * !((sizeof (size_t) <= sizeof (unsigned int)) >= 0)]; -test_array [0] = 0 +struct stat st; + if (!stat ("conftest.tmp/", &st)) return 1; +#if HAVE_LSTAT + if (!stat ("conftest.lnk/", &st)) return 2; +#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_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof (size_t) <= sizeof (unsigned int)) <= $ac_mid)]; -test_array [0] = 0 - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_stat_file_slash=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + gl_cv_func_stat_file_slash=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` + rm -f conftest.tmp conftest.lnk fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5 +$as_echo "$gl_cv_func_stat_file_slash" >&6; } + case $gl_cv_func_stat_dir_slash in + *no) REPLACE_STAT=1 -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +$as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h +;; + esac + case $gl_cv_func_stat_file_slash in + *no) REPLACE_STAT=1 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof (size_t) <= sizeof (unsigned int)) < 0)]; -test_array [0] = 0 +$as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h +;; + esac + if test $REPLACE_STAT = 1; then - ; - 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_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof (size_t) <= sizeof (unsigned int)) >= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof (size_t) <= sizeof (unsigned int)) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext" - ac_lo=`expr '(' $ac_mid ')' + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) fits_in_uint=$ac_lo;; -'') fits_in_uint= ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -static long int longval () { return sizeof (size_t) <= sizeof (unsigned int); } -static unsigned long int ulongval () { return sizeof (size_t) <= sizeof (unsigned int); } -#include -#include -int -main () -{ + fi - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if ((sizeof (size_t) <= sizeof (unsigned int)) < 0) - { - long int i = longval (); - if (i != (sizeof (size_t) <= sizeof (unsigned int))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != (sizeof (size_t) <= sizeof (unsigned int))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - ; - 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 - fits_in_uint=`cat conftest.val` -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 ) -fits_in_uint= -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 -rm -f conftest.val - if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then - if test $fits_in_uint = 1; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - extern size_t foo; - extern unsigned long foo; + GNULIB_STAT=1 -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 - fits_in_uint=0 -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +$as_echo "#define GNULIB_TEST_STAT 1" >>confdefs.h -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi - if test $fits_in_uint = 1; then - result="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)" - else - result="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)" - fi - else - result='((size_t)~(size_t)0)' - fi + + # Code from module stdbool: + + + + # Define two additional variables used in the Makefile substitution. + + if test "$ac_cv_header_stdbool_h" = yes; then + STDBOOL_H='' + else + STDBOOL_H='stdbool.h' fi - { $as_echo "$as_me:$LINENO: result: $result" >&5 -$as_echo "$result" >&6; } - if test "$result" != yes; then -cat >>confdefs.h <<_ACEOF -#define SIZE_MAX $result -_ACEOF + if test "$ac_cv_type__Bool" = yes; then + HAVE__BOOL=1 + else + HAVE__BOOL=0 fi - # Code from module snprintf: + # Code from module stddef: - gl_cv_func_snprintf_usable=no -for ac_func in snprintf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then + + if test $gt_cv_c_wchar_t = no; then + HAVE_WCHAR_T=0 + STDDEF_H=stddef.h + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5 +$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; } +if ${gl_cv_decl_null_works+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif +#include + int test[2 * (sizeof NULL == sizeof (void *)) -1]; int main () { -return $ac_func (); + ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_decl_null_works=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" + gl_cv_decl_null_works=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5 +$as_echo "$gl_cv_decl_null_works" >&6; } + if test $gl_cv_decl_null_works = no; then + REPLACE_NULL=1 + STDDEF_H=stddef.h + fi + if test -n "$STDDEF_H"; then -fi -done - if test $ac_cv_func_snprintf = yes; then - { $as_echo "$as_me:$LINENO: checking whether snprintf respects a size of 1" >&5 -$as_echo_n "checking whether snprintf respects a size of 1... " >&6; } -if test "${gl_cv_func_snprintf_size1+set}" = set; then - $as_echo_n "(cached) " >&6 -else + : - if test "$cross_compiling" = yes; then - gl_cv_func_snprintf_size1="guessing yes" -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int main() -{ - static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' }; - snprintf (buf, 1, "%d", 12345); - return buf[1] != 'E'; -} -_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 - gl_cv_func_snprintf_size1=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 -( exit $ac_status ) -gl_cv_func_snprintf_size1=no -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_snprintf_size1" >&5 -$as_echo "$gl_cv_func_snprintf_size1" >&6; } - case "$gl_cv_func_snprintf_size1" in - *yes) - gl_cv_func_snprintf_usable=yes - ;; - esac - fi - if test $gl_cv_func_snprintf_usable = no; then + if test $gl_cv_have_include_next = yes; then + gl_cv_next_stddef_h='<'stddef.h'>' + else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_stddef_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test $ac_cv_header_stddef_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac + gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/stddef.h#{ + s#.*"\(.*/stddef.h\)".*#\1# + s#^/[^/]#//&# + p + q + }'`'"' + else + gl_cv_next_stddef_h='<'stddef.h'>' + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5 +$as_echo "$gl_cv_next_stddef_h" >&6; } + fi + NEXT_STDDEF_H=$gl_cv_next_stddef_h + if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' + gl_next_as_first_directive='<'stddef.h'>' + else + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' + gl_next_as_first_directive=$gl_cv_next_stddef_h + fi + NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive + fi + # Code from module stdint: - gl_LIBOBJS="$gl_LIBOBJS snprintf.$ac_objext" - if test $ac_cv_func_snprintf = yes; then - REPLACE_SNPRINTF=1 + if test $ac_cv_type_long_long_int = yes; then + HAVE_LONG_LONG_INT=1 + else + HAVE_LONG_LONG_INT=0 fi - : + + if test $ac_cv_type_unsigned_long_long_int = yes; then + HAVE_UNSIGNED_LONG_LONG_INT=1 + else + HAVE_UNSIGNED_LONG_LONG_INT=0 fi - : + + if test $ac_cv_header_inttypes_h = yes; then + HAVE_INTTYPES_H=1 + else + HAVE_INTTYPES_H=0 + fi + if test $ac_cv_header_sys_types_h = yes; then + HAVE_SYS_TYPES_H=1 + else + HAVE_SYS_TYPES_H=0 + fi - if test $ac_cv_have_decl_snprintf = no; then - HAVE_DECL_SNPRINTF=0 - fi + : - GNULIB_SNPRINTF=1 -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_SNPRINTF 1 -_ACEOF - # Code from module socklen: - { $as_echo "$as_me:$LINENO: checking for socklen_t" >&5 -$as_echo_n "checking for socklen_t... " >&6; } -if test "${ac_cv_type_socklen_t+set}" = set; then + if test $gl_cv_have_include_next = yes; then + gl_cv_next_stdint_h='<'stdint.h'>' + else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_stdint_h+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_type_socklen_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #if HAVE_SYS_SOCKET_H - # include - #elif HAVE_WS2TCPIP_H - # include - #endif -int -main () -{ -if (sizeof (socklen_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + if test $ac_cv_header_stdint_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include - #if HAVE_SYS_SOCKET_H - # include - #elif HAVE_WS2TCPIP_H - # include - #endif +#include -int -main () -{ -if (sizeof ((socklen_t))) - return 0; - ; - return 0; -} _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac + gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/stdint.h#{ + s#.*"\(.*/stdint.h\)".*#\1# + s#^/[^/]#//&# + p + q + }'`'"' + else + gl_cv_next_stdint_h='<'stdint.h'>' + fi - ac_cv_type_socklen_t=yes fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5 +$as_echo "$gl_cv_next_stdint_h" >&6; } + fi + NEXT_STDINT_H=$gl_cv_next_stdint_h -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5 -$as_echo "$ac_cv_type_socklen_t" >&6; } -if test "x$ac_cv_type_socklen_t" = x""yes; then - : -else - { $as_echo "$as_me:$LINENO: checking for socklen_t equivalent" >&5 -$as_echo_n "checking for socklen_t equivalent... " >&6; } - if test "${gl_cv_socklen_t_equiv+set}" = set; then - $as_echo_n "(cached) " >&6 -else - # Systems have either "struct sockaddr *" or - # "void *" as the second argument to getpeername - gl_cv_socklen_t_equiv= - for arg2 in "struct sockaddr" void; do - for t in int size_t "unsigned int" "long int" "unsigned long int"; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #include - - int getpeername (int, $arg2 *, $t *); -int -main () -{ -$t len; - getpeername (0, 0, &len); - ; - 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 - gl_cv_socklen_t_equiv="$t" -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 - test "$gl_cv_socklen_t_equiv" != "" && break - done - test "$gl_cv_socklen_t_equiv" != "" && break - done - -fi - - if test "$gl_cv_socklen_t_equiv" = ""; then - { { $as_echo "$as_me:$LINENO: error: Cannot find a type to use in place of socklen_t" >&5 -$as_echo "$as_me: error: Cannot find a type to use in place of socklen_t" >&2;} - { (exit 1); exit 1; }; } - fi - { $as_echo "$as_me:$LINENO: result: $gl_cv_socklen_t_equiv" >&5 -$as_echo "$gl_cv_socklen_t_equiv" >&6; } - -cat >>confdefs.h <<_ACEOF -#define socklen_t $gl_cv_socklen_t_equiv -_ACEOF - -fi - - # Code from module ssize_t: - - { $as_echo "$as_me:$LINENO: checking for ssize_t" >&5 -$as_echo_n "checking for ssize_t... " >&6; } -if test "${gt_cv_ssize_t+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 -int -main () -{ -int x = sizeof (ssize_t *) + sizeof (ssize_t); - return !x; - ; - 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 - gt_cv_ssize_t=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_ssize_t=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_ssize_t" >&5 -$as_echo "$gt_cv_ssize_t" >&6; } - if test $gt_cv_ssize_t = no; then - -cat >>confdefs.h <<\_ACEOF -#define ssize_t int -_ACEOF - - fi - - # Code from module stat: - - - - - : - - - - - - { $as_echo "$as_me:$LINENO: checking whether stat handles trailing slashes on directories" >&5 -$as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; } -if test "${gl_cv_func_stat_dir_slash+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - case $host_os in - mingw*) gl_cv_func_stat_dir_slash="guessing no";; - *) gl_cv_func_stat_dir_slash="guessing yes";; - esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -struct stat st; return stat (".", &st) != stat ("./", &st); - ; - 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 - gl_cv_func_stat_dir_slash=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_stat_dir_slash=no -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_stat_dir_slash" >&5 -$as_echo "$gl_cv_func_stat_dir_slash" >&6; } - { $as_echo "$as_me:$LINENO: checking whether stat handles trailing slashes on files" >&5 -$as_echo_n "checking whether stat handles trailing slashes on files... " >&6; } -if test "${gl_cv_func_stat_file_slash+set}" = set; then - $as_echo_n "(cached) " >&6 -else - touch conftest.tmp - # Assume that if we have lstat, we can also check symlinks. - if test $ac_cv_func_lstat = yes; then - ln -s conftest.tmp conftest.lnk - fi - if test "$cross_compiling" = yes; then - gl_cv_func_stat_file_slash="guessing no" -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -int -main () -{ -struct stat st; - if (!stat ("conftest.tmp/", &st)) return 1; -#if HAVE_LSTAT - if (!stat ("conftest.lnk/", &st)) return 2; -#endif - - ; - 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 - gl_cv_func_stat_file_slash=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -gl_cv_func_stat_file_slash=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 - - - rm -f conftest.tmp conftest.lnk -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_stat_file_slash" >&5 -$as_echo "$gl_cv_func_stat_file_slash" >&6; } - case $gl_cv_func_stat_dir_slash in - *no) REPLACE_STAT=1 - -cat >>confdefs.h <<\_ACEOF -#define REPLACE_FUNC_STAT_DIR 1 -_ACEOF -;; - esac - case $gl_cv_func_stat_file_slash in - *no) REPLACE_STAT=1 - -cat >>confdefs.h <<\_ACEOF -#define REPLACE_FUNC_STAT_FILE 1 -_ACEOF -;; - esac - if test $REPLACE_STAT = 1; then - - - - - - - - - gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext" - - - fi - - - - - GNULIB_STAT=1 - - - -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_STAT 1 -_ACEOF - - - - # Code from module stdbool: - - - - # Define two additional variables used in the Makefile substitution. - - if test "$ac_cv_header_stdbool_h" = yes; then - STDBOOL_H='' - else - STDBOOL_H='stdbool.h' - fi - - - if test "$ac_cv_type__Bool" = yes; then - HAVE__BOOL=1 - else - HAVE__BOOL=0 - fi - - - # Code from module stddef: - - - - if test $gt_cv_c_wchar_t = no; then - HAVE_WCHAR_T=0 - STDDEF_H=stddef.h - fi - { $as_echo "$as_me:$LINENO: checking whether NULL can be used in arbitrary expressions" >&5 -$as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; } -if test "${gl_cv_decl_null_works+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 - int test[2 * (sizeof NULL == sizeof (void *)) -1]; - -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 - gl_cv_decl_null_works=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gl_cv_decl_null_works=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_decl_null_works" >&5 -$as_echo "$gl_cv_decl_null_works" >&6; } - if test $gl_cv_decl_null_works = no; then - REPLACE_NULL=1 - STDDEF_H=stddef.h - fi - if test -n "$STDDEF_H"; then - - - - - : - - - - - - - - if test $gl_cv_have_include_next = yes; then - gl_cv_next_stddef_h='<'stddef.h'>' - else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_stddef_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else - - if test $ac_cv_header_stddef_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac - gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/stddef.h#{ - s#.*"\(.*/stddef.h\)".*#\1# - s#^/[^/]#//&# - p - q - }'`'"' - else - gl_cv_next_stddef_h='<'stddef.h'>' - fi - -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_stddef_h" >&5 -$as_echo "$gl_cv_next_stddef_h" >&6; } - fi - NEXT_STDDEF_H=$gl_cv_next_stddef_h - - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'stddef.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_stddef_h - fi - NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive - - - - fi - - # Code from module stdint: - - - - if test $ac_cv_type_long_long_int = yes; then - HAVE_LONG_LONG_INT=1 - else - HAVE_LONG_LONG_INT=0 - fi - - - if test $ac_cv_type_unsigned_long_long_int = yes; then - HAVE_UNSIGNED_LONG_LONG_INT=1 - else - HAVE_UNSIGNED_LONG_LONG_INT=0 - fi - - - if test $ac_cv_header_inttypes_h = yes; then - HAVE_INTTYPES_H=1 - else - HAVE_INTTYPES_H=0 - fi - - - if test $ac_cv_header_sys_types_h = yes; then - HAVE_SYS_TYPES_H=1 - else - HAVE_SYS_TYPES_H=0 - fi - - - - - - - : - - - - - - - - if test $gl_cv_have_include_next = yes; then - gl_cv_next_stdint_h='<'stdint.h'>' - else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_stdint_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else - - if test $ac_cv_header_stdint_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - -_ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac - gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/stdint.h#{ - s#.*"\(.*/stdint.h\)".*#\1# - s#^/[^/]#//&# - p - q - }'`'"' - else - gl_cv_next_stdint_h='<'stdint.h'>' - fi - -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_stdint_h" >&5 -$as_echo "$gl_cv_next_stdint_h" >&6; } - fi - NEXT_STDINT_H=$gl_cv_next_stdint_h - - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'stdint.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_stdint_h - fi - NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive + if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' + gl_next_as_first_directive='<'stdint.h'>' + else + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' + gl_next_as_first_directive=$gl_cv_next_stdint_h + fi + NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive @@ -28518,20 +17481,16 @@ $as_echo "$gl_cv_next_stdint_h" >&6; } if test $ac_cv_header_stdint_h = yes; then - { $as_echo "$as_me:$LINENO: checking whether stdint.h conforms to C99" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; } -if test "${gl_cv_header_working_stdint_h+set}" = set; then +if ${gl_cv_header_working_stdint_h+:} false; then : $as_echo_n "(cached) " >&6 else gl_cv_header_working_stdint_h=no - cat >conftest.$ac_ext <<_ACEOF - - /* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */ #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */ #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */ @@ -28691,36 +17650,15 @@ 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 - if test "$cross_compiling" = yes; then +if ac_fn_c_try_compile "$LINENO"; then : + if test "$cross_compiling" = yes; then : gl_cv_header_working_stdint_h=yes else - cat >conftest.$ac_ext <<_ACEOF - - /* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ + #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */ #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */ #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */ @@ -28794,199 +17732,32 @@ main () 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 +if ac_fn_c_try_run "$LINENO"; then : gl_cv_header_working_stdint_h=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_working_stdint_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5 $as_echo "$gl_cv_header_working_stdint_h" >&6; } fi if test "$gl_cv_header_working_stdint_h" = yes; then STDINT_H= else - - -for ac_header in sys/inttypes.h sys/bitypes.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;} - - ;; -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 + for ac_header in sys/inttypes.h sys/bitypes.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF fi @@ -29018,23 +17789,13 @@ done if test $APPLE_UNIVERSAL_BUILD = 0; then - - for gltype in ptrdiff_t size_t ; do - { $as_echo "$as_me:$LINENO: checking for bit size of $gltype" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5 $as_echo_n "checking for bit size of $gltype... " >&6; } -if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${gl_cv_bitsizeof_${gltype}+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" " /* BSD/OS 4.0.1 has a bug: , and must be included before . */ #include @@ -29045,44 +17806,41 @@ cat >>conftest.$ac_ext <<_ACEOF # include #endif -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) >= 0)]; -test_array [0] = 0 +#include "; then : - ; - 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_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +else + result=unknown +fi + + eval gl_cv_bitsizeof_${gltype}=\$result + +fi +eval ac_res=\$gl_cv_bitsizeof_${gltype} + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval result=\$gl_cv_bitsizeof_${gltype} + if test $result = unknown; then + result=0 + fi + GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` + cat >>confdefs.h <<_ACEOF +#define BITSIZEOF_${GLTYPE} $result _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + eval BITSIZEOF_${GLTYPE}=\$result + done + + + fi + + + for gltype in sig_atomic_t wchar_t wint_t ; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5 +$as_echo_n "checking for bit size of $gltype... " >&6; } +if eval \${gl_cv_bitsizeof_${gltype}+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" " /* BSD/OS 4.0.1 has a bug: , and must be included before . */ #include @@ -29093,107 +17851,40 @@ cat >>conftest.$ac_ext <<_ACEOF # include #endif -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) <= $ac_mid)]; -test_array [0] = 0 +#include "; then : - ; - 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_hi=$ac_mid; break else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + result=unknown +fi + + eval gl_cv_bitsizeof_${gltype}=\$result - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` fi +eval ac_res=\$gl_cv_bitsizeof_${gltype} + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval result=\$gl_cv_bitsizeof_${gltype} + if test $result = unknown; then + result=0 + fi + GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` + cat >>confdefs.h <<_ACEOF +#define BITSIZEOF_${GLTYPE} $result +_ACEOF -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + eval BITSIZEOF_${GLTYPE}=\$result done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + for gltype in sig_atomic_t wchar_t wint_t ; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5 +$as_echo_n "checking whether $gltype is signed... " >&6; } +if eval \${gl_cv_type_${gltype}_signed+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* BSD/OS 4.0.1 has a bug: , and must be @@ -29206,69 +17897,71 @@ cat >>conftest.$ac_ext <<_ACEOF # include #endif -#include + int verify[2 * (($gltype) -1 < ($gltype) 0) - 1]; int main () { -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) >= $ac_mid)]; -test_array [0] = 0 ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break +if ac_fn_c_try_compile "$LINENO"; then : + result=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + result=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + eval gl_cv_type_${gltype}_signed=\$result - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` fi +eval ac_res=\$gl_cv_type_${gltype}_signed + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + eval result=\$gl_cv_type_${gltype}_signed + GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` + if test "$result" = yes; then + cat >>confdefs.h <<_ACEOF +#define HAVE_SIGNED_${GLTYPE} 1 +_ACEOF -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + eval HAVE_SIGNED_${GLTYPE}=1 + else + eval HAVE_SIGNED_${GLTYPE}=0 + fi done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi + gl_cv_type_ptrdiff_t_signed=yes + gl_cv_type_size_t_signed=no + if test $APPLE_UNIVERSAL_BUILD = 0; then -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + + for gltype in ptrdiff_t size_t ; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5 +$as_echo_n "checking for $gltype integer literal suffix... " >&6; } +if eval \${gl_cv_type_${gltype}_suffix+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval gl_cv_type_${gltype}_suffix=no + eval result=\$gl_cv_type_${gltype}_signed + if test "$result" = yes; then + glsufu= + else + glsufu=u + fi + for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do + case $glsuf in + '') gltype1='int';; + l) gltype1='long int';; + ll) gltype1='long long int';; + i64) gltype1='__int64';; + u) gltype1='unsigned int';; + ul) gltype1='unsigned long int';; + ull) gltype1='unsigned long long int';; + ui64)gltype1='unsigned __int64';; + esac + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* BSD/OS 4.0.1 has a bug: , and must be @@ -29281,55 +17974,66 @@ cat >>conftest.$ac_ext <<_ACEOF # include #endif -#include + extern $gltype foo; + extern $gltype1 foo; int main () { -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) <= $ac_mid)]; -test_array [0] = 0 ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr '(' $ac_mid ')' + 1` +if ac_fn_c_try_compile "$LINENO"; then : + eval gl_cv_type_${gltype}_suffix=\$glsuf fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) result=$ac_lo;; -'') result=unknown ;; -esac -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ + eval result=\$gl_cv_type_${gltype}_suffix + test "$result" != no && break + done +fi +eval ac_res=\$gl_cv_type_${gltype}_suffix + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` + eval result=\$gl_cv_type_${gltype}_suffix + test "$result" = no && result= + eval ${GLTYPE}_SUFFIX=\$result + cat >>confdefs.h <<_ACEOF +#define ${GLTYPE}_SUFFIX $result _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + + done + + + fi + + + for gltype in sig_atomic_t wchar_t wint_t ; do + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5 +$as_echo_n "checking for $gltype integer literal suffix... " >&6; } +if eval \${gl_cv_type_${gltype}_suffix+:} false; then : + $as_echo_n "(cached) " >&6 +else + eval gl_cv_type_${gltype}_suffix=no + eval result=\$gl_cv_type_${gltype}_signed + if test "$result" = yes; then + glsufu= + else + glsufu=u + fi + for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do + case $glsuf in + '') gltype1='int';; + l) gltype1='long int';; + ll) gltype1='long long int';; + i64) gltype1='__int64';; + u) gltype1='unsigned int';; + ul) gltype1='unsigned long int';; + ull) gltype1='unsigned long long int';; + ui64)gltype1='unsigned __int64';; + esac + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* BSD/OS 4.0.1 has a bug: , and must be @@ -29342,647 +18046,325 @@ cat >>conftest.$ac_ext <<_ACEOF # include #endif -#include -static long int longval () { return sizeof ($gltype) * CHAR_BIT; } -static unsigned long int ulongval () { return sizeof ($gltype) * CHAR_BIT; } -#include -#include + extern $gltype foo; + extern $gltype1 foo; int main () { - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if ((sizeof ($gltype) * CHAR_BIT) < 0) - { - long int i = longval (); - if (i != (sizeof ($gltype) * CHAR_BIT)) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != (sizeof ($gltype) * CHAR_BIT)) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - ; 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 - result=`cat conftest.val` -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 ) -result=unknown -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +if ac_fn_c_try_compile "$LINENO"; then : + eval gl_cv_type_${gltype}_suffix=\$glsuf fi -rm -f conftest.val - eval gl_cv_bitsizeof_${gltype}=\$result - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + eval result=\$gl_cv_type_${gltype}_suffix + test "$result" != no && break + done fi -ac_res=`eval 'as_val=${'gl_cv_bitsizeof_${gltype}'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$gl_cv_type_${gltype}_suffix + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval result=\$gl_cv_bitsizeof_${gltype} - if test $result = unknown; then - result=0 - fi - GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` + GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` + eval result=\$gl_cv_type_${gltype}_suffix + test "$result" = no && result= + eval ${GLTYPE}_SUFFIX=\$result cat >>confdefs.h <<_ACEOF -#define BITSIZEOF_${GLTYPE} $result +#define ${GLTYPE}_SUFFIX $result _ACEOF - eval BITSIZEOF_${GLTYPE}=\$result done + + STDINT_H=stdint.h fi + # Code from module stdio: - for gltype in sig_atomic_t wchar_t wint_t ; do - { $as_echo "$as_me:$LINENO: checking for bit size of $gltype" >&5 -$as_echo_n "checking for bit size of $gltype... " >&6; } -if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then + + + + + + : + + + + + + + + if test $gl_cv_have_include_next = yes; then + gl_cv_next_stdio_h='<'stdio.h'>' + else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_stdio_h+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + + if test $ac_cv_header_stdio_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif +_ACEOF + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac + gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/stdio.h#{ + s#.*"\(.*/stdio.h\)".*#\1# + s#^/[^/]#//&# + p + q + }'`'"' + else + gl_cv_next_stdio_h='<'stdio.h'>' + fi -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) >= 0)]; -test_array [0] = 0 +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5 +$as_echo "$gl_cv_next_stdio_h" >&6; } + fi + NEXT_STDIO_H=$gl_cv_next_stdio_h - ; - 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_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' + gl_next_as_first_directive='<'stdio.h'>' + else + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' + gl_next_as_first_directive=$gl_cv_next_stdio_h + fi + NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif -#include + + GNULIB_FPRINTF=1 + GNULIB_PRINTF=1 + GNULIB_VFPRINTF=1 + GNULIB_VPRINTF=1 + GNULIB_FPUTC=1 + GNULIB_PUTC=1 + GNULIB_PUTCHAR=1 + GNULIB_FPUTS=1 + GNULIB_PUTS=1 + GNULIB_FWRITE=1 + + + + for gl_func in dprintf fpurge fseeko ftello getdelim getline popen renameat snprintf tmpfile vdprintf vsnprintf; do + as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 +$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } +if eval \${$as_gl_Symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + int main () { -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) <= $ac_mid)]; -test_array [0] = 0 - +#undef $gl_func + (void) $gl_func; ; 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_hi=$ac_mid; break +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +fi +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif + eval ac_cv_have_decl_$gl_func=yes +fi + done -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + # Code from module stdlib: - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) >= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= -fi + : -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif -#include -int -main () -{ -static int test_array [1 - 2 * !((sizeof ($gltype) * CHAR_BIT) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr '(' $ac_mid ')' + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) result=$ac_lo;; -'') result=unknown ;; -esac + if test $gl_cv_have_include_next = yes; then + gl_cv_next_stdlib_h='<'stdlib.h'>' + else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_stdlib_h+:} false; 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 + + if test $ac_cv_header_stdlib_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif +_ACEOF + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac + gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/stdlib.h#{ + s#.*"\(.*/stdlib.h\)".*#\1# + s#^/[^/]#//&# + p + q + }'`'"' + else + gl_cv_next_stdlib_h='<'stdlib.h'>' + fi -#include -static long int longval () { return sizeof ($gltype) * CHAR_BIT; } -static unsigned long int ulongval () { return sizeof ($gltype) * CHAR_BIT; } -#include -#include -int -main () -{ +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5 +$as_echo "$gl_cv_next_stdlib_h" >&6; } + fi + NEXT_STDLIB_H=$gl_cv_next_stdlib_h - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if ((sizeof ($gltype) * CHAR_BIT) < 0) - { - long int i = longval (); - if (i != (sizeof ($gltype) * CHAR_BIT)) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != (sizeof ($gltype) * CHAR_BIT)) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; + if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' + gl_next_as_first_directive='<'stdlib.h'>' + else + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' + gl_next_as_first_directive=$gl_cv_next_stdlib_h + fi + NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive - ; - return 0; -} + + + for ac_header in random.h +do : + ac_fn_c_check_header_compile "$LINENO" "random.h" "ac_cv_header_random_h" "$ac_includes_default +" +if test "x$ac_cv_header_random_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_RANDOM_H 1 _ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - result=`cat conftest.val` -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 ) -result=unknown 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 -rm -f conftest.val - eval gl_cv_bitsizeof_${gltype}=\$result -fi -ac_res=`eval 'as_val=${'gl_cv_bitsizeof_${gltype}'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - eval result=\$gl_cv_bitsizeof_${gltype} - if test $result = unknown; then - result=0 - fi - GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` - cat >>confdefs.h <<_ACEOF -#define BITSIZEOF_${GLTYPE} $result -_ACEOF +done - eval BITSIZEOF_${GLTYPE}=\$result - done + if test $ac_cv_header_random_h = yes; then + HAVE_RANDOM_H=1 + else + HAVE_RANDOM_H=0 + fi + + ac_fn_c_check_type "$LINENO" "struct random_data" "ac_cv_type_struct_random_data" "#include + #if HAVE_RANDOM_H + # include + #endif +" +if test "x$ac_cv_type_struct_random_data" = xyes; then : +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_RANDOM_DATA 1 +_ACEOF +else + HAVE_STRUCT_RANDOM_DATA=0 +fi - for gltype in sig_atomic_t wchar_t wint_t ; do - { $as_echo "$as_me:$LINENO: checking whether $gltype is signed" >&5 -$as_echo_n "checking whether $gltype is signed... " >&6; } -if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then + for gl_func in _Exit atoll canonicalize_file_name getloadavg getsubopt grantpt mkdtemp mkostemp mkostemps mkstemp mkstemps ptsname random_r initstat_r srandom_r setstate_r realpath rpmatch setenv strtod strtoll strtoull unlockpt unsetenv; do + as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 +$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ +#include +#if HAVE_SYS_LOADAVG_H +# include +#endif +#if HAVE_RANDOM_H +# include +#endif - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif - - int verify[2 * (($gltype) -1 < ($gltype) 0) - 1]; int main () { - +#undef $gl_func + (void) $gl_func; ; 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 - result=yes +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - result=no + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - eval gl_cv_type_${gltype}_signed=\$result - fi -ac_res=`eval 'as_val=${'gl_cv_type_${gltype}_signed'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval result=\$gl_cv_type_${gltype}_signed - GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` - if test "$result" = yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_SIGNED_${GLTYPE} 1 + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF - eval HAVE_SIGNED_${GLTYPE}=1 - else - eval HAVE_SIGNED_${GLTYPE}=0 - fi - done + eval ac_cv_have_decl_$gl_func=yes +fi + done - gl_cv_type_ptrdiff_t_signed=yes - gl_cv_type_size_t_signed=no - if test $APPLE_UNIVERSAL_BUILD = 0; then + # Code from module streq: + # Code from module string: + # Code from module sys_socket: - for gltype in ptrdiff_t size_t ; do - { $as_echo "$as_me:$LINENO: checking for $gltype integer literal suffix" >&5 -$as_echo_n "checking for $gltype integer literal suffix... " >&6; } -if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether is self-contained" >&5 +$as_echo_n "checking whether is self-contained... " >&6; } +if ${gl_cv_header_sys_socket_h_selfcontained+:} false; then : $as_echo_n "(cached) " >&6 else - eval gl_cv_type_${gltype}_suffix=no - eval result=\$gl_cv_type_${gltype}_signed - if test "$result" = yes; then - glsufu= - else - glsufu=u - fi - for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do - case $glsuf in - '') gltype1='int';; - l) gltype1='long int';; - ll) gltype1='long long int';; - i64) gltype1='__int64';; - u) gltype1='unsigned int';; - ul) gltype1='unsigned long int';; - ull) gltype1='unsigned long long int';; - ui64)gltype1='unsigned __int64';; - esac - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif - extern $gltype foo; - extern $gltype1 foo; + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include int main () { @@ -29991,164 +18373,62 @@ 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 - eval gl_cv_type_${gltype}_suffix=\$glsuf +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_header_sys_socket_h_selfcontained=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - + gl_cv_header_sys_socket_h_selfcontained=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - eval result=\$gl_cv_type_${gltype}_suffix - test "$result" != no && break - done + fi -ac_res=`eval 'as_val=${'gl_cv_type_${gltype}_suffix'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` - eval result=\$gl_cv_type_${gltype}_suffix - test "$result" = no && result= - eval ${GLTYPE}_SUFFIX=\$result - cat >>confdefs.h <<_ACEOF -#define ${GLTYPE}_SUFFIX $result +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_selfcontained" >&5 +$as_echo "$gl_cv_header_sys_socket_h_selfcontained" >&6; } + if test $gl_cv_header_sys_socket_h_selfcontained = yes; then + for ac_func in shutdown +do : + ac_fn_c_check_func "$LINENO" "shutdown" "ac_cv_func_shutdown" +if test "x$ac_cv_func_shutdown" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SHUTDOWN 1 _ACEOF - done - - - fi - - - - +fi +done - for gltype in sig_atomic_t wchar_t wint_t ; do - { $as_echo "$as_me:$LINENO: checking for $gltype integer literal suffix" >&5 -$as_echo_n "checking for $gltype integer literal suffix... " >&6; } -if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then + if test $ac_cv_func_shutdown = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether defines the SHUT_* macros" >&5 +$as_echo_n "checking whether defines the SHUT_* macros... " >&6; } +if ${gl_cv_header_sys_socket_h_shut+:} false; then : $as_echo_n "(cached) " >&6 else - eval gl_cv_type_${gltype}_suffix=no - eval result=\$gl_cv_type_${gltype}_signed - if test "$result" = yes; then - glsufu= - else - glsufu=u - fi - for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do - case $glsuf in - '') gltype1='int';; - l) gltype1='long int';; - ll) gltype1='long long int';; - i64) gltype1='__int64';; - u) gltype1='unsigned int';; - ul) gltype1='unsigned long int';; - ull) gltype1='unsigned long long int';; - ui64)gltype1='unsigned __int64';; - esac - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - - /* BSD/OS 4.0.1 has a bug: , and must be - included before . */ - #include - #include - #if HAVE_WCHAR_H - # include - # include - # include - #endif - extern $gltype foo; - extern $gltype1 foo; + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include int main () { - +int a[] = { SHUT_RD, SHUT_WR, SHUT_RDWR }; ; 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 - eval gl_cv_type_${gltype}_suffix=\$glsuf +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_header_sys_socket_h_shut=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - + gl_cv_header_sys_socket_h_shut=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - eval result=\$gl_cv_type_${gltype}_suffix - test "$result" != no && break - done -fi -ac_res=`eval 'as_val=${'gl_cv_type_${gltype}_suffix'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'` - eval result=\$gl_cv_type_${gltype}_suffix - test "$result" = no && result= - eval ${GLTYPE}_SUFFIX=\$result - cat >>confdefs.h <<_ACEOF -#define ${GLTYPE}_SUFFIX $result -_ACEOF - - done - - - STDINT_H=stdint.h +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_shut" >&5 +$as_echo "$gl_cv_header_sys_socket_h_shut" >&6; } + if test $gl_cv_header_sys_socket_h_shut = no; then + SYS_SOCKET_H='sys/socket.h' + fi + fi fi - - - # Code from module stdio: - - - + # We need to check for ws2tcpip.h now. @@ -30163,95 +18443,178 @@ _ACEOF if test $gl_cv_have_include_next = yes; then - gl_cv_next_stdio_h='<'stdio.h'>' + gl_cv_next_sys_socket_h='<'sys/socket.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_stdio_h+set}" = set; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_sys_socket_h+:} false; then : $as_echo_n "(cached) " >&6 else - if test $ac_cv_header_stdio_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + if test $ac_cv_header_sys_socket_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include +#include _ACEOF case "$host_os" in aix*) gl_absname_cpp="$ac_cpp -C" ;; *) gl_absname_cpp="$ac_cpp" ;; esac - gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/stdio.h#{ - s#.*"\(.*/stdio.h\)".*#\1# + gl_cv_next_sys_socket_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/sys/socket.h#{ + s#.*"\(.*/sys/socket.h\)".*#\1# s#^/[^/]#//&# p q }'`'"' else - gl_cv_next_stdio_h='<'stdio.h'>' + gl_cv_next_sys_socket_h='<'sys/socket.h'>' fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_stdio_h" >&5 -$as_echo "$gl_cv_next_stdio_h" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_socket_h" >&5 +$as_echo "$gl_cv_next_sys_socket_h" >&6; } fi - NEXT_STDIO_H=$gl_cv_next_stdio_h + NEXT_SYS_SOCKET_H=$gl_cv_next_sys_socket_h if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'stdio.h'>' + gl_next_as_first_directive='<'sys/socket.h'>' else # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_stdio_h + gl_next_as_first_directive=$gl_cv_next_sys_socket_h fi - NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive - - + NEXT_AS_FIRST_DIRECTIVE_SYS_SOCKET_H=$gl_next_as_first_directive - GNULIB_FPRINTF=1 - GNULIB_PRINTF=1 - GNULIB_VFPRINTF=1 - GNULIB_VPRINTF=1 - GNULIB_FPUTC=1 - GNULIB_PUTC=1 - GNULIB_PUTCHAR=1 - GNULIB_FPUTS=1 - GNULIB_PUTS=1 - GNULIB_FWRITE=1 + + + if test $ac_cv_header_sys_socket_h = yes; then + HAVE_SYS_SOCKET_H=1 + HAVE_WS2TCPIP_H=0 + else + HAVE_SYS_SOCKET_H=0 + for ac_header in ws2tcpip.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default" +if test "x$ac_cv_header_ws2tcpip_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_WS2TCPIP_H 1 +_ACEOF + +fi + +done + + if test $ac_cv_header_ws2tcpip_h = yes; then + HAVE_WS2TCPIP_H=1 + else + HAVE_WS2TCPIP_H=0 + fi + fi + + + + ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" " + /* sys/types.h is not needed according to POSIX, but the + sys/socket.h in i386-unknown-freebsd4.10 and + powerpc-apple-darwin5.5 required it. */ +#include +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_WS2TCPIP_H +#include +#endif + +" +if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRUCT_SOCKADDR_STORAGE 1 +_ACEOF + + +fi +ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" " + /* sys/types.h is not needed according to POSIX, but the + sys/socket.h in i386-unknown-freebsd4.10 and + powerpc-apple-darwin5.5 required it. */ +#include +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_WS2TCPIP_H +#include +#endif + +" +if test "x$ac_cv_type_sa_family_t" = xyes; then : + +cat >>confdefs.h <<_ACEOF +#define HAVE_SA_FAMILY_T 1 +_ACEOF + + +fi + + if test $ac_cv_type_struct_sockaddr_storage = no; then + HAVE_STRUCT_SOCKADDR_STORAGE=0 + fi + if test $ac_cv_type_sa_family_t = no; then + HAVE_SA_FAMILY_T=0 + fi + : + + if test $ac_cv_header_sys_socket_h != yes; then + for ac_header in winsock2.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default" +if test "x$ac_cv_header_winsock2_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_WINSOCK2_H 1 +_ACEOF +fi +done + fi + if test "$ac_cv_header_winsock2_h" = yes; then + HAVE_WINSOCK2_H=1 + UNISTD_H_HAVE_WINSOCK2_H=1 + SYS_IOCTL_H_HAVE_WINSOCK2_H=1 + else + HAVE_WINSOCK2_H=0 + fi - for gl_func in dprintf fpurge fseeko ftello getdelim getline popen renameat snprintf tmpfile vdprintf vsnprintf; do + for gl_func in socket connect accept bind getpeername getsockname getsockopt listen recv send recvfrom sendto setsockopt shutdown accept4; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include + +/* Some systems require prerequisite headers. */ +#include +#if !defined __GLIBC__ && HAVE_SYS_TIME_H +# include +#endif +#include int main () @@ -30262,52 +18625,33 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done - # Code from module stdlib: + + # Code from module sys_stat: + + + + + @@ -30323,241 +18667,149 @@ fi if test $gl_cv_have_include_next = yes; then - gl_cv_next_stdlib_h='<'stdlib.h'>' + gl_cv_next_sys_stat_h='<'sys/stat.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_stdlib_h+set}" = set; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_sys_stat_h+:} false; then : $as_echo_n "(cached) " >&6 else - if test $ac_cv_header_stdlib_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + if test $ac_cv_header_sys_stat_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include +#include _ACEOF case "$host_os" in aix*) gl_absname_cpp="$ac_cpp -C" ;; *) gl_absname_cpp="$ac_cpp" ;; esac - gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/stdlib.h#{ - s#.*"\(.*/stdlib.h\)".*#\1# + gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/sys/stat.h#{ + s#.*"\(.*/sys/stat.h\)".*#\1# s#^/[^/]#//&# p q }'`'"' else - gl_cv_next_stdlib_h='<'stdlib.h'>' + gl_cv_next_sys_stat_h='<'sys/stat.h'>' fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_stdlib_h" >&5 -$as_echo "$gl_cv_next_stdlib_h" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5 +$as_echo "$gl_cv_next_sys_stat_h" >&6; } fi - NEXT_STDLIB_H=$gl_cv_next_stdlib_h + NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'stdlib.h'>' + gl_next_as_first_directive='<'sys/stat.h'>' else # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_stdlib_h + gl_next_as_first_directive=$gl_cv_next_sys_stat_h fi - NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive + NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive -for ac_header in random.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 + ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include + #include +" +if test "x$ac_cv_type_nlink_t" = xyes; then : -#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 +$as_echo "#define nlink_t int" >>confdefs.h fi -done - if test $ac_cv_header_random_h = yes; then - HAVE_RANDOM_H=1 - else - HAVE_RANDOM_H=0 - fi - { $as_echo "$as_me:$LINENO: checking for struct random_data" >&5 -$as_echo_n "checking for struct random_data... " >&6; } -if test "${ac_cv_type_struct_random_data+set}" = set; then + for gl_func in fchmodat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do + as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 +$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } +if eval \${$as_gl_Symbol+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_type_struct_random_data=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include - #if HAVE_RANDOM_H - # include - #endif - +#include int main () { -if (sizeof (struct random_data)) - return 0; +#undef $gl_func + (void) $gl_func; ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_gl_Symbol=yes" +else + eval "$as_gl_Symbol=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #if HAVE_RANDOM_H - # include - #endif + + eval ac_cv_have_decl_$gl_func=yes +fi + done + + + + # Code from module sys_time: + + + + + # Code from module tempname: + + + + + + + + + + + + gl_LIBOBJS="$gl_LIBOBJS tempname.$ac_objext" -int -main () -{ -if (sizeof ((struct random_data))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_type_struct_random_data=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + # Code from module threadlib: -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_random_data" >&5 -$as_echo "$ac_cv_type_struct_random_data" >&6; } -if test "x$ac_cv_type_struct_random_data" = x""yes; then -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_RANDOM_DATA 1 -_ACEOF + # Code from module time: + + + + # Code from module unistd: + + + -else - HAVE_STRUCT_RANDOM_DATA=0 -fi + : @@ -30565,42 +18817,87 @@ fi + if test $gl_cv_have_include_next = yes; then + gl_cv_next_unistd_h='<'unistd.h'>' + else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_unistd_h+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test $ac_cv_header_unistd_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +_ACEOF + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac + gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/unistd.h#{ + s#.*"\(.*/unistd.h\)".*#\1# + s#^/[^/]#//&# + p + q + }'`'"' + else + gl_cv_next_unistd_h='<'unistd.h'>' + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5 +$as_echo "$gl_cv_next_unistd_h" >&6; } + fi + NEXT_UNISTD_H=$gl_cv_next_unistd_h + if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' + gl_next_as_first_directive='<'unistd.h'>' + else + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' + gl_next_as_first_directive=$gl_cv_next_unistd_h + fi + NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive + : + if test $ac_cv_header_unistd_h = yes; then + HAVE_UNISTD_H=1 + else + HAVE_UNISTD_H=0 + fi - for gl_func in _Exit atoll canonicalize_file_name getloadavg getsubopt grantpt mkdtemp mkostemp mkostemps mkstemp mkstemps ptsname random_r initstat_r srandom_r setstate_r realpath rpmatch setenv strtod strtoll strtoull unlockpt unsetenv; do + for gl_func in chown dup2 dup3 environ euidaccess faccessat fchdir fchownat fsync ftruncate getcwd getdomainname getdtablesize getgroups gethostname getlogin getlogin_r getpagesize getusershell setusershell endusershell lchown link linkat lseek pipe2 pread pwrite readlink readlinkat rmdir sleep symlink symlinkat ttyname_r unlink unlinkat usleep; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -#if HAVE_SYS_LOADAVG_H -# include -#endif -#if HAVE_RANDOM_H -# include +#include +/* Some systems declare various items in the wrong headers. */ +#ifndef __GLIBC__ +# include +# include +# include +# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ +# include +# endif #endif int @@ -30612,280 +18909,63 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done - # Code from module streq: - # Code from module string: + # Code from module vasnprintf: + : - # Code from module sys_socket: - { $as_echo "$as_me:$LINENO: checking whether is self-contained" >&5 -$as_echo_n "checking whether is self-contained... " >&6; } -if test "${gl_cv_header_sys_socket_h_selfcontained+set}" = set; then - $as_echo_n "(cached) " >&6 -else + if test $ac_cv_func_vasnprintf = no; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#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 - gl_cv_header_sys_socket_h_selfcontained=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + : - gl_cv_header_sys_socket_h_selfcontained=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_sys_socket_h_selfcontained" >&5 -$as_echo "$gl_cv_header_sys_socket_h_selfcontained" >&6; } - if test $gl_cv_header_sys_socket_h_selfcontained = yes; then -for ac_func in shutdown -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ -#ifdef __STDC__ -# include -#else -# include -#endif -#undef $ac_func -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_ac_var=no" -fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF -fi -done - if test $ac_cv_func_shutdown = yes; then - { $as_echo "$as_me:$LINENO: checking whether defines the SHUT_* macros" >&5 -$as_echo_n "checking whether defines the SHUT_* macros... " >&6; } -if test "${gl_cv_header_sys_socket_h_shut+set}" = set; then - $as_echo_n "(cached) " >&6 -else + gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -int a[] = { SHUT_RD, SHUT_WR, SHUT_RDWR }; - ; - 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 - gl_cv_header_sys_socket_h_shut=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - gl_cv_header_sys_socket_h_shut=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_header_sys_socket_h_shut" >&5 -$as_echo "$gl_cv_header_sys_socket_h_shut" >&6; } - if test $gl_cv_header_sys_socket_h_shut = no; then - SYS_SOCKET_H='sys/socket.h' - fi - fi - fi - # We need to check for ws2tcpip.h now. - : + gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext" @@ -30893,476 +18973,66 @@ $as_echo "$gl_cv_header_sys_socket_h_shut" >&6; } - if test $gl_cv_have_include_next = yes; then - gl_cv_next_sys_socket_h='<'sys/socket.h'>' - else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_sys_socket_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test $ac_cv_header_sys_socket_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -_ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac - gl_cv_next_sys_socket_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/sys/socket.h#{ - s#.*"\(.*/sys/socket.h\)".*#\1# - s#^/[^/]#//&# - p - q - }'`'"' - else - gl_cv_next_sys_socket_h='<'sys/socket.h'>' - fi + gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext" -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_sys_socket_h" >&5 -$as_echo "$gl_cv_next_sys_socket_h" >&6; } - fi - NEXT_SYS_SOCKET_H=$gl_cv_next_sys_socket_h - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'sys/socket.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_sys_socket_h - fi - NEXT_AS_FIRST_DIRECTIVE_SYS_SOCKET_H=$gl_next_as_first_directive - - - - if test $ac_cv_header_sys_socket_h = yes; then - HAVE_SYS_SOCKET_H=1 - HAVE_WS2TCPIP_H=0 - else - HAVE_SYS_SOCKET_H=0 - -for ac_header in ws2tcpip.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;} - ;; -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 + gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext" -fi + if test $ac_cv_func_vasnprintf = yes; then -done +$as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h - if test $ac_cv_header_ws2tcpip_h = yes; then - HAVE_WS2TCPIP_H=1 - else - HAVE_WS2TCPIP_H=0 - fi fi - { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5 -$as_echo_n "checking for struct sockaddr_storage... " >&6; } -if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_struct_sockaddr_storage=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - /* sys/types.h is not needed according to POSIX, but the - sys/socket.h in i386-unknown-freebsd4.10 and - powerpc-apple-darwin5.5 required it. */ -#include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_WS2TCPIP_H -#include -#endif -int -main () -{ -if (sizeof (struct sockaddr_storage)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - /* sys/types.h is not needed according to POSIX, but the - sys/socket.h in i386-unknown-freebsd4.10 and - powerpc-apple-darwin5.5 required it. */ -#include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_WS2TCPIP_H -#include -#endif -int -main () -{ -if (sizeof ((struct sockaddr_storage))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_type_struct_sockaddr_storage=yes -fi + ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" +if test "x$ac_cv_type_ptrdiff_t" = xyes; then : -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +$as_echo "#define ptrdiff_t long" >>confdefs.h -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5 -$as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; } -if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STRUCT_SOCKADDR_STORAGE 1 -_ACEOF -fi -{ $as_echo "$as_me:$LINENO: checking for sa_family_t" >&5 -$as_echo_n "checking for sa_family_t... " >&6; } -if test "${ac_cv_type_sa_family_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_sa_family_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - /* sys/types.h is not needed according to POSIX, but the - sys/socket.h in i386-unknown-freebsd4.10 and - powerpc-apple-darwin5.5 required it. */ -#include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_WS2TCPIP_H -#include -#endif -int -main () -{ -if (sizeof (sa_family_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - /* sys/types.h is not needed according to POSIX, but the - sys/socket.h in i386-unknown-freebsd4.10 and - powerpc-apple-darwin5.5 required it. */ -#include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_WS2TCPIP_H -#include -#endif + fi -int -main () -{ -if (sizeof ((sa_family_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + # Code from module verify: + # Code from module warn-on-use: + # Code from module wchar: - ac_cv_type_sa_family_t=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 -fi + : -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_sa_family_t" >&5 -$as_echo "$ac_cv_type_sa_family_t" >&6; } -if test "x$ac_cv_type_sa_family_t" = x""yes; then -cat >>confdefs.h <<_ACEOF -#define HAVE_SA_FAMILY_T 1 -_ACEOF -fi - if test $ac_cv_type_struct_sockaddr_storage = no; then - HAVE_STRUCT_SOCKADDR_STORAGE=0 - fi - if test $ac_cv_type_sa_family_t = no; then - HAVE_SA_FAMILY_T=0 - fi @@ -31373,200 +19043,88 @@ fi - if test $ac_cv_header_sys_socket_h != yes; then -for ac_header in winsock2.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 + + if test $gl_cv_have_include_next = yes; then + gl_cv_next_wchar_h='<'wchar.h'>' + else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_wchar_h+:} false; 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 + if test $ac_cv_header_wchar_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* 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; } +#include -# 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;} +_ACEOF + case "$host_os" in + aix*) gl_absname_cpp="$ac_cpp -C" ;; + *) gl_absname_cpp="$ac_cpp" ;; + esac + gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/wchar.h#{ + s#.*"\(.*/wchar.h\)".*#\1# + s#^/[^/]#//&# + p + q + }'`'"' + else + gl_cv_next_wchar_h='<'wchar.h'>' + fi - ;; -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; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5 +$as_echo "$gl_cv_next_wchar_h" >&6; } + fi + NEXT_WCHAR_H=$gl_cv_next_wchar_h -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 + if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' + gl_next_as_first_directive='<'wchar.h'>' + else + # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' + gl_next_as_first_directive=$gl_cv_next_wchar_h + fi + NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive -fi -done - fi - if test "$ac_cv_header_winsock2_h" = yes; then - HAVE_WINSOCK2_H=1 - UNISTD_H_HAVE_WINSOCK2_H=1 - SYS_IOCTL_H_HAVE_WINSOCK2_H=1 + if test $ac_cv_header_wchar_h = yes; then + HAVE_WCHAR_H=1 else - HAVE_WINSOCK2_H=0 + HAVE_WCHAR_H=0 fi + if test $gt_cv_c_wint_t = yes; then + HAVE_WINT_T=1 + else + HAVE_WINT_T=0 + fi - - - - - - - - - - - - - - for gl_func in socket connect accept bind getpeername getsockname getsockopt listen recv send recvfrom sendto setsockopt shutdown accept4; do + for gl_func in btowc wctob mbsinit mbrtowc mbrlen mbsrtowcs mbsnrtowcs wcrtomb wcsrtombs wcsnrtombs wcwidth; do as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gl_func is declared without a macro" >&5 $as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then +if eval \${$as_gl_Symbol+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Some systems require prerequisite headers. */ -#include -#if !defined __GLIBC__ && HAVE_SYS_TIME_H -# include +/* Some systems require additional headers. */ +#ifndef __GLIBC__ +# include +# include +# include #endif -#include +#include int main () @@ -31577,100 +19135,37 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : eval "$as_gl_Symbol=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + eval "$as_gl_Symbol=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 +eval ac_res=\$$as_gl_Symbol + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + if eval test \"x\$"$as_gl_Symbol"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 _ACEOF eval ac_cv_have_decl_$gl_func=yes fi - done - { $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 + # Code from module wcrtomb: -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; } - # Code from module sys_stat: + : @@ -31683,373 +19178,375 @@ $as_echo "$MKDIR_P" >&6; } + if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then - if test $gl_cv_have_include_next = yes; then - gl_cv_next_sys_stat_h='<'sys/stat.h'>' - else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_sys_stat_h+set}" = set; then + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5 +$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; } +if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then : $as_echo_n "(cached) " >&6 else - if test $ac_cv_header_sys_stat_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + case "$host_os" in + # Guess no on AIX and OSF/1. + aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;; + # Guess yes otherwise. + *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;; + esac + if test $LOCALE_JA != none; then + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -_ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac - gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/sys/stat.h#{ - s#.*"\(.*/sys/stat.h\)".*#\1# - s#^/[^/]#//&# - p - q - }'`'"' - else - gl_cv_next_sys_stat_h='<'sys/stat.h'>' - fi +#include +#include +#include +int main () +{ + if (setlocale (LC_ALL, "$LOCALE_JA") != NULL) + { + const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */ + mbstate_t state; + wchar_t wc; + memset (&state, '\0', sizeof (mbstate_t)); + if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2)) + if (mbsinit (&state)) + return 1; + } + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_mbrtowc_incomplete_state=yes +else + gl_cv_func_mbrtowc_incomplete_state=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_sys_stat_h" >&5 -$as_echo "$gl_cv_next_sys_stat_h" >&6; } - fi - NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'sys/stat.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_sys_stat_h - fi - NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive + fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5 +$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; } - { $as_echo "$as_me:$LINENO: checking for nlink_t" >&5 -$as_echo_n "checking for nlink_t... " >&6; } -if test "${ac_cv_type_nlink_t+set}" = set; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5 +$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; } +if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_type_nlink_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + + case "$host_os" in + # Guess no on Solaris 8. + solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;; + # Guess yes otherwise. + *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;; + esac + if test $LOCALE_ZH_CN != none; then + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include - #include -int -main () +#include +#include +#include +#include +int main () { -if (sizeof (nlink_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #include + /* This fails on Solaris 8: + mbrtowc returns 2, and sets wc to 0x00F0. + mbtowc returns 4 (correct) and sets wc to 0x5EDC. */ + if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL) + { + char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */ + mbstate_t state; + wchar_t wc; -int -main () -{ -if (sizeof ((nlink_t))) - return 0; - ; + memset (&state, '\0', sizeof (mbstate_t)); + if (mbrtowc (&wc, input + 3, 6, &state) != 4 + && mbtowc (&wc, input + 3, 6) == 4) + return 1; + } return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_nlink_t=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_mbrtowc_sanitycheck=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - + gl_cv_func_mbrtowc_sanitycheck=no fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_nlink_t" >&5 -$as_echo "$ac_cv_type_nlink_t" >&6; } -if test "x$ac_cv_type_nlink_t" = x""yes; then - : -else -cat >>confdefs.h <<\_ACEOF -#define nlink_t int -_ACEOF + fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5 +$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; } + + REPLACE_MBSTATE_T=0 + case "$gl_cv_func_mbrtowc_incomplete_state" in + *yes) ;; + *) REPLACE_MBSTATE_T=1 ;; + esac + case "$gl_cv_func_mbrtowc_sanitycheck" in + *yes) ;; + *) REPLACE_MBSTATE_T=1 ;; + esac + else + REPLACE_MBSTATE_T=1 + fi + if test $REPLACE_MBSTATE_T = 1; then + : + fi + : + if test $ac_cv_func_wcrtomb = no; then + HAVE_WCRTOMB=0 + else + if test $REPLACE_MBSTATE_T = 1; then + REPLACE_WCRTOMB=1 + else - for gl_func in fchmodat fstatat futimens lchmod lstat mkdirat mkfifo mkfifoat mknod mknodat stat utimensat; do - as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 -$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; eval "test \"\${$as_var+set}\" = set"; }; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wcrtomb return value is correct" >&5 +$as_echo_n "checking whether wcrtomb return value is correct... " >&6; } +if ${gl_cv_func_wcrtomb_retval+:} false; 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 + + case "$host_os" in + # Guess no on AIX 4, OSF/1 and Solaris. + aix4* | osf* | solaris*) gl_cv_func_wcrtomb_retval="guessing no" ;; + # Guess yes otherwise. + *) gl_cv_func_wcrtomb_retval="guessing yes" ;; + esac + if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then + if test "$cross_compiling" = yes; then : + : +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include -int -main () +#include +#include +#include +#include +int main () { -#undef $gl_func - (void) $gl_func; - ; + if (setlocale (LC_ALL, "$LOCALE_FR") != NULL) + { + if (wcrtomb (NULL, 0, NULL) != 1) + return 1; + } + if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL) + { + if (wcrtomb (NULL, 0, NULL) != 1) + return 1; + } + if (setlocale (LC_ALL, "$LOCALE_JA") != NULL) + { + if (wcrtomb (NULL, 0, NULL) != 1) + return 1; + } + if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL) + { + if (wcrtomb (NULL, 0, NULL) != 1) + return 1; + } return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - eval "$as_gl_Symbol=yes" +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_wcrtomb_retval=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" + gl_cv_func_wcrtomb_retval=no fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 -_ACEOF - eval ac_cv_have_decl_$gl_func=yes + fi + fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcrtomb_retval" >&5 +$as_echo "$gl_cv_func_wcrtomb_retval" >&6; } + case "$gl_cv_func_wcrtomb_retval" in + *yes) ;; + *) REPLACE_WCRTOMB=1 ;; + esac + fi + fi + if test $HAVE_WCRTOMB = 0 || test $REPLACE_WCRTOMB = 1; then - done + : - { $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" + + + + + + gl_LIBOBJS="$gl_LIBOBJS wcrtomb.$ac_objext" + + + : + fi -fi -{ $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5 -$as_echo "$MKDIR_P" >&6; } - # Code from module sys_time: + GNULIB_WCRTOMB=1 - { $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" +$as_echo "#define GNULIB_TEST_WCRTOMB 1" >>confdefs.h + + + + # Code from module wctype: + + + + + : + + + + + + if test $ac_cv_func_iswcntrl = yes; then + HAVE_ISWCNTRL=1 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" + HAVE_ISWCNTRL=0 fi -fi -{ $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5 -$as_echo "$MKDIR_P" >&6; } - # Code from module tempname: + : + : - gl_LIBOBJS="$gl_LIBOBJS tempname.$ac_objext" + if test $ac_cv_func_iswblank = yes; then + HAVE_ISWBLANK=1 + REPLACE_ISWBLANK=0 + else + HAVE_ISWBLANK=0 + if test $ac_cv_have_decl_iswblank = yes; then + REPLACE_ISWBLANK=1 + else + REPLACE_ISWBLANK=0 + fi + fi + + : - # Code from module threadlib: - # Code from module time: + if test $gt_cv_c_wint_t = yes; then + HAVE_WINT_T=1 + else + HAVE_WINT_T=0 + fi + - # Code from module unistd: + if test $ac_cv_header_wctype_h = yes; then + if test $ac_cv_func_iswcntrl = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5 +$as_echo_n "checking whether iswcntrl works... " >&6; } +if ${gl_cv_func_iswcntrl_works+:} false; then : + $as_echo_n "(cached) " >&6 +else + + if test "$cross_compiling" = yes; then : + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #if __GNU_LIBRARY__ == 1 + Linux libc5 i18n is broken. + #endif +int +main () +{ + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + gl_cv_func_iswcntrl_works=yes +else + gl_cv_func_iswcntrl_works=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + #include + #include + #include + #include + #include + int main () { return iswprint ('x') == 0; } +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + gl_cv_func_iswcntrl_works=yes +else + gl_cv_func_iswcntrl_works=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5 +$as_echo "$gl_cv_func_iswcntrl_works" >&6; } + fi @@ -32063,73 +19560,66 @@ $as_echo "$MKDIR_P" >&6; } if test $gl_cv_have_include_next = yes; then - gl_cv_next_unistd_h='<'unistd.h'>' + gl_cv_next_wctype_h='<'wctype.h'>' else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_unistd_h+set}" = set; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of " >&5 +$as_echo_n "checking absolute name of ... " >&6; } +if ${gl_cv_next_wctype_h+:} false; then : $as_echo_n "(cached) " >&6 else - if test $ac_cv_header_unistd_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + if test $ac_cv_header_wctype_h = yes; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include +#include _ACEOF case "$host_os" in aix*) gl_absname_cpp="$ac_cpp -C" ;; *) gl_absname_cpp="$ac_cpp" ;; esac - gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/unistd.h#{ - s#.*"\(.*/unistd.h\)".*#\1# + gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | + sed -n '\#/wctype.h#{ + s#.*"\(.*/wctype.h\)".*#\1# s#^/[^/]#//&# p q }'`'"' else - gl_cv_next_unistd_h='<'unistd.h'>' + gl_cv_next_wctype_h='<'wctype.h'>' fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_unistd_h" >&5 -$as_echo "$gl_cv_next_unistd_h" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5 +$as_echo "$gl_cv_next_wctype_h" >&6; } fi - NEXT_UNISTD_H=$gl_cv_next_unistd_h + NEXT_WCTYPE_H=$gl_cv_next_wctype_h if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'unistd.h'>' + gl_next_as_first_directive='<'wctype.h'>' else # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_unistd_h + gl_next_as_first_directive=$gl_cv_next_wctype_h fi - NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive - - - - - - : - - + NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive - if test $ac_cv_header_unistd_h = yes; then - HAVE_UNISTD_H=1 + HAVE_WCTYPE_H=1 else - HAVE_UNISTD_H=0 + HAVE_WCTYPE_H=0 fi + if test "$gl_cv_func_iswcntrl_works" = no; then + REPLACE_ISWCNTRL=1 + else + REPLACE_ISWCNTRL=0 + fi + # Code from module write: @@ -32137,19 +19627,32 @@ $as_echo "$gl_cv_next_unistd_h" >&6; } + GNULIB_WRITE=1 +$as_echo "#define GNULIB_TEST_WRITE 1" >>confdefs.h + # Code from module xsize: + for ac_header in stdint.h +do : + ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default" +if test "x$ac_cv_header_stdint_h" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_STDINT_H 1 +_ACEOF +fi +done + # End of code from modules @@ -32159,6 +19662,8 @@ $as_echo "$gl_cv_next_unistd_h" >&6; } + gltests_libdeps= + gltests_ltlibdeps= @@ -32166,2620 +19671,2563 @@ $as_echo "$gl_cv_next_unistd_h" >&6; } - - for gl_func in chown dup2 dup3 environ euidaccess faccessat fchdir fchownat fsync ftruncate getcwd getdomainname getdtablesize getgroups gethostname getlogin getlogin_r getpagesize getusershell setusershell endusershell lchown link linkat lseek pipe2 pread pwrite readlink readlinkat rmdir sleep symlink symlinkat ttyname_r unlink unlinkat usleep; do - as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 -$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; 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. */ -#include -/* Some systems declare various items in the wrong headers. */ -#ifndef __GLIBC__ -# include -# include -# include -# if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__ -# include -# endif -#endif - -int -main () -{ -#undef $gl_func - (void) $gl_func; - ; - 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 - eval "$as_gl_Symbol=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_gl_Symbol=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 -_ACEOF - - eval ac_cv_have_decl_$gl_func=yes -fi - - done - # Code from module vasnprintf: + gl_source_base='tests' + gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS + gl_module_indicator_condition=$gltests_WITNESS - : - if test $ac_cv_func_vasnprintf = no; then - : + # support deprecated ./configure flags to set various compiler flags +# Check whether --with-cflags was given. +if test "${with_cflags+set}" = set; then : + withval=$with_cflags; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-cflags option." "$LINENO" 5 + ;; + esac + CFLAGS="$withval" +fi +# Check whether --with-includes was given. +if test "${with_includes+set}" = set; then : + withval=$with_includes; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-includes option." "$LINENO" 5 + ;; + esac - gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext" + for dir in $withval; do + if test -d "$dir"; then + CPPFLAGS="$CPPFLAGS -I$dir" + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Include directory $dir does not exist." >&5 +$as_echo "$as_me: WARNING: Include directory $dir does not exist." >&2;} + cat <>config.warnings +Include directory $dir does not exist. +AAW_EOF + fi + done +fi - gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext" +# Check whether --with-libraries was given. +if test "${with_libraries+set}" = set; then : + withval=$with_libraries; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-libraries option." "$LINENO" 5 + ;; + esac + for dir in $withval; do + if test -d "$dir"; then + case "$host" in + *-solaris2*,*-netbsd*) + LDFLAGS="$LDFLAGS -R$dir" + ;; + esac + LDFLAGS="$LDFLAGS -L$dir" + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Library directory $dir does not exist." >&5 +$as_echo "$as_me: WARNING: Library directory $dir does not exist." >&2;} + cat <>config.warnings +Library directory $dir does not exist. +AAW_EOF + fi + done +fi - gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext" + # Disable strict-aliasing optimizations + # test for -W'feature', then add the 'no-' version. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -fstrict-aliasing" >&5 +$as_echo_n "checking for gcc flag -fstrict-aliasing... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-fstrict-aliasing[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + CFLAGS="$CFLAGS -fno-strict-aliasing" + CPPFLAGS="$CPPFLAGS -fno-strict-aliasing" + else + : + fi - gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext" - if test $ac_cv_func_vasnprintf = yes; then -cat >>confdefs.h <<\_ACEOF -#define REPLACE_VASNPRINTF 1 -_ACEOF + # Warn for just about everything - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wall" >&5 +$as_echo_n "checking for gcc flag -Wall... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wall[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wall" + else + : + fi + # And add any extra warnings too - { $as_echo "$as_me:$LINENO: checking for ptrdiff_t" >&5 -$as_echo_n "checking for ptrdiff_t... " >&6; } -if test "${ac_cv_type_ptrdiff_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_ptrdiff_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof (ptrdiff_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof ((ptrdiff_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_type_ptrdiff_t=yes -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wextra" >&5 +$as_echo_n "checking for gcc flag -Wextra... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wextra[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wextra" -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5 -$as_echo "$ac_cv_type_ptrdiff_t" >&6; } -if test "x$ac_cv_type_ptrdiff_t" = x""yes; then - : -else + else -cat >>confdefs.h <<\_ACEOF -#define ptrdiff_t long -_ACEOF -fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -W" >&5 +$as_echo_n "checking for gcc flag -W... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '^[:alnum:]-W^[:alnum:]-' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -W" + else + : + fi + fi - fi - # Code from module verify: - # Code from module warn-on-use: - # Code from module wchar: +CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" + # Check whether --enable-as-needed was given. +if test "${enable_as_needed+set}" = set; then : + enableval=$enable_as_needed; WANT_AS_NEEDED=$enableval +else + WANT_AS_NEEDED=no +fi - : + if test x"$WANT_AS_NEEDED" = x"yes"; then + WANT_AS_NEEDED_TRUE= + WANT_AS_NEEDED_FALSE='#' +else + WANT_AS_NEEDED_TRUE='#' + WANT_AS_NEEDED_FALSE= +fi + if test x"$WANT_AS_NEEDED" = x"yes"; then + AS_NEEDED_FLAGS="-Wl,--as-needed" + else + AS_NEEDED_FLAGS="" + fi +# +# Configuration flags (--with-xxx and --enable-xxx) +# - : +# Check whether --with-user was given. +if test "${with_user+set}" = set; then : + withval=$with_user; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-user option." "$LINENO" 5 + ;; + *) + CLIENT_LOGIN="$withval" + ;; + esac +else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no user specified (--with-user) -- using 'amanda'" >&5 +$as_echo "$as_me: WARNING: no user specified (--with-user) -- using 'amanda'" >&2;} + cat <>config.warnings +no user specified (--with-user) -- using 'amanda' +AAW_EOF - if test $gl_cv_have_include_next = yes; then - gl_cv_next_wchar_h='<'wchar.h'>' - else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_wchar_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else + CLIENT_LOGIN=amanda + + +fi - if test $ac_cv_header_wchar_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include + +cat >>confdefs.h <<_ACEOF +#define CLIENT_LOGIN "$CLIENT_LOGIN" _ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; + + + + + +# Check whether --with-group was given. +if test "${with_group+set}" = set; then : + withval=$with_group; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-group option." "$LINENO" 5 + ;; + *) SETUID_GROUP="$withval" + ;; esac - gl_cv_next_wchar_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/wchar.h#{ - s#.*"\(.*/wchar.h\)".*#\1# - s#^/[^/]#//&# - p - q - }'`'"' - else - gl_cv_next_wchar_h='<'wchar.h'>' - fi -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_wchar_h" >&5 -$as_echo "$gl_cv_next_wchar_h" >&6; } - fi - NEXT_WCHAR_H=$gl_cv_next_wchar_h +else - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'wchar.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_wchar_h - fi - NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no group specified (--with-group) -- using 'backup'" >&5 +$as_echo "$as_me: WARNING: no group specified (--with-group) -- using 'backup'" >&2;} - if test $ac_cv_header_wchar_h = yes; then - HAVE_WCHAR_H=1 - else - HAVE_WCHAR_H=0 - fi + cat <>config.warnings +no group specified (--with-group) -- using 'backup' +AAW_EOF + SETUID_GROUP=backup - if test $gt_cv_c_wint_t = yes; then - HAVE_WINT_T=1 - else - HAVE_WINT_T=0 - fi +fi +# Check whether --with-dumperdir was given. +if test "${with_dumperdir+set}" = set; then : + withval=$with_dumperdir; + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-dumperdir is no longer used." >&5 +$as_echo "$as_me: WARNING: --with-dumperdir is no longer used." >&2;} + cat <>config.warnings +--with-dumperdir is no longer used. +AAW_EOF +fi - for gl_func in btowc wctob mbsinit mbrtowc mbrlen mbsrtowcs mbsnrtowcs wcrtomb wcsrtombs wcsnrtombs wcwidth; do - as_gl_Symbol=`$as_echo "gl_cv_have_raw_decl_$gl_func" | $as_tr_sh` - { $as_echo "$as_me:$LINENO: checking whether $gl_func is declared without a macro" >&5 -$as_echo_n "checking whether $gl_func is declared without a macro... " >&6; } -if { as_var=$as_gl_Symbol; 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. */ -/* Some systems require additional headers. */ -#ifndef __GLIBC__ -# include -# include -# include -#endif -#include -int -main () -{ -#undef $gl_func - (void) $gl_func; - ; - 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 - eval "$as_gl_Symbol=yes" + +# Check whether --with-configdir was given. +if test "${with_configdir+set}" = set; then : + withval=$with_configdir; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-configdir option." "$LINENO" 5 + ;; + *) CONFIG_DIR="$withval" + ;; + esac + else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_gl_Symbol=no" -fi + : ${CONFIG_DIR='${sysconfdir}/amanda'} # (variable will be evaluated below) -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } - as_val=`eval 'as_val=${'$as_gl_Symbol'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_RAW_DECL_$gl_func" | $as_tr_cpp` 1 -_ACEOF - eval ac_cv_have_decl_$gl_func=yes fi - done + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$CONFIG_DIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + CONFIG_DIR="$ac_define_dir" - # Code from module wcrtomb: +cat >>confdefs.h <<_ACEOF +#define CONFIG_DIR "$ac_define_dir" +_ACEOF + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE +# Check whether --with-indexdir was given. +if test "${with_indexdir+set}" = set; then : + withval=$with_indexdir; as_fn_error $? "*** --with-indexdir is deprecated; use indexdir in amanda.conf instead." "$LINENO" 5 +fi - : +# Check whether --with-dbdir was given. +if test "${with_dbdir+set}" = set; then : + withval=$with_dbdir; as_fn_error $? "*** --with-dbdir is deprecated; use infofile in amanda.conf instead." "$LINENO" 5 +fi - : +# Check whether --with-logdir was given. +if test "${with_logdir+set}" = set; then : + withval=$with_logdir; as_fn_error $? "*** --with-logdir is deprecated; use logfile in amanda.conf instead." "$LINENO" 5 +fi - if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then +# Check whether --with-suffixes was given. +if test "${with_suffixes+set}" = set; then : + withval=$with_suffixes; + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ** --with-suffixes is deprecated" >&5 +$as_echo "$as_me: WARNING: ** --with-suffixes is deprecated" >&2;} - { $as_echo "$as_me:$LINENO: checking whether mbrtowc handles incomplete characters" >&5 -$as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; } -if test "${gl_cv_func_mbrtowc_incomplete_state+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case "$host_os" in - # Guess no on AIX and OSF/1. - aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;; - # Guess yes otherwise. - *) gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;; - esac - if test $LOCALE_JA != none; then - 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. */ + cat <>config.warnings +** --with-suffixes is deprecated +AAW_EOF -#include -#include -#include -int main () -{ - if (setlocale (LC_ALL, "$LOCALE_JA") != NULL) - { - const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */ - mbstate_t state; - wchar_t wc; - memset (&state, '\0', sizeof (mbstate_t)); - if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2)) - if (mbsinit (&state)) - return 1; - } - 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 - gl_cv_func_mbrtowc_incomplete_state=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 -( exit $ac_status ) -gl_cv_func_mbrtowc_incomplete_state=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 + + +# Check whether --with-gnutar-listdir was given. +if test "${with_gnutar_listdir+set}" = set; then : + withval=$with_gnutar_listdir; + case "$withval" in + n | no) GNUTAR_LISTDIR= ;; + y | ye | yes) GNUTAR_LISTDIR='${localstatedir}/amanda/gnutar-lists' ;; + *) GNUTAR_LISTDIR="$withval" ;; + esac + +else + + GNUTAR_LISTDIR='${localstatedir}/amanda/gnutar-lists' + fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_incomplete_state" >&5 -$as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; } + # substitute $prefix, etc. if necessary + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$GNUTAR_LISTDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + GNUTAR_LISTED_INCREMENTAL_DIR="$ac_define_dir" - { $as_echo "$as_me:$LINENO: checking whether mbrtowc works as well as mbtowc" >&5 -$as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; } -if test "${gl_cv_func_mbrtowc_sanitycheck+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case "$host_os" in - # Guess no on Solaris 8. - solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;; - # Guess yes otherwise. - *) gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;; - esac - if test $LOCALE_ZH_CN != none; then - if test "$cross_compiling" = yes; then - : -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +cat >>confdefs.h <<_ACEOF +#define GNUTAR_LISTED_INCREMENTAL_DIR "$ac_define_dir" _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#include -#include -int main () -{ - /* This fails on Solaris 8: - mbrtowc returns 2, and sets wc to 0x00F0. - mbtowc returns 4 (correct) and sets wc to 0x5EDC. */ - if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL) - { - char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */ - mbstate_t state; - wchar_t wc; + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE - memset (&state, '\0', sizeof (mbstate_t)); - if (mbrtowc (&wc, input + 3, 6, &state) != 4 - && mbtowc (&wc, input + 3, 6) == 4) - return 1; - } - 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 - gl_cv_func_mbrtowc_sanitycheck=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 -( exit $ac_status ) -gl_cv_func_mbrtowc_sanitycheck=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 + # handle deprecated option +# Check whether --with-gnutar-listed-incremental was given. +if test "${with_gnutar_listed_incremental+set}" = set; then : + withval=$with_gnutar_listed_incremental; + as_fn_error $? "*** The gnutar-listed-incremental option is deprecated; use --with-gnutar-listdir instead" "$LINENO" 5 - fi fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_mbrtowc_sanitycheck" >&5 -$as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; } - REPLACE_MBSTATE_T=0 - case "$gl_cv_func_mbrtowc_incomplete_state" in - *yes) ;; - *) REPLACE_MBSTATE_T=1 ;; - esac - case "$gl_cv_func_mbrtowc_sanitycheck" in - *yes) ;; - *) REPLACE_MBSTATE_T=1 ;; - esac - else - REPLACE_MBSTATE_T=1 - fi - if test $REPLACE_MBSTATE_T = 1; then - : - fi +# Check whether --with-tmpdir was given. +if test "${with_tmpdir+set}" = set; then : + withval=$with_tmpdir; + tmpdir="$withval" +else - : + tmpdir=yes +fi + case "$tmpdir" in + n | no) as_fn_error $? "*** --without-tmpdir is not allowed." "$LINENO" 5;; + y | ye | yes) AMANDA_TMPDIR="/tmp/amanda";; + *) AMANDA_TMPDIR="$tmpdir";; + esac - if test $ac_cv_func_wcrtomb = no; then - HAVE_WCRTOMB=0 - else - if test $REPLACE_MBSTATE_T = 1; then - REPLACE_WCRTOMB=1 - else + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$AMANDA_TMPDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + AMANDA_TMPDIR="$ac_define_dir" +cat >>confdefs.h <<_ACEOF +#define AMANDA_TMPDIR "$ac_define_dir" +_ACEOF + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE - { $as_echo "$as_me:$LINENO: checking whether wcrtomb return value is correct" >&5 -$as_echo_n "checking whether wcrtomb return value is correct... " >&6; } -if test "${gl_cv_func_wcrtomb_retval+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case "$host_os" in - # Guess no on AIX 4, OSF/1 and Solaris. - aix4* | osf* | solaris*) gl_cv_func_wcrtomb_retval="guessing no" ;; - # Guess yes otherwise. - *) gl_cv_func_wcrtomb_retval="guessing yes" ;; - esac - if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then - 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 -#include -#include -int main () -{ - if (setlocale (LC_ALL, "$LOCALE_FR") != NULL) - { - if (wcrtomb (NULL, 0, NULL) != 1) - return 1; - } - if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL) - { - if (wcrtomb (NULL, 0, NULL) != 1) - return 1; - } - if (setlocale (LC_ALL, "$LOCALE_JA") != NULL) - { - if (wcrtomb (NULL, 0, NULL) != 1) - return 1; - } - if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL) - { - if (wcrtomb (NULL, 0, NULL) != 1) - return 1; - } - 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 - gl_cv_func_wcrtomb_retval=yes + +# Check whether --with-force-uid was given. +if test "${with_force_uid+set}" = set; then : + withval=$with_force_uid; CHECK_USERID="$withval" 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 + : ${CHECK_USERID=yes} -( exit $ac_status ) -gl_cv_func_wcrtomb_retval=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 + case "$CHECK_USERID" in + y | ye | yes) + CHECK_USERID=1 - fi +$as_echo "#define CHECK_USERID 1" >>confdefs.h -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_wcrtomb_retval" >&5 -$as_echo "$gl_cv_func_wcrtomb_retval" >&6; } - case "$gl_cv_func_wcrtomb_retval" in - *yes) ;; - *) REPLACE_WCRTOMB=1 ;; - esac - fi - fi - if test $HAVE_WCRTOMB = 0 || test $REPLACE_WCRTOMB = 1; then + ;; + n | no) : + CHECK_USERID= + ;; + *) + as_fn_error $? "*** You must not supply an argument to --with-force-uid option." "$LINENO" 5 + esac - : + if test x"$CHECK_USERID" = x"1"; then + CHECK_USERID_TRUE= + CHECK_USERID_FALSE='#' +else + CHECK_USERID_TRUE='#' + CHECK_USERID_FALSE= +fi +# Check whether --with-owner was given. +if test "${with_owner+set}" = set; then : + withval=$with_owner; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-owner option." "$LINENO" 5 + ;; + *) BINARY_OWNER="$withval" + ;; + esac +else + BINARY_OWNER="$CLIENT_LOGIN" - gl_LIBOBJS="$gl_LIBOBJS wcrtomb.$ac_objext" +fi - : +cat >>confdefs.h <<_ACEOF +#define BINARY_OWNER "$BINARY_OWNER" +_ACEOF - fi - GNULIB_WCRTOMB=1 +# Check whether --with-fqdn was given. +if test "${with_fqdn+set}" = set; then : + withval=$with_fqdn; USE_FQDN=$withval +else + USE_FQDN=no +fi + case "$USE_FQDN" in + n | no) : ;; + y | ye | yes) -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_WCRTOMB 1 -_ACEOF +$as_echo "#define USE_FQDN 1" >>confdefs.h + ;; + *) as_fn_error $? "You must not supply an argument to --with-fqdn option." "$LINENO" 5 + ;; + esac - # Code from module wctype: +# Check whether --with-reuseports was given. +if test "${with_reuseports+set}" = set; then : + withval=$with_reuseports; case "$withval" in + y | ye | yes) USE_REUSEADDR=no;; + n | no) USE_REUSEADDR=yes;; + *) as_fn_error $? "You must not supply an argument to --without-reuseports" "$LINENO" 5;; + esac +else + USE_REUSEADDR=yes; +fi + if test x"$USE_REUSEADDR" = x"yes"; then - : +$as_echo "#define USE_REUSEADDR 1" >>confdefs.h + fi +# Check whether --with-low-tcpportrange was given. +if test "${with_low_tcpportrange+set}" = set; then : + withval=$with_low_tcpportrange; LOW_TCPPORTRANGE="$withval" +else + LOW_TCPPORTRANGE=unlimited +fi - if test $ac_cv_func_iswcntrl = yes; then - HAVE_ISWCNTRL=1 - else - HAVE_ISWCNTRL=0 - fi + if test x"$LOW_TCPPORTRANGE" != x"unlimited"; then + if test x`echo "$LOW_TCPPORTRANGE" | sed 's/[0-9][0-9]*,[0-9][0-9]*//'` != x""; then + as_fn_error $? "--with-low-tcpportrange requires two comma-separated positive numbers" "$LINENO" 5 + fi + min_low_tcp_port=`echo "$LOW_TCPPORTRANGE" | sed 's/,.*//'` + max_low_tcp_port=`echo "$LOW_TCPPORTRANGE" | sed 's/.*,//'` + if test $min_low_tcp_port -gt $max_low_tcp_port; then + as_fn_error $? "the second TCP port number must be greater than the first in --with-low-tcpportrange" "$LINENO" 5 + fi + if test $min_low_tcp_port -lt 512; then - : + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the low TCP port range should be 512 or greater in --with-low-tcpportrange" >&5 +$as_echo "$as_me: WARNING: the low TCP port range should be 512 or greater in --with-low-tcpportrange" >&2;} + cat <>config.warnings +the low TCP port range should be 512 or greater in --with-low-tcpportrange +AAW_EOF + fi + if test $max_low_tcp_port -ge 1024; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the low TCP port range should be less than 1024 in --with-low-tcpportrange" >&5 +$as_echo "$as_me: WARNING: the low TCP port range should be less than 1024 in --with-low-tcpportrange" >&2;} - : + cat <>config.warnings +the low TCP port range should be less than 1024 in --with-low-tcpportrange +AAW_EOF + fi +cat >>confdefs.h <<_ACEOF +#define LOW_TCPPORTRANGE $LOW_TCPPORTRANGE +_ACEOF - if test $ac_cv_func_iswblank = yes; then - HAVE_ISWBLANK=1 - REPLACE_ISWBLANK=0 - else - HAVE_ISWBLANK=0 - if test $ac_cv_have_decl_iswblank = yes; then - REPLACE_ISWBLANK=1 - else - REPLACE_ISWBLANK=0 fi - fi - +# Check whether --with-tcpportrange was given. +if test "${with_tcpportrange+set}" = set; then : + withval=$with_tcpportrange; TCPPORTRANGE="$withval" +else + TCPPORTRANGE="unlimited" +fi - : + if test x"$TCPPORTRANGE" != x"unlimited"; then + if test x`echo "$TCPPORTRANGE" | sed 's/[0-9][0-9]*,[0-9][0-9]*//'` != x""; then + as_fn_error $? "--with-tcpportrange requires two comma-separated positive numbers" "$LINENO" 5 + fi + min_tcp_port=`echo "$TCPPORTRANGE" | sed 's/,.*//'` + max_tcp_port=`echo "$TCPPORTRANGE" | sed 's/.*,//'` + if test $min_tcp_port -gt $max_tcp_port; then + as_fn_error $? "the second TCP port number must be greater than the first in --with-tcpportrange" "$LINENO" 5 + fi + if test $min_tcp_port -lt 1024; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the TCP port range should be 1024 or greater in --with-tcpportrange" >&5 +$as_echo "$as_me: WARNING: the TCP port range should be 1024 or greater in --with-tcpportrange" >&2;} + cat <>config.warnings +the TCP port range should be 1024 or greater in --with-tcpportrange +AAW_EOF + fi + if test $max_tcp_port -ge 65536; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the TCP port range should be less than 65536 in --with-tcpportrange" >&5 +$as_echo "$as_me: WARNING: the TCP port range should be less than 65536 in --with-tcpportrange" >&2;} - if test $gt_cv_c_wint_t = yes; then - HAVE_WINT_T=1 - else - HAVE_WINT_T=0 - fi + cat <>config.warnings +the TCP port range should be less than 65536 in --with-tcpportrange +AAW_EOF - if test $ac_cv_header_wctype_h = yes; then - if test $ac_cv_func_iswcntrl = yes; then - { $as_echo "$as_me:$LINENO: checking whether iswcntrl works" >&5 -$as_echo_n "checking whether iswcntrl works... " >&6; } -if test "${gl_cv_func_iswcntrl_works+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #if __GNU_LIBRARY__ == 1 - Linux libc5 i18n is broken. - #endif -int -main () -{ + fi - ; - return 0; -} +cat >>confdefs.h <<_ACEOF +#define TCPPORTRANGE $TCPPORTRANGE _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 - gl_cv_func_iswcntrl_works=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - gl_cv_func_iswcntrl_works=no -fi + fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +# Check whether --with-udpportrange was given. +if test "${with_udpportrange+set}" = set; then : + withval=$with_udpportrange; UDPPORTRANGE="$withval" else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + UDPPORTRANGE="unlimited" +fi - #include - #include - #include - #include - #include - int main () { return iswprint ('x') == 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 - gl_cv_func_iswcntrl_works=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + if test x"$UDPPORTRANGE" != x"unlimited"; then + if test x`echo "$UDPPORTRANGE" | sed 's/[0-9][0-9]*,[0-9][0-9]*//'` != x""; then + as_fn_error $? "--with-udpportrange requires two comma-separated positive numbers" "$LINENO" 5 + fi + min_udp_port=`echo "$UDPPORTRANGE" | sed 's/,.*//'` + max_udp_port=`echo "$UDPPORTRANGE" | sed 's/.*,//'` + if test $min_udp_port -gt $max_udp_port; then + as_fn_error $? "the second UDP port number must be greater than the first in --with-udpportrange" "$LINENO" 5 + fi + if test $max_udp_port -ge 1024; then -( exit $ac_status ) -gl_cv_func_iswcntrl_works=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 + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the UDP port range should be less than 1025 in --with-udpportrange" >&5 +$as_echo "$as_me: WARNING: the UDP port range should be less than 1025 in --with-udpportrange" >&2;} + cat <>config.warnings +the UDP port range should be less than 1025 in --with-udpportrange +AAW_EOF -fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_func_iswcntrl_works" >&5 -$as_echo "$gl_cv_func_iswcntrl_works" >&6; } - fi + fi + if test $min_udp_port -le 0; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the UDP port range should be greater than 0 in --with-udpportrange" >&5 +$as_echo "$as_me: WARNING: the UDP port range should be greater than 0 in --with-udpportrange" >&2;} - : + cat <>config.warnings +the UDP port range should be greater than 0 in --with-udpportrange +AAW_EOF + fi +cat >>confdefs.h <<_ACEOF +#define UDPPORTRANGE $UDPPORTRANGE +_ACEOF + fi - if test $gl_cv_have_include_next = yes; then - gl_cv_next_wctype_h='<'wctype.h'>' - else - { $as_echo "$as_me:$LINENO: checking absolute name of " >&5 -$as_echo_n "checking absolute name of ... " >&6; } -if test "${gl_cv_next_wctype_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test $ac_cv_header_wctype_h = yes; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -_ACEOF - case "$host_os" in - aix*) gl_absname_cpp="$ac_cpp -C" ;; - *) gl_absname_cpp="$ac_cpp" ;; - esac - gl_cv_next_wctype_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 | - sed -n '\#/wctype.h#{ - s#.*"\(.*/wctype.h\)".*#\1# - s#^/[^/]#//&# - p - q - }'`'"' - else - gl_cv_next_wctype_h='<'wctype.h'>' - fi +# Check whether --with-buffered-dump was given. +if test "${with_buffered_dump+set}" = set; then : + withval=$with_buffered_dump; DUMPER_SOCKET_BUFFERING=$withval +else + DUMPER_SOCKET_BUFFERING=no fi -{ $as_echo "$as_me:$LINENO: result: $gl_cv_next_wctype_h" >&5 -$as_echo "$gl_cv_next_wctype_h" >&6; } - fi - NEXT_WCTYPE_H=$gl_cv_next_wctype_h - if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next' - gl_next_as_first_directive='<'wctype.h'>' - else - # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include' - gl_next_as_first_directive=$gl_cv_next_wctype_h - fi - NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive + case "$DUMPER_SOCKET_BUFFERING" in + n | no) ;; + y | ye | yes) +$as_echo "#define DUMPER_SOCKET_BUFFERING 1" >>confdefs.h + ;; + *) as_fn_error $? "You must not supply an argument to --with-buffered-dump." "$LINENO" 5 ;; + esac - HAVE_WCTYPE_H=1 - else - HAVE_WCTYPE_H=0 - fi - if test "$gl_cv_func_iswcntrl_works" = no; then - REPLACE_ISWCNTRL=1 - else - REPLACE_ISWCNTRL=0 - fi +# Check whether --with-maxtapeblocksize was given. +if test "${with_maxtapeblocksize+set}" = set; then : + withval=$with_maxtapeblocksize; + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-maxtapeblocksize is no longer needed" >&5 +$as_echo "$as_me: WARNING: --with-maxtapeblocksize is no longer needed" >&2;} - # Code from module write: + cat <>config.warnings +--with-maxtapeblocksize is no longer needed +AAW_EOF +fi + ASSERTIONS= - GNULIB_WRITE=1 +# Check whether --with-assertions was given. +if test "${with_assertions+set}" = set; then : + withval=$with_assertions; + case "$withval" in + n | no) : ;; + y | ye | yes) + ASSERTIONS=1 +$as_echo "#define ASSERTIONS 1" >>confdefs.h + ;; + *) as_fn_error $? "*** You must not supply an argument to --with-assertions option." "$LINENO" 5 + ;; + esac -cat >>confdefs.h <<\_ACEOF -#define GNULIB_TEST_WRITE 1 -_ACEOF +fi - # Code from module xsize: -for ac_header in stdint.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 +# Check whether --with-debugging was given. +if test "${with_debugging+set}" = set; then : + withval=$with_debugging; debugging="$withval" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + debugging="yes" - 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 + case "$debugging" in + n | no) as_fn_error $? "Amanda no longer supports building with debugging disabled" "$LINENO" 5;; + y | ye | yes) AMANDA_DBGDIR="$AMANDA_TMPDIR";; + *) AMANDA_DBGDIR="$debugging";; + esac -rm -f conftest.err conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } + # evaluate any extra variables in the directory -# 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;} + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$AMANDA_DBGDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + AMANDA_DBGDIR="$ac_define_dir" - ;; -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 +cat >>confdefs.h <<_ACEOF +#define AMANDA_DBGDIR "$ac_define_dir" _ACEOF -fi - -done + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE - # End of code from modules +# Check whether --with-debug_days was given. +if test "${with_debug_days+set}" = set; then : + withval=$with_debug_days; + debug_days="$withval" +else + debug_days="yes" +fi + case "$debug_days" in + n | no) + AMANDA_DEBUG_DAYS=0 ;; + y | ye | yes) + AMANDA_DEBUG_DAYS=4 ;; + [0-9] | [0-9][0-9] | [0-9][0-9][0-9]) + AMANDA_DEBUG_DAYS="$debug_days" ;; + *) as_fn_error $? "*** --with-debug-days value not numeric or out of range." "$LINENO" 5 + ;; + esac +cat >>confdefs.h <<_ACEOF +#define AMANDA_DEBUG_DAYS $AMANDA_DEBUG_DAYS +_ACEOF - gltests_libdeps= - gltests_ltlibdeps= +# Check whether --with-testing was given. +if test "${with_testing+set}" = set; then : + withval=$with_testing; + TESTING="$withval" +else + TESTING="no" +fi - gl_source_base='tests' - gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS + case "$TESTING" in + n | no) SERVICE_SUFFIX="";; + y | ye | yes) SERVICE_SUFFIX="-test";; + *) SERVICE_SUFFIX="-$TESTING";; + esac - gl_module_indicator_condition=$gltests_WITNESS + AMANDA_SERVICE_NAME="amanda$SERVICE_SUFFIX" + KAMANDA_SERVICE_NAME="kamanda$SERVICE_SUFFIX" +cat >>confdefs.h <<_ACEOF +#define SERVICE_SUFFIX "$SERVICE_SUFFIX" +_ACEOF +cat >>confdefs.h <<_ACEOF +#define AMANDA_SERVICE_NAME "$AMANDA_SERVICE_NAME" +_ACEOF +cat >>confdefs.h <<_ACEOF +#define KAMANDA_SERVICE_NAME "$KAMANDA_SERVICE_NAME" +_ACEOF + SINGLE_USERID=${SINGLE_USERID:-no} + WANT_SETUID_CLIENT=${WANT_SETUID_CLIENT:-true} +# Check whether --with-single-userid was given. +if test "${with_single_userid+set}" = set; then : + withval=$with_single_userid; SINGLE_USERID=$withval +fi - # support deprecated ./configure flags to set various compiler flags + case "$host" in + *-pc-cygwin) + WANT_SETUID_CLIENT=false + SINGLE_USERID=yes + ;; + esac -# Check whether --with-cflags was given. -if test "${with_cflags+set}" = set; then - withval=$with_cflags; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-cflags option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-cflags option." >&2;} - { (exit 1); exit 1; }; } - ;; - esac + if test x"$WANT_SETUID_CLIENT" = x"true"; then - CFLAGS="$withval" +$as_echo "#define WANT_SETUID_CLIENT 1" >>confdefs.h + fi + if test x"$WANT_SETUID_CLIENT" = x"true"; then + WANT_SETUID_CLIENT_TRUE= + WANT_SETUID_CLIENT_FALSE='#' +else + WANT_SETUID_CLIENT_TRUE='#' + WANT_SETUID_CLIENT_FALSE= fi + if test x"$SINGLE_USERID" = x"yes"; then -# Check whether --with-includes was given. -if test "${with_includes+set}" = set; then - withval=$with_includes; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-includes option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-includes option." >&2;} - { (exit 1); exit 1; }; } - ;; - esac - - for dir in $withval; do - if test -d "$dir"; then - CPPFLAGS="$CPPFLAGS -I$dir" - else - - { $as_echo "$as_me:$LINENO: WARNING: Include directory $dir does not exist." >&5 -$as_echo "$as_me: WARNING: Include directory $dir does not exist." >&2;} +$as_echo "#define SINGLE_USERID 1" >>confdefs.h - - cat <>config.warnings -Include directory $dir does not exist. -AAW_EOF + fi - fi - done + WANT_INSTALLPERMS=yes + # Check whether --enable-installperms was given. +if test "${enable_installperms+set}" = set; then : + enableval=$enable_installperms; WANT_INSTALLPERMS="$enableval" +else + WANT_INSTALLPERMS="yes" fi + if test x"$WANT_INSTALLPERMS" = x"yes"; then + WANT_INSTALLPERMS_TRUE= + WANT_INSTALLPERMS_FALSE='#' +else + WANT_INSTALLPERMS_TRUE='#' + WANT_INSTALLPERMS_FALSE= +fi -# Check whether --with-libraries was given. -if test "${with_libraries+set}" = set; then - withval=$with_libraries; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-libraries option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-libraries option." >&2;} - { (exit 1); exit 1; }; } - ;; - esac - for dir in $withval; do - if test -d "$dir"; then - case "$host" in - *-solaris2*,*-netbsd*) - LDFLAGS="$LDFLAGS -R$dir" - ;; - esac - LDFLAGS="$LDFLAGS -L$dir" - else + # Check whether --enable-syntax-checks was given. +if test "${enable_syntax_checks+set}" = set; then : + enableval=$enable_syntax_checks; + case "$enableval" in + no) SYNTAX_CHECKS=false;; + *) + SYNTAX_CHECKS=true - { $as_echo "$as_me:$LINENO: WARNING: Library directory $dir does not exist." >&5 -$as_echo "$as_me: WARNING: Library directory $dir does not exist." >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-syntax-checks can cause build failures and should only be used by developers" >&5 +$as_echo "$as_me: WARNING: --enable-syntax-checks can cause build failures and should only be used by developers" >&2;} cat <>config.warnings -Library directory $dir does not exist. +--enable-syntax-checks can cause build failures and should only be used by developers AAW_EOF - fi - done - -fi + ;; + esac +else - # Disable strict-aliasing optimizations + SYNTAX_CHECKS=false - # test for -W'feature', then add the 'no-' version. +fi + if $SYNTAX_CHECKS; then + SYNTAX_CHECKS_TRUE= + SYNTAX_CHECKS_FALSE='#' +else + SYNTAX_CHECKS_TRUE='#' + SYNTAX_CHECKS_FALSE= +fi - { $as_echo "$as_me:$LINENO: checking for gcc flag -fstrict-aliasing" >&5 -$as_echo_n "checking for gcc flag -fstrict-aliasing... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-fstrict-aliasing[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - if test x"$found_warning" = x"yes"; then - CFLAGS="$CFLAGS -fno-strict-aliasing" - CPPFLAGS="$CPPFLAGS -fno-strict-aliasing" +# +# Set up for Amanda components and modules +# - else - : - fi + WANT_SERVER=true +# Check whether --with-server was given. +if test "${with_server+set}" = set; then : + withval=$with_server; + case "$withval" in + y | ye | yes) WANT_SERVER=true;; + n | no) WANT_SERVER=false;; + *) as_fn_error $? "You must not supply an argument to the --without-server option." "$LINENO" 5 ;; + esac +fi - # Warn for just about everything + WANT_CLIENT=true +# Check whether --with-client was given. +if test "${with_client+set}" = set; then : + withval=$with_client; + case "$withval" in + y | ye | yes) WANT_CLIENT=true;; + n | no) WANT_CLIENT=false;; + *) as_fn_error $? "You must not supply an argument to the --without-client option." "$LINENO" 5 ;; + esac - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wall" >&5 -$as_echo_n "checking for gcc flag -Wall... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wall[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi +fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wall" - else - : - fi + WANT_RESTORE=${WANT_SERVER-true} +# Check whether --with-restore was given. +if test "${with_restore+set}" = set; then : + withval=$with_restore; + case "$withval" in + y | ye | yes) WANT_RESTORE=true;; + n | no) WANT_RESTORE=false;; + *) as_fn_error $? "You must not supply an argument to --with-restore option." "$LINENO" 5 ;; + esac - # And add any extra warnings too +fi - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wextra" >&5 -$as_echo_n "checking for gcc flag -Wextra... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wextra[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wextra" + WANT_RECOVER=${WANT_CLIENT-true} +# Check whether --with-amrecover was given. +if test "${with_amrecover+set}" = set; then : + withval=$with_amrecover; + case "$withval" in + y | ye | yes) WANT_RECOVER=true;; + n | no) WANT_RECOVER=false;; + *) as_fn_error $? "You must not supply an argument to --with-amrecover option." "$LINENO" 5 ;; + esac - else +fi - { $as_echo "$as_me:$LINENO: checking for gcc flag -W" >&5 -$as_echo_n "checking for gcc flag -W... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '^[:alnum:]-W^[:alnum:]-' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -W" +# Check whether --with-client-only was given. +if test "${with_client_only+set}" = set; then : + withval=$with_client_only; as_fn_error $? "--with-client-only is deprecated, use --without-server instead." "$LINENO" 5 +fi - else - : - fi - fi +# Check whether --with-server-only was given. +if test "${with_server_only+set}" = set; then : + withval=$with_server_only; as_fn_error $? "--with-server-only is deprecated, use --without-client instead." "$LINENO" 5 +fi -CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE" - # Check whether --enable-as-needed was given. -if test "${enable_as_needed+set}" = set; then - enableval=$enable_as_needed; WANT_AS_NEEDED=$enableval -else - WANT_AS_NEEDED=no -fi + WANT_NDMP=${WANT_NDMP-true} +# Check whether --with-ndmp was given. +if test "${with_ndmp+set}" = set; then : + withval=$with_ndmp; + case "$withval" in + y | ye | yes) WANT_NDMP=true;; + n | no) WANT_NDMP=false;; + *) as_fn_error $? "You must not supply an argument to --with-ndmp option." "$LINENO" 5 ;; + esac - if test x"$WANT_AS_NEEDED" = x"yes"; then - WANT_AS_NEEDED_TRUE= - WANT_AS_NEEDED_FALSE='#' -else - WANT_AS_NEEDED_TRUE='#' - WANT_AS_NEEDED_FALSE= fi - if test x"$WANT_AS_NEEDED" = x"yes"; then - AS_NEEDED_FLAGS="-Wl,--as-needed" - else - AS_NEEDED_FLAGS="" - fi -# -# Configuration flags (--with-xxx and --enable-xxx) -# -# Check whether --with-user was given. -if test "${with_user+set}" = set; then - withval=$with_user; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-user option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-user option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) - CLIENT_LOGIN="$withval" - ;; - esac + # detect invalid combinations of components + if ! ${WANT_SERVER-true} && ${WANT_RESTORE-true}; then + as_fn_error $? "--without-server requires --without-restore" "$LINENO" 5 + fi + if ! ${WANT_CLIENT-true} && ${WANT_RECOVER-true}; then + as_fn_error $? "--without-client requires --without-amrecover" "$LINENO" 5 + fi + if $WANT_CLIENT; then + WANT_CLIENT_TRUE= + WANT_CLIENT_FALSE='#' else - - - { $as_echo "$as_me:$LINENO: WARNING: no user specified (--with-user) -- using 'amanda'" >&5 -$as_echo "$as_me: WARNING: no user specified (--with-user) -- using 'amanda'" >&2;} - - - cat <>config.warnings -no user specified (--with-user) -- using 'amanda' -AAW_EOF - - - CLIENT_LOGIN=amanda - - + WANT_CLIENT_TRUE='#' + WANT_CLIENT_FALSE= fi + if $WANT_RESTORE; then + WANT_RESTORE_TRUE= + WANT_RESTORE_FALSE='#' +else + WANT_RESTORE_TRUE='#' + WANT_RESTORE_FALSE= +fi + if $WANT_SERVER; then + WANT_SERVER_TRUE= + WANT_SERVER_FALSE='#' +else + WANT_SERVER_TRUE='#' + WANT_SERVER_FALSE= +fi -cat >>confdefs.h <<_ACEOF -#define CLIENT_LOGIN "$CLIENT_LOGIN" -_ACEOF + if $WANT_RECOVER; then + WANT_RECOVER_TRUE= + WANT_RECOVER_FALSE='#' +else + WANT_RECOVER_TRUE='#' + WANT_RECOVER_FALSE= +fi + if $WANT_NDMP; then + WANT_NDMP_TRUE= + WANT_NDMP_FALSE='#' +else + WANT_NDMP_TRUE='#' + WANT_NDMP_FALSE= +fi + if $WANT_SERVER || $WANT_RESTORE; then + WANT_TAPE_TRUE= + WANT_TAPE_FALSE='#' +else + WANT_TAPE_TRUE='#' + WANT_TAPE_FALSE= +fi -# Check whether --with-group was given. -if test "${with_group+set}" = set; then - withval=$with_group; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-group option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-group option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) SETUID_GROUP="$withval" - ;; - esac + # AMANDA_COMPONENTS goes to Amanda::Constants; missing_components is just for the + # summary, below + AMANDA_COMPONENTS='' + missing_components='' -else + if $WANT_SERVER; then + AMANDA_COMPONENTS="$AMANDA_COMPONENTS server"; + else + missing_components="$missing_components (no server)"; + fi + if $WANT_RESTORE; then + AMANDA_COMPONENTS="$AMANDA_COMPONENTS restore"; + else + missing_components="$missing_components (no restore)"; + fi + if $WANT_CLIENT; then + AMANDA_COMPONENTS="$AMANDA_COMPONENTS client"; + else + missing_components="$missing_components (no client)"; + fi + if $WANT_RECOVER; then + AMANDA_COMPONENTS="$AMANDA_COMPONENTS amrecover"; + else + missing_components="$missing_components (no amrecover)"; + fi + if $WANT_NDMP; then + AMANDA_COMPONENTS="$AMANDA_COMPONENTS ndmp"; + else + missing_components="$missing_components (no ndmp)"; + fi - { $as_echo "$as_me:$LINENO: WARNING: no group specified (--with-group) -- using 'backup'" >&5 -$as_echo "$as_me: WARNING: no group specified (--with-group) -- using 'backup'" >&2;} - cat <>config.warnings -no group specified (--with-group) -- using 'backup' -AAW_EOF - SETUID_GROUP=backup +# Check whether --with-gnuplot was given. +if test "${with_gnuplot+set}" = set; then : + withval=$with_gnuplot; + case "$withval" in + y | ye | yes) : ;; + n | no) GNUPLOT=no ;; + *) GNUPLOT="$withval" ;; + esac fi + if test "x$GNUPLOT" = "xno"; then + GNUPLOT= + else + # Extract the first word of "gnuplot", so it can be a program name with args. +set dummy gnuplot; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GNUPLOT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GNUPLOT in + [\\/]* | ?:[\\/]*) + ac_cv_path_GNUPLOT="$GNUPLOT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_GNUPLOT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +GNUPLOT=$ac_cv_path_GNUPLOT +if test -n "$GNUPLOT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNUPLOT" >&5 +$as_echo "$GNUPLOT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + fi -# Check whether --with-dumperdir was given. -if test "${with_dumperdir+set}" = set; then - withval=$with_dumperdir; - - { $as_echo "$as_me:$LINENO: WARNING: --with-dumperdir is no longer used." >&5 -$as_echo "$as_me: WARNING: --with-dumperdir is no longer used." >&2;} - cat <>config.warnings ---with-dumperdir is no longer used. -AAW_EOF + # Extract the first word of "pcat", so it can be a program name with args. +set dummy pcat; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_PCAT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $PCAT in + [\\/]* | ?:[\\/]*) + ac_cv_path_PCAT="$PCAT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_PCAT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +PCAT=$ac_cv_path_PCAT +if test -n "$PCAT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PCAT" >&5 +$as_echo "$PCAT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -# Check whether --with-configdir was given. -if test "${with_configdir+set}" = set; then - withval=$with_configdir; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-configdir option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-configdir option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) CONFIG_DIR="$withval" - ;; - esac + # Extract the first word of "compress", so it can be a program name with args. +set dummy compress; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_COMPRESS+:} false; then : + $as_echo_n "(cached) " >&6 else + case $COMPRESS in + [\\/]* | ?:[\\/]*) + ac_cv_path_COMPRESS="$COMPRESS" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_COMPRESS="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - : ${CONFIG_DIR='${sysconfdir}/amanda'} # (variable will be evaluated below) - - + ;; +esac +fi +COMPRESS=$ac_cv_path_COMPRESS +if test -n "$COMPRESS"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPRESS" >&5 +$as_echo "$COMPRESS" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$CONFIG_DIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - CONFIG_DIR="$ac_define_dir" - - -cat >>confdefs.h <<_ACEOF -#define CONFIG_DIR "$ac_define_dir" -_ACEOF - - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE - -# Check whether --with-indexdir was given. -if test "${with_indexdir+set}" = set; then - withval=$with_indexdir; { { $as_echo "$as_me:$LINENO: error: *** --with-indexdir is deprecated; use indexdir in amanda.conf instead." >&5 -$as_echo "$as_me: error: *** --with-indexdir is deprecated; use indexdir in amanda.conf instead." >&2;} - { (exit 1); exit 1; }; } + # Extract the first word of "gzip", so it can be a program name with args. +set dummy gzip; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GZIP+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GZIP in + [\\/]* | ?:[\\/]*) + ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_GZIP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +GZIP=$ac_cv_path_GZIP +if test -n "$GZIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 +$as_echo "$GZIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -# Check whether --with-dbdir was given. -if test "${with_dbdir+set}" = set; then - withval=$with_dbdir; { { $as_echo "$as_me:$LINENO: error: *** --with-dbdir is deprecated; use infofile in amanda.conf instead." >&5 -$as_echo "$as_me: error: *** --with-dbdir is deprecated; use infofile in amanda.conf instead." >&2;} - { (exit 1); exit 1; }; } -fi -# Check whether --with-logdir was given. -if test "${with_logdir+set}" = set; then - withval=$with_logdir; { { $as_echo "$as_me:$LINENO: error: *** --with-logdir is deprecated; use logfile in amanda.conf instead." >&5 -$as_echo "$as_me: error: *** --with-logdir is deprecated; use logfile in amanda.conf instead." >&2;} - { (exit 1); exit 1; }; } -fi + if test "x$GNUPLOT" != "x"; then + WANT_AMPLOT=true + + # variable substitutions for amcat.awk + if test "$PCAT"; then + AMPLOT_CAT_PACK="if(o==\"z\")print \"$PCAT\"; else" + else + AMPLOT_CAT_PACK= + fi + if test "$COMPRESS"; then + AMPLOT_COMPRESS=$COMPRESS + AMPLOT_CAT_COMPRESS="if(o==\"Z\")print \"$COMPRESS -dc\"; else" + else + AMPLOT_CAT_COMPRESS= + fi + if test "$GZIP"; then + AMPLOT_COMPRESS=$GZIP + AMPLOT_CAT_GZIP="if(o==\"gz\")print \"$GZIP -dc\"; else" + else + AMPLOT_CAT_GZIP= + fi -# Check whether --with-suffixes was given. -if test "${with_suffixes+set}" = set; then - withval=$with_suffixes; - { $as_echo "$as_me:$LINENO: WARNING: ** --with-suffixes is deprecated" >&5 -$as_echo "$as_me: WARNING: ** --with-suffixes is deprecated" >&2;} + else + WANT_AMPLOT=false + + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Not building 'amplot', because gnuplot was not found" >&5 +$as_echo "$as_me: WARNING: Not building 'amplot', because gnuplot was not found" >&2;} cat <>config.warnings -** --with-suffixes is deprecated +Not building 'amplot', because gnuplot was not found AAW_EOF + fi + if test x"$WANT_AMPLOT" = x"true"; then + WANT_AMPLOT_TRUE= + WANT_AMPLOT_FALSE='#' +else + WANT_AMPLOT_TRUE='#' + WANT_AMPLOT_FALSE= fi - -# Check whether --with-gnutar-listdir was given. -if test "${with_gnutar_listdir+set}" = set; then - withval=$with_gnutar_listdir; - case "$withval" in - n | no) GNUTAR_LISTDIR= ;; - y | ye | yes) GNUTAR_LISTDIR='${localstatedir}/amanda/gnutar-lists' ;; - *) GNUTAR_LISTDIR="$withval" ;; - esac - + # Check whether --enable-manpage-build was given. +if test "${enable_manpage_build+set}" = set; then : + enableval=$enable_manpage_build; ENABLE_MANPAGE_BUILD=$enableval else + ENABLE_MANPAGE_BUILD=no +fi - GNUTAR_LISTDIR='${localstatedir}/amanda/gnutar-lists' + # and ensure that everything docbook-related is OK if we'll be using it + if test "x$ENABLE_MANPAGE_BUILD" = "xyes"; then + DOC_BUILD_DATE=`date '+%d-%m-%Y'` -fi +XSLTPROC_FLAGS="--nonet" - # substitute $prefix, etc. if necessary - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$GNUTAR_LISTDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - GNUTAR_LISTED_INCREMENTAL_DIR="$ac_define_dir" +# The (lack of) whitespace and overquoting here are all necessary for +# proper formatting. +# Check whether --with-xsltproc was given. +if test "${with_xsltproc+set}" = set; then : + withval=$with_xsltproc; ac_with_xsltproc=$withval; +else + ac_with_xsltproc=maybe; +fi -cat >>confdefs.h <<_ACEOF -#define GNUTAR_LISTED_INCREMENTAL_DIR "$ac_define_dir" -_ACEOF - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# Check whether --with-xsltproc-flags was given. +if test "${with_xsltproc_flags+set}" = set; then : + withval=$with_xsltproc_flags; if test "x$withval" == "xno"; then + XSLTPROC_FLAGS='' + else + if test "x$withval" != "xyes"; then + XSLTPROC_FLAGS="$withval" + fi + fi - # handle deprecated option +fi -# Check whether --with-gnutar-listed-incremental was given. -if test "${with_gnutar_listed_incremental+set}" = set; then - withval=$with_gnutar_listed_incremental; - { { $as_echo "$as_me:$LINENO: error: *** The gnutar-listed-incremental option is deprecated; use --with-gnutar-listdir instead" >&5 -$as_echo "$as_me: error: *** The gnutar-listed-incremental option is deprecated; use --with-gnutar-listdir instead" >&2;} - { (exit 1); exit 1; }; } +# search for xsltproc if it wasn't specified +if test "$ac_with_xsltproc" = "yes" -o "$ac_with_xsltproc" = "maybe"; then + for ac_prog in xsltproc +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_XSLTPROC+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $XSLTPROC in + [\\/]* | ?:[\\/]*) + ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_XSLTPROC="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +XSLTPROC=$ac_cv_path_XSLTPROC +if test -n "$XSLTPROC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5 +$as_echo "$XSLTPROC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi + test -n "$XSLTPROC" && break +done + +else + if test "$ac_with_xsltproc" != "no"; then + if test -x "$ac_with_xsltproc"; then + XSLTPROC="$ac_with_xsltproc"; + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative." >&5 +$as_echo "$as_me: WARNING: Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative." >&2;} -# Check whether --with-tmpdir was given. -if test "${with_tmpdir+set}" = set; then - withval=$with_tmpdir; - tmpdir="$withval" -else + cat <>config.warnings +Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative. +AAW_EOF - tmpdir=yes + for ac_prog in xsltproc +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_XSLTPROC+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $XSLTPROC in + [\\/]* | ?:[\\/]*) + ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_XSLTPROC="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +XSLTPROC=$ac_cv_path_XSLTPROC +if test -n "$XSLTPROC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5 +$as_echo "$XSLTPROC" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - case "$tmpdir" in - n | no) { { $as_echo "$as_me:$LINENO: error: *** --without-tmpdir is not allowed." >&5 -$as_echo "$as_me: error: *** --without-tmpdir is not allowed." >&2;} - { (exit 1); exit 1; }; };; - y | ye | yes) AMANDA_TMPDIR="/tmp/amanda";; - *) AMANDA_TMPDIR="$tmpdir";; - esac + test -n "$XSLTPROC" && break +done + fi + fi +fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$AMANDA_TMPDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - AMANDA_TMPDIR="$ac_define_dir" -cat >>confdefs.h <<_ACEOF -#define AMANDA_TMPDIR "$ac_define_dir" -_ACEOF - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE -# Check whether --with-force-uid was given. -if test "${with_force_uid+set}" = set; then - withval=$with_force_uid; CHECK_USERID="$withval" -else - : ${CHECK_USERID=yes} -fi - case "$CHECK_USERID" in - y | ye | yes) - CHECK_USERID=1 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Docbook XSLT version 1.72.0" >&5 +$as_echo_n "checking for Docbook XSLT version 1.72.0... " >&6; } +if ${ac_cv_docbook_xslt_1_72_0+:} false; then : + $as_echo_n "(cached) " >&6 +else -cat >>confdefs.h <<\_ACEOF -#define CHECK_USERID 1 -_ACEOF + ac_cv_docbook_xslt_1_72_0=no + if test -n "$XSLTPROC"; then + echo "Trying '$XSLTPROC $XSLTPROC_FLAGS http://docbook.sourceforge.net/release/xsl/1.72.0/xhtml/docbook.xsl'" >&5 + $XSLTPROC $XSLTPROC_FLAGS http://docbook.sourceforge.net/release/xsl/1.72.0/xhtml/docbook.xsl >&5 2>&5 - ;; - n | no) : - CHECK_USERID= - ;; - *) - { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-force-uid option." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --with-force-uid option." >&2;} - { (exit 1); exit 1; }; } - esac + if test "$?" = 0; then + ac_cv_docbook_xslt_1_72_0=yes + fi + fi - if test x"$CHECK_USERID" = x"1"; then - CHECK_USERID_TRUE= - CHECK_USERID_FALSE='#' -else - CHECK_USERID_TRUE='#' - CHECK_USERID_FALSE= fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_docbook_xslt_1_72_0" >&5 +$as_echo "$ac_cv_docbook_xslt_1_72_0" >&6; } + HAVE_DOCBOOK_XSLT_1_72_0="$ac_cv_docbook_xslt_1_72_0" + HAVE_DOCBOOK_XSLT="$HAVE_DOCBOOK_XSLT_1_72_0" -# Check whether --with-owner was given. -if test "${with_owner+set}" = set; then - withval=$with_owner; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-owner option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-owner option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) BINARY_OWNER="$withval" - ;; - esac - -else - BINARY_OWNER="$CLIENT_LOGIN" -fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for current Docbook XSLT version" >&5 +$as_echo_n "checking for current Docbook XSLT version... " >&6; } +if ${ac_cv_docbook_xslt_current_version+:} false; then : + $as_echo_n "(cached) " >&6 +else -cat >>confdefs.h <<_ACEOF -#define BINARY_OWNER "$BINARY_OWNER" -_ACEOF + ac_cv_docbook_xslt_current_version=no + if test -n "$XSLTPROC"; then + cat >conftest.xsl < + + + + + + + +EOF + echo "Trying '$XSLTPROC $XSLTPROC_FLAGS http://docbook.sourceforge.net/release/xsl/current/VERSION' with input:" >&5 + echo "====" >&5 + cat conftest.xsl >&5 + echo "====" >&5 + ac_cv_docbook_xslt_current_version=`$XSLTPROC $XSLTPROC_FLAGS conftest.xsl http://docbook.sourceforge.net/release/xsl/current/VERSION 2>&5` + if test "$?" != 0; then + ac_cv_docbook_xslt_current_version='no' + fi + rm conftest.xsl + fi -# Check whether --with-fqdn was given. -if test "${with_fqdn+set}" = set; then - withval=$with_fqdn; USE_FQDN=$withval -else - USE_FQDN=no fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_docbook_xslt_current_version" >&5 +$as_echo "$ac_cv_docbook_xslt_current_version" >&6; } + DOCBOOK_XSLT_CURRENT_VERSION="$ac_cv_docbook_xslt_current_version" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Docbook XSLT version is 1.72.0 or newer" >&5 +$as_echo_n "checking whether Docbook XSLT version is 1.72.0 or newer... " >&6; } - case "$USE_FQDN" in - n | no) : ;; - y | ye | yes) + if test x"$DOCBOOK_XSLT_CURRENT_VERSION" = x"no"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + else -cat >>confdefs.h <<\_ACEOF -#define USE_FQDN 1 -_ACEOF + # Used to indicate true or false condition + ax_compare_version=false - ;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to --with-fqdn option." >&5 -$as_echo "$as_me: error: You must not supply an argument to --with-fqdn option." >&2;} - { (exit 1); exit 1; }; } - ;; - esac + # Convert the two version strings to be compared into a format that + # allows a simple string comparison. The end result is that a version + # string of the form 1.12.5-r617 will be converted to the form + # 0001001200050617. In other words, each number is zero padded to four + # digits, and non digits are removed. + ax_compare_version_A=`echo "$DOCBOOK_XSLT_CURRENT_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ + -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/[^0-9]//g'` -# Check whether --with-reuseports was given. -if test "${with_reuseports+set}" = set; then - withval=$with_reuseports; case "$withval" in - y | ye | yes) USE_REUSEADDR=no;; - n | no) USE_REUSEADDR=yes;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to --without-reuseports" >&5 -$as_echo "$as_me: error: You must not supply an argument to --without-reuseports" >&2;} - { (exit 1); exit 1; }; };; - esac + ax_compare_version_B=`echo "1.72.0" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ + -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/[^0-9]//g'` -else - USE_REUSEADDR=yes; -fi - if test x"$USE_REUSEADDR" = x"yes"; then + ax_compare_version=`echo "x$ax_compare_version_A +x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/false/;s/x${ax_compare_version_B}/true/;1q"` -cat >>confdefs.h <<\_ACEOF -#define USE_REUSEADDR 1 -_ACEOF - fi + if test "$ax_compare_version" = "true" ; then + # version is less than required, so mark it as "no" + DOCBOOK_XSLT_CURRENT_VERSION=no -# Check whether --with-low-tcpportrange was given. -if test "${with_low_tcpportrange+set}" = set; then - withval=$with_low_tcpportrange; LOW_TCPPORTRANGE="$withval" -else - LOW_TCPPORTRANGE=unlimited -fi + fi - if test x"$LOW_TCPPORTRANGE" != x"unlimited"; then - if test x`echo "$LOW_TCPPORTRANGE" | sed 's/[0-9][0-9]*,[0-9][0-9]*//'` != x""; then - { { $as_echo "$as_me:$LINENO: error: --with-low-tcpportrange requires two comma-separated positive numbers" >&5 -$as_echo "$as_me: error: --with-low-tcpportrange requires two comma-separated positive numbers" >&2;} - { (exit 1); exit 1; }; } - fi - min_low_tcp_port=`echo "$LOW_TCPPORTRANGE" | sed 's/,.*//'` - max_low_tcp_port=`echo "$LOW_TCPPORTRANGE" | sed 's/.*,//'` - if test $min_low_tcp_port -gt $max_low_tcp_port; then - { { $as_echo "$as_me:$LINENO: error: the second TCP port number must be greater than the first in --with-low-tcpportrange" >&5 -$as_echo "$as_me: error: the second TCP port number must be greater than the first in --with-low-tcpportrange" >&2;} - { (exit 1); exit 1; }; } + if test x"$DOCBOOK_XSLT_CURRENT_VERSION" = x"no"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($DOCBOOK_XSLT_CURRENT_VERSION)" >&5 +$as_echo "yes ($DOCBOOK_XSLT_CURRENT_VERSION)" >&6; } fi - if test $min_low_tcp_port -lt 512; then + fi - { $as_echo "$as_me:$LINENO: WARNING: the low TCP port range should be 512 or greater in --with-low-tcpportrange" >&5 -$as_echo "$as_me: WARNING: the low TCP port range should be 512 or greater in --with-low-tcpportrange" >&2;} - cat <>config.warnings -the low TCP port range should be 512 or greater in --with-low-tcpportrange -AAW_EOF - fi - if test $max_low_tcp_port -ge 1024; then - { $as_echo "$as_me:$LINENO: WARNING: the low TCP port range should be less than 1024 in --with-low-tcpportrange" >&5 -$as_echo "$as_me: WARNING: the low TCP port range should be less than 1024 in --with-low-tcpportrange" >&2;} - cat <>config.warnings -the low TCP port range should be less than 1024 in --with-low-tcpportrange -AAW_EOF - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Docbook DTD version 4.1.2" >&5 +$as_echo_n "checking for Docbook DTD version 4.1.2... " >&6; } +if ${ac_cv_docbook_dtd_4_1_2+:} false; then : + $as_echo_n "(cached) " >&6 +else -cat >>confdefs.h <<_ACEOF -#define LOW_TCPPORTRANGE $LOW_TCPPORTRANGE -_ACEOF + ac_cv_docbook_dtd_4_1_2=no + if test -n "$XSLTPROC"; then + MY_XSLTPROC_FLAGS=`echo "" $XSLTPROC_FLAGS|sed -e s/--novalid//g` + cat <conftest.xml + + + + +EOF + echo "Trying '$XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml'" >&5 + echo "conftest.xml:" >&5 + echo "====" >&5 + cat conftest.xml >&5 + echo "====" >&5 - fi + $XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml >conftest.out 2>&1 + if test "$?" = 0 -o "$?" = 5; then + # failing to load the DTD is just a warning, so check for it in the output. + if grep 'warning: failed to load external entity' conftest.out >/dev/null 2>&1; then + : # no good.. + else + ac_cv_docbook_dtd_4_1_2=yes + fi + fi + cat conftest.out >&5 + rm -f conftest.xml conftest.out + fi -# Check whether --with-tcpportrange was given. -if test "${with_tcpportrange+set}" = set; then - withval=$with_tcpportrange; TCPPORTRANGE="$withval" -else - TCPPORTRANGE="unlimited" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_docbook_dtd_4_1_2" >&5 +$as_echo "$ac_cv_docbook_dtd_4_1_2" >&6; } + HAVE_DOCBOOK_DTD_4_1_2="$ac_cv_docbook_dtd_4_1_2" + HAVE_DOCBOOK_DTD="$HAVE_DOCBOOK_DTD_4_1_2" - if test x"$TCPPORTRANGE" != x"unlimited"; then - if test x`echo "$TCPPORTRANGE" | sed 's/[0-9][0-9]*,[0-9][0-9]*//'` != x""; then - { { $as_echo "$as_me:$LINENO: error: --with-tcpportrange requires two comma-separated positive numbers" >&5 -$as_echo "$as_me: error: --with-tcpportrange requires two comma-separated positive numbers" >&2;} - { (exit 1); exit 1; }; } - fi - min_tcp_port=`echo "$TCPPORTRANGE" | sed 's/,.*//'` - max_tcp_port=`echo "$TCPPORTRANGE" | sed 's/.*,//'` - if test $min_tcp_port -gt $max_tcp_port; then - { { $as_echo "$as_me:$LINENO: error: the second TCP port number must be greater than the first in --with-tcpportrange" >&5 -$as_echo "$as_me: error: the second TCP port number must be greater than the first in --with-tcpportrange" >&2;} - { (exit 1); exit 1; }; } - fi - if test $min_tcp_port -lt 1024; then - - { $as_echo "$as_me:$LINENO: WARNING: the TCP port range should be 1024 or greater in --with-tcpportrange" >&5 -$as_echo "$as_me: WARNING: the TCP port range should be 1024 or greater in --with-tcpportrange" >&2;} - cat <>config.warnings -the TCP port range should be 1024 or greater in --with-tcpportrange -AAW_EOF - fi - if test $max_tcp_port -ge 65536; then - { $as_echo "$as_me:$LINENO: WARNING: the TCP port range should be less than 65536 in --with-tcpportrange" >&5 -$as_echo "$as_me: WARNING: the TCP port range should be less than 65536 in --with-tcpportrange" >&2;} - cat <>config.warnings -the TCP port range should be less than 65536 in --with-tcpportrange -AAW_EOF - fi -cat >>confdefs.h <<_ACEOF -#define TCPPORTRANGE $TCPPORTRANGE -_ACEOF - fi -# Check whether --with-udpportrange was given. -if test "${with_udpportrange+set}" = set; then - withval=$with_udpportrange; UDPPORTRANGE="$withval" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Docbook DTD version 4.2" >&5 +$as_echo_n "checking for Docbook DTD version 4.2... " >&6; } +if ${ac_cv_docbook_dtd_4_2+:} false; then : + $as_echo_n "(cached) " >&6 else - UDPPORTRANGE="unlimited" -fi - if test x"$UDPPORTRANGE" != x"unlimited"; then - if test x`echo "$UDPPORTRANGE" | sed 's/[0-9][0-9]*,[0-9][0-9]*//'` != x""; then - { { $as_echo "$as_me:$LINENO: error: --with-udpportrange requires two comma-separated positive numbers" >&5 -$as_echo "$as_me: error: --with-udpportrange requires two comma-separated positive numbers" >&2;} - { (exit 1); exit 1; }; } - fi - min_udp_port=`echo "$UDPPORTRANGE" | sed 's/,.*//'` - max_udp_port=`echo "$UDPPORTRANGE" | sed 's/.*,//'` - if test $min_udp_port -gt $max_udp_port; then - { { $as_echo "$as_me:$LINENO: error: the second UDP port number must be greater than the first in --with-udpportrange" >&5 -$as_echo "$as_me: error: the second UDP port number must be greater than the first in --with-udpportrange" >&2;} - { (exit 1); exit 1; }; } - fi - if test $max_udp_port -ge 1024; then + ac_cv_docbook_dtd_4_2=no + if test -n "$XSLTPROC"; then + MY_XSLTPROC_FLAGS=`echo "" $XSLTPROC_FLAGS|sed -e s/--novalid//g` + cat <conftest.xml + + + + +EOF + echo "Trying '$XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml'" >&5 + echo "conftest.xml:" >&5 + echo "====" >&5 + cat conftest.xml >&5 + echo "====" >&5 - { $as_echo "$as_me:$LINENO: WARNING: the UDP port range should be less than 1025 in --with-udpportrange" >&5 -$as_echo "$as_me: WARNING: the UDP port range should be less than 1025 in --with-udpportrange" >&2;} + $XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml >conftest.out 2>&1 + if test "$?" = 0 -o "$?" = 5; then + # failing to load the DTD is just a warning, so check for it in the output. + if grep 'warning: failed to load external entity' conftest.out >/dev/null 2>&1; then + : # no good.. + else + ac_cv_docbook_dtd_4_2=yes + fi + fi + cat conftest.out >&5 + rm -f conftest.xml conftest.out + fi - cat <>config.warnings -the UDP port range should be less than 1025 in --with-udpportrange -AAW_EOF +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_docbook_dtd_4_2" >&5 +$as_echo "$ac_cv_docbook_dtd_4_2" >&6; } + HAVE_DOCBOOK_DTD_4_2="$ac_cv_docbook_dtd_4_2" + HAVE_DOCBOOK_DTD="$HAVE_DOCBOOK_DTD_4_2" - fi - if test $min_udp_port -le 0; then - { $as_echo "$as_me:$LINENO: WARNING: the UDP port range should be greater than 0 in --with-udpportrange" >&5 -$as_echo "$as_me: WARNING: the UDP port range should be greater than 0 in --with-udpportrange" >&2;} - cat <>config.warnings -the UDP port range should be greater than 0 in --with-udpportrange -AAW_EOF + if test -z "$XSLTPROC"; then + as_fn_error $? "Cannot build manpages: 'xsltproc' was not found." "$LINENO" 5 fi -cat >>confdefs.h <<_ACEOF -#define UDPPORTRANGE $UDPPORTRANGE -_ACEOF + # if the 'current' Docbook revision is good enough, use that; otherwise, + # if 1.72.0 is available, use that. + XSLREL=current + if test "x$DOCBOOK_XSLT_CURRENT_VERSION" = "xno"; then + if test "x$HAVE_DOCBOOK_XSLT_1_72_0" = "xno"; then + as_fn_error $? "Cannot build manpages: docbook version 1.72.0 or higher required." "$LINENO" 5 + else + XSLREL=1.72.0 + fi + fi - fi + # disable validation if the correct DTDs are not available + if test "x$HAVE_DOCBOOK_DTD_4_1_2" = "xno" || test "x$HAVE_DOCBOOK_DTD_4_2" = "xno"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Docbook DTD versions 4.1.2 and 4.2 are required for manpage validation; disabling validation" >&5 +$as_echo "$as_me: WARNING: Docbook DTD versions 4.1.2 and 4.2 are required for manpage validation; disabling validation" >&2;} + cat <>config.warnings +Docbook DTD versions 4.1.2 and 4.2 are required for manpage validation; disabling validation +AAW_EOF + XSLTPROC_FLAGS="$XSLTPROC_FLAGS --novalid" + fi + fi -# Check whether --with-buffered-dump was given. -if test "${with_buffered_dump+set}" = set; then - withval=$with_buffered_dump; DUMPER_SOCKET_BUFFERING=$withval + if test "x$ENABLE_MANPAGE_BUILD" = "xyes"; then + ENABLE_MANPAGE_BUILD_TRUE= + ENABLE_MANPAGE_BUILD_FALSE='#' else - DUMPER_SOCKET_BUFFERING=no + ENABLE_MANPAGE_BUILD_TRUE='#' + ENABLE_MANPAGE_BUILD_FALSE= fi - case "$DUMPER_SOCKET_BUFFERING" in - n | no) ;; - y | ye | yes) -cat >>confdefs.h <<\_ACEOF -#define DUMPER_SOCKET_BUFFERING 1 -_ACEOF - ;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to --with-buffered-dump." >&5 -$as_echo "$as_me: error: You must not supply an argument to --with-buffered-dump." >&2;} - { (exit 1); exit 1; }; } ;; - esac + #allow configure CONFIG_CLOBBER_MY_CONFIG= to be used by make. + CONFIG_CLOBBER_MY_CONFIG=$CLOBBER_MY_CONFIG -# Check whether --with-maxtapeblocksize was given. -if test "${with_maxtapeblocksize+set}" = set; then - withval=$with_maxtapeblocksize; - { $as_echo "$as_me:$LINENO: WARNING: --with-maxtapeblocksize is no longer needed" >&5 -$as_echo "$as_me: WARNING: --with-maxtapeblocksize is no longer needed" >&2;} - cat <>config.warnings ---with-maxtapeblocksize is no longer needed -AAW_EOF - +# Check whether --with-index-server was given. +if test "${with_index_server+set}" = set; then : + withval=$with_index_server; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-index-server option." "$LINENO" 5 + ;; + *) DEFAULT_SERVER="$withval" + ;; + esac +else + : ${DEFAULT_SERVER=`uname -n`} fi +cat >>confdefs.h <<_ACEOF +#define DEFAULT_SERVER "$DEFAULT_SERVER" +_ACEOF - ASSERTIONS= -# Check whether --with-assertions was given. -if test "${with_assertions+set}" = set; then - withval=$with_assertions; - case "$withval" in - n | no) : ;; - y | ye | yes) - ASSERTIONS=1 -cat >>confdefs.h <<\_ACEOF -#define ASSERTIONS 1 -_ACEOF - ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-assertions option." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --with-assertions option." >&2;} - { (exit 1); exit 1; }; } - ;; - esac +# Check whether --with-config was given. +if test "${with_config+set}" = set; then : + withval=$with_config; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-config option." "$LINENO" 5 + ;; + *) DEFAULT_CONFIG="$withval" + ;; + esac +else + : ${DEFAULT_CONFIG=DailySet1} fi +cat >>confdefs.h <<_ACEOF +#define DEFAULT_CONFIG "$DEFAULT_CONFIG" +_ACEOF -# Check whether --with-debugging was given. -if test "${with_debugging+set}" = set; then - withval=$with_debugging; debugging="$withval" +# Check whether --with-tape-server was given. +if test "${with_tape_server+set}" = set; then : + withval=$with_tape_server; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-tape-server option." "$LINENO" 5 + ;; + *) DEFAULT_TAPE_SERVER="$withval" + ;; + esac + else - debugging="yes" + : ${DEFAULT_TAPE_SERVER=$DEFAULT_SERVER} fi - case "$debugging" in - n | no) { { $as_echo "$as_me:$LINENO: error: Amanda no longer supports building with debugging disabled" >&5 -$as_echo "$as_me: error: Amanda no longer supports building with debugging disabled" >&2;} - { (exit 1); exit 1; }; };; - y | ye | yes) AMANDA_DBGDIR="$AMANDA_TMPDIR";; - *) AMANDA_DBGDIR="$debugging";; - esac +cat >>confdefs.h <<_ACEOF +#define DEFAULT_TAPE_SERVER "$DEFAULT_TAPE_SERVER" +_ACEOF - # evaluate any extra variables in the directory - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$AMANDA_DBGDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - AMANDA_DBGDIR="$ac_define_dir" + + +# Check whether --with-tape-device was given. +if test "${with_tape_device+set}" = set; then : + withval=$with_tape_device; + case "$withval" in + "" | y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to the --with-tape-device option." "$LINENO" 5 + ;; + *) DEFAULT_TAPE_DEVICE="$withval" + ;; + esac + + +fi + cat >>confdefs.h <<_ACEOF -#define AMANDA_DBGDIR "$ac_define_dir" +#define DEFAULT_TAPE_DEVICE "$DEFAULT_TAPE_DEVICE" _ACEOF - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + if test "${DEFAULT_TAPE_DEVICE+set}" = "set"; then + EXAMPLE_TAPEDEV="$DEFAULT_TAPE_DEVICE" + else + EXAMPLE_TAPEDEV="tape:/dev/YOUR-TAPE-DEVICE-HERE" + fi -# Check whether --with-debug_days was given. -if test "${with_debug_days+set}" = set; then - withval=$with_debug_days; - debug_days="$withval" -else +# Check whether --with-changer-device was given. +if test "${with_changer_device+set}" = set; then : + withval=$with_changer_device; - debug_days="yes" + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-changer-device is no longer used." >&5 +$as_echo "$as_me: WARNING: --with-changer-device is no longer used." >&2;} -fi + cat <>config.warnings +--with-changer-device is no longer used. +AAW_EOF - case "$debug_days" in - n | no) - AMANDA_DEBUG_DAYS=0 ;; - y | ye | yes) - AMANDA_DEBUG_DAYS=4 ;; - [0-9] | [0-9][0-9] | [0-9][0-9][0-9]) - AMANDA_DEBUG_DAYS="$debug_days" ;; - *) { { $as_echo "$as_me:$LINENO: error: *** --with-debug-days value not numeric or out of range." >&5 -$as_echo "$as_me: error: *** --with-debug-days value not numeric or out of range." >&2;} - { (exit 1); exit 1; }; } - ;; - esac -cat >>confdefs.h <<_ACEOF -#define AMANDA_DEBUG_DAYS $AMANDA_DEBUG_DAYS -_ACEOF +fi -# Check whether --with-testing was given. -if test "${with_testing+set}" = set; then - withval=$with_testing; - TESTING="$withval" +# Check whether --with-amandates was given. +if test "${with_amandates+set}" = set; then : + withval=$with_amandates; + case "$withval" in + n | no) as_fn_error $? "*** --without-amandates is not allowed." "$LINENO" 5;; + y | ye | yes) amandates='$localstatedir/amanda/amandates' ;; + *) amandates="$withval";; + esac else - - TESTING="no" - + amandates='$localstatedir/amanda/amandates' fi - case "$TESTING" in - n | no) SERVICE_SUFFIX="";; - y | ye | yes) SERVICE_SUFFIX="-test";; - *) SERVICE_SUFFIX="-$TESTING";; - esac - AMANDA_SERVICE_NAME="amanda$SERVICE_SUFFIX" - KAMANDA_SERVICE_NAME="kamanda$SERVICE_SUFFIX" + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$amandates\"" + eval ac_define_dir="\"$ac_define_dir\"" + DEFAULT_AMANDATES_FILE="$ac_define_dir" cat >>confdefs.h <<_ACEOF -#define SERVICE_SUFFIX "$SERVICE_SUFFIX" +#define DEFAULT_AMANDATES_FILE "$ac_define_dir" _ACEOF + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE -cat >>confdefs.h <<_ACEOF -#define AMANDA_SERVICE_NAME "$AMANDA_SERVICE_NAME" -_ACEOF + DEFAULT_FSF_AFTER_FILEMARK="FALSE" + case "$host" in + *-solaris*) DEFAULT_FSF_AFTER_FILEMARK="TRUE" + ;; + esac cat >>confdefs.h <<_ACEOF -#define KAMANDA_SERVICE_NAME "$KAMANDA_SERVICE_NAME" +#define DEFAULT_FSF_AFTER_FILEMARK $DEFAULT_FSF_AFTER_FILEMARK _ACEOF - SINGLE_USERID=${SINGLE_USERID:-no} - WANT_SETUID_CLIENT=${WANT_SETUID_CLIENT:-true} + # Extract the first word of "getconf", so it can be a program name with args. +set dummy getconf; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GETCONF+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GETCONF in + [\\/]* | ?:[\\/]*) + ac_cv_path_GETCONF="$GETCONF" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $SYSPATH +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_GETCONF="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# Check whether --with-single-userid was given. -if test "${with_single_userid+set}" = set; then - withval=$with_single_userid; SINGLE_USERID=$withval + ;; +esac +fi +GETCONF=$ac_cv_path_GETCONF +if test -n "$GETCONF"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GETCONF" >&5 +$as_echo "$GETCONF" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - case "$host" in - *-pc-cygwin) - WANT_SETUID_CLIENT=false - SINGLE_USERID=yes - ;; - esac - - if test x"$WANT_SETUID_CLIENT" = x"true"; then -cat >>confdefs.h <<\_ACEOF -#define WANT_SETUID_CLIENT 1 -_ACEOF - fi - if test x"$WANT_SETUID_CLIENT" = x"true"; then - WANT_SETUID_CLIENT_TRUE= - WANT_SETUID_CLIENT_FALSE='#' -else - WANT_SETUID_CLIENT_TRUE='#' - WANT_SETUID_CLIENT_FALSE= -fi - if test x"$SINGLE_USERID" = x"yes"; then -cat >>confdefs.h <<\_ACEOF -#define SINGLE_USERID 1 -_ACEOF + # we use 'getconf', if it exists, to get the relevant + # compiler flags. + GETCONF_LFS="LFS" + case "$host" in + *-hp-*) GETCONF_LFS="XBS5_ILP32_OFFBIG" ;; + *-ibm-aix*) GETCONF_LFS="XBS5_ILP32_OFFBIG" ;; + esac - fi + # Checks for compilers, typedefs, structures, and compiler characteristics. + # Check for large file compilation environment. + NEED_RESETOFS=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for large file compilation CFLAGS" >&5 +$as_echo_n "checking for large file compilation CFLAGS... " >&6; } +if ${amanda_cv_LFS_CFLAGS+:} false; then : + $as_echo_n "(cached) " >&6 +else + amanda_cv_LFS_CFLAGS= + if test "$GETCONF"; then + if $GETCONF ${GETCONF_LFS}_CFLAGS >/dev/null 2>&1; then + amanda_cv_LFS_CFLAGS=`$GETCONF ${GETCONF_LFS}_CFLAGS 2>/dev/null` + NEED_RESETOFS=no + fi + fi - WANT_INSTALLPERMS=yes - # Check whether --enable-installperms was given. -if test "${enable_installperms+set}" = set; then - enableval=$enable_installperms; WANT_INSTALLPERMS="$enableval" -else - WANT_INSTALLPERMS="yes" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_LFS_CFLAGS" >&5 +$as_echo "$amanda_cv_LFS_CFLAGS" >&6; } + CFLAGS="$CFLAGS $amanda_cv_LFS_CFLAGS" - if test x"$WANT_INSTALLPERMS" = x"yes"; then - WANT_INSTALLPERMS_TRUE= - WANT_INSTALLPERMS_FALSE='#' + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for large file compilation LDFLAGS" >&5 +$as_echo_n "checking for large file compilation LDFLAGS... " >&6; } +if ${amanda_cv_LFS_LDFLAGS+:} false; then : + $as_echo_n "(cached) " >&6 else - WANT_INSTALLPERMS_TRUE='#' - WANT_INSTALLPERMS_FALSE= + + amanda_cv_LFS_LDFLAGS= + if test "$GETCONF"; then + if $GETCONF ${GETCONF_LFS}_LDFLAGS >/dev/null 2>&1; then + amanda_cv_LFS_LDFLAGS=`$GETCONF ${GETCONF_LFS}_LDFLAGS 2>/dev/null` + NEED_RESETOFS=no + fi + fi + + fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_LFS_LDFLAGS" >&5 +$as_echo "$amanda_cv_LFS_LDFLAGS" >&6; } + LDFLAGS="$LDFLAGS $amanda_cv_LFS_LDFLAGS" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for large file compilation LIBS" >&5 +$as_echo_n "checking for large file compilation LIBS... " >&6; } +if ${amanda_cv_LFS_LIBS+:} false; then : + $as_echo_n "(cached) " >&6 +else - # Check whether --enable-syntax-checks was given. -if test "${enable_syntax_checks+set}" = set; then - enableval=$enable_syntax_checks; - case "$enableval" in - no) SYNTAX_CHECKS=false;; - *) - SYNTAX_CHECKS=true + amanda_cv_LFS_LIBS= + if test "$GETCONF"; then + if $GETCONF ${GETCONF_LFS}_LIBS >/dev/null 2>&1; then + amanda_cv_LFS_LIBS=`$GETCONF ${GETCONF_LFS}_LIBS 2>/dev/null` + NEED_RESETOFS=no + fi + fi - { $as_echo "$as_me:$LINENO: WARNING: --enable-syntax-checks can cause build failures and should only be used by developers" >&5 -$as_echo "$as_me: WARNING: --enable-syntax-checks can cause build failures and should only be used by developers" >&2;} +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_LFS_LIBS" >&5 +$as_echo "$amanda_cv_LFS_LIBS" >&6; } + LIBS="$amanda_cv_LFS_LIBS $LIBS" - cat <>config.warnings ---enable-syntax-checks can cause build failures and should only be used by developers -AAW_EOF + if test x"$NEED_RESETOFS" = x"yes"; then - ;; - esac +$as_echo "#define NEED_RESETOFS 1" >>confdefs.h -else + fi - SYNTAX_CHECKS=false -fi + for ac_header in fstab.h \ + mntent.h \ + mnttab.h \ + sys/vfstab.h \ +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF - if $SYNTAX_CHECKS; then - SYNTAX_CHECKS_TRUE= - SYNTAX_CHECKS_FALSE='#' -else - SYNTAX_CHECKS_TRUE='#' - SYNTAX_CHECKS_FALSE= fi +done + for ac_func in endmntent +do : + ac_fn_c_check_func "$LINENO" "endmntent" "ac_cv_func_endmntent" +if test "x$ac_cv_func_endmntent" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_ENDMNTENT 1 +_ACEOF -# -# Set up for Amanda components and modules -# - - WANT_SERVER=true +fi +done -# Check whether --with-server was given. -if test "${with_server+set}" = set; then - withval=$with_server; - case "$withval" in - y | ye | yes) WANT_SERVER=true;; - n | no) WANT_SERVER=false;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to the --without-server option." >&5 -$as_echo "$as_me: error: You must not supply an argument to the --without-server option." >&2;} - { (exit 1); exit 1; }; } ;; - esac + for ac_func in setmntent +do : + ac_fn_c_check_func "$LINENO" "setmntent" "ac_cv_func_setmntent" +if test "x$ac_cv_func_setmntent" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_SETMNTENT 1 +_ACEOF fi +done - WANT_CLIENT=true + for ac_header in fcntl.h \ + sys/fcntl.h \ + sys/types.h \ + sys/file.h \ + unistd.h \ -# Check whether --with-client was given. -if test "${with_client+set}" = set; then - withval=$with_client; - case "$withval" in - y | ye | yes) WANT_CLIENT=true;; - n | no) WANT_CLIENT=false;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to the --without-client option." >&5 -$as_echo "$as_me: error: You must not supply an argument to the --without-client option." >&2;} - { (exit 1); exit 1; }; } ;; - esac +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF fi +done + # find a working file-locking mechanism. + # Note: these all use AC_TRY_LINK to make sure that we can compile + # and link each variant. They do not try to test the variants -- + # that is left to runtime. + LOCKING="no" - WANT_RESTORE=${WANT_SERVER-true} + # check POSIX locking + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether POSIX locking (with fcntl(2)) is available" >&5 +$as_echo_n "checking whether POSIX locking (with fcntl(2)) is available... " >&6; } +if ${amanda_cv_posix_filelocking+:} false; then : + $as_echo_n "(cached) " >&6 +else -# Check whether --with-restore was given. -if test "${with_restore+set}" = set; then - withval=$with_restore; - case "$withval" in - y | ye | yes) WANT_RESTORE=true;; - n | no) WANT_RESTORE=false;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to --with-restore option." >&5 -$as_echo "$as_me: error: You must not supply an argument to --with-restore option." >&2;} - { (exit 1); exit 1; }; } ;; - esac + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -fi +#if HAVE_SYS_TYPES_H +# include +#endif +#if HAVE_UNISTD_H +# include +#endif +#if HAVE_FCNTL_H +# include +#endif +int +main () +{ + struct flock lock; + lock.l_type = F_RDLCK; + lock.l_start = 0; + lock.l_whence = SEEK_CUR; + lock.l_len = 0; + return fcntl(1, F_SETLK, &lock); - WANT_RECOVER=${WANT_CLIENT-true} + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : -# Check whether --with-amrecover was given. -if test "${with_amrecover+set}" = set; then - withval=$with_amrecover; - case "$withval" in - y | ye | yes) WANT_RECOVER=true;; - n | no) WANT_RECOVER=false;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to --with-amrecover option." >&5 -$as_echo "$as_me: error: You must not supply an argument to --with-amrecover option." >&2;} - { (exit 1); exit 1; }; } ;; - esac + amanda_cv_posix_filelocking="yes" -fi +else + amanda_cv_posix_filelocking="no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_posix_filelocking" >&5 +$as_echo "$amanda_cv_posix_filelocking" >&6; } + if test "x$amanda_cv_posix_filelocking" = xyes; then -# Check whether --with-client-only was given. -if test "${with_client_only+set}" = set; then - withval=$with_client_only; { { $as_echo "$as_me:$LINENO: error: --with-client-only is deprecated, use --without-server instead." >&5 -$as_echo "$as_me: error: --with-client-only is deprecated, use --without-server instead." >&2;} - { (exit 1); exit 1; }; } +$as_echo "#define WANT_AMFLOCK_POSIX 1" >>confdefs.h + WANT_AMFLOCK_POSIX="yes" + LOCKING="POSIX_FCNTL" + fi + if test x"$WANT_AMFLOCK_POSIX" = x"yes"; then + WANT_AMFLOCK_POSIX_TRUE= + WANT_AMFLOCK_POSIX_FALSE='#' +else + WANT_AMFLOCK_POSIX_TRUE='#' + WANT_AMFLOCK_POSIX_FALSE= fi + # check flock-based (BSD) locking + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether flock locking is available" >&5 +$as_echo_n "checking whether flock locking is available... " >&6; } +if ${amanda_cv_flock_filelocking+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ -# Check whether --with-server-only was given. -if test "${with_server_only+set}" = set; then - withval=$with_server_only; { { $as_echo "$as_me:$LINENO: error: --with-server-only is deprecated, use --without-client instead." >&5 -$as_echo "$as_me: error: --with-server-only is deprecated, use --without-client instead." >&2;} - { (exit 1); exit 1; }; } +#if HAVE_SYS_FILE_H +# include +#endif -fi +int +main () +{ + + return flock(1, LOCK_SH); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + amanda_cv_flock_filelocking="yes" - WANT_NDMP=${WANT_NDMP-true} +else -# Check whether --with-ndmp was given. -if test "${with_ndmp+set}" = set; then - withval=$with_ndmp; - case "$withval" in - y | ye | yes) WANT_NDMP=true;; - n | no) WANT_NDMP=false;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to --with-ndmp option." >&5 -$as_echo "$as_me: error: You must not supply an argument to --with-ndmp option." >&2;} - { (exit 1); exit 1; }; } ;; - esac + amanda_cv_flock_filelocking="no" + +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_flock_filelocking" >&5 +$as_echo "$amanda_cv_flock_filelocking" >&6; } + if test "x$amanda_cv_flock_filelocking" = xyes; then +$as_echo "#define WANT_AMFLOCK_FLOCK 1" >>confdefs.h + + WANT_AMFLOCK_FLOCK="yes" + LOCKING="FLOCK" + fi + if test x"$WANT_AMFLOCK_FLOCK" = x"yes"; then + WANT_AMFLOCK_FLOCK_TRUE= + WANT_AMFLOCK_FLOCK_FALSE='#' +else + WANT_AMFLOCK_FLOCK_TRUE='#' + WANT_AMFLOCK_FLOCK_FALSE= +fi + # check lockf-based (SVR2, SVR3, SVR4) locking + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lockf(3) locking is available" >&5 +$as_echo_n "checking whether lockf(3) locking is available... " >&6; } +if ${amanda_cv_lockf_filelocking+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#if HAVE_UNISTD_H +# include +#endif +int +main () +{ + return lockf(1, F_LOCK, 0); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : - # detect invalid combinations of components - if ! ${WANT_SERVER-true} && ${WANT_RESTORE-true}; then - { { $as_echo "$as_me:$LINENO: error: --without-server requires --without-restore" >&5 -$as_echo "$as_me: error: --without-server requires --without-restore" >&2;} - { (exit 1); exit 1; }; } - fi - if ! ${WANT_CLIENT-true} && ${WANT_RECOVER-true}; then - { { $as_echo "$as_me:$LINENO: error: --without-client requires --without-amrecover" >&5 -$as_echo "$as_me: error: --without-client requires --without-amrecover" >&2;} - { (exit 1); exit 1; }; } - fi + amanda_cv_lockf_filelocking="yes" - if $WANT_CLIENT; then - WANT_CLIENT_TRUE= - WANT_CLIENT_FALSE='#' else - WANT_CLIENT_TRUE='#' - WANT_CLIENT_FALSE= -fi - if $WANT_RESTORE; then - WANT_RESTORE_TRUE= - WANT_RESTORE_FALSE='#' -else - WANT_RESTORE_TRUE='#' - WANT_RESTORE_FALSE= -fi + amanda_cv_lockf_filelocking="no" - if $WANT_SERVER; then - WANT_SERVER_TRUE= - WANT_SERVER_FALSE='#' -else - WANT_SERVER_TRUE='#' - WANT_SERVER_FALSE= fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext - if $WANT_RECOVER; then - WANT_RECOVER_TRUE= - WANT_RECOVER_FALSE='#' -else - WANT_RECOVER_TRUE='#' - WANT_RECOVER_FALSE= fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_lockf_filelocking" >&5 +$as_echo "$amanda_cv_lockf_filelocking" >&6; } + if test "x$amanda_cv_lockf_filelocking" = xyes; then - if $WANT_NDMP; then - WANT_NDMP_TRUE= - WANT_NDMP_FALSE='#' +$as_echo "#define WANT_AMFLOCK_LOCKF 1" >>confdefs.h + + WANT_AMFLOCK_LOCKF="yes" + LOCKING="LOCKF" + fi + if test x"$WANT_AMFLOCK_LOCKF" = x"yes"; then + WANT_AMFLOCK_LOCKF_TRUE= + WANT_AMFLOCK_LOCKF_FALSE='#' else - WANT_NDMP_TRUE='#' - WANT_NDMP_FALSE= + WANT_AMFLOCK_LOCKF_TRUE='#' + WANT_AMFLOCK_LOCKF_FALSE= fi - if $WANT_SERVER || $WANT_RESTORE; then - WANT_TAPE_TRUE= - WANT_TAPE_FALSE='#' + # check our homebrew hardlink-based locking (requires hardlinks) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link(2) is available for locking" >&5 +$as_echo_n "checking whether link(2) is available for locking... " >&6; } +if ${amanda_cv_lnlock_filelocking+:} false; then : + $as_echo_n "(cached) " >&6 else - WANT_TAPE_TRUE='#' - WANT_TAPE_FALSE= -fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - # AMANDA_COMPONENTS goes to Amanda::Constants; missing_components is just for the - # summary, below - AMANDA_COMPONENTS='' - missing_components='' +#if HAVE_UNISTD_H +# include +#endif - if $WANT_SERVER; then - AMANDA_COMPONENTS="$AMANDA_COMPONENTS server"; - else - missing_components="$missing_components (no server)"; - fi - if $WANT_RESTORE; then - AMANDA_COMPONENTS="$AMANDA_COMPONENTS restore"; - else - missing_components="$missing_components (no restore)"; - fi - if $WANT_CLIENT; then - AMANDA_COMPONENTS="$AMANDA_COMPONENTS client"; - else - missing_components="$missing_components (no client)"; - fi - if $WANT_RECOVER; then - AMANDA_COMPONENTS="$AMANDA_COMPONENTS amrecover"; - else - missing_components="$missing_components (no amrecover)"; - fi - if $WANT_NDMP; then - AMANDA_COMPONENTS="$AMANDA_COMPONENTS ndmp"; - else - missing_components="$missing_components (no ndmp)"; - fi +int +main () +{ + + return link("/tmp/foo", "/tmp/bar"); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + amanda_cv_lnlock_filelocking="yes" +else + amanda_cv_lnlock_filelocking="no" +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_lnlock_filelocking" >&5 +$as_echo "$amanda_cv_lnlock_filelocking" >&6; } + if test "x$amanda_cv_lnlock_filelocking" = xyes; then -# Check whether --with-gnuplot was given. -if test "${with_gnuplot+set}" = set; then - withval=$with_gnuplot; - case "$withval" in - y | ye | yes) : ;; - n | no) GNUPLOT=no ;; - *) GNUPLOT="$withval" ;; - esac +$as_echo "#define WANT_AMFLOCK_LNLOCK 1" >>confdefs.h + WANT_AMFLOCK_LNLOCK="yes" + LOCKING="LNLOCK" + fi + if test x"$WANT_AMFLOCK_LNLOCK" = x"yes"; then + WANT_AMFLOCK_LNLOCK_TRUE= + WANT_AMFLOCK_LNLOCK_FALSE='#' +else + WANT_AMFLOCK_LNLOCK_TRUE='#' + WANT_AMFLOCK_LNLOCK_FALSE= fi - if test "x$GNUPLOT" = "xno"; then - GNUPLOT= - else - # Extract the first word of "gnuplot", so it can be a program name with args. -set dummy gnuplot; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + + if test x"$LOCKING" = "no"; then + # this shouldn't happen, and is *bad* if it does + as_fn_error $? "*** No working file locking capability found!" "$LINENO" 5 + fi + + + + + + for ac_prog in swig +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GNUPLOT+set}" = set; then +if ${ac_cv_path_SWIG+:} false; then : $as_echo_n "(cached) " >&6 else - case $GNUPLOT in + case $SWIG in [\\/]* | ?:[\\/]*) - ac_cv_path_GNUPLOT="$GNUPLOT" # Let the user override the test with a path. + ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -34787,89 +22235,145 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GNUPLOT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -GNUPLOT=$ac_cv_path_GNUPLOT -if test -n "$GNUPLOT"; then - { $as_echo "$as_me:$LINENO: result: $GNUPLOT" >&5 -$as_echo "$GNUPLOT" >&6; } +SWIG=$ac_cv_path_SWIG +if test -n "$SWIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 +$as_echo "$SWIG" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - fi - - - + test -n "$SWIG" && break +done + # 1.3.32 introduces a change in the way empty strings are handled (old versions + # returned undef in Perl, while new versions return an empty Perl string) + # 1.3.39 is required for the %begin block - # Extract the first word of "pcat", so it can be a program name with args. -set dummy pcat; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + # Extract the first word of "swig", so it can be a program name with args. +set dummy swig; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PCAT+set}" = set; then +if ${ac_cv_path_SWIG+:} false; then : $as_echo_n "(cached) " >&6 else - case $PCAT in + case $SWIG in [\\/]* | ?:[\\/]*) - ac_cv_path_PCAT="$PCAT" # Let the user override the test with a path. + ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH +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 + 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_PCAT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -PCAT=$ac_cv_path_PCAT -if test -n "$PCAT"; then - { $as_echo "$as_me:$LINENO: result: $PCAT" >&5 -$as_echo "$PCAT" >&6; } +SWIG=$ac_cv_path_SWIG +if test -n "$SWIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 +$as_echo "$SWIG" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi + if test -z "$SWIG" ; then + SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false' + elif test -n "1.3.39" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5 +$as_echo_n "checking for SWIG version... " >&6; } + swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5 +$as_echo "$swig_version" >&6; } + if test -n "$swig_version" ; then + + # Used to indicate true or false condition + ax_compare_version=false + + # Convert the two version strings to be compared into a format that + # allows a simple string comparison. The end result is that a version + # string of the form 1.12.5-r617 will be converted to the form + # 0001001200050617. In other words, each number is zero padded to four + # digits, and non digits are removed. + ax_compare_version_A=`echo "$swig_version" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ + -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/[^0-9]//g'` - # Extract the first word of "compress", so it can be a program name with args. -set dummy compress; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + ax_compare_version_B=`echo "1.3.39" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ + -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/[^0-9]//g'` + + + ax_compare_version=`echo "x$ax_compare_version_A +x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"` + + + + if test "$ax_compare_version" = "true" ; then + + SWIG_LIB=`$SWIG -swiglib` + + else + SWIG='echo "Error: SWIG version >= 1.3.39 is required. You have '"$swig_version"'. You should look at http://www.swig.org" ; false' + + fi + + else + SWIG='echo "Error: Cannot determine SWIG version. You should look at http://www.swig.org" ; false' + fi + fi + + + + + + for ac_prog in perl5 perl +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_COMPRESS+set}" = set; then +if ${ac_cv_path_PERL+:} false; then : $as_echo_n "(cached) " >&6 else - case $COMPRESS in + case $PERL in [\\/]* | ?:[\\/]*) - ac_cv_path_COMPRESS="$COMPRESS" # Let the user override the test with a path. + ac_cv_path_PERL="$PERL" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -34877,185 +22381,299 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_COMPRESS="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -COMPRESS=$ac_cv_path_COMPRESS -if test -n "$COMPRESS"; then - { $as_echo "$as_me:$LINENO: result: $COMPRESS" >&5 -$as_echo "$COMPRESS" >&6; } +PERL=$ac_cv_path_PERL +if test -n "$PERL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +$as_echo "$PERL" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi + test -n "$PERL" && break +done - - # Extract the first word of "gzip", so it can be a program name with args. -set dummy gzip; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + # Make sure we have perl +if test -z "$PERL"; then +# Extract the first word of "perl", so it can be a program name with args. +set dummy perl; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GZIP+set}" = set; then +if ${ac_cv_prog_PERL+:} false; then : $as_echo_n "(cached) " >&6 else - case $GZIP in - [\\/]* | ?:[\\/]*) - ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH + if test -n "$PERL"; then + ac_cv_prog_PERL="$PERL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GZIP="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_prog_PERL="perl" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS - ;; -esac fi -GZIP=$ac_cv_path_GZIP -if test -n "$GZIP"; then - { $as_echo "$as_me:$LINENO: result: $GZIP" >&5 -$as_echo "$GZIP" >&6; } +fi +PERL=$ac_cv_prog_PERL +if test -n "$PERL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +$as_echo "$PERL" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi +fi +# Check if version of Perl is sufficient +ac_perl_version="5.6.0" +if test "x$PERL" != "x"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl version greater than or equal to $ac_perl_version" >&5 +$as_echo_n "checking for perl version greater than or equal to $ac_perl_version... " >&6; } + # NB: It would be nice to log the error if there is one, but we cannot rely + # on autoconf internals + $PERL -e "use $ac_perl_version;" > /dev/null 2>&1 + if test $? -ne 0; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; }; + as_fn_error $? "Amanda requires at least perl 5.6.0" "$LINENO" 5 + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; }; + fi +else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5 +$as_echo "$as_me: WARNING: could not find perl" >&2;} +fi - if test "x$GNUPLOT" != "x"; then - WANT_AMPLOT=true - - # variable substitutions for amcat.awk - if test "$PCAT"; then - AMPLOT_CAT_PACK="if(o==\"z\")print \"$PCAT\"; else" - else - AMPLOT_CAT_PACK= - fi - if test "$COMPRESS"; then - AMPLOT_COMPRESS=$COMPRESS - AMPLOT_CAT_COMPRESS="if(o==\"Z\")print \"$COMPRESS -dc\"; else" - else - AMPLOT_CAT_COMPRESS= - fi - if test "$GZIP"; then - AMPLOT_COMPRESS=$GZIP - AMPLOT_CAT_GZIP="if(o==\"gz\")print \"$GZIP -dc\"; else" - else - AMPLOT_CAT_GZIP= - fi + WANT_CYGWIN_COPY_PERL_DLL=false + WANT_MANDATORY_THREAD_CHECK=false + # test for ExtUtils::Embed + ac_perl_list_modules="ExtUtils::Embed 0.0" +# Make sure we have perl +if test -z "$PERL"; then +# Extract the first word of "perl", so it can be a program name with args. +set dummy perl; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_PERL+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$PERL"; then + ac_cv_prog_PERL="$PERL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_PERL="perl" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - else - WANT_AMPLOT=false +fi +fi +PERL=$ac_cv_prog_PERL +if test -n "$PERL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +$as_echo "$PERL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - { $as_echo "$as_me:$LINENO: WARNING: Not building 'amplot', because gnuplot was not found" >&5 -$as_echo "$as_me: WARNING: Not building 'amplot', because gnuplot was not found" >&2;} +fi - cat <>config.warnings -Not building 'amplot', because gnuplot was not found -AAW_EOF +# Check the number of arguments +args_num=`echo $ac_perl_list_modules | wc -w` +let "ckeck_args = $args_num % 2" +if test "$check_args" = "1" ; then + as_fn_error $? "syntax error" "$LINENO" 5 +else + eval +fi +if test "x$PERL" != x; then + ac_failed=0 + while test ${#ac_perl_list_modules} -gt 2 ; do + module_name=`echo $ac_perl_list_modules | cut -d " " -f 1` + module_version=`echo $ac_perl_list_modules | cut -d " " -f 2` + ac_perl_list_modules=`echo $ac_perl_list_modules | cut -d " " -f 3-` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl module $module_name version $module_version" >&5 +$as_echo_n "checking for perl module $module_name version $module_version... " >&6; } - fi + $PERL "-M$module_name" -e exit > /dev/null 2>&1 + if test $? -ne 0; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; }; + ac_failed=1 + ac_perl_list_modules="" + else + version=`$PERL "-M$module_name" -e 'print $'"$module_name::VERSION" 2>&1` + $PERL -e 'exit(shift cmp shift)' "$version" "$module_version" + if test $? -eq 0 -o $? -eq 1 ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; }; + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ac_failed=1 + ac_perl_list_modules="" + fi + fi; + done - if test x"$WANT_AMPLOT" = x"true"; then - WANT_AMPLOT_TRUE= - WANT_AMPLOT_FALSE='#' -else - WANT_AMPLOT_TRUE='#' - WANT_AMPLOT_FALSE= -fi + if test "$ac_failed" = 0; then + : + else + : + as_fn_error $? "*** Amanda requires the perl package ExtUtils::Embed to build its perl modules" "$LINENO" 5 - # Check whether --enable-manpage-build was given. -if test "${enable_manpage_build+set}" = set; then - enableval=$enable_manpage_build; ENABLE_MANPAGE_BUILD=$enableval + fi else - ENABLE_MANPAGE_BUILD=no + as_fn_error $? "could not find perl" "$LINENO" 5 fi + # get the include path for building perl extensions + PERL_INC=`$PERL -MExtUtils::Embed -e perl_inc` - # and ensure that everything docbook-related is OK if we'll be using it - if test "x$ENABLE_MANPAGE_BUILD" = "xyes"; then - DOC_BUILD_DATE=`date '+%d-%m-%Y'` + if test x"$enable_shared" = x"no"; then + as_fn_error $? "*** Amanda cannot be compiled without shared-library support (do not use --disable-shared)" "$LINENO" 5 + fi -XSLTPROC_FLAGS="--nonet" + case "$host" in + *freebsd[123456].*) # up to and including FreeBSD 6.* + # Before 7.0, FreeBSD systems don't include a DT_NEEDS segment in + # libgthread to automatically pull in the desired threading library. + # Instead, they assume that any application linking against + # libgthread will pull in the threading library. This is fine for + # Amanda C applications, but for Perl applications this assumption + # means that the perl binary would pull in the threading library. + # But perl is compiled without threading by default. + # + # Specifically, this occurs on any FreeBSD using gcc-3.*: the linking + # decision is made in gcc's spec files, which were changed in + # gcc-4.0. For a more in-depth discussion, see + # http://wiki.zmanda.com/index.php/Installation/OS_Specific_Notes/Installing_Amanda_on_FreeBSD + # + # The easiest solution for the "default" case is to link all perl + # extension libraries against the threading library, so it is loaded + # when perl loads the extension library. The default threading + # library in FreeBSD is libpthread. The below default will work on + # such a FreeBSD system, but ports maintainers and those with + # different configurations may need to override this value with + # --with-perlextlibs. + # + # We can't use -pthread because gcc on FreeBSD ignores -pthread in + # combination with -shared. See + # http://lists.freebsd.org/pipermail/freebsd-stable/2006-June/026229.html + PERLEXTLIBS="-lpthread" + WANT_MANDATORY_THREAD_CHECK=true + ;; -# The (lack of) whitespace and overquoting here are all necessary for -# proper formatting. + *freebsd*) # all FreeBSD not matched above + # for all FreeBSD (including 1.0-6.0, above), we want to run the + # thread-check rule in perl/Makefile.am to double-check that a Perl + # script can call a C extension that uses threads. + WANT_MANDATORY_THREAD_CHECK=true + ;; -# Check whether --with-xsltproc was given. -if test "${with_xsltproc+set}" = set; then - withval=$with_xsltproc; ac_with_xsltproc=$withval; + *-pc-cygwin) + # When need -lperl and the '-L' where it is located, + # we don't want the DynaLoader.a + PERLEXTLIBS=`perl -MExtUtils::Embed -e ldopts | sed -e 's/^.*-L/-L/'` + # we want cygwin to copy ddl to modules directory. + WANT_CYGWIN_COPY_PERL_DLL="true"; + ;; + esac + if $WANT_CYGWIN_COPY_PERL_DLL; then + WANT_CYGWIN_COPY_PERL_DLL_TRUE= + WANT_CYGWIN_COPY_PERL_DLL_FALSE='#' else - ac_with_xsltproc=maybe; + WANT_CYGWIN_COPY_PERL_DLL_TRUE='#' + WANT_CYGWIN_COPY_PERL_DLL_FALSE= +fi + + if $WANT_MANDATORY_THREAD_CHECK; then + WANT_MANDATORY_THREAD_CHECK_TRUE= + WANT_MANDATORY_THREAD_CHECK_FALSE='#' +else + WANT_MANDATORY_THREAD_CHECK_TRUE='#' + WANT_MANDATORY_THREAD_CHECK_FALSE= fi -# Check whether --with-xsltproc-flags was given. -if test "${with_xsltproc_flags+set}" = set; then - withval=$with_xsltproc_flags; if test "x$withval" == "xno"; then - XSLTPROC_FLAGS='' - else - if test "x$withval" != "xyes"; then - XSLTPROC_FLAGS="$withval" - fi - fi +# Check whether --with-perlextlibs was given. +if test "${with_perlextlibs+set}" = set; then : + withval=$with_perlextlibs; + case "$withval" in + y|ye|yes) as_fn_error $? "*** You must specify a value for --with-perlextlibs" "$LINENO" 5;; + n|no) PERLEXTLIBS='';; + *) PERLEXTLIBS="$withval" ;; + esac fi -# search for xsltproc if it wasn't specified -if test "$ac_with_xsltproc" = "yes" -o "$ac_with_xsltproc" = "maybe"; then - for ac_prog in xsltproc -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 + + + + # Extract the first word of "cat", so it can be a program name with args. +set dummy cat; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_XSLTPROC+set}" = set; then +if ${ac_cv_path_CAT+:} false; then : $as_echo_n "(cached) " >&6 else - case $XSLTPROC in + case $CAT in [\\/]* | ?:[\\/]*) - ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path. + ac_cv_path_CAT="$CAT" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -35063,228 +22681,112 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_XSLTPROC="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS + test -z "$ac_cv_path_CAT" && ac_cv_path_CAT="cat" ;; esac fi -XSLTPROC=$ac_cv_path_XSLTPROC -if test -n "$XSLTPROC"; then - { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5 -$as_echo "$XSLTPROC" >&6; } +CAT=$ac_cv_path_CAT +if test -n "$CAT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 +$as_echo "$CAT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$XSLTPROC" && break -done -else - if test "$ac_with_xsltproc" != "no"; then - if test -x "$ac_with_xsltproc"; then - XSLTPROC="$ac_with_xsltproc"; - else - - { $as_echo "$as_me:$LINENO: WARNING: Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative." >&5 -$as_echo "$as_me: WARNING: Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative." >&2;} - - - cat <>config.warnings -Specified xsltproc of $ac_with_xsltproc isn't executable; searching for an alternative. -AAW_EOF - - - for ac_prog in xsltproc -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_XSLTPROC+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $XSLTPROC in - [\\/]* | ?:[\\/]*) - ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_XSLTPROC="$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 -XSLTPROC=$ac_cv_path_XSLTPROC -if test -n "$XSLTPROC"; then - { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5 -$as_echo "$XSLTPROC" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - - - test -n "$XSLTPROC" && break -done - - fi - fi -fi - - - - - - - - - - - { $as_echo "$as_me:$LINENO: checking for Docbook XSLT version 1.72.0" >&5 -$as_echo_n "checking for Docbook XSLT version 1.72.0... " >&6; } -if test "${ac_cv_docbook_xslt_1_72_0+set}" = set; then - $as_echo_n "(cached) " >&6 -else - - ac_cv_docbook_xslt_1_72_0=no - if test -n "$XSLTPROC"; then - echo "Trying '$XSLTPROC $XSLTPROC_FLAGS http://docbook.sourceforge.net/release/xsl/1.72.0/xhtml/docbook.xsl'" >&5 - $XSLTPROC $XSLTPROC_FLAGS http://docbook.sourceforge.net/release/xsl/1.72.0/xhtml/docbook.xsl >&5 2>&5 - - if test "$?" = 0; then - ac_cv_docbook_xslt_1_72_0=yes - fi - fi - -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_docbook_xslt_1_72_0" >&5 -$as_echo "$ac_cv_docbook_xslt_1_72_0" >&6; } - - HAVE_DOCBOOK_XSLT_1_72_0="$ac_cv_docbook_xslt_1_72_0" - HAVE_DOCBOOK_XSLT="$HAVE_DOCBOOK_XSLT_1_72_0" + HAVE_GZIP= + if test "$GZIP"; then +$as_echo "#define HAVE_GZIP 1" >>confdefs.h + HAVE_GZIP=1 + COMPRESS_PATH="$GZIP" + COMPRESS_SUFFIX=".gz" + COMPRESS_FAST_OPT="--fast" + COMPRESS_BEST_OPT="--best" + UNCOMPRESS_PATH="$GZIP" + UNCOMPRESS_OPT="-dc" + else + if test "$COMPRESS"; then + COMPRESS_PATH="$COMPRESS" + COMPRESS_SUFFIX=".Z" + COMPRESS_FAST_OPT="-f" + COMPRESS_BEST_OPT="-f" + UNCOMPRESS_PATH="$COMPRESS" + UNCOMPRESS_OPT="-dc" + else + # If we have to use cat, we don't define COMPRESS_FAST_OPT, + # COMPRESS_BEST_OPT, or UNCOMPRESS_OPT as "" since cat will look + # look for a file by the name of "". + # XXX is the above true? --dustin - { $as_echo "$as_me:$LINENO: checking for current Docbook XSLT version" >&5 -$as_echo_n "checking for current Docbook XSLT version... " >&6; } -if test "${ac_cv_docbook_xslt_current_version+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_docbook_xslt_current_version=no + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find either gzip or compress. Using cat." >&5 +$as_echo "$as_me: WARNING: Cannot find either gzip or compress. Using cat." >&2;} - if test -n "$XSLTPROC"; then - cat >conftest.xsl < - - - - - - - -EOF - echo "Trying '$XSLTPROC $XSLTPROC_FLAGS http://docbook.sourceforge.net/release/xsl/current/VERSION' with input:" >&5 - echo "====" >&5 - cat conftest.xsl >&5 - echo "====" >&5 - ac_cv_docbook_xslt_current_version=`$XSLTPROC $XSLTPROC_FLAGS conftest.xsl http://docbook.sourceforge.net/release/xsl/current/VERSION 2>&5` + cat <>config.warnings +Cannot find either gzip or compress. Using cat. +AAW_EOF - if test "$?" != 0; then - ac_cv_docbook_xslt_current_version='no' - fi - rm conftest.xsl + COMPRESS_PATH="$CAT" + COMPRESS_SUFFIX="" + COMPRESS_FAST_OPT="" + COMPRESS_BEST_OPT="" + UNCOMPRESS_PATH="$CAT" + UNCOMPRESS_OPT="" fi + fi -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_docbook_xslt_current_version" >&5 -$as_echo "$ac_cv_docbook_xslt_current_version" >&6; } - - DOCBOOK_XSLT_CURRENT_VERSION="$ac_cv_docbook_xslt_current_version" - { $as_echo "$as_me:$LINENO: checking whether Docbook XSLT version is 1.72.0 or newer" >&5 -$as_echo_n "checking whether Docbook XSLT version is 1.72.0 or newer... " >&6; } - - if test x"$DOCBOOK_XSLT_CURRENT_VERSION" = x"no"; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - else - - # Used to indicate true or false condition - ax_compare_version=false - # Convert the two version strings to be compared into a format that - # allows a simple string comparison. The end result is that a version - # string of the form 1.12.5-r617 will be converted to the form - # 0001001200050617. In other words, each number is zero padded to four - # digits, and non digits are removed. +cat >>confdefs.h <<_ACEOF +#define COMPRESS_PATH "$COMPRESS_PATH" +_ACEOF - ax_compare_version_A=`echo "$DOCBOOK_XSLT_CURRENT_VERSION" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ - -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/[^0-9]//g'` +cat >>confdefs.h <<_ACEOF +#define COMPRESS_SUFFIX "$COMPRESS_SUFFIX" +_ACEOF - ax_compare_version_B=`echo "1.72.0" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ - -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/[^0-9]//g'` +cat >>confdefs.h <<_ACEOF +#define COMPRESS_FAST_OPT "$COMPRESS_FAST_OPT" +_ACEOF - ax_compare_version=`echo "x$ax_compare_version_A -x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/false/;s/x${ax_compare_version_B}/true/;1q"` +cat >>confdefs.h <<_ACEOF +#define COMPRESS_BEST_OPT "$COMPRESS_BEST_OPT" +_ACEOF - if test "$ax_compare_version" = "true" ; then +cat >>confdefs.h <<_ACEOF +#define UNCOMPRESS_PATH "$UNCOMPRESS_PATH" +_ACEOF - # version is less than required, so mark it as "no" - DOCBOOK_XSLT_CURRENT_VERSION=no - fi +cat >>confdefs.h <<_ACEOF +#define UNCOMPRESS_OPT "$UNCOMPRESS_OPT" +_ACEOF - if test x"$DOCBOOK_XSLT_CURRENT_VERSION" = x"no"; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - else - { $as_echo "$as_me:$LINENO: result: yes ($DOCBOOK_XSLT_CURRENT_VERSION)" >&5 -$as_echo "yes ($DOCBOOK_XSLT_CURRENT_VERSION)" >&6; } - fi - fi @@ -35293,306 +22795,652 @@ $as_echo "yes ($DOCBOOK_XSLT_CURRENT_VERSION)" >&6; } + # Empty GZIP so that make dist works. + GZIP= - { $as_echo "$as_me:$LINENO: checking for Docbook DTD version 4.1.2" >&5 -$as_echo_n "checking for Docbook DTD version 4.1.2... " >&6; } -if test "${ac_cv_docbook_dtd_4_1_2+set}" = set; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sockaddr_storage struct exists" >&5 +$as_echo_n "checking if sockaddr_storage struct exists... " >&6; } +if ${ac_cv_has_sockaddr_storage+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_docbook_dtd_4_1_2=no - if test -n "$XSLTPROC"; then - MY_XSLTPROC_FLAGS=`echo "" $XSLTPROC_FLAGS|sed -e s/--novalid//g` - cat <conftest.xml - - - - -EOF - echo "Trying '$XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml'" >&5 - echo "conftest.xml:" >&5 - echo "====" >&5 - cat conftest.xml >&5 - echo "====" >&5 - - $XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml >conftest.out 2>&1 - if test "$?" = 0 -o "$?" = 5; then - # failing to load the DTD is just a warning, so check for it in the output. - if grep 'warning: failed to load external entity' conftest.out >/dev/null 2>&1; then - : # no good.. - else - ac_cv_docbook_dtd_4_1_2=yes - fi - fi - cat conftest.out >&5 - - rm -f conftest.xml conftest.out - fi + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +# include +# include +int +main () +{ +u_int i = sizeof (struct sockaddr_storage) + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_has_sockaddr_storage=yes +else + ac_cv_has_sockaddr_storage=no fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_docbook_dtd_4_1_2" >&5 -$as_echo "$ac_cv_docbook_dtd_4_1_2" >&6; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - HAVE_DOCBOOK_DTD_4_1_2="$ac_cv_docbook_dtd_4_1_2" - HAVE_DOCBOOK_DTD="$HAVE_DOCBOOK_DTD_4_1_2" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_has_sockaddr_storage" >&5 +$as_echo "$ac_cv_has_sockaddr_storage" >&6; } + if test $ac_cv_has_sockaddr_storage = yes ; then +$as_echo "#define HAVE_SOCKADDR_STORAGE 1" >>confdefs.h + fi + WORKING_IPV6=no +# Check whether --with-ipv6 was given. +if test "${with_ipv6+set}" = set; then : + withval=$with_ipv6; + case "$withval" in + y | ye | yes) amanda_with_ipv6=yes;; + n | no) amanda_with_ipv6=no;; + *) + as_fn_error $? "*** You must not supply an argument to --with-ipv6 option." "$LINENO" 5 + ;; + esac +else + amanda_with_ipv6=maybe +fi - { $as_echo "$as_me:$LINENO: checking for Docbook DTD version 4.2" >&5 -$as_echo_n "checking for Docbook DTD version 4.2... " >&6; } -if test "${ac_cv_docbook_dtd_4_2+set}" = set; then + if test x"$amanda_with_ipv6" = x"yes" || + test x"$amanda_with_ipv6" = x"maybe" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working IPv6" >&5 +$as_echo_n "checking for working IPv6... " >&6; } +if ${amanda_cv_working_ipv6+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_docbook_dtd_4_2=no - if test -n "$XSLTPROC"; then - MY_XSLTPROC_FLAGS=`echo "" $XSLTPROC_FLAGS|sed -e s/--novalid//g` - cat <conftest.xml - - - - -EOF - echo "Trying '$XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml'" >&5 - echo "conftest.xml:" >&5 - echo "====" >&5 - cat conftest.xml >&5 - echo "====" >&5 + case "$host" in + *-pc-cygwin) amanda_cv_working_ipv6=no;; + *) + if test "$cross_compiling" = yes; then : + amanda_cv_working_ipv6=yes - $XSLTPROC $MY_XSLTPROC_FLAGS conftest.xml >conftest.out 2>&1 - if test "$?" = 0 -o "$?" = 5; then - # failing to load the DTD is just a warning, so check for it in the output. - if grep 'warning: failed to load external entity' conftest.out >/dev/null 2>&1; then - : # no good.. - else - ac_cv_docbook_dtd_4_2=yes - fi - fi - cat conftest.out >&5 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - rm -f conftest.xml conftest.out - fi +#include +#ifdef HAVE_SYS_SOCKET_H +#include +#endif +#ifdef HAVE_NETINET_IN_H +#include +#endif +#ifdef HAVE_WINSOCK2_H +#include +#endif +#include +#include +main() +{ + int aa; + aa = socket(AF_INET6, SOCK_STREAM, 0); + if (aa > 0) return 0; + return aa; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + amanda_cv_working_ipv6=yes +else + amanda_cv_working_ipv6=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_docbook_dtd_4_2" >&5 -$as_echo "$ac_cv_docbook_dtd_4_2" >&6; } - - HAVE_DOCBOOK_DTD_4_2="$ac_cv_docbook_dtd_4_2" - HAVE_DOCBOOK_DTD="$HAVE_DOCBOOK_DTD_4_2" - - + esac +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_working_ipv6" >&5 +$as_echo "$amanda_cv_working_ipv6" >&6; } + if test "$amanda_cv_working_ipv6" = yes; then + WORKING_IPV6=yes - if test -z "$XSLTPROC"; then - { { $as_echo "$as_me:$LINENO: error: Cannot build manpages: 'xsltproc' was not found." >&5 -$as_echo "$as_me: error: Cannot build manpages: 'xsltproc' was not found." >&2;} - { (exit 1); exit 1; }; } - fi +$as_echo "#define WORKING_IPV6 1" >>confdefs.h - # if the 'current' Docbook revision is good enough, use that; otherwise, - # if 1.72.0 is available, use that. - XSLREL=current - if test "x$DOCBOOK_XSLT_CURRENT_VERSION" = "xno"; then - if test "x$HAVE_DOCBOOK_XSLT_1_72_0" = "xno"; then - { { $as_echo "$as_me:$LINENO: error: Cannot build manpages: docbook version 1.72.0 or higher required." >&5 -$as_echo "$as_me: error: Cannot build manpages: docbook version 1.72.0 or higher required." >&2;} - { (exit 1); exit 1; }; } - else - XSLREL=1.72.0 + else + # error out only if the user specifically requested support + if test x"$amanda_with_ipv6" = x"yes"; then + as_fn_error $? "IPv6 support was requested, but opening an IPv6 socket failed" "$LINENO" 5 fi fi + fi - # disable validation if the correct DTDs are not available - if test "x$HAVE_DOCBOOK_DTD_4_1_2" = "xno" || test "x$HAVE_DOCBOOK_DTD_4_2" = "xno"; then - { $as_echo "$as_me:$LINENO: WARNING: Docbook DTD versions 4.1.2 and 4.2 are required for manpage validation; disabling validation" >&5 -$as_echo "$as_me: WARNING: Docbook DTD versions 4.1.2 and 4.2 are required for manpage validation; disabling validation" >&2;} + ac_header_dirent=no +for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do + as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 +$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } +if eval \${$as_ac_Header+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include <$ac_hdr> +int +main () +{ +if ((DIR *) 0) +return 0; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_ac_Header=yes" +else + eval "$as_ac_Header=no" +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +eval ac_res=\$$as_ac_Header + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 +_ACEOF - cat <>config.warnings -Docbook DTD versions 4.1.2 and 4.2 are required for manpage validation; disabling validation -AAW_EOF +ac_header_dirent=$ac_hdr; break +fi +done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - XSLTPROC_FLAGS="$XSLTPROC_FLAGS --novalid" - fi - fi +/* Override any GCC internal prototype to avoid an error. + Use char because int might match the return type of a GCC + builtin and then its argument prototype would still apply. */ +#ifdef __cplusplus +extern "C" +#endif +char opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' dir; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break +fi +done +if ${ac_cv_search_opendir+:} false; then : - if test "x$ENABLE_MANPAGE_BUILD" = "xyes"; then - ENABLE_MANPAGE_BUILD_TRUE= - ENABLE_MANPAGE_BUILD_FALSE='#' else - ENABLE_MANPAGE_BUILD_TRUE='#' - ENABLE_MANPAGE_BUILD_FALSE= + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +fi +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* 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 opendir (); +int +main () +{ +return opendir (); + ; + return 0; +} +_ACEOF +for ac_lib in '' x; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break +fi +done +if ${ac_cv_search_opendir+:} false; then : +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - #allow configure CONFIG_CLOBBER_MY_CONFIG= to be used by make. - CONFIG_CLOBBER_MY_CONFIG=$CLOBBER_MY_CONFIG +fi +fi -# Check whether --with-index-server was given. -if test "${with_index_server+set}" = set; then - withval=$with_index_server; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-index-server option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-index-server option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) DEFAULT_SERVER="$withval" - ;; - esac + # include the dirent headers as described in the autoconf documentation. + ac_fn_c_check_decl "$LINENO" "readdir" "ac_cv_have_decl_readdir" " +#if HAVE_DIRENT_H +# include +# define NAMLEN(dirent) strlen((dirent)->d_name) +#else +# define dirent direct +# define NAMLEN(dirent) (dirent)->d_namlen +# if HAVE_SYS_NDIR_H +# include +# endif +# if HAVE_SYS_DIR_H +# include +# endif +# if HAVE_NDIR_H +# include +# endif +#endif +" +if test "x$ac_cv_have_decl_readdir" = xyes; then : + ac_have_decl=1 else - : ${DEFAULT_SERVER=`uname -n`} - + ac_have_decl=0 fi - cat >>confdefs.h <<_ACEOF -#define DEFAULT_SERVER "$DEFAULT_SERVER" +#define HAVE_DECL_READDIR $ac_have_decl _ACEOF +ac_fn_c_check_decl "$LINENO" "readdir_r" "ac_cv_have_decl_readdir_r" " +#if HAVE_DIRENT_H +# include +# define NAMLEN(dirent) strlen((dirent)->d_name) +#else +# define dirent direct +# define NAMLEN(dirent) (dirent)->d_namlen +# if HAVE_SYS_NDIR_H +# include +# endif +# if HAVE_SYS_DIR_H +# include +# endif +# if HAVE_NDIR_H +# include +# endif +#endif - - - -# Check whether --with-config was given. -if test "${with_config+set}" = set; then - withval=$with_config; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-config option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-config option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) DEFAULT_CONFIG="$withval" - ;; - esac - +" +if test "x$ac_cv_have_decl_readdir_r" = xyes; then : + ac_have_decl=1 else - : ${DEFAULT_CONFIG=DailySet1} - + ac_have_decl=0 fi - cat >>confdefs.h <<_ACEOF -#define DEFAULT_CONFIG "$DEFAULT_CONFIG" +#define HAVE_DECL_READDIR_R $ac_have_decl _ACEOF +ac_fn_c_check_decl "$LINENO" "readdir64" "ac_cv_have_decl_readdir64" " +#if HAVE_DIRENT_H +# include +# define NAMLEN(dirent) strlen((dirent)->d_name) +#else +# define dirent direct +# define NAMLEN(dirent) (dirent)->d_namlen +# if HAVE_SYS_NDIR_H +# include +# endif +# if HAVE_SYS_DIR_H +# include +# endif +# if HAVE_NDIR_H +# include +# endif +#endif +" +if test "x$ac_cv_have_decl_readdir64" = xyes; then : + ac_have_decl=1 +else + ac_have_decl=0 +fi +cat >>confdefs.h <<_ACEOF +#define HAVE_DECL_READDIR64 $ac_have_decl +_ACEOF +ac_fn_c_check_decl "$LINENO" "readdir64_r" "ac_cv_have_decl_readdir64_r" " +#if HAVE_DIRENT_H +# include +# define NAMLEN(dirent) strlen((dirent)->d_name) +#else +# define dirent direct +# define NAMLEN(dirent) (dirent)->d_namlen +# if HAVE_SYS_NDIR_H +# include +# endif +# if HAVE_SYS_DIR_H +# include +# endif +# if HAVE_NDIR_H +# include +# endif +#endif - -# Check whether --with-tape-server was given. -if test "${with_tape_server+set}" = set; then - withval=$with_tape_server; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-tape-server option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-tape-server option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) DEFAULT_TAPE_SERVER="$withval" - ;; - esac - +" +if test "x$ac_cv_have_decl_readdir64_r" = xyes; then : + ac_have_decl=1 else - : ${DEFAULT_TAPE_SERVER=$DEFAULT_SERVER} - + ac_have_decl=0 fi - cat >>confdefs.h <<_ACEOF -#define DEFAULT_TAPE_SERVER "$DEFAULT_TAPE_SERVER" +#define HAVE_DECL_READDIR64_R $ac_have_decl _ACEOF + # disk device prefixes + { $as_echo "$as_me:${as_lineno-$LINENO}: checking disk device prefixes" >&5 +$as_echo_n "checking disk device prefixes... " >&6; } -# Check whether --with-tape-device was given. -if test "${with_tape_device+set}" = set; then - withval=$with_tape_device; - case "$withval" in - "" | y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to the --with-tape-device option." >&5 -$as_echo "$as_me: error: *** You must supply an argument to the --with-tape-device option." >&2;} - { (exit 1); exit 1; }; } - ;; - *) DEFAULT_TAPE_DEVICE="$withval" - ;; + # Use df to find the mount point for the root filesystem. Use + # the positional parameters to find the particular line from df + # that contains the root paritition. We put it in a subshell so + # that the original positional parameters are not messed with. + dfline=`( + df / | while read line; do + set -- $line + while test $# -gt 0; do + if test "x$1" = "x/"; then + echo $line + break 2 + fi + shift + done + done + ) | sed 's/(//' | sed 's/)//' ` + + # Search for the mount point by using expr to find the parameter + # with dev in it. + mount=`( + set -- $dfline + while test $# -gt 0; do + if expr "$1" : '.*dev' >/dev/null 2>&1; then + echo $1 + break + fi + shift + done + )` + + # get any system-specific configuration information + case "$host" in + *-hp-*) + CLIENT_SCRIPTS_OPT=amhpfixdevs + case $mount in + /dev/vg*) + + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Run amhpfixdevs on HP-UX systems using /dev/vg??." >&5 +$as_echo "$as_me: WARNING: Run amhpfixdevs on HP-UX systems using /dev/vg??." >&2;} + + + cat <>config.warnings +Run amhpfixdevs on HP-UX systems using /dev/vg??. +AAW_EOF + + + ;; esac + ;; + *-sni-sysv4) + DEV_PREFIX=/dev/dsk/ + RDEV_PREFIX=/dev/rdsk/ + CLIENT_SCRIPTS_OPT=amsinixfixdevs + if ! test -d /dev/dsk; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Run amsinixfixdevs on Sinix systems using VxFS." >&5 +$as_echo "$as_me: WARNING: Run amsinixfixdevs on Sinix systems using VxFS." >&2;} -fi + cat <>config.warnings +Run amsinixfixdevs on Sinix systems using VxFS. +AAW_EOF + + + fi + ;; + *-sco3.2v4*) + DEV_PREFIX=/dev/ + RDEV_PREFIX=/dev/ + ;; + *) + CLIENT_SCRIPTS_OPT= + ;; + esac + + if test "$DEV_PREFIX" && test "$RDEV_PREFIX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: (predefined) $DEV_PREFIX - $RDEV_PREFIX" >&5 +$as_echo "(predefined) $DEV_PREFIX - $RDEV_PREFIX" >&6; } + else + if test -d /dev/dsk; then + DEV_PREFIX=/dev/dsk/ + if test -d /dev/rdsk; then + RDEV_PREFIX=/dev/rdsk/ + else + RDEV_PREFIX=/dev/dsk/ + fi + elif test -d /dev; then + DEV_PREFIX=/dev/ + + # Some systems, notably Linux, do not have raw disk devices + # names. Check this by trying to see if a raw disk device name + # exists using the normal raw device path prepended to the + # mount point of the root filesystem. + if test "$mount"; then + dev_name="/dev/r`basename $mount`" + if test -b $dev_name -o -c $dev_name; then + RDEV_PREFIX=/dev/r + else + RDEV_PREFIX=/dev/ + fi + else + RDEV_PREFIX=/dev/r + fi + else + # just fake it.. + DEV_PREFIX=/ + RDEV_PREFIX=/ + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEV_PREFIX - $RDEV_PREFIX" >&5 +$as_echo "$DEV_PREFIX - $RDEV_PREFIX" >&6; } + fi cat >>confdefs.h <<_ACEOF -#define DEFAULT_TAPE_DEVICE "$DEFAULT_TAPE_DEVICE" +#define DEV_PREFIX "${DEV_PREFIX}" _ACEOF +cat >>confdefs.h <<_ACEOF +#define RDEV_PREFIX "${RDEV_PREFIX}" +_ACEOF - if test "${DEFAULT_TAPE_DEVICE+set}" = "set"; then - EXAMPLE_TAPEDEV="$DEFAULT_TAPE_DEVICE" - else - EXAMPLE_TAPEDEV="tape:/dev/YOUR-TAPE-DEVICE-HERE" - fi -# Check whether --with-changer-device was given. -if test "${with_changer_device+set}" = set; then - withval=$with_changer_device; + case "$host" in + *-dec-osf*) + ;; + *-dg-*) + ;; + *-netbsd*) + ;; + *-freebsd*) + ;; + *-openbsd*) + ;; + *-hp-*) + case "$CC" in + *gcc*) + CPPFLAGS="$CPPFLAGS -D__STDC_EXT__" - { $as_echo "$as_me:$LINENO: WARNING: --with-changer-device is no longer used." >&5 -$as_echo "$as_me: WARNING: --with-changer-device is no longer used." >&2;} + ;; + *cc*) + CFLAGS="$CFLAGS -Ae" + + ;; + esac + ;; + *-ibm-aix*) + ;; + m88k-motorola-sysv4) + ;; + *-nextstep3) + ;; + *-pc-bsdi*) + ;; + *-pc-linux-*) + ;; + *-redhat-linux-*) + ;; + *-suse-linux-*) + ;; + x86_64-*-linux-*) + ;; + alpha*-*-linux-*) + ;; + sparc*-*-linux-*) + ;; + powerpc-*-linux-*) + ;; + *-sgi-irix3*) + # The old cc won't work! + if test "x$GCC" != "xyes"; then + as_fn_error $? "The old SGI IRIX compiler ($CC) will not compile Amanda; use CC=gcc" "$LINENO" 5 + fi + ;; + *-sgi-irix4*) + ;; + *-sgi-irix5*) + ;; + *-sgi-irix6*) + ;; + *-solaris2*) + ;; + *-sun-sunos4.1*) + ;; + *-ultrix*) + ;; + *-sysv4.2uw2*) + ;; + *-sco3.2v5*) + ;; + i386-pc-isc4*) + ;; + *-sni-sysv4) + ;; + *-pc-cygwin) +$as_echo "#define IGNORE_TAR_ERRORS 1" >>confdefs.h - cat <>config.warnings ---with-changer-device is no longer used. -AAW_EOF + # Cygwin needs PATH to find cygwin1.dll +$as_echo "#define NEED_PATH_ENV 1" >>confdefs.h +$as_echo "#define IGNORE_FSTAB 1" >>confdefs.h -fi + LDFLAGS="$LDFLAGS -Wl,-enable-runtime-pseudo-reloc -no-undefined" + + ;; + *-apple-darwin7*) # MacOS X 10.3.* (Panther) + ;; + *-apple-darwin8*) # MacOS X 10.4.* (Tiger) + ;; + *-apple-darwin9*) # MacOS X 10.5.* (Leopard) + ;; + *-apple-darwin10*) # MacOS X 10.6.* (Snow Leopard) + ;; + *) + cat <>config.warnings +***** +This machine, target type $host, is not known to be fully supported +by this configure script. If the installation of Amanda on this system +succeeds or needed any patches, please email amanda-hackers@amanda.org +with the patches or an indication of the sucess or failure of the +Amanda installation on your system. +***** +AAW_EOF -# Check whether --with-amandates was given. -if test "${with_amandates+set}" = set; then - withval=$with_amandates; - case "$withval" in - n | no) { { $as_echo "$as_me:$LINENO: error: *** --without-amandates is not allowed." >&5 -$as_echo "$as_me: error: *** --without-amandates is not allowed." >&2;} - { (exit 1); exit 1; }; };; - y | ye | yes) amandates='$localstatedir/amanda/amandates' ;; - *) amandates="$withval";; - esac + ;; + esac -else - amandates='$localstatedir/amanda/amandates' -fi @@ -35600,446 +23448,263 @@ fi exec_prefix_NONE= test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$amandates\"" + eval ac_define_dir="\"$bindir\"" eval ac_define_dir="\"$ac_define_dir\"" - DEFAULT_AMANDATES_FILE="$ac_define_dir" + bindir="$ac_define_dir" cat >>confdefs.h <<_ACEOF -#define DEFAULT_AMANDATES_FILE "$ac_define_dir" +#define bindir "$ac_define_dir" _ACEOF test "$prefix_NONE" && prefix=NONE test "$exec_prefix_NONE" && exec_prefix=NONE - DEFAULT_FSF_AFTER_FILEMARK="FALSE" - case "$host" in - *-solaris*) DEFAULT_FSF_AFTER_FILEMARK="TRUE" - ;; - esac + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$sbindir\"" + eval ac_define_dir="\"$ac_define_dir\"" + sbindir="$ac_define_dir" + cat >>confdefs.h <<_ACEOF -#define DEFAULT_FSF_AFTER_FILEMARK $DEFAULT_FSF_AFTER_FILEMARK +#define sbindir "$ac_define_dir" _ACEOF + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE - # Extract the first word of "getconf", so it can be a program name with args. -set dummy getconf; 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_GETCONF+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $GETCONF in - [\\/]* | ?:[\\/]*) - ac_cv_path_GETCONF="$GETCONF" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSPATH -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_GETCONF="$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 + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$libexecdir\"" + eval ac_define_dir="\"$ac_define_dir\"" + libexecdir="$ac_define_dir" - ;; -esac -fi -GETCONF=$ac_cv_path_GETCONF -if test -n "$GETCONF"; then - { $as_echo "$as_me:$LINENO: result: $GETCONF" >&5 -$as_echo "$GETCONF" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi +cat >>confdefs.h <<_ACEOF +#define libexecdir "$ac_define_dir" +_ACEOF + + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$mandir\"" + eval ac_define_dir="\"$ac_define_dir\"" + mandir="$ac_define_dir" +cat >>confdefs.h <<_ACEOF +#define mandir "$ac_define_dir" +_ACEOF - # we use 'getconf', if it exists, to get the relevant - # compiler flags. - GETCONF_LFS="LFS" - case "$host" in - *-hp-*) GETCONF_LFS="XBS5_ILP32_OFFBIG" ;; - *-ibm-aix*) GETCONF_LFS="XBS5_ILP32_OFFBIG" ;; - esac + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE - # Checks for compilers, typedefs, structures, and compiler characteristics. - # Check for large file compilation environment. - NEED_RESETOFS=yes - { $as_echo "$as_me:$LINENO: checking for large file compilation CFLAGS" >&5 -$as_echo_n "checking for large file compilation CFLAGS... " >&6; } -if test "${amanda_cv_LFS_CFLAGS+set}" = set; then - $as_echo_n "(cached) " >&6 -else - amanda_cv_LFS_CFLAGS= - if test "$GETCONF"; then - if $GETCONF ${GETCONF_LFS}_CFLAGS >/dev/null 2>&1; then - amanda_cv_LFS_CFLAGS=`$GETCONF ${GETCONF_LFS}_CFLAGS 2>/dev/null` - NEED_RESETOFS=no - fi - fi + + # amanda-specific directories + AMLIBDIR=$libdir/amanda + +# Check whether --with-amlibdir was given. +if test "${with_amlibdir+set}" = set; then : + withval=$with_amlibdir; + case "$withval" in + n | no) AMLIBDIR=$libdir ;; + y | ye | yes) AMLIBDIR=$libdir/amanda ;; + *) AMLIBDIR=$withval ;; + esac fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_LFS_CFLAGS" >&5 -$as_echo "$amanda_cv_LFS_CFLAGS" >&6; } - CFLAGS="$CFLAGS $amanda_cv_LFS_CFLAGS" - { $as_echo "$as_me:$LINENO: checking for large file compilation LDFLAGS" >&5 -$as_echo_n "checking for large file compilation LDFLAGS... " >&6; } -if test "${amanda_cv_LFS_LDFLAGS+set}" = set; then - $as_echo_n "(cached) " >&6 -else + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$AMLIBDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + amlibdir="$ac_define_dir" - amanda_cv_LFS_LDFLAGS= - if test "$GETCONF"; then - if $GETCONF ${GETCONF_LFS}_LDFLAGS >/dev/null 2>&1; then - amanda_cv_LFS_LDFLAGS=`$GETCONF ${GETCONF_LFS}_LDFLAGS 2>/dev/null` - NEED_RESETOFS=no - fi - fi +cat >>confdefs.h <<_ACEOF +#define amlibdir "$ac_define_dir" +_ACEOF -fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_LFS_LDFLAGS" >&5 -$as_echo "$amanda_cv_LFS_LDFLAGS" >&6; } - LDFLAGS="$LDFLAGS $amanda_cv_LFS_LDFLAGS" + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE - { $as_echo "$as_me:$LINENO: checking for large file compilation LIBS" >&5 -$as_echo_n "checking for large file compilation LIBS... " >&6; } -if test "${amanda_cv_LFS_LIBS+set}" = set; then - $as_echo_n "(cached) " >&6 -else + AMLIBEXECDIR=$libexecdir/amanda - amanda_cv_LFS_LIBS= - if test "$GETCONF"; then - if $GETCONF ${GETCONF_LFS}_LIBS >/dev/null 2>&1; then - amanda_cv_LFS_LIBS=`$GETCONF ${GETCONF_LFS}_LIBS 2>/dev/null` - NEED_RESETOFS=no - fi - fi +# Check whether --with-amlibexecdir was given. +if test "${with_amlibexecdir+set}" = set; then : + withval=$with_amlibexecdir; + case "$withval" in + n | no) AMLIBEXECDIR=$libexecdir ;; + y | ye | yes) AMLIBEXECDIR=$libexecdir/amanda ;; + *) AMLIBEXECDIR=$withval ;; + esac fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_LFS_LIBS" >&5 -$as_echo "$amanda_cv_LFS_LIBS" >&6; } - LIBS="$amanda_cv_LFS_LIBS $LIBS" - if test x"$NEED_RESETOFS" = x"yes"; then + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$AMLIBEXECDIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + amlibexecdir="$ac_define_dir" -cat >>confdefs.h <<\_ACEOF -#define NEED_RESETOFS 1 + +cat >>confdefs.h <<_ACEOF +#define amlibexecdir "$ac_define_dir" _ACEOF - fi + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + amincludedir="${includedir}/amanda" + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$amincludedir\"" + eval ac_define_dir="\"$ac_define_dir\"" + amincludedir="$ac_define_dir" +cat >>confdefs.h <<_ACEOF +#define amincludedir "$ac_define_dir" +_ACEOF -for ac_header in fstab.h \ - mntent.h \ - mnttab.h \ - sys/vfstab.h \ + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE + + + +# Check whether --with-amperldir was given. +if test "${with_amperldir+set}" = set; then : + withval=$with_amperldir; + case "$withval" in + y | ye | yes) AMPERLLIB=DEFAULT ;; + n | no) AMPERLLIB=$amlibdir/perl ;; + *) AMPERLLIB=$withval ;; + esac -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 + AMPERLLIB=DEFAULT -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; } + # apply the default if no value was given. + if test x"$AMPERLLIB" = x"DEFAULT"; then + eval `$PERL -V:installsitelib` + AMPERLLIB=$installsitelib + fi -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$AMPERLLIB\"" + eval ac_define_dir="\"$ac_define_dir\"" + amperldir="$ac_define_dir" - ;; -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 +cat >>confdefs.h <<_ACEOF +#define amperldir "$ac_define_dir" _ACEOF -fi + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE -done + APPLICATION_DIR='${amlibexecdir}/application' + + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$APPLICATION_DIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + APPLICATION_DIR="$ac_define_dir" -for ac_func in endmntent -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ +cat >>confdefs.h <<_ACEOF +#define APPLICATION_DIR "$ac_define_dir" _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE -#ifdef __STDC__ -# include -#else -# include -#endif -#undef $ac_func -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif +# Check whether --with-amdatadir was given. +if test "${with_amdatadir+set}" = set; then : + withval=$with_amdatadir; + AMDATADIR=$withval -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_ac_var=no" -fi + AMDATADIR=$datadir/amanda -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF fi -done -for ac_func in setmntent -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ + prefix_NONE= + exec_prefix_NONE= + test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix + test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix + eval ac_define_dir="\"$AMDATADIR\"" + eval ac_define_dir="\"$ac_define_dir\"" + amdatadir="$ac_define_dir" + + +cat >>confdefs.h <<_ACEOF +#define amdatadir "$ac_define_dir" _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ + test "$prefix_NONE" && prefix=NONE + test "$exec_prefix_NONE" && exec_prefix=NONE -#ifdef __STDC__ -# include -#else -# include -#endif -#undef $ac_func + +# +# Internationalization +# + + # FreeBSD needs to link libxpg4 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setlocale in -lxpg4" >&5 +$as_echo_n "checking for setlocale in -lxpg4... " >&6; } +if ${ac_cv_lib_xpg4_setlocale+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lxpg4 $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC @@ -36047,3331 +23712,2649 @@ cat >>conftest.$ac_ext <<_ACEOF #ifdef __cplusplus extern "C" #endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - +char setlocale (); int main () { -return $ac_func (); +return setlocale (); ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_xpg4_setlocale=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" + ac_cv_lib_xpg4_setlocale=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xpg4_setlocale" >&5 +$as_echo "$ac_cv_lib_xpg4_setlocale" >&6; } +if test "x$ac_cv_lib_xpg4_setlocale" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_LIBXPG4 1 _ACEOF -fi -done - - - - + LIBS="-lxpg4 $LIBS" +fi + # ------------------------------------------------------------------ + # All list of languages for which a translation exist. Each + # language is separated by a space. + # ------------------------------------------------------------------ + ALL_LINGUAS="" -for ac_header in fcntl.h \ - sys/fcntl.h \ - sys/types.h \ - sys/file.h \ - unistd.h \ -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 -$as_echo_n "checking for $ac_header... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + # Extract the first word of "msgfmt", so it can be a program name with args. +set dummy msgfmt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_MSGFMT+:} false; 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; } + case $MSGFMT in + [\\/]* | ?:[\\/]*) + ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_MSGFMT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -# 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 +fi +MSGFMT=$ac_cv_path_MSGFMT +if test -n "$MSGFMT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5 +$as_echo "$MSGFMT" >&6; } else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_preproc=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } 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;} - ;; -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 + # Extract the first word of "gettext", so it can be a program name with args. +set dummy gettext; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GETTEXT+:} false; 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; } + case $GETTEXT in + [\\/]* | ?:[\\/]*) + ac_cv_path_GETTEXT="$GETTEXT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_GETTEXT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac 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 - +GETTEXT=$ac_cv_path_GETTEXT +if test -n "$GETTEXT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GETTEXT" >&5 +$as_echo "$GETTEXT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -done - # find a working file-locking mechanism. - # Note: these all use AC_TRY_LINK to make sure that we can compile - # and link each variant. They do not try to test the variants -- - # that is left to runtime. - LOCKING="no" - # check POSIX locking - { $as_echo "$as_me:$LINENO: checking whether POSIX locking (with fcntl(2)) is available" >&5 -$as_echo_n "checking whether POSIX locking (with fcntl(2)) is available... " >&6; } -if test "${amanda_cv_posix_filelocking+set}" = set; then - $as_echo_n "(cached) " >&6 + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 +$as_echo_n "checking whether NLS is requested... " >&6; } + # Check whether --enable-nls was given. +if test "${enable_nls+set}" = set; then : + enableval=$enable_nls; USE_NLS=$enableval else + USE_NLS=yes +fi - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 +$as_echo "$USE_NLS" >&6; } -#if HAVE_SYS_TYPES_H -# include -#endif -#if HAVE_UNISTD_H -# include -#endif -#if HAVE_FCNTL_H -# include -#endif -int -main () -{ - struct flock lock; - lock.l_type = F_RDLCK; - lock.l_start = 0; - lock.l_whence = SEEK_CUR; - lock.l_len = 0; - return fcntl(1, F_SETLK, &lock); - ; - 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 - amanda_cv_posix_filelocking="yes" +# Prepare PATH_SEPARATOR. +# 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 +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - - amanda_cv_posix_filelocking="no" - + ac_executable_p="test -f" fi +rm -f conf$$.file -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - +# Extract the first word of "msgfmt", so it can be a program name with args. +set dummy msgfmt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_MSGFMT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case "$MSGFMT" in + [\\/]* | ?:[\\/]*) + ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. + ;; + *) + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + echo "$as_me: trying $ac_dir/$ac_word..." >&5 + if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 && + (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then + ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" + test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" + ;; +esac fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_posix_filelocking" >&5 -$as_echo "$amanda_cv_posix_filelocking" >&6; } - if test "x$amanda_cv_posix_filelocking" = xyes; then - -cat >>confdefs.h <<\_ACEOF -#define WANT_AMFLOCK_POSIX 1 -_ACEOF - - WANT_AMFLOCK_POSIX="yes" - LOCKING="POSIX_FCNTL" - fi - if test x"$WANT_AMFLOCK_POSIX" = x"yes"; then - WANT_AMFLOCK_POSIX_TRUE= - WANT_AMFLOCK_POSIX_FALSE='#' +MSGFMT="$ac_cv_path_MSGFMT" +if test "$MSGFMT" != ":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5 +$as_echo "$MSGFMT" >&6; } else - WANT_AMFLOCK_POSIX_TRUE='#' - WANT_AMFLOCK_POSIX_FALSE= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - - # check flock-based (BSD) locking - { $as_echo "$as_me:$LINENO: checking whether flock locking is available" >&5 -$as_echo_n "checking whether flock locking is available... " >&6; } -if test "${amanda_cv_flock_filelocking+set}" = set; then + # Extract the first word of "gmsgfmt", so it can be a program name with args. +set dummy gmsgfmt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GMSGFMT+:} false; then : $as_echo_n "(cached) " >&6 else + case $GMSGFMT in + [\\/]* | ?:[\\/]*) + ac_cv_path_GMSGFMT="$GMSGFMT" # 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_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#if HAVE_SYS_FILE_H -# include -#endif - -int -main () -{ - - return flock(1, LOCK_SH); - - ; - 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;; + test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" + ;; 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 +fi +GMSGFMT=$ac_cv_path_GMSGFMT +if test -n "$GMSGFMT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5 +$as_echo "$GMSGFMT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - amanda_cv_flock_filelocking="yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in + '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;; + *) MSGFMT_015=$MSGFMT ;; + esac - amanda_cv_flock_filelocking="no" + case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in + '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;; + *) GMSGFMT_015=$GMSGFMT ;; + esac -fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - -fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_flock_filelocking" >&5 -$as_echo "$amanda_cv_flock_filelocking" >&6; } - if test "x$amanda_cv_flock_filelocking" = xyes; then - -cat >>confdefs.h <<\_ACEOF -#define WANT_AMFLOCK_FLOCK 1 -_ACEOF - - WANT_AMFLOCK_FLOCK="yes" - LOCKING="FLOCK" - fi - if test x"$WANT_AMFLOCK_FLOCK" = x"yes"; then - WANT_AMFLOCK_FLOCK_TRUE= - WANT_AMFLOCK_FLOCK_FALSE='#' -else - WANT_AMFLOCK_FLOCK_TRUE='#' - WANT_AMFLOCK_FLOCK_FALSE= -fi - - - # check lockf-based (SVR2, SVR3, SVR4) locking - { $as_echo "$as_me:$LINENO: checking whether lockf(3) locking is available" >&5 -$as_echo_n "checking whether lockf(3) locking is available... " >&6; } -if test "${amanda_cv_lockf_filelocking+set}" = set; then - $as_echo_n "(cached) " >&6 -else - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#if HAVE_UNISTD_H -# include -#endif - -int -main () -{ - - return lockf(1, F_LOCK, 0); - - ; - 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 - - amanda_cv_lockf_filelocking="yes" - -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - - amanda_cv_lockf_filelocking="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: $amanda_cv_lockf_filelocking" >&5 -$as_echo "$amanda_cv_lockf_filelocking" >&6; } - if test "x$amanda_cv_lockf_filelocking" = xyes; then - -cat >>confdefs.h <<\_ACEOF -#define WANT_AMFLOCK_LOCKF 1 -_ACEOF - - WANT_AMFLOCK_LOCKF="yes" - LOCKING="LOCKF" - fi - if test x"$WANT_AMFLOCK_LOCKF" = x"yes"; then - WANT_AMFLOCK_LOCKF_TRUE= - WANT_AMFLOCK_LOCKF_FALSE='#' -else - WANT_AMFLOCK_LOCKF_TRUE='#' - WANT_AMFLOCK_LOCKF_FALSE= -fi - - - # check our homebrew hardlink-based locking (requires hardlinks) - { $as_echo "$as_me:$LINENO: checking whether link(2) is available for locking" >&5 -$as_echo_n "checking whether link(2) is available for locking... " >&6; } -if test "${amanda_cv_lnlock_filelocking+set}" = set; then - $as_echo_n "(cached) " >&6 -else - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#if HAVE_UNISTD_H -# include -#endif - -int -main () -{ - - return link("/tmp/foo", "/tmp/bar"); - - ; - 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 - - amanda_cv_lnlock_filelocking="yes" - -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - - amanda_cv_lnlock_filelocking="no" - -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +# Prepare PATH_SEPARATOR. +# 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_echo "$as_me:$LINENO: result: $amanda_cv_lnlock_filelocking" >&5 -$as_echo "$amanda_cv_lnlock_filelocking" >&6; } - if test "x$amanda_cv_lnlock_filelocking" = xyes; then -cat >>confdefs.h <<\_ACEOF -#define WANT_AMFLOCK_LNLOCK 1 -_ACEOF - - WANT_AMFLOCK_LNLOCK="yes" - LOCKING="LNLOCK" - fi - if test x"$WANT_AMFLOCK_LNLOCK" = x"yes"; then - WANT_AMFLOCK_LNLOCK_TRUE= - WANT_AMFLOCK_LNLOCK_FALSE='#' +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" else - WANT_AMFLOCK_LNLOCK_TRUE='#' - WANT_AMFLOCK_LNLOCK_FALSE= + ac_executable_p="test -f" fi +rm -f conf$$.file - - if test x"$LOCKING" = "no"; then - # this shouldn't happen, and is *bad* if it does - { { $as_echo "$as_me:$LINENO: error: *** No working file locking capability found!" >&5 -$as_echo "$as_me: error: *** No working file locking capability found!" >&2;} - { (exit 1); exit 1; }; } - fi - - - - - - for ac_prog in swig -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 +# Extract the first word of "xgettext", so it can be a program name with args. +set dummy xgettext; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_SWIG+set}" = set; then +if ${ac_cv_path_XGETTEXT+:} false; then : $as_echo_n "(cached) " >&6 else - case $SWIG in + case "$XGETTEXT" in [\\/]* | ?:[\\/]*) - ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path. - ;; + ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. + ;; *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_SWIG="$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 - - ;; + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + echo "$as_me: trying $ac_dir/$ac_word..." >&5 + if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 && + (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then + ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" + test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" + ;; esac fi -SWIG=$ac_cv_path_SWIG -if test -n "$SWIG"; then - { $as_echo "$as_me:$LINENO: result: $SWIG" >&5 -$as_echo "$SWIG" >&6; } +XGETTEXT="$ac_cv_path_XGETTEXT" +if test "$XGETTEXT" != ":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5 +$as_echo "$XGETTEXT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi + rm -f messages.po - test -n "$SWIG" && break -done + case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in + '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;; + *) XGETTEXT_015=$XGETTEXT ;; + esac - # 1.3.32 introduces a change in the way empty strings are handled (old versions - # returned undef in Perl, while new versions return an empty Perl string) - # 1.3.39 is required for the %begin block - # Extract the first word of "swig", so it can be a program name with args. -set dummy swig; 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_SWIG+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $SWIG in - [\\/]* | ?:[\\/]*) - ac_cv_path_SWIG="$SWIG" # 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_SWIG="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 +# Prepare PATH_SEPARATOR. +# 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 -done -done -IFS=$as_save_IFS - - ;; -esac + rm -f conf$$.sh fi -SWIG=$ac_cv_path_SWIG -if test -n "$SWIG"; then - { $as_echo "$as_me:$LINENO: result: $SWIG" >&5 -$as_echo "$SWIG" >&6; } + +# Find out how to test for executable files. Don't use a zero-byte file, +# as systems may use methods other than mode bits to determine executability. +cat >conf$$.file <<_ASEOF +#! /bin/sh +exit 0 +_ASEOF +chmod +x conf$$.file +if test -x conf$$.file >/dev/null 2>&1; then + ac_executable_p="test -x" else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + ac_executable_p="test -f" fi +rm -f conf$$.file - - if test -z "$SWIG" ; then - SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false' - elif test -n "1.3.39" ; then - { $as_echo "$as_me:$LINENO: checking for SWIG version" >&5 -$as_echo_n "checking for SWIG version... " >&6; } - swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'` - { $as_echo "$as_me:$LINENO: result: $swig_version" >&5 -$as_echo "$swig_version" >&6; } - if test -n "$swig_version" ; then - - # Used to indicate true or false condition - ax_compare_version=false - - # Convert the two version strings to be compared into a format that - # allows a simple string comparison. The end result is that a version - # string of the form 1.12.5-r617 will be converted to the form - # 0001001200050617. In other words, each number is zero padded to four - # digits, and non digits are removed. - - ax_compare_version_A=`echo "$swig_version" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ - -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/[^0-9]//g'` - - - ax_compare_version_B=`echo "1.3.39" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ - -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/[^0-9]//g'` - - - ax_compare_version=`echo "x$ax_compare_version_A -x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"` - - - - if test "$ax_compare_version" = "true" ; then - - SWIG_LIB=`$SWIG -swiglib` - - else - SWIG='echo "Error: SWIG version >= 1.3.39 is required. You have '"$swig_version"'. You should look at http://www.swig.org" ; false' - - fi - - else - SWIG='echo "Error: Cannot determine SWIG version. You should look at http://www.swig.org" ; false' - fi - fi - - - - - - for ac_prog in perl5 perl -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +# Extract the first word of "msgmerge", so it can be a program name with args. +set dummy msgmerge; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PERL+set}" = set; then +if ${ac_cv_path_MSGMERGE+:} false; then : $as_echo_n "(cached) " >&6 else - case $PERL in + case "$MSGMERGE" in [\\/]* | ?:[\\/]*) - ac_cv_path_PERL="$PERL" # Let the user override the test with a path. - ;; + ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. + ;; *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_PERL="$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 - - ;; + ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR + for ac_dir in $PATH; do + IFS="$ac_save_IFS" + test -z "$ac_dir" && ac_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then + echo "$as_me: trying $ac_dir/$ac_word..." >&5 + if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then + ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext" + break 2 + fi + fi + done + done + IFS="$ac_save_IFS" + test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":" + ;; esac fi -PERL=$ac_cv_path_PERL -if test -n "$PERL"; then - { $as_echo "$as_me:$LINENO: result: $PERL" >&5 -$as_echo "$PERL" >&6; } +MSGMERGE="$ac_cv_path_MSGMERGE" +if test "$MSGMERGE" != ":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5 +$as_echo "$MSGMERGE" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$PERL" && break -done + test -n "$localedir" || localedir='${datadir}/locale' - # Make sure we have perl -if test -z "$PERL"; then -# Extract the first word of "perl", so it can be a program name with args. -set dummy perl; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_PERL+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$PERL"; then - ac_cv_prog_PERL="$PERL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_PERL="perl" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + ac_config_commands="$ac_config_commands po-directories" -fi -fi -PERL=$ac_cv_prog_PERL -if test -n "$PERL"; then - { $as_echo "$as_me:$LINENO: result: $PERL" >&5 -$as_echo "$PERL" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi -fi -# Check if version of Perl is sufficient -ac_perl_version="5.6.0" -if test "x$PERL" != "x"; then - { $as_echo "$as_me:$LINENO: checking for perl version greater than or equal to $ac_perl_version" >&5 -$as_echo_n "checking for perl version greater than or equal to $ac_perl_version... " >&6; } - # NB: It would be nice to log the error if there is one, but we cannot rely - # on autoconf internals - $PERL -e "use $ac_perl_version;" > /dev/null 2>&1 - if test $? -ne 0; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; }; - { { $as_echo "$as_me:$LINENO: error: Amanda requires at least perl 5.6.0" >&5 -$as_echo "$as_me: error: Amanda requires at least perl 5.6.0" >&2;} - { (exit 1); exit 1; }; } - else - { $as_echo "$as_me:$LINENO: result: ok" >&5 -$as_echo "ok" >&6; }; - fi -else - { $as_echo "$as_me:$LINENO: WARNING: could not find perl" >&5 -$as_echo "$as_me: WARNING: could not find perl" >&2;} -fi + use_additional=yes + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval additional_includedir=\"$includedir\" + eval additional_libdir=\"$libdir\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" - WANT_CYGWIN_COPY_PERL_DLL=false - WANT_MANDATORY_THREAD_CHECK=false +# Check whether --with-libiconv-prefix was given. +if test "${with_libiconv_prefix+set}" = set; then : + withval=$with_libiconv_prefix; + if test "X$withval" = "Xno"; then + use_additional=no + else + if test "X$withval" = "X"; then - # test for ExtUtils::Embed - ac_perl_list_modules="ExtUtils::Embed 0.0" -# Make sure we have perl -if test -z "$PERL"; then -# Extract the first word of "perl", so it can be a program name with args. -set dummy perl; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_PERL+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$PERL"; then - ac_cv_prog_PERL="$PERL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_PERL="perl" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" -fi -fi -PERL=$ac_cv_prog_PERL -if test -n "$PERL"; then - { $as_echo "$as_me:$LINENO: result: $PERL" >&5 -$as_echo "$PERL" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi + eval additional_includedir=\"$includedir\" + eval additional_libdir=\"$libdir\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" -fi + else + additional_includedir="$withval/include" + additional_libdir="$withval/$acl_libdirstem" + fi + fi -# Check the number of arguments -args_num=`echo $ac_perl_list_modules | wc -w` -let "ckeck_args = $args_num % 2" -if test "$check_args" = "1" ; then - { { $as_echo "$as_me:$LINENO: error: syntax error" >&5 -$as_echo "$as_me: error: syntax error" >&2;} - { (exit 1); exit 1; }; } -else - eval fi -if test "x$PERL" != x; then - ac_failed=0 - while test ${#ac_perl_list_modules} -gt 2 ; do - module_name=`echo $ac_perl_list_modules | cut -d " " -f 1` - module_version=`echo $ac_perl_list_modules | cut -d " " -f 2` - ac_perl_list_modules=`echo $ac_perl_list_modules | cut -d " " -f 3-` - { $as_echo "$as_me:$LINENO: checking for perl module $module_name version $module_version" >&5 -$as_echo_n "checking for perl module $module_name version $module_version... " >&6; } - - $PERL "-M$module_name" -e exit > /dev/null 2>&1 - if test $? -ne 0; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; }; - ac_failed=1 - ac_perl_list_modules="" - else - version=`$PERL "-M$module_name" -e 'print $'"$module_name::VERSION" 2>&1` - $PERL -e 'exit(shift cmp shift)' "$version" "$module_version" - if test $? -eq 0 -o $? -eq 1 ; then - { $as_echo "$as_me:$LINENO: result: ok" >&5 -$as_echo "ok" >&6; }; - else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - ac_failed=1 - ac_perl_list_modules="" - fi - fi; - done + LIBICONV= + LTLIBICONV= + INCICONV= + rpathdirs= + ltrpathdirs= + names_already_handled= + names_next_round='iconv ' + while test -n "$names_next_round"; do + names_this_round="$names_next_round" + names_next_round= + for name in $names_this_round; do + already_handled= + for n in $names_already_handled; do + if test "$n" = "$name"; then + already_handled=yes + break + fi + done + if test -z "$already_handled"; then + names_already_handled="$names_already_handled $name" + uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` + eval value=\"\$HAVE_LIB$uppername\" + if test -n "$value"; then + if test "$value" = yes; then + eval value=\"\$LIB$uppername\" + test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value" + eval value=\"\$LTLIB$uppername\" + test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value" + else + : + fi + else + found_dir= + found_la= + found_so= + found_a= + if test $use_additional = yes; then + if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then + found_dir="$additional_libdir" + found_so="$additional_libdir/lib$name.$shlibext" + if test -f "$additional_libdir/lib$name.la"; then + found_la="$additional_libdir/lib$name.la" + fi + else + if test -f "$additional_libdir/lib$name.$libext"; then + found_dir="$additional_libdir" + found_a="$additional_libdir/lib$name.$libext" + if test -f "$additional_libdir/lib$name.la"; then + found_la="$additional_libdir/lib$name.la" + fi + fi + fi + fi + if test "X$found_dir" = "X"; then + for x in $LDFLAGS $LTLIBICONV; do - if test "$ac_failed" = 0; then - : + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" - else - : + case "$x" in + -L*) + dir=`echo "X$x" | sed -e 's/^X-L//'` + if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then + found_dir="$dir" + found_so="$dir/lib$name.$shlibext" + if test -f "$dir/lib$name.la"; then + found_la="$dir/lib$name.la" + fi + else + if test -f "$dir/lib$name.$libext"; then + found_dir="$dir" + found_a="$dir/lib$name.$libext" + if test -f "$dir/lib$name.la"; then + found_la="$dir/lib$name.la" + fi + fi + fi + ;; + esac + if test "X$found_dir" != "X"; then + break + fi + done + fi + if test "X$found_dir" != "X"; then + LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name" + if test "X$found_so" != "X"; then + if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then + LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" + else + haveit= + for x in $ltrpathdirs; do + if test "X$x" = "X$found_dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + ltrpathdirs="$ltrpathdirs $found_dir" + fi + if test "$hardcode_direct" = yes; then + LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" + else + if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then + LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" + haveit= + for x in $rpathdirs; do + if test "X$x" = "X$found_dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + rpathdirs="$rpathdirs $found_dir" + fi + else + haveit= + for x in $LDFLAGS $LIBICONV; do - { { $as_echo "$as_me:$LINENO: error: *** Amanda requires the perl package ExtUtils::Embed to build its perl modules" >&5 -$as_echo "$as_me: error: *** Amanda requires the perl package ExtUtils::Embed to build its perl modules" >&2;} - { (exit 1); exit 1; }; } + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" - fi -else - { { $as_echo "$as_me:$LINENO: error: could not find perl" >&5 -$as_echo "$as_me: error: could not find perl" >&2;} - { (exit 1); exit 1; }; } -fi + if test "X$x" = "X-L$found_dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir" + fi + if test "$hardcode_minus_L" != no; then + LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" + else + LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" + fi + fi + fi + fi + else + if test "X$found_a" != "X"; then + LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a" + else + LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name" + fi + fi + additional_includedir= + case "$found_dir" in + */$acl_libdirstem | */$acl_libdirstem/) + basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` + additional_includedir="$basedir/include" + ;; + esac + if test "X$additional_includedir" != "X"; then + if test "X$additional_includedir" != "X/usr/include"; then + haveit= + if test "X$additional_includedir" = "X/usr/local/include"; then + if test -n "$GCC"; then + case $host_os in + linux* | gnu* | k*bsd*-gnu) haveit=yes;; + esac + fi + fi + if test -z "$haveit"; then + for x in $CPPFLAGS $INCICONV; do - # get the include path for building perl extensions - PERL_INC=`$PERL -MExtUtils::Embed -e perl_inc` + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" + + if test "X$x" = "X-I$additional_includedir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + if test -d "$additional_includedir"; then + INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir" + fi + fi + fi + fi + fi + if test -n "$found_la"; then + save_libdir="$libdir" + case "$found_la" in + */* | *\\*) . "$found_la" ;; + *) . "./$found_la" ;; + esac + libdir="$save_libdir" + for dep in $dependency_libs; do + case "$dep" in + -L*) + additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` + if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then + haveit= + if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then + if test -n "$GCC"; then + case $host_os in + linux* | gnu* | k*bsd*-gnu) haveit=yes;; + esac + fi + fi + if test -z "$haveit"; then + haveit= + for x in $LDFLAGS $LIBICONV; do + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" - if test x"$enable_shared" = x"no"; then - { { $as_echo "$as_me:$LINENO: error: *** Amanda cannot be compiled without shared-library support (do not use --disable-shared)" >&5 -$as_echo "$as_me: error: *** Amanda cannot be compiled without shared-library support (do not use --disable-shared)" >&2;} - { (exit 1); exit 1; }; } + if test "X$x" = "X-L$additional_libdir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + if test -d "$additional_libdir"; then + LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir" + fi + fi + haveit= + for x in $LDFLAGS $LTLIBICONV; do + + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" + + if test "X$x" = "X-L$additional_libdir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + if test -d "$additional_libdir"; then + LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir" + fi + fi + fi + fi + ;; + -R*) + dir=`echo "X$dep" | sed -e 's/^X-R//'` + if test "$enable_rpath" != no; then + haveit= + for x in $rpathdirs; do + if test "X$x" = "X$dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + rpathdirs="$rpathdirs $dir" + fi + haveit= + for x in $ltrpathdirs; do + if test "X$x" = "X$dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + ltrpathdirs="$ltrpathdirs $dir" + fi + fi + ;; + -l*) + names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` + ;; + *.la) + names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` + ;; + *) + LIBICONV="${LIBICONV}${LIBICONV:+ }$dep" + LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep" + ;; + esac + done + fi + else + LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" + LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name" + fi + fi + fi + done + done + if test "X$rpathdirs" != "X"; then + if test -n "$hardcode_libdir_separator"; then + alldirs= + for found_dir in $rpathdirs; do + alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" + done + acl_save_libdir="$libdir" + libdir="$alldirs" + eval flag=\"$hardcode_libdir_flag_spec\" + libdir="$acl_save_libdir" + LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" + else + for found_dir in $rpathdirs; do + acl_save_libdir="$libdir" + libdir="$found_dir" + eval flag=\"$hardcode_libdir_flag_spec\" + libdir="$acl_save_libdir" + LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" + done fi + fi + if test "X$ltrpathdirs" != "X"; then + for found_dir in $ltrpathdirs; do + LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir" + done + fi - case "$host" in - *freebsd[123456].*) # up to and including FreeBSD 6.* - # Before 7.0, FreeBSD systems don't include a DT_NEEDS segment in - # libgthread to automatically pull in the desired threading library. - # Instead, they assume that any application linking against - # libgthread will pull in the threading library. This is fine for - # Amanda C applications, but for Perl applications this assumption - # means that the perl binary would pull in the threading library. - # But perl is compiled without threading by default. - # - # Specifically, this occurs on any FreeBSD using gcc-3.*: the linking - # decision is made in gcc's spec files, which were changed in - # gcc-4.0. For a more in-depth discussion, see - # http://wiki.zmanda.com/index.php/Installation/OS_Specific_Notes/Installing_Amanda_on_FreeBSD - # - # The easiest solution for the "default" case is to link all perl - # extension libraries against the threading library, so it is loaded - # when perl loads the extension library. The default threading - # library in FreeBSD is libpthread. The below default will work on - # such a FreeBSD system, but ports maintainers and those with - # different configurations may need to override this value with - # --with-perlextlibs. - # - # We can't use -pthread because gcc on FreeBSD ignores -pthread in - # combination with -shared. See - # http://lists.freebsd.org/pipermail/freebsd-stable/2006-June/026229.html - PERLEXTLIBS="-lpthread" - WANT_MANDATORY_THREAD_CHECK=true - ;; - *freebsd*) # all FreeBSD not matched above - # for all FreeBSD (including 1.0-6.0, above), we want to run the - # thread-check rule in perl/Makefile.am to double-check that a Perl - # script can call a C extension that uses threads. - WANT_MANDATORY_THREAD_CHECK=true - ;; - *-pc-cygwin) - # When need -lperl and the '-L' where it is located, - # we don't want the DynaLoader.a - PERLEXTLIBS=`perl -MExtUtils::Embed -e ldopts | sed -e 's/^.*-L/-L/'` - # we want cygwin to copy ddl to modules directory. - WANT_CYGWIN_COPY_PERL_DLL="true"; - ;; - esac - if $WANT_CYGWIN_COPY_PERL_DLL; then - WANT_CYGWIN_COPY_PERL_DLL_TRUE= - WANT_CYGWIN_COPY_PERL_DLL_FALSE='#' -else - WANT_CYGWIN_COPY_PERL_DLL_TRUE='#' - WANT_CYGWIN_COPY_PERL_DLL_FALSE= -fi - if $WANT_MANDATORY_THREAD_CHECK; then - WANT_MANDATORY_THREAD_CHECK_TRUE= - WANT_MANDATORY_THREAD_CHECK_FALSE='#' -else - WANT_MANDATORY_THREAD_CHECK_TRUE='#' - WANT_MANDATORY_THREAD_CHECK_FALSE= -fi -# Check whether --with-perlextlibs was given. -if test "${with_perlextlibs+set}" = set; then - withval=$with_perlextlibs; - case "$withval" in - y|ye|yes) { { $as_echo "$as_me:$LINENO: error: *** You must specify a value for --with-perlextlibs" >&5 -$as_echo "$as_me: error: *** You must specify a value for --with-perlextlibs" >&2;} - { (exit 1); exit 1; }; };; - n|no) PERLEXTLIBS='';; - *) PERLEXTLIBS="$withval" ;; - esac -fi - # Extract the first word of "cat", so it can be a program name with args. -set dummy cat; 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_CAT+set}" = set; then + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5 +$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; } +if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then : $as_echo_n "(cached) " >&6 else - case $CAT in - [\\/]* | ?:[\\/]*) - ac_cv_path_CAT="$CAT" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_CAT="$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_CAT" && ac_cv_path_CAT="cat" - ;; -esac + gt_save_LIBS="$LIBS" + LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +CFPreferencesCopyAppValue(NULL, NULL) + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + gt_cv_func_CFPreferencesCopyAppValue=yes +else + gt_cv_func_CFPreferencesCopyAppValue=no fi -CAT=$ac_cv_path_CAT -if test -n "$CAT"; then - { $as_echo "$as_me:$LINENO: result: $CAT" >&5 -$as_echo "$CAT" >&6; } +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$gt_save_LIBS" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5 +$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; } + if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then + +$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h + + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5 +$as_echo_n "checking for CFLocaleCopyCurrent... " >&6; } +if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then : + $as_echo_n "(cached) " >&6 else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + gt_save_LIBS="$LIBS" + LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +CFLocaleCopyCurrent(); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + gt_cv_func_CFLocaleCopyCurrent=yes +else + gt_cv_func_CFLocaleCopyCurrent=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$gt_save_LIBS" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5 +$as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; } + if test $gt_cv_func_CFLocaleCopyCurrent = yes; then +$as_echo "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h + fi + INTL_MACOSX_LIBS= + if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then + INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation" + fi - HAVE_GZIP= - if test "$GZIP"; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_GZIP 1 -_ACEOF - - HAVE_GZIP=1 - COMPRESS_PATH="$GZIP" - COMPRESS_SUFFIX=".gz" - COMPRESS_FAST_OPT="--fast" - COMPRESS_BEST_OPT="--best" - UNCOMPRESS_PATH="$GZIP" - UNCOMPRESS_OPT="-dc" - else - if test "$COMPRESS"; then - COMPRESS_PATH="$COMPRESS" - COMPRESS_SUFFIX=".Z" - COMPRESS_FAST_OPT="-f" - COMPRESS_BEST_OPT="-f" - UNCOMPRESS_PATH="$COMPRESS" - UNCOMPRESS_OPT="-dc" - else - # If we have to use cat, we don't define COMPRESS_FAST_OPT, - # COMPRESS_BEST_OPT, or UNCOMPRESS_OPT as "" since cat will look - # look for a file by the name of "". - # XXX is the above true? --dustin - - - { $as_echo "$as_me:$LINENO: WARNING: Cannot find either gzip or compress. Using cat." >&5 -$as_echo "$as_me: WARNING: Cannot find either gzip or compress. Using cat." >&2;} - - - cat <>config.warnings -Cannot find either gzip or compress. Using cat. -AAW_EOF - - - COMPRESS_PATH="$CAT" - COMPRESS_SUFFIX="" - COMPRESS_FAST_OPT="" - COMPRESS_BEST_OPT="" - UNCOMPRESS_PATH="$CAT" - UNCOMPRESS_OPT="" - fi - fi - - -cat >>confdefs.h <<_ACEOF -#define COMPRESS_PATH "$COMPRESS_PATH" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define COMPRESS_SUFFIX "$COMPRESS_SUFFIX" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define COMPRESS_FAST_OPT "$COMPRESS_FAST_OPT" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define COMPRESS_BEST_OPT "$COMPRESS_BEST_OPT" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define UNCOMPRESS_PATH "$UNCOMPRESS_PATH" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define UNCOMPRESS_OPT "$UNCOMPRESS_OPT" -_ACEOF - - + LIBINTL= + LTLIBINTL= + POSUB= + if test "$USE_NLS" = "yes"; then + gt_use_preinstalled_gnugettext=no - - # Empty GZIP so that make dist works. - GZIP= - - - { $as_echo "$as_me:$LINENO: checking if sockaddr_storage struct exists" >&5 -$as_echo_n "checking if sockaddr_storage struct exists... " >&6; } -if test "${ac_cv_has_sockaddr_storage+set}" = set; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5 +$as_echo_n "checking for GNU gettext in libc... " >&6; } +if ${gt_cv_func_gnugettext1_libc+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -# include -# include +#include +extern int _nl_msg_cat_cntr; +extern int *_nl_domain_bindings; int main () { -u_int i = sizeof (struct sockaddr_storage) +bindtextdomain ("", ""); +return * gettext ("") + _nl_msg_cat_cntr + *_nl_domain_bindings ; 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_has_sockaddr_storage=yes +if ac_fn_c_try_link "$LINENO"; then : + gt_cv_func_gnugettext1_libc=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_has_sockaddr_storage=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - + gt_cv_func_gnugettext1_libc=no fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_has_sockaddr_storage" >&5 -$as_echo "$ac_cv_has_sockaddr_storage" >&6; } - - if test $ac_cv_has_sockaddr_storage = yes ; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_SOCKADDR_STORAGE 1 -_ACEOF - - fi - - - - - WORKING_IPV6=no - -# Check whether --with-ipv6 was given. -if test "${with_ipv6+set}" = set; then - withval=$with_ipv6; - case "$withval" in - y | ye | yes) amanda_with_ipv6=yes;; - n | no) amanda_with_ipv6=no;; - *) - { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-ipv6 option." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --with-ipv6 option." >&2;} - { (exit 1); exit 1; }; } - ;; - esac - -else - - amanda_with_ipv6=maybe - - +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext1_libc" >&5 +$as_echo "$gt_cv_func_gnugettext1_libc" >&6; } + if test "$gt_cv_func_gnugettext1_libc" != "yes"; then - if test x"$amanda_with_ipv6" = x"yes" || - test x"$amanda_with_ipv6" = x"maybe" ; then - { $as_echo "$as_me:$LINENO: checking for working IPv6" >&5 -$as_echo_n "checking for working IPv6... " >&6; } -if test "${amanda_cv_working_ipv6+set}" = set; then - $as_echo_n "(cached) " >&6 -else - - case "$host" in - *-pc-cygwin) amanda_cv_working_ipv6=no;; - *) - if test "$cross_compiling" = yes; then - amanda_cv_working_ipv6=yes - -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#include -#ifdef HAVE_SYS_SOCKET_H -#include -#endif -#ifdef HAVE_NETINET_IN_H -#include -#endif -#ifdef HAVE_WINSOCK2_H -#include -#endif -#include -#include - -main() -{ - int aa; - aa = socket(AF_INET6, SOCK_STREAM, 0); - if (aa > 0) return 0; - return aa; -} -_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 - amanda_cv_working_ipv6=yes -else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 -( exit $ac_status ) - amanda_cv_working_ipv6=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 - esac -fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_working_ipv6" >&5 -$as_echo "$amanda_cv_working_ipv6" >&6; } + am_save_CPPFLAGS="$CPPFLAGS" - if test "$amanda_cv_working_ipv6" = yes; then - WORKING_IPV6=yes + for element in $INCICONV; do + haveit= + for x in $CPPFLAGS; do -cat >>confdefs.h <<\_ACEOF -#define WORKING_IPV6 1 -_ACEOF + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" - else - # error out only if the user specifically requested support - if test x"$amanda_with_ipv6" = x"yes"; then - { { $as_echo "$as_me:$LINENO: error: IPv6 support was requested, but opening an IPv6 socket failed" >&5 -$as_echo "$as_me: error: IPv6 support was requested, but opening an IPv6 socket failed" >&2;} - { (exit 1); exit 1; }; } - fi - fi + if test "X$x" = "X$element"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" fi + done - - - - - -ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5 +$as_echo_n "checking for iconv... " >&6; } +if ${am_cv_func_iconv+:} false; 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 <$ac_hdr> + am_cv_func_iconv="no, consider installing GNU libiconv" + am_cv_lib_iconv=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +#include int main () { -if ((DIR *) 0) -return 0; +iconv_t cd = iconv_open("",""); + iconv(cd,NULL,NULL,NULL,NULL); + iconv_close(cd); ; 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 - 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_hdr" | $as_tr_cpp` 1 -_ACEOF - -ac_header_dirent=$ac_hdr; break +if ac_fn_c_try_link "$LINENO"; then : + am_cv_func_iconv=yes fi - -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:$LINENO: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test "$am_cv_func_iconv" != yes; then + am_save_LIBS="$LIBS" + LIBS="$LIBS $LIBICONV" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* 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 opendir (); +#include +#include int main () { -return opendir (); +iconv_t cd = iconv_open("",""); + iconv(cd,NULL,NULL,NULL,NULL); + iconv_close(cd); ; return 0; } _ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_opendir=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then - : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS +if ac_fn_c_try_link "$LINENO"; then : + am_cv_lib_iconv=yes + am_cv_func_iconv=yes fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LIBS="$am_save_LIBS" + fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5 +$as_echo "$am_cv_func_iconv" >&6; } + if test "$am_cv_func_iconv" = yes; then -else - { $as_echo "$as_me:$LINENO: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ +$as_echo "#define HAVE_ICONV 1" >>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 opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" + fi + if test "$am_cv_lib_iconv" = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5 +$as_echo_n "checking how to link with libiconv... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5 +$as_echo "$LIBICONV" >&6; } else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" + CPPFLAGS="$am_save_CPPFLAGS" + LIBICONV= + LTLIBICONV= fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_opendir=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then - : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -fi -fi - # include the dirent headers as described in the autoconf documentation. - { $as_echo "$as_me:$LINENO: checking whether readdir is declared" >&5 -$as_echo_n "checking whether readdir is declared... " >&6; } -if test "${ac_cv_have_decl_readdir+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#if HAVE_DIRENT_H -# include -# define NAMLEN(dirent) strlen((dirent)->d_name) -#else -# define dirent direct -# define NAMLEN(dirent) (dirent)->d_namlen -# if HAVE_SYS_NDIR_H -# include -# endif -# if HAVE_SYS_DIR_H -# include -# endif -# if HAVE_NDIR_H -# include -# endif -#endif + use_additional=yes + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" -int -main () -{ -#ifndef readdir - (void) readdir; -#endif + eval additional_includedir=\"$includedir\" + eval additional_libdir=\"$libdir\" - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_readdir=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" - ac_cv_have_decl_readdir=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_readdir" >&5 -$as_echo "$ac_cv_have_decl_readdir" >&6; } -if test "x$ac_cv_have_decl_readdir" = x""yes; then +# Check whether --with-libintl-prefix was given. +if test "${with_libintl_prefix+set}" = set; then : + withval=$with_libintl_prefix; + if test "X$withval" = "Xno"; then + use_additional=no + else + if test "X$withval" = "X"; then -cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR 1 -_ACEOF + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval additional_includedir=\"$includedir\" + eval additional_libdir=\"$libdir\" -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR 0 -_ACEOF + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" + else + additional_includedir="$withval/include" + additional_libdir="$withval/$acl_libdirstem" + fi + fi fi -{ $as_echo "$as_me:$LINENO: checking whether readdir_r is declared" >&5 -$as_echo_n "checking whether readdir_r is declared... " >&6; } -if test "${ac_cv_have_decl_readdir_r+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#if HAVE_DIRENT_H -# include -# define NAMLEN(dirent) strlen((dirent)->d_name) -#else -# define dirent direct -# define NAMLEN(dirent) (dirent)->d_namlen -# if HAVE_SYS_NDIR_H -# include -# endif -# if HAVE_SYS_DIR_H -# include -# endif -# if HAVE_NDIR_H -# include -# endif -#endif - -int -main () -{ -#ifndef readdir_r - (void) readdir_r; -#endif - - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_readdir_r=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + LIBINTL= + LTLIBINTL= + INCINTL= + rpathdirs= + ltrpathdirs= + names_already_handled= + names_next_round='intl ' + while test -n "$names_next_round"; do + names_this_round="$names_next_round" + names_next_round= + for name in $names_this_round; do + already_handled= + for n in $names_already_handled; do + if test "$n" = "$name"; then + already_handled=yes + break + fi + done + if test -z "$already_handled"; then + names_already_handled="$names_already_handled $name" + uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` + eval value=\"\$HAVE_LIB$uppername\" + if test -n "$value"; then + if test "$value" = yes; then + eval value=\"\$LIB$uppername\" + test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value" + eval value=\"\$LTLIB$uppername\" + test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value" + else + : + fi + else + found_dir= + found_la= + found_so= + found_a= + if test $use_additional = yes; then + if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then + found_dir="$additional_libdir" + found_so="$additional_libdir/lib$name.$shlibext" + if test -f "$additional_libdir/lib$name.la"; then + found_la="$additional_libdir/lib$name.la" + fi + else + if test -f "$additional_libdir/lib$name.$libext"; then + found_dir="$additional_libdir" + found_a="$additional_libdir/lib$name.$libext" + if test -f "$additional_libdir/lib$name.la"; then + found_la="$additional_libdir/lib$name.la" + fi + fi + fi + fi + if test "X$found_dir" = "X"; then + for x in $LDFLAGS $LTLIBINTL; do - ac_cv_have_decl_readdir_r=no -fi + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_readdir_r" >&5 -$as_echo "$ac_cv_have_decl_readdir_r" >&6; } -if test "x$ac_cv_have_decl_readdir_r" = x""yes; then + case "$x" in + -L*) + dir=`echo "X$x" | sed -e 's/^X-L//'` + if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then + found_dir="$dir" + found_so="$dir/lib$name.$shlibext" + if test -f "$dir/lib$name.la"; then + found_la="$dir/lib$name.la" + fi + else + if test -f "$dir/lib$name.$libext"; then + found_dir="$dir" + found_a="$dir/lib$name.$libext" + if test -f "$dir/lib$name.la"; then + found_la="$dir/lib$name.la" + fi + fi + fi + ;; + esac + if test "X$found_dir" != "X"; then + break + fi + done + fi + if test "X$found_dir" != "X"; then + LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name" + if test "X$found_so" != "X"; then + if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then + LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" + else + haveit= + for x in $ltrpathdirs; do + if test "X$x" = "X$found_dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + ltrpathdirs="$ltrpathdirs $found_dir" + fi + if test "$hardcode_direct" = yes; then + LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" + else + if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then + LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" + haveit= + for x in $rpathdirs; do + if test "X$x" = "X$found_dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + rpathdirs="$rpathdirs $found_dir" + fi + else + haveit= + for x in $LDFLAGS $LIBINTL; do -cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR_R 1 -_ACEOF + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" + + if test "X$x" = "X-L$found_dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir" + fi + if test "$hardcode_minus_L" != no; then + LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" + else + LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" + fi + fi + fi + fi + else + if test "X$found_a" != "X"; then + LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a" + else + LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name" + fi + fi + additional_includedir= + case "$found_dir" in + */$acl_libdirstem | */$acl_libdirstem/) + basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` + additional_includedir="$basedir/include" + ;; + esac + if test "X$additional_includedir" != "X"; then + if test "X$additional_includedir" != "X/usr/include"; then + haveit= + if test "X$additional_includedir" = "X/usr/local/include"; then + if test -n "$GCC"; then + case $host_os in + linux* | gnu* | k*bsd*-gnu) haveit=yes;; + esac + fi + fi + if test -z "$haveit"; then + for x in $CPPFLAGS $INCINTL; do + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR_R 0 -_ACEOF + if test "X$x" = "X-I$additional_includedir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + if test -d "$additional_includedir"; then + INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir" + fi + fi + fi + fi + fi + if test -n "$found_la"; then + save_libdir="$libdir" + case "$found_la" in + */* | *\\*) . "$found_la" ;; + *) . "./$found_la" ;; + esac + libdir="$save_libdir" + for dep in $dependency_libs; do + case "$dep" in + -L*) + additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` + if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then + haveit= + if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then + if test -n "$GCC"; then + case $host_os in + linux* | gnu* | k*bsd*-gnu) haveit=yes;; + esac + fi + fi + if test -z "$haveit"; then + haveit= + for x in $LDFLAGS $LIBINTL; do + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" -fi -{ $as_echo "$as_me:$LINENO: checking whether readdir64 is declared" >&5 -$as_echo_n "checking whether readdir64 is declared... " >&6; } -if test "${ac_cv_have_decl_readdir64+set}" = set; then + if test "X$x" = "X-L$additional_libdir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + if test -d "$additional_libdir"; then + LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir" + fi + fi + haveit= + for x in $LDFLAGS $LTLIBINTL; do + + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" + + if test "X$x" = "X-L$additional_libdir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + if test -d "$additional_libdir"; then + LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir" + fi + fi + fi + fi + ;; + -R*) + dir=`echo "X$dep" | sed -e 's/^X-R//'` + if test "$enable_rpath" != no; then + haveit= + for x in $rpathdirs; do + if test "X$x" = "X$dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + rpathdirs="$rpathdirs $dir" + fi + haveit= + for x in $ltrpathdirs; do + if test "X$x" = "X$dir"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + ltrpathdirs="$ltrpathdirs $dir" + fi + fi + ;; + -l*) + names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` + ;; + *.la) + names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` + ;; + *) + LIBINTL="${LIBINTL}${LIBINTL:+ }$dep" + LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep" + ;; + esac + done + fi + else + LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" + LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name" + fi + fi + fi + done + done + if test "X$rpathdirs" != "X"; then + if test -n "$hardcode_libdir_separator"; then + alldirs= + for found_dir in $rpathdirs; do + alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" + done + acl_save_libdir="$libdir" + libdir="$alldirs" + eval flag=\"$hardcode_libdir_flag_spec\" + libdir="$acl_save_libdir" + LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" + else + for found_dir in $rpathdirs; do + acl_save_libdir="$libdir" + libdir="$found_dir" + eval flag=\"$hardcode_libdir_flag_spec\" + libdir="$acl_save_libdir" + LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" + done + fi + fi + if test "X$ltrpathdirs" != "X"; then + for found_dir in $ltrpathdirs; do + LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir" + done + fi + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5 +$as_echo_n "checking for GNU gettext in libintl... " >&6; } +if ${gt_cv_func_gnugettext1_libintl+:} false; 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 + gt_save_CPPFLAGS="$CPPFLAGS" + CPPFLAGS="$CPPFLAGS $INCINTL" + gt_save_LIBS="$LIBS" + LIBS="$LIBS $LIBINTL" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -#if HAVE_DIRENT_H -# include -# define NAMLEN(dirent) strlen((dirent)->d_name) -#else -# define dirent direct -# define NAMLEN(dirent) (dirent)->d_namlen -# if HAVE_SYS_NDIR_H -# include -# endif -# if HAVE_SYS_DIR_H -# include -# endif -# if HAVE_NDIR_H -# include -# endif +#include +extern int _nl_msg_cat_cntr; +extern +#ifdef __cplusplus +"C" #endif - - +const char *_nl_expand_alias (const char *); int main () { -#ifndef readdir64 - (void) readdir64; -#endif - +bindtextdomain ("", ""); +return * gettext ("") + _nl_msg_cat_cntr + *_nl_expand_alias ("") ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_readdir64=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_have_decl_readdir64=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_readdir64" >&5 -$as_echo "$ac_cv_have_decl_readdir64" >&6; } -if test "x$ac_cv_have_decl_readdir64" = x""yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR64 1 -_ACEOF - - +if ac_fn_c_try_link "$LINENO"; then : + gt_cv_func_gnugettext1_libintl=yes else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR64 0 -_ACEOF - - + gt_cv_func_gnugettext1_libintl=no fi -{ $as_echo "$as_me:$LINENO: checking whether readdir64_r is declared" >&5 -$as_echo_n "checking whether readdir64_r is declared... " >&6; } -if test "${ac_cv_have_decl_readdir64_r+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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test "$gt_cv_func_gnugettext1_libintl" != yes && test -n "$LIBICONV"; then + LIBS="$LIBS $LIBICONV" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -#if HAVE_DIRENT_H -# include -# define NAMLEN(dirent) strlen((dirent)->d_name) -#else -# define dirent direct -# define NAMLEN(dirent) (dirent)->d_namlen -# if HAVE_SYS_NDIR_H -# include -# endif -# if HAVE_SYS_DIR_H -# include -# endif -# if HAVE_NDIR_H -# include -# endif +#include +extern int _nl_msg_cat_cntr; +extern +#ifdef __cplusplus +"C" #endif - - +const char *_nl_expand_alias (const char *); int main () { -#ifndef readdir64_r - (void) readdir64_r; -#endif - +bindtextdomain ("", ""); +return * gettext ("") + _nl_msg_cat_cntr + *_nl_expand_alias ("") ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_have_decl_readdir64_r=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +if ac_fn_c_try_link "$LINENO"; then : + LIBINTL="$LIBINTL $LIBICONV" + LTLIBINTL="$LTLIBINTL $LTLIBICONV" + gt_cv_func_gnugettext1_libintl=yes - ac_cv_have_decl_readdir64_r=no fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + fi + CPPFLAGS="$gt_save_CPPFLAGS" + LIBS="$gt_save_LIBS" fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_readdir64_r" >&5 -$as_echo "$ac_cv_have_decl_readdir64_r" >&6; } -if test "x$ac_cv_have_decl_readdir64_r" = x""yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext1_libintl" >&5 +$as_echo "$gt_cv_func_gnugettext1_libintl" >&6; } + fi -cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR64_R 1 -_ACEOF + if test "$gt_cv_func_gnugettext1_libc" = "yes" \ + || { test "$gt_cv_func_gnugettext1_libintl" = "yes" \ + && test "$PACKAGE" != gettext-runtime \ + && test "$PACKAGE" != gettext-tools; }; then + gt_use_preinstalled_gnugettext=yes + else + LIBINTL= + LTLIBINTL= + INCINTL= + fi -else - cat >>confdefs.h <<_ACEOF -#define HAVE_DECL_READDIR64_R 0 -_ACEOF + if test -n "$INTL_MACOSX_LIBS"; then + if test "$gt_use_preinstalled_gnugettext" = "yes" \ + || test "$nls_cv_use_gnu_gettext" = "yes"; then + LIBINTL="$LIBINTL $INTL_MACOSX_LIBS" + LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS" + fi + fi -fi + if test "$gt_use_preinstalled_gnugettext" = "yes" \ + || test "$nls_cv_use_gnu_gettext" = "yes"; then +$as_echo "#define ENABLE_NLS 1" >>confdefs.h + else + USE_NLS=no + fi + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5 +$as_echo_n "checking whether to use NLS... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 +$as_echo "$USE_NLS" >&6; } + if test "$USE_NLS" = "yes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5 +$as_echo_n "checking where the gettext function comes from... " >&6; } + if test "$gt_use_preinstalled_gnugettext" = "yes"; then + if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then + gt_source="external libintl" + else + gt_source="libc" + fi + else + gt_source="included intl directory" + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5 +$as_echo "$gt_source" >&6; } + fi - # disk device prefixes - { $as_echo "$as_me:$LINENO: checking disk device prefixes" >&5 -$as_echo_n "checking disk device prefixes... " >&6; } + if test "$USE_NLS" = "yes"; then - # Use df to find the mount point for the root filesystem. Use - # the positional parameters to find the particular line from df - # that contains the root paritition. We put it in a subshell so - # that the original positional parameters are not messed with. - dfline=`( - df / | while read line; do - set -- $line - while test $# -gt 0; do - if test "x$1" = "x/"; then - echo $line - break 2 - fi - shift - done - done - ) | sed 's/(//' | sed 's/)//' ` - - # Search for the mount point by using expr to find the parameter - # with dev in it. - mount=`( - set -- $dfline - while test $# -gt 0; do - if expr "$1" : '.*dev' >/dev/null 2>&1; then - echo $1 - break - fi - shift - done - )` - - # get any system-specific configuration information - case "$host" in - *-hp-*) - CLIENT_SCRIPTS_OPT=amhpfixdevs - case $mount in - /dev/vg*) + if test "$gt_use_preinstalled_gnugettext" = "yes"; then + if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5 +$as_echo_n "checking how to link with libintl... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5 +$as_echo "$LIBINTL" >&6; } - { $as_echo "$as_me:$LINENO: WARNING: Run amhpfixdevs on HP-UX systems using /dev/vg??." >&5 -$as_echo "$as_me: WARNING: Run amhpfixdevs on HP-UX systems using /dev/vg??." >&2;} + for element in $INCINTL; do + haveit= + for x in $CPPFLAGS; do + acl_save_prefix="$prefix" + prefix="$acl_final_prefix" + acl_save_exec_prefix="$exec_prefix" + exec_prefix="$acl_final_exec_prefix" + eval x=\"$x\" + exec_prefix="$acl_save_exec_prefix" + prefix="$acl_save_prefix" - cat <>config.warnings -Run amhpfixdevs on HP-UX systems using /dev/vg??. -AAW_EOF + if test "X$x" = "X$element"; then + haveit=yes + break + fi + done + if test -z "$haveit"; then + CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" + fi + done + fi - ;; - esac - ;; - *-sni-sysv4) - DEV_PREFIX=/dev/dsk/ - RDEV_PREFIX=/dev/rdsk/ - CLIENT_SCRIPTS_OPT=amsinixfixdevs - if ! test -d /dev/dsk; then - { $as_echo "$as_me:$LINENO: WARNING: Run amsinixfixdevs on Sinix systems using VxFS." >&5 -$as_echo "$as_me: WARNING: Run amsinixfixdevs on Sinix systems using VxFS." >&2;} +$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h - cat <>config.warnings -Run amsinixfixdevs on Sinix systems using VxFS. -AAW_EOF +$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h + fi - fi - ;; - *-sco3.2v4*) - DEV_PREFIX=/dev/ - RDEV_PREFIX=/dev/ - ;; - *) - CLIENT_SCRIPTS_OPT= - ;; - esac + POSUB=po + fi - if test "$DEV_PREFIX" && test "$RDEV_PREFIX"; then - { $as_echo "$as_me:$LINENO: result: (predefined) $DEV_PREFIX - $RDEV_PREFIX" >&5 -$as_echo "(predefined) $DEV_PREFIX - $RDEV_PREFIX" >&6; } - else - if test -d /dev/dsk; then - DEV_PREFIX=/dev/dsk/ - if test -d /dev/rdsk; then - RDEV_PREFIX=/dev/rdsk/ - else - RDEV_PREFIX=/dev/dsk/ - fi - elif test -d /dev; then - DEV_PREFIX=/dev/ - # Some systems, notably Linux, do not have raw disk devices - # names. Check this by trying to see if a raw disk device name - # exists using the normal raw device path prepended to the - # mount point of the root filesystem. - if test "$mount"; then - dev_name="/dev/r`basename $mount`" - if test -b $dev_name -o -c $dev_name; then - RDEV_PREFIX=/dev/r - else - RDEV_PREFIX=/dev/ - fi - else - RDEV_PREFIX=/dev/r - fi - else - # just fake it.. - DEV_PREFIX=/ - RDEV_PREFIX=/ - fi - { $as_echo "$as_me:$LINENO: result: $DEV_PREFIX - $RDEV_PREFIX" >&5 -$as_echo "$DEV_PREFIX - $RDEV_PREFIX" >&6; } - fi + INTLLIBS="$LIBINTL" -cat >>confdefs.h <<_ACEOF -#define DEV_PREFIX "${DEV_PREFIX}" -_ACEOF -cat >>confdefs.h <<_ACEOF -#define RDEV_PREFIX "${RDEV_PREFIX}" -_ACEOF - case "$host" in - *-dec-osf*) - ;; - *-dg-*) - ;; - *-netbsd*) - ;; - *-freebsd*) - ;; - *-openbsd*) - ;; - *-hp-*) - case "$CC" in - *gcc*) - CPPFLAGS="$CPPFLAGS -D__STDC_EXT__" +# +# Security (authentication) mechansims +# - ;; - *cc*) - CFLAGS="$CFLAGS -Ae" + BSD_SECURITY="yes" - ;; - esac - ;; - *-ibm-aix*) - ;; - m88k-motorola-sysv4) - ;; - *-nextstep3) - ;; - *-pc-bsdi*) - ;; - *-pc-linux-*) - ;; - *-redhat-linux-*) - ;; - *-suse-linux-*) - ;; - x86_64-*-linux-*) - ;; - alpha*-*-linux-*) - ;; - sparc*-*-linux-*) - ;; - powerpc-*-linux-*) - ;; - *-sgi-irix3*) - # The old cc won't work! - if test "x$GCC" != "xyes"; then - { { $as_echo "$as_me:$LINENO: error: The old SGI IRIX compiler ($CC) will not compile Amanda; use CC=gcc" >&5 -$as_echo "$as_me: error: The old SGI IRIX compiler ($CC) will not compile Amanda; use CC=gcc" >&2;} - { (exit 1); exit 1; }; } - fi - ;; - *-sgi-irix4*) - ;; - *-sgi-irix5*) - ;; - *-sgi-irix6*) - ;; - *-solaris2*) - ;; - *-sun-sunos4.1*) - ;; - *-ultrix*) - ;; - *-sysv4.2uw2*) - ;; - *-sco3.2v5*) - ;; - i386-pc-isc4*) - ;; - *-sni-sysv4) - ;; - *-pc-cygwin) +# Check whether --with-bsd-security was given. +if test "${with_bsd_security+set}" = set; then : + withval=$with_bsd_security; + case "$withval" in + n | no) BSD_SECURITY=no ;; + y | ye | yes) BSD_SECURITY=yes ;; + *) as_fn_error $? "*** You must not supply an argument to --without-bsd-security." "$LINENO" 5 + ;; + esac -cat >>confdefs.h <<\_ACEOF -#define IGNORE_TAR_ERRORS 1 -_ACEOF +fi - # Cygwin needs PATH to find cygwin1.dll -cat >>confdefs.h <<\_ACEOF -#define NEED_PATH_ENV 1 -_ACEOF + USE_AMANDAHOSTS=yes +# Check whether --with-amandahosts was given. +if test "${with_amandahosts+set}" = set; then : + withval=$with_amandahosts; + case "$withval" in + n | no ) USE_AMANDAHOSTS=no ;; + y | ye | yes) USE_AMANDAHOSTS=yes ;; + *) as_fn_error $? "*** You must not supply an argument to --without-amandahosts option." "$LINENO" 5 + ;; + esac -cat >>confdefs.h <<\_ACEOF -#define IGNORE_FSTAB 1 -_ACEOF - LDFLAGS="$LDFLAGS -Wl,-enable-runtime-pseudo-reloc -no-undefined" +fi - ;; - *-apple-darwin7*) # MacOS X 10.3.* (Panther) - ;; - *-apple-darwin8*) # MacOS X 10.4.* (Tiger) - ;; - *-apple-darwin9*) # MacOS X 10.5.* (Leopard) - ;; - *-apple-darwin10*) # MacOS X 10.6.* (Snow Leopard) - ;; - *) + if test "x$BSD_SECURITY" = "xyes"; then - cat <>config.warnings -***** -This machine, target type $host, is not known to be fully supported -by this configure script. If the installation of Amanda on this system -succeeds or needed any patches, please email amanda-hackers@amanda.org -with the patches or an indication of the sucess or failure of the -Amanda installation on your system. -***** -AAW_EOF +$as_echo "#define BSD_SECURITY 1" >>confdefs.h - ;; - esac + if test "x$USE_AMANDAHOSTS" = "xyes"; then +$as_echo "#define USE_AMANDAHOSTS 1" >>confdefs.h + fi + fi + if test x"$BSD_SECURITY" = x"yes"; then + WANT_BSD_SECURITY_TRUE= + WANT_BSD_SECURITY_FALSE='#' +else + WANT_BSD_SECURITY_TRUE='#' + WANT_BSD_SECURITY_FALSE= +fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$bindir\"" - eval ac_define_dir="\"$ac_define_dir\"" - bindir="$ac_define_dir" -cat >>confdefs.h <<_ACEOF -#define bindir "$ac_define_dir" -_ACEOF - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + BSDTCP_SECURITY="yes" +# Check whether --with-bsdtcp-security was given. +if test "${with_bsdtcp_security+set}" = set; then : + withval=$with_bsdtcp_security; + case "$withval" in + n | no) BSDTCP_SECURITY=no ;; + y | ye | yes) BSDTCP_SECURITY=yes ;; + *) as_fn_error $? "*** You must not supply an argument to --with-bsdtcp-security." "$LINENO" 5 + ;; + esac +fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$sbindir\"" - eval ac_define_dir="\"$ac_define_dir\"" - sbindir="$ac_define_dir" + if test "x$BSDTCP_SECURITY" = "xyes"; then -cat >>confdefs.h <<_ACEOF -#define sbindir "$ac_define_dir" -_ACEOF +$as_echo "#define BSDTCP_SECURITY 1" >>confdefs.h - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + fi + if test x"$BSDTCP_SECURITY" = x"yes"; then + WANT_BSDTCP_SECURITY_TRUE= + WANT_BSDTCP_SECURITY_FALSE='#' +else + WANT_BSDTCP_SECURITY_TRUE='#' + WANT_BSDTCP_SECURITY_FALSE= +fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$libexecdir\"" - eval ac_define_dir="\"$ac_define_dir\"" - libexecdir="$ac_define_dir" -cat >>confdefs.h <<_ACEOF -#define libexecdir "$ac_define_dir" -_ACEOF + BSDUDP_SECURITY="no" - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE +# Check whether --with-bsdudp-security was given. +if test "${with_bsdudp_security+set}" = set; then : + withval=$with_bsdudp_security; + case "$withval" in + n | no) : ;; + y | ye | yes) BSDUDP_SECURITY=yes ;; + *) as_fn_error $? "*** You must not supply an argument to --with-bsdudp-security." "$LINENO" 5 + ;; + esac +fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$mandir\"" - eval ac_define_dir="\"$ac_define_dir\"" - mandir="$ac_define_dir" + if test "x$BSDUDP_SECURITY" = "xyes"; then +$as_echo "#define BSDUDP_SECURITY 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define mandir "$ac_define_dir" -_ACEOF + fi - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + if test x"$BSDUDP_SECURITY" = x"yes"; then + WANT_BSDUDP_SECURITY_TRUE= + WANT_BSDUDP_SECURITY_FALSE='#' +else + WANT_BSDUDP_SECURITY_TRUE='#' + WANT_BSDUDP_SECURITY_FALSE= +fi - # amanda-specific directories - AMLIBDIR=$libdir/amanda -# Check whether --with-amlibdir was given. -if test "${with_amlibdir+set}" = set; then - withval=$with_amlibdir; - case "$withval" in - n | no) AMLIBDIR=$libdir ;; - y | ye | yes) AMLIBDIR=$libdir/amanda ;; - *) AMLIBDIR=$withval ;; - esac + RSH_SECURITY=no +# Check whether --with-rsh-security was given. +if test "${with_rsh_security+set}" = set; then : + withval=$with_rsh_security; + case "$withval" in + n | no) : ;; + y | ye | yes) RSH_SECURITY=yes ;; + *) as_fn_error $? "*** You must not supply an argument to --with-rsh-security." "$LINENO" 5 + ;; + esac fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$AMLIBDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - amlibdir="$ac_define_dir" + if test "x$RSH_SECURITY" = "xyes"; then +$as_echo "#define RSH_SECURITY 1" >>confdefs.h -cat >>confdefs.h <<_ACEOF -#define amlibdir "$ac_define_dir" -_ACEOF + fi + if test x"$RSH_SECURITY" = x"yes"; then + WANT_RSH_SECURITY_TRUE= + WANT_RSH_SECURITY_FALSE='#' +else + WANT_RSH_SECURITY_TRUE='#' + WANT_RSH_SECURITY_FALSE= +fi - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE - AMLIBEXECDIR=$libexecdir/amanda -# Check whether --with-amlibexecdir was given. -if test "${with_amlibexecdir+set}" = set; then - withval=$with_amlibexecdir; - case "$withval" in - n | no) AMLIBEXECDIR=$libexecdir ;; - y | ye | yes) AMLIBEXECDIR=$libexecdir/amanda ;; - *) AMLIBEXECDIR=$withval ;; - esac + SSH_SECURITY=yes +# Check whether --with-ssh-security was given. +if test "${with_ssh_security+set}" = set; then : + withval=$with_ssh_security; + case "$withval" in + n | no) SSH_SECURITY=no ;; + y | ye | yes) SSH_SECURITY=yes ;; + *) as_fn_error $? "*** You must not supply an argument to --with-ssh-security." "$LINENO" 5 + ;; + esac fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$AMLIBEXECDIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - amlibexecdir="$ac_define_dir" + if test "x$SSH_SECURITY" = "xyes"; then + # find the SSH binary + for ac_prog in ssh +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_SSH+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $SSH in + [\\/]* | ?:[\\/]*) + ac_cv_path_SSH="$SSH" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_SSH="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +SSH=$ac_cv_path_SSH +if test -n "$SSH"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SSH" >&5 +$as_echo "$SSH" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -cat >>confdefs.h <<_ACEOF -#define amlibexecdir "$ac_define_dir" -_ACEOF - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + test -n "$SSH" && break +done - amincludedir="${includedir}/amanda" + # see what options we should use - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$amincludedir\"" - eval ac_define_dir="\"$ac_define_dir\"" - amincludedir="$ac_define_dir" +# Check whether --with-ssh-options was given. +if test "${with_ssh_options+set}" = set; then : + withval=$with_ssh_options; SSH_OPTIONS="$withval" +else + SSH_OPTIONS='' + +fi -cat >>confdefs.h <<_ACEOF -#define amincludedir "$ac_define_dir" -_ACEOF + case "$SSH_OPTIONS" in + y | ye | yes | n | no) + as_fn_error $? "*** You must supply an argument to --with-ssh-options." "$LINENO" 5;; + *) : ;; + esac - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + { $as_echo "$as_me:${as_lineno-$LINENO}: checking SSH options" >&5 +$as_echo_n "checking SSH options... " >&6; } + # if we didn't get SSH options from the user, figure them out for ourselves + if test -z "$SSH_OPTIONS"; then + case `$SSH -V 2>&1` in + OpenSSH*) SSH_OPTIONS='-x -o BatchMode=yes -o PreferredAuthentications=publickey';; + *) SSH_OPTIONS='-x -o BatchMode=yes' ;; + esac + fi + # now convert that to a comma-separated list of C strings + eval "set dummy ${SSH_OPTIONS}"; shift + SSH_OPTIONS='' + for i in "${@}"; do + quoted="\"`echo "$i" | sed -e 's/\"/\\\"/'`\"" + SSH_OPTIONS="${SSH_OPTIONS}${SSH_OPTIONS:+, }$quoted"; + done + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SSH_OPTIONS" >&5 +$as_echo "$SSH_OPTIONS" >&6; } + # finally, make the various outputs for all of this -# Check whether --with-amperldir was given. -if test "${with_amperldir+set}" = set; then - withval=$with_amperldir; - case "$withval" in - y | ye | yes) AMPERLLIB=DEFAULT ;; - n | no) AMPERLLIB=$amlibdir/perl ;; - *) AMPERLLIB=$withval ;; - esac +$as_echo "#define SSH_SECURITY 1" >>confdefs.h -else - AMPERLLIB=DEFAULT +cat >>confdefs.h <<_ACEOF +#define SSH "$SSH" +_ACEOF -fi +cat >>confdefs.h <<_ACEOF +#define SSH_OPTIONS $SSH_OPTIONS +_ACEOF - # apply the default if no value was given. - if test x"$AMPERLLIB" = x"DEFAULT"; then - eval `$PERL -V:installsitelib` - AMPERLLIB=$installsitelib fi + if test x"$SSH_SECURITY" = x"yes"; then + WANT_SSH_SECURITY_TRUE= + WANT_SSH_SECURITY_FALSE='#' +else + WANT_SSH_SECURITY_TRUE='#' + WANT_SSH_SECURITY_FALSE= +fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$AMPERLLIB\"" - eval ac_define_dir="\"$ac_define_dir\"" - amperldir="$ac_define_dir" -cat >>confdefs.h <<_ACEOF -#define amperldir "$ac_define_dir" -_ACEOF - - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE - - - APPLICATION_DIR='${amlibexecdir}/application' - - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$APPLICATION_DIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - APPLICATION_DIR="$ac_define_dir" - - -cat >>confdefs.h <<_ACEOF -#define APPLICATION_DIR "$ac_define_dir" -_ACEOF - - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + # (note -- don't just substitute SSH_OPTIONS -- shell quoting will break) + # Specify --with-krb5-security if Kerberos software is in somewhere + # other than the listed KRB5_SPOTS. We only compile kerberos support in + # if the right files are there. -# Check whether --with-amdatadir was given. -if test "${with_amdatadir+set}" = set; then - withval=$with_amdatadir; - AMDATADIR=$withval + KRB5_SECURITY="no" + : ${KRB5_SPOTS="/usr/kerberos /usr/cygnus /usr /opt/kerberos"} -else - AMDATADIR=$datadir/amanda +# Check whether --with-krb5-security was given. +if test "${with_krb5_security+set}" = set; then : + withval=$with_krb5_security; + case "$withval" in + n | no) KRB5_SECURITY=no ;; + y | ye | yes) KRB5_SECURITY=yes ;; + *) KRB5_SPOTS="$KRB5_SECURITY" + KRB5_SECURITY=yes + ;; + esac fi - prefix_NONE= - exec_prefix_NONE= - test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix - test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix - eval ac_define_dir="\"$AMDATADIR\"" - eval ac_define_dir="\"$ac_define_dir\"" - amdatadir="$ac_define_dir" - - -cat >>confdefs.h <<_ACEOF -#define amdatadir "$ac_define_dir" -_ACEOF + if test "x$KRB5_SECURITY" = "xyes"; then + # if found, force the static versions of these libs (.a) by linking directly + # with the .a files. I don't know how to get -R dependancies checked + # in autoconf at this time. -kashmir + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kerberos V libraries" >&5 +$as_echo_n "checking for Kerberos V libraries... " >&6; } + KRB5_DIR_FOUND="" + for dir in $KRB5_SPOTS; do + for lib in lib lib64; do + k5libdir=${dir}/${lib} + if test \( -f ${k5libdir}/libkrb5.a -o -f ${k5libdir}/libkrb5.so \) -a \( -f ${k5libdir}/libgssapi_krb5.so -o -f ${k5libdir}/libgssapi_krb5.a \) -a \( -f ${k5libdir}/libcom_err.a -o -f ${k5libdir}/libcom_err.so \); then + if test -f ${k5libdir}/libk5crypto.a -o -f ${k5libdir}/libk5crypto.so; then + K5CRYPTO=-lk5crypto + elif test -f ${k5libdir}/libcrypto.a -o -f ${k5libdir}/libcrypto.so; then + K5CRYPTO=-lcrypto + else + K5CRYPTO="" + fi + if test -f ${k5libdir}/libkrb5support.a -o -f ${k5libdir}/libkrb5support.so; then + K5SUPPORT=-lkrb5support + else + K5SUPPORT="" + fi + KRB5_DIR_FOUND=$dir + KRB5_LIBDIR_FOUND=$k5libdir + LIBS="-lgssapi_krb5 -lkrb5 $K5CRYPTO $K5SUPPORT -lcom_err $LIBS" - test "$prefix_NONE" && prefix=NONE - test "$exec_prefix_NONE" && exec_prefix=NONE + break + elif test \( -f ${k5libdir}/libkrb5.a -o -f ${k5libdir}/libkrb5.so \) -a \( -f ${k5libdir}/libasn1.a -o -f ${k5libdir}/libasn1.so \) -a \( -f ${k5libdir}/libgssapi.a -o -f ${k5libdir}/libgssapi.so \); then + LIBS="-lgssapi -lkrb5 -lasn1 $LIBS" + CPPFLAGS="$CPPFLAGS -DKRB5_HEIMDAL_INCLUDES" + break + fi + done + done -# -# Internationalization -# + if test "$KRB5_DIR_FOUND"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: found in $KRB5_DIR_FOUND" >&5 +$as_echo "found in $KRB5_DIR_FOUND" >&6; } + # + # some OS's, such as NetBSD, stick krb5 includes out of the way... + # should probably just use autoconf to look for various include + # options and set them, but don't quite want to do that until I've + # dug into it a bit more. + # + if test -d "$KRB5_DIR_FOUND/krb5" ; then + CPPFLAGS="$CPPFLAGS -I$KRB5_DIR_FOUND/include/krb5" - # FreeBSD needs to link libxpg4 + else + CPPFLAGS="$CPPFLAGS -I$KRB5_DIR_FOUND/include" -{ $as_echo "$as_me:$LINENO: checking for setlocale in -lxpg4" >&5 -$as_echo_n "checking for setlocale in -lxpg4... " >&6; } -if test "${ac_cv_lib_xpg4_setlocale+set}" = set; then + fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lkrb5support" >&5 +$as_echo_n "checking for main in -lkrb5support... " >&6; } +if ${ac_cv_lib_krb5support_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS -LIBS="-lxpg4 $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +LIBS="-lkrb5support $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* 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 setlocale (); + int main () { -return setlocale (); +return main (); ; return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_lib_xpg4_setlocale=yes +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_krb5support_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_xpg4_setlocale=no + ac_cv_lib_krb5support_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xpg4_setlocale" >&5 -$as_echo "$ac_cv_lib_xpg4_setlocale" >&6; } -if test "x$ac_cv_lib_xpg4_setlocale" = x""yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5support_main" >&5 +$as_echo "$ac_cv_lib_krb5support_main" >&6; } +if test "x$ac_cv_lib_krb5support_main" = xyes; then : cat >>confdefs.h <<_ACEOF -#define HAVE_LIBXPG4 1 +#define HAVE_LIBKRB5SUPPORT 1 _ACEOF - LIBS="-lxpg4 $LIBS" + LIBS="-lkrb5support $LIBS" fi - # ------------------------------------------------------------------ - # All list of languages for which a translation exist. Each - # language is separated by a space. - # ------------------------------------------------------------------ - ALL_LINGUAS="" + if test "$KRB5_LIBDIR_FOUND" != "$libdir" ; then + LDFLAGS="$LDFLAGS -L$KRB5_LIBDIR_FOUND" + + fi - # Extract the first word of "msgfmt", so it can be a program name with args. -set dummy msgfmt; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +$as_echo "#define KRB5_SECURITY 1" >>confdefs.h + + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no krb5 system libraries found" >&5 +$as_echo "no krb5 system libraries found" >&6; } + as_fn_error $? "No Kerberos V libraries were found on your system; krb5-security cannot be enabled" "$LINENO" 5 + KRB5_SECURITY="no" + fi + fi + + if test x"$KRB5_SECURITY" = x"yes"; then + WANT_KRB5_SECURITY_TRUE= + WANT_KRB5_SECURITY_FALSE='#' +else + WANT_KRB5_SECURITY_TRUE='#' + WANT_KRB5_SECURITY_FALSE= +fi + + + + +# +# Dumpers +# + + + + for ac_prog in xfsdump +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_MSGFMT+set}" = set; then +if ${ac_cv_path_XFSDUMP+:} false; then : $as_echo_n "(cached) " >&6 else - case $MSGFMT in + case $XFSDUMP in [\\/]* | ?:[\\/]*) - ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. + ac_cv_path_XFSDUMP="$XFSDUMP" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH +for as_dir in $SYSLOCPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_MSGFMT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_XFSDUMP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -MSGFMT=$ac_cv_path_MSGFMT -if test -n "$MSGFMT"; then - { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5 -$as_echo "$MSGFMT" >&6; } +XFSDUMP=$ac_cv_path_XFSDUMP +if test -n "$XFSDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFSDUMP" >&5 +$as_echo "$XFSDUMP" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - # Extract the first word of "gettext", so it can be a program name with args. -set dummy gettext; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + test -n "$XFSDUMP" && break +done + + for ac_prog in xfsrestore +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GETTEXT+set}" = set; then +if ${ac_cv_path_XFSRESTORE+:} false; then : $as_echo_n "(cached) " >&6 else - case $GETTEXT in + case $XFSRESTORE in [\\/]* | ?:[\\/]*) - ac_cv_path_GETTEXT="$GETTEXT" # Let the user override the test with a path. + ac_cv_path_XFSRESTORE="$XFSRESTORE" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH +for as_dir in $SYSLOCPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GETTEXT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_XFSRESTORE="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -GETTEXT=$ac_cv_path_GETTEXT -if test -n "$GETTEXT"; then - { $as_echo "$as_me:$LINENO: result: $GETTEXT" >&5 -$as_echo "$GETTEXT" >&6; } +XFSRESTORE=$ac_cv_path_XFSRESTORE +if test -n "$XFSRESTORE"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFSRESTORE" >&5 +$as_echo "$XFSRESTORE" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi + test -n "$XFSRESTORE" && break +done + if test "$XFSDUMP" -a "$XFSRESTORE"; then +cat >>confdefs.h <<_ACEOF +#define XFSDUMP "$XFSDUMP" +_ACEOF - { $as_echo "$as_me:$LINENO: checking whether NLS is requested" >&5 -$as_echo_n "checking whether NLS is requested... " >&6; } - # Check whether --enable-nls was given. -if test "${enable_nls+set}" = set; then - enableval=$enable_nls; USE_NLS=$enableval -else - USE_NLS=yes -fi - { $as_echo "$as_me:$LINENO: result: $USE_NLS" >&5 -$as_echo "$USE_NLS" >&6; } +cat >>confdefs.h <<_ACEOF +#define XFSRESTORE "$XFSRESTORE" +_ACEOF + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: xfsdump causes the setuid-root rundump program to be enabled. To disable it, just #undef XFSDUMP in config/config.h" >&5 +$as_echo "$as_me: WARNING: xfsdump causes the setuid-root rundump program to be enabled. To disable it, just #undef XFSDUMP in config/config.h" >&2;} + cat <>config.warnings +xfsdump causes the setuid-root rundump program to be enabled. To disable it, just #undef XFSDUMP in config/config.h +AAW_EOF -# Prepare PATH_SEPARATOR. -# 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 + fi -# Find out how to test for executable files. Don't use a zero-byte file, -# as systems may use methods other than mode bits to determine executability. -cat >conf$$.file <<_ASEOF -#! /bin/sh -exit 0 -_ASEOF -chmod +x conf$$.file -if test -x conf$$.file >/dev/null 2>&1; then - ac_executable_p="test -x" -else - ac_executable_p="test -f" -fi -rm -f conf$$.file -# Extract the first word of "msgfmt", so it can be a program name with args. -set dummy msgfmt; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + + + # Extract the first word of "vxdump", so it can be a program name with args. +set dummy vxdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_MSGFMT+set}" = set; then +if ${ac_cv_path_VXDUMP+:} false; then : $as_echo_n "(cached) " >&6 else - case "$MSGFMT" in + case $VXDUMP in [\\/]* | ?:[\\/]*) - ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. - ;; + ac_cv_path_VXDUMP="$VXDUMP" # Let the user override the test with a path. + ;; *) - ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$ac_save_IFS" - test -z "$ac_dir" && ac_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then - echo "$as_me: trying $ac_dir/$ac_word..." >&5 - if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 && - (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then - ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext" - break 2 - fi - fi - done - done - IFS="$ac_save_IFS" - test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" - ;; + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_dummy="$SYSLOCPATH:/usr/lib/fs/vxfs" +for as_dir in $as_dummy +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_VXDUMP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; esac fi -MSGFMT="$ac_cv_path_MSGFMT" -if test "$MSGFMT" != ":"; then - { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5 -$as_echo "$MSGFMT" >&6; } +VXDUMP=$ac_cv_path_VXDUMP +if test -n "$VXDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VXDUMP" >&5 +$as_echo "$VXDUMP" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - # Extract the first word of "gmsgfmt", so it can be a program name with args. -set dummy gmsgfmt; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + + # Extract the first word of "vxrestore", so it can be a program name with args. +set dummy vxrestore; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GMSGFMT+set}" = set; then +if ${ac_cv_path_VXRESTORE+:} false; then : $as_echo_n "(cached) " >&6 else - case $GMSGFMT in + case $VXRESTORE in [\\/]* | ?:[\\/]*) - ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. + ac_cv_path_VXRESTORE="$VXRESTORE" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH +as_dummy="$SYSLOCPATH:/usr/lib/fs/vxfs" +for as_dir in $as_dummy do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_VXRESTORE="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS - test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" ;; esac fi -GMSGFMT=$ac_cv_path_GMSGFMT -if test -n "$GMSGFMT"; then - { $as_echo "$as_me:$LINENO: result: $GMSGFMT" >&5 -$as_echo "$GMSGFMT" >&6; } +VXRESTORE=$ac_cv_path_VXRESTORE +if test -n "$VXRESTORE"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VXRESTORE" >&5 +$as_echo "$VXRESTORE" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi + if test "$VXDUMP" -a "$VXRESTORE"; then - case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in - '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;; - *) MSGFMT_015=$MSGFMT ;; - esac +cat >>confdefs.h <<_ACEOF +#define VXDUMP "$VXDUMP" +_ACEOF - case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in - '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;; - *) GMSGFMT_015=$GMSGFMT ;; - esac +cat >>confdefs.h <<_ACEOF +#define VXRESTORE "$VXRESTORE" +_ACEOF + fi -# Prepare PATH_SEPARATOR. -# 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=: + + + + # Extract the first word of "vdump", so it can be a program name with args. +set dummy vdump; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_VDUMP+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $VDUMP in + [\\/]* | ?:[\\/]*) + ac_cv_path_VDUMP="$VDUMP" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $SYSLOCPATH +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_VDUMP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi - rm -f conf$$.sh -fi +done + done +IFS=$as_save_IFS -# Find out how to test for executable files. Don't use a zero-byte file, -# as systems may use methods other than mode bits to determine executability. -cat >conf$$.file <<_ASEOF -#! /bin/sh -exit 0 -_ASEOF -chmod +x conf$$.file -if test -x conf$$.file >/dev/null 2>&1; then - ac_executable_p="test -x" + ;; +esac +fi +VDUMP=$ac_cv_path_VDUMP +if test -n "$VDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VDUMP" >&5 +$as_echo "$VDUMP" >&6; } else - ac_executable_p="test -f" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -rm -f conf$$.file -# Extract the first word of "xgettext", so it can be a program name with args. -set dummy xgettext; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + + # Extract the first word of "vrestore", so it can be a program name with args. +set dummy vrestore; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_XGETTEXT+set}" = set; then +if ${ac_cv_path_VRESTORE+:} false; then : $as_echo_n "(cached) " >&6 else - case "$XGETTEXT" in + case $VRESTORE in [\\/]* | ?:[\\/]*) - ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. - ;; + ac_cv_path_VRESTORE="$VRESTORE" # Let the user override the test with a path. + ;; *) - ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$ac_save_IFS" - test -z "$ac_dir" && ac_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then - echo "$as_me: trying $ac_dir/$ac_word..." >&5 - if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 && - (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then - ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext" - break 2 - fi - fi - done - done - IFS="$ac_save_IFS" - test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" - ;; + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $SYSLOCPATH +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_VRESTORE="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; esac fi -XGETTEXT="$ac_cv_path_XGETTEXT" -if test "$XGETTEXT" != ":"; then - { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5 -$as_echo "$XGETTEXT" >&6; } +VRESTORE=$ac_cv_path_VRESTORE +if test -n "$VRESTORE"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VRESTORE" >&5 +$as_echo "$VRESTORE" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - rm -f messages.po - case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in - '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;; - *) XGETTEXT_015=$XGETTEXT ;; - esac + if test "$VDUMP" -a "$VRESTORE"; then +cat >>confdefs.h <<_ACEOF +#define VDUMP "$VDUMP" +_ACEOF -# Prepare PATH_SEPARATOR. -# 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 +cat >>confdefs.h <<_ACEOF +#define VRESTORE "$VRESTORE" +_ACEOF -# Find out how to test for executable files. Don't use a zero-byte file, -# as systems may use methods other than mode bits to determine executability. -cat >conf$$.file <<_ASEOF -#! /bin/sh -exit 0 -_ASEOF -chmod +x conf$$.file -if test -x conf$$.file >/dev/null 2>&1; then - ac_executable_p="test -x" -else - ac_executable_p="test -f" -fi -rm -f conf$$.file + fi -# Extract the first word of "msgmerge", so it can be a program name with args. -set dummy msgmerge; 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_MSGMERGE+set}" = set; then + + + + + # Set the order of dump programs to look for. Finding the proper file + # system dumping program is problematic. Some systems, notably HP-UX + # and AIX, have both the backup and dump programs. HP-UX can't use the + # the backup program while AIX systems can't use the dump program. So + # a variable is set up here to specify the order of dump programs to + # search for on the system. + DUMP_PROGRAMS="ufsdump dump backup" + DUMP_RETURNS_1= + AIX_BACKUP= + case "$host" in + *-dg-*) + DUMP_PROGRAMS="dump "$DUMP_PROGRAMS + DUMP_RETURNS_1=1 + ;; + *-ibm-aix*) + DUMP_PROGRAMS="backup "$DUMP_PROGRAMS + AIX_BACKUP=1 + +$as_echo "#define AIX_BACKUP 1" >>confdefs.h + + ;; + *-ultrix*) + DUMP_RETURNS_1=1 + ;; + esac + + if test -n "$DUMP_RETURNS_1"; then + +$as_echo "#define DUMP_RETURNS_1 1" >>confdefs.h + + fi + + for ac_prog in $DUMP_PROGRAMS +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_DUMP+:} false; then : $as_echo_n "(cached) " >&6 else - case "$MSGMERGE" in + case $DUMP in [\\/]* | ?:[\\/]*) - ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. - ;; + ac_cv_path_DUMP="$DUMP" # Let the user override the test with a path. + ;; *) - ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR - for ac_dir in $PATH; do - IFS="$ac_save_IFS" - test -z "$ac_dir" && ac_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then - echo "$as_me: trying $ac_dir/$ac_word..." >&5 - if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then - ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext" - break 2 - fi - fi - done - done - IFS="$ac_save_IFS" - test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":" - ;; + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $SYSLOCPATH +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_DUMP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; esac fi -MSGMERGE="$ac_cv_path_MSGMERGE" -if test "$MSGMERGE" != ":"; then - { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5 -$as_echo "$MSGMERGE" >&6; } +DUMP=$ac_cv_path_DUMP +if test -n "$DUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMP" >&5 +$as_echo "$DUMP" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$localedir" || localedir='${datadir}/locale' + test -n "$DUMP" && break +done + for ac_prog in ufsrestore restore +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_RESTORE+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $RESTORE in + [\\/]* | ?:[\\/]*) + ac_cv_path_RESTORE="$RESTORE" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $SYSLOCPATH +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_RESTORE="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - ac_config_commands="$ac_config_commands po-directories" + ;; +esac +fi +RESTORE=$ac_cv_path_RESTORE +if test -n "$RESTORE"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RESTORE" >&5 +$as_echo "$RESTORE" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + test -n "$RESTORE" && break +done + # newer versions of GNU tar include a program named 'backup' which + # does *not* implement the expected 'dump' interface. Detect that here + # and pretend we never saw it. + if test -n "$DUMP"; then + if test "`basename $DUMP`" = "backup"; then + backup_gnutar=`$DUMP --version | $GREP "GNU tar"` + if test $? -eq 0; then + DUMP= + fi + fi + fi + if test "$DUMP" -a "$RESTORE"; then +cat >>confdefs.h <<_ACEOF +#define DUMP "$DUMP" +_ACEOF +cat >>confdefs.h <<_ACEOF +#define RESTORE "$RESTORE" +_ACEOF - use_additional=yes - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" + # check for an estimate flag + if test -x $DUMP; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $DUMP supports -E or -S for estimates" >&5 +$as_echo_n "checking whether $DUMP supports -E or -S for estimates... " >&6; } +if ${amanda_cv_dump_estimate+:} false; then : + $as_echo_n "(cached) " >&6 +else - eval additional_includedir=\"$includedir\" - eval additional_libdir=\"$libdir\" + case "$DUMP" in + *dump) + { ac_try='$DUMP 9Ef /dev/null /dev/null/invalid/fs 2>&1 + | $GREP -v Dumping + | $GREP -v Date + | $GREP -v Label >conftest.d-E 2>&1' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } + cat conftest.d-E >&5 + { ac_try='$DUMP 9Sf /dev/null /dev/null/invalid/fs 2>&1 + | $GREP -v Dumping + | $GREP -v Date + | $GREP -v Label >conftest.d-S 2>&1' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } + cat conftest.d-S >&5 + { ac_try='$DUMP 9f /dev/null /dev/null/invalid/fs 2>&1 + | $GREP -v Dumping + | $GREP -v Date + | $GREP -v Label >conftest.d 2>&1' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } + cat conftest.d >&5 + if { ac_try='cmp conftest.d-E conftest.d 1>&2' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + amanda_cv_dump_estimate=E + elif { ac_try='cmp conftest.d-S conftest.d 1>&2' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + amanda_cv_dump_estimate=S + else + amanda_cv_dump_estimate=no + fi + rm -f conftest.d conftest.d-E conftest.d-S + ;; + *) amanda_cv_dump_estimate=no + ;; + esac - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_dump_estimate" >&5 +$as_echo "$amanda_cv_dump_estimate" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $DUMP is not executable, cannot run -E/-S test" >&5 +$as_echo "$as_me: WARNING: $DUMP is not executable, cannot run -E/-S test" >&2;} -# Check whether --with-libiconv-prefix was given. -if test "${with_libiconv_prefix+set}" = set; then - withval=$with_libiconv_prefix; - if test "X$withval" = "Xno"; then - use_additional=no - else - if test "X$withval" = "X"; then - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" + cat <>config.warnings +$DUMP is not executable, cannot run -E/-S test +AAW_EOF - eval additional_includedir=\"$includedir\" - eval additional_libdir=\"$libdir\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" + amanda_cv_dump_estimate=no + fi + if test "x$amanda_cv_dump_estimate" != xno; then - else - additional_includedir="$withval/include" - additional_libdir="$withval/$acl_libdirstem" - fi - fi +cat >>confdefs.h <<_ACEOF +#define HAVE_DUMP_ESTIMATE "$amanda_cv_dump_estimate" +_ACEOF -fi + fi - LIBICONV= - LTLIBICONV= - INCICONV= - rpathdirs= - ltrpathdirs= - names_already_handled= - names_next_round='iconv ' - while test -n "$names_next_round"; do - names_this_round="$names_next_round" - names_next_round= - for name in $names_this_round; do - already_handled= - for n in $names_already_handled; do - if test "$n" = "$name"; then - already_handled=yes - break - fi - done - if test -z "$already_handled"; then - names_already_handled="$names_already_handled $name" - uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` - eval value=\"\$HAVE_LIB$uppername\" - if test -n "$value"; then - if test "$value" = yes; then - eval value=\"\$LIB$uppername\" - test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value" - eval value=\"\$LTLIB$uppername\" - test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value" - else - : - fi - else - found_dir= - found_la= - found_so= - found_a= - if test $use_additional = yes; then - if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then - found_dir="$additional_libdir" - found_so="$additional_libdir/lib$name.$shlibext" - if test -f "$additional_libdir/lib$name.la"; then - found_la="$additional_libdir/lib$name.la" - fi - else - if test -f "$additional_libdir/lib$name.$libext"; then - found_dir="$additional_libdir" - found_a="$additional_libdir/lib$name.$libext" - if test -f "$additional_libdir/lib$name.la"; then - found_la="$additional_libdir/lib$name.la" - fi - fi - fi - fi - if test "X$found_dir" = "X"; then - for x in $LDFLAGS $LTLIBICONV; do - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" +# Check whether --with-dump-honor-nodump was given. +if test "${with_dump_honor_nodump+set}" = set; then : + withval=$with_dump_honor_nodump; + if test -x $DUMP; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $DUMP supports -h (honor nodump flag)" >&5 +$as_echo_n "checking whether $DUMP supports -h (honor nodump flag)... " >&6; } +if ${amanda_cv_honor_nodump+:} false; then : + $as_echo_n "(cached) " >&6 +else - case "$x" in - -L*) - dir=`echo "X$x" | sed -e 's/^X-L//'` - if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then - found_dir="$dir" - found_so="$dir/lib$name.$shlibext" - if test -f "$dir/lib$name.la"; then - found_la="$dir/lib$name.la" - fi - else - if test -f "$dir/lib$name.$libext"; then - found_dir="$dir" - found_a="$dir/lib$name.$libext" - if test -f "$dir/lib$name.la"; then - found_la="$dir/lib$name.la" - fi - fi - fi - ;; - esac - if test "X$found_dir" != "X"; then - break - fi - done - fi - if test "X$found_dir" != "X"; then - LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name" - if test "X$found_so" != "X"; then - if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then - LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" - else - haveit= - for x in $ltrpathdirs; do - if test "X$x" = "X$found_dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - ltrpathdirs="$ltrpathdirs $found_dir" - fi - if test "$hardcode_direct" = yes; then - LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" - else - if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then - LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" - haveit= - for x in $rpathdirs; do - if test "X$x" = "X$found_dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - rpathdirs="$rpathdirs $found_dir" - fi - else - haveit= - for x in $LDFLAGS $LIBICONV; do + case "$DUMP" in + *dump) + { ac_try='$DUMP 9hf 0 /dev/null /dev/null/invalid/fs 2>&1 + | $GREP -v Dumping + | $GREP -v Date + | $GREP -v Label >conftest.d-h 2>&1' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } + cat conftest.d-h >&5 + { ac_try='$DUMP 9f /dev/null /dev/null/invalid/fs 2>&1 + | $GREP -v Dumping + | $GREP -v Date + | $GREP -v Label >conftest.d 2>&1' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; } + cat conftest.d >&5 + if { ac_try='diff conftest.d-h conftest.d 1>&2' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 + (eval $ac_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; }; then + amanda_cv_honor_nodump=yes + else + amanda_cv_honor_nodump=no + fi + rm -f conftest.d conftest.d-h + ;; + *) amanda_cv_honor_nodump=no + ;; + esac - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_honor_nodump" >&5 +$as_echo "$amanda_cv_honor_nodump" >&6; } + else - if test "X$x" = "X-L$found_dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir" - fi - if test "$hardcode_minus_L" != no; then - LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" - else - LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" - fi - fi - fi - fi - else - if test "X$found_a" != "X"; then - LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a" - else - LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name" - fi - fi - additional_includedir= - case "$found_dir" in - */$acl_libdirstem | */$acl_libdirstem/) - basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` - additional_includedir="$basedir/include" - ;; - esac - if test "X$additional_includedir" != "X"; then - if test "X$additional_includedir" != "X/usr/include"; then - haveit= - if test "X$additional_includedir" = "X/usr/local/include"; then - if test -n "$GCC"; then - case $host_os in - linux* | gnu* | k*bsd*-gnu) haveit=yes;; - esac - fi - fi - if test -z "$haveit"; then - for x in $CPPFLAGS $INCICONV; do + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $DUMP is not executable, cannot run -h test" >&5 +$as_echo "$as_me: WARNING: $DUMP is not executable, cannot run -h test" >&2;} - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" - if test "X$x" = "X-I$additional_includedir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - if test -d "$additional_includedir"; then - INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir" - fi - fi - fi - fi - fi - if test -n "$found_la"; then - save_libdir="$libdir" - case "$found_la" in - */* | *\\*) . "$found_la" ;; - *) . "./$found_la" ;; - esac - libdir="$save_libdir" - for dep in $dependency_libs; do - case "$dep" in - -L*) - additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` - if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then - haveit= - if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then - if test -n "$GCC"; then - case $host_os in - linux* | gnu* | k*bsd*-gnu) haveit=yes;; - esac - fi - fi - if test -z "$haveit"; then - haveit= - for x in $LDFLAGS $LIBICONV; do + cat <>config.warnings +$DUMP is not executable, cannot run -h test +AAW_EOF - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" - if test "X$x" = "X-L$additional_libdir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - if test -d "$additional_libdir"; then - LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir" - fi - fi - haveit= - for x in $LDFLAGS $LTLIBICONV; do + amanda_cv_honor_nodump=no + fi + if test "x$amanda_cv_honor_nodump" = xyes; then - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" +$as_echo "#define HAVE_HONOR_NODUMP 1" >>confdefs.h + + fi + +fi - if test "X$x" = "X-L$additional_libdir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - if test -d "$additional_libdir"; then - LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir" - fi - fi - fi - fi - ;; - -R*) - dir=`echo "X$dep" | sed -e 's/^X-R//'` - if test "$enable_rpath" != no; then - haveit= - for x in $rpathdirs; do - if test "X$x" = "X$dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - rpathdirs="$rpathdirs $dir" - fi - haveit= - for x in $ltrpathdirs; do - if test "X$x" = "X$dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - ltrpathdirs="$ltrpathdirs $dir" - fi - fi - ;; - -l*) - names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` - ;; - *.la) - names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` - ;; - *) - LIBICONV="${LIBICONV}${LIBICONV:+ }$dep" - LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep" - ;; - esac - done - fi - else - LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" - LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name" - fi - fi - fi - done - done - if test "X$rpathdirs" != "X"; then - if test -n "$hardcode_libdir_separator"; then - alldirs= - for found_dir in $rpathdirs; do - alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" - done - acl_save_libdir="$libdir" - libdir="$alldirs" - eval flag=\"$hardcode_libdir_flag_spec\" - libdir="$acl_save_libdir" - LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" - else - for found_dir in $rpathdirs; do - acl_save_libdir="$libdir" - libdir="$found_dir" - eval flag=\"$hardcode_libdir_flag_spec\" - libdir="$acl_save_libdir" - LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" - done fi - fi - if test "X$ltrpathdirs" != "X"; then - for found_dir in $ltrpathdirs; do - LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir" - done - fi @@ -39379,394 +26362,284 @@ fi + # call with +# Check whether --with-gnutar was given. +if test "${with_gnutar+set}" = set; then : + withval=$with_gnutar; + # check withval + case "$withval" in + /*) GNUTAR="$withval";; + y|ye|yes) :;; + n|no) GNUTAR=no ;; + *) as_fn_error $? "*** You must supply a full pathname to --with-gnutar" "$LINENO" 5;; + esac + # done +fi + if test "x$GNUTAR" = "xno"; then + GNUTAR= + else + OLD_GNUTAR=$GNUTAR + for gnutar_name in gtar gnutar tar; do + for ac_prog in $gnutar_name +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GNUTAR+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GNUTAR in + [\\/]* | ?:[\\/]*) + ac_cv_path_GNUTAR="$GNUTAR" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_GNUTAR="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +GNUTAR=$ac_cv_path_GNUTAR +if test -n "$GNUTAR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNUTAR" >&5 +$as_echo "$GNUTAR" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + test -n "$GNUTAR" && break +done + if test -n "$GNUTAR"; then + case `"$GNUTAR" --version 2>&1` in + *GNU*tar* | *Free*paxutils* ) + # OK, it is GNU tar + break + ;; + *) + if test -n "$OLD_GNUTAR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $GNUTAR is not GNU tar, it will be used." >&5 +$as_echo "$as_me: WARNING: $GNUTAR is not GNU tar, it will be used." >&2;} - { $as_echo "$as_me:$LINENO: checking for CFPreferencesCopyAppValue" >&5 -$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; } -if test "${gt_cv_func_CFPreferencesCopyAppValue+set}" = set; then - $as_echo_n "(cached) " >&6 -else - gt_save_LIBS="$LIBS" - LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -CFPreferencesCopyAppValue(NULL, NULL) - ; - 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 - gt_cv_func_CFPreferencesCopyAppValue=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - gt_cv_func_CFPreferencesCopyAppValue=no -fi + cat <>config.warnings +$GNUTAR is not GNU tar, it will be used. +AAW_EOF -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - LIBS="$gt_save_LIBS" -fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5 -$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; } - if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_CFPREFERENCESCOPYAPPVALUE 1 -_ACEOF + else + # warning.. - fi - { $as_echo "$as_me:$LINENO: checking for CFLocaleCopyCurrent" >&5 -$as_echo_n "checking for CFLocaleCopyCurrent... " >&6; } -if test "${gt_cv_func_CFLocaleCopyCurrent+set}" = set; then - $as_echo_n "(cached) " >&6 -else - gt_save_LIBS="$LIBS" - LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -CFLocaleCopyCurrent(); - ; - 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 - gt_cv_func_CFLocaleCopyCurrent=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $GNUTAR is not GNU tar, so it will not be used." >&5 +$as_echo "$as_me: WARNING: $GNUTAR is not GNU tar, so it will not be used." >&2;} - gt_cv_func_CFLocaleCopyCurrent=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="$gt_save_LIBS" -fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_func_CFLocaleCopyCurrent" >&5 -$as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; } - if test $gt_cv_func_CFLocaleCopyCurrent = yes; then + cat <>config.warnings +$GNUTAR is not GNU tar, so it will not be used. +AAW_EOF -cat >>confdefs.h <<\_ACEOF -#define HAVE_CFLOCALECOPYCURRENT 1 -_ACEOF - fi - INTL_MACOSX_LIBS= - if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then - INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation" - fi + # reset the cache for GNUTAR so AC_PATH_PROGS will search again + GNUTAR='' + unset ac_cv_path_GNUTAR + fi + ;; + esac + fi + done + fi + if test "x$GNUTAR" != "x"; then + # define unquoted +cat >>confdefs.h <<_ACEOF +#define GNUTAR "$GNUTAR" +_ACEOF + + fi - LIBINTL= - LTLIBINTL= - POSUB= - if test "$USE_NLS" = "yes"; then - gt_use_preinstalled_gnugettext=no + # call with +# Check whether --with-star was given. +if test "${with_star+set}" = set; then : + withval=$with_star; + # check withval + case "$withval" in + /*) STAR="$withval";; + y|ye|yes) :;; + n|no) STAR=no ;; + *) as_fn_error $? "*** You must supply a full pathname to --with-star" "$LINENO" 5;; + esac + # done +fi - { $as_echo "$as_me:$LINENO: checking for GNU gettext in libc" >&5 -$as_echo_n "checking for GNU gettext in libc... " >&6; } -if test "${gt_cv_func_gnugettext1_libc+set}" = set; then + if test "x$STAR" = "xno"; then + STAR= + else + OLD_STAR=$STAR + for ac_prog in star +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_STAR+:} false; 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 -extern int _nl_msg_cat_cntr; -extern int *_nl_domain_bindings; -int -main () -{ -bindtextdomain ("", ""); -return * gettext ("") + _nl_msg_cat_cntr + *_nl_domain_bindings - ; - 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;; + case $STAR in + [\\/]* | ?:[\\/]*) + ac_cv_path_STAR="$STAR" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_STAR="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; 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 - gt_cv_func_gnugettext1_libc=yes +fi +STAR=$ac_cv_path_STAR +if test -n "$STAR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAR" >&5 +$as_echo "$STAR" >&6; } else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_func_gnugettext1_libc=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } 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: $gt_cv_func_gnugettext1_libc" >&5 -$as_echo "$gt_cv_func_gnugettext1_libc" >&6; } - if test "$gt_cv_func_gnugettext1_libc" != "yes"; then + test -n "$STAR" && break +done + if test -n "$STAR"; then + case `"$STAR" --version 2>/dev/null` in + *star*) + # OK, it is star + break + ;; + *) + if test -n "$OLD_STAR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $STAR is not star, it will be used." >&5 +$as_echo "$as_me: WARNING: $STAR is not star, it will be used." >&2;} + cat <>config.warnings +$STAR is not star, it will be used. +AAW_EOF - am_save_CPPFLAGS="$CPPFLAGS" - for element in $INCICONV; do - haveit= - for x in $CPPFLAGS; do + else + # warning.. - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $STAR is not star, so it will not be used." >&5 +$as_echo "$as_me: WARNING: $STAR is not star, so it will not be used." >&2;} - if test "X$x" = "X$element"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" - fi - done + cat <>config.warnings +$STAR is not star, so it will not be used. +AAW_EOF - { $as_echo "$as_me:$LINENO: checking for iconv" >&5 -$as_echo_n "checking for iconv... " >&6; } -if test "${am_cv_func_iconv+set}" = set; then - $as_echo_n "(cached) " >&6 -else - am_cv_func_iconv="no, consider installing GNU libiconv" - am_cv_lib_iconv=no - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -int -main () -{ -iconv_t cd = iconv_open("",""); - iconv(cd,NULL,NULL,NULL,NULL); - iconv_close(cd); - ; - return 0; -} + # reset the cache for STAR so AC_PATH_PROGS will search again + STAR='' + unset ac_cv_path_STAR + fi + ;; + esac + fi + fi + + if test "x$STAR" != "x"; then + # define unquoted + +cat >>confdefs.h <<_ACEOF +#define STAR "$STAR" _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 - am_cv_func_iconv=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + fi -fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - if test "$am_cv_func_iconv" != yes; then - am_save_LIBS="$LIBS" - LIBS="$LIBS $LIBICONV" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -int -main () -{ -iconv_t cd = iconv_open("",""); - iconv(cd,NULL,NULL,NULL,NULL); - iconv_close(cd); - ; - 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 - am_cv_lib_iconv=yes - am_cv_func_iconv=yes + + + + + # call with + +# Check whether --with-suntar was given. +if test "${with_suntar+set}" = set; then : + withval=$with_suntar; + # check withval + case "$withval" in + /*) SUNTAR="$withval";; + y|ye|yes) :;; + n|no) SUNTAR=no ;; + *) as_fn_error $? "*** You must supply a full pathname to --with-suntar" "$LINENO" 5;; + esac + # done + else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + + if test "x$SUNTAR" == "x"; then + SUNTAR="/usr/sbin/tar" + fi fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - LIBS="$am_save_LIBS" + + if test "x$SUNTAR" = "xno"; then + SUNTAR= fi -fi -{ $as_echo "$as_me:$LINENO: result: $am_cv_func_iconv" >&5 -$as_echo "$am_cv_func_iconv" >&6; } - if test "$am_cv_func_iconv" = yes; then + if test "x$SUNTAR" != "x"; then + # define unquoted -cat >>confdefs.h <<\_ACEOF -#define HAVE_ICONV 1 +cat >>confdefs.h <<_ACEOF +#define SUNTAR "$SUNTAR" _ACEOF - fi - if test "$am_cv_lib_iconv" = yes; then - { $as_echo "$as_me:$LINENO: checking how to link with libiconv" >&5 -$as_echo_n "checking how to link with libiconv... " >&6; } - { $as_echo "$as_me:$LINENO: result: $LIBICONV" >&5 -$as_echo "$LIBICONV" >&6; } - else - CPPFLAGS="$am_save_CPPFLAGS" - LIBICONV= - LTLIBICONV= - fi + fi @@ -39774,1783 +26647,1144 @@ $as_echo "$LIBICONV" >&6; } - use_additional=yes +# Check whether --with-smbclient was given. +if test "${with_smbclient+set}" = set; then : + withval=$with_smbclient; + case "$withval" in + /*) SAMBA_CLIENT="$withval";; + y|ye|yes) :;; + n|no) SAMBA_CLIENT=no ;; + *) as_fn_error $? "*** You must supply a full pathname to --with-smbclient" "$LINENO" 5;; + esac - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval additional_includedir=\"$includedir\" - eval additional_libdir=\"$libdir\" +fi - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" -# Check whether --with-libintl-prefix was given. -if test "${with_libintl_prefix+set}" = set; then - withval=$with_libintl_prefix; - if test "X$withval" = "Xno"; then - use_additional=no - else - if test "X$withval" = "X"; then - - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" +# Check whether --with-samba-user was given. +if test "${with_samba_user+set}" = set; then : + withval=$with_samba_user; as_fn_error $? "--with-samba-user is no longer supported; place username in 'amandapass'" "$LINENO" 5 - eval additional_includedir=\"$includedir\" - eval additional_libdir=\"$libdir\" +fi - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" - else - additional_includedir="$withval/include" - additional_libdir="$withval/$acl_libdirstem" - fi - fi + if test "x$SAMBA_CLIENT" != "xno"; then + # Extract the first word of "smbclient", so it can be a program name with args. +set dummy smbclient; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_SAMBA_CLIENT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $SAMBA_CLIENT in + [\\/]* | ?:[\\/]*) + ac_cv_path_SAMBA_CLIENT="$SAMBA_CLIENT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_SAMBA_CLIENT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac +fi +SAMBA_CLIENT=$ac_cv_path_SAMBA_CLIENT +if test -n "$SAMBA_CLIENT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SAMBA_CLIENT" >&5 +$as_echo "$SAMBA_CLIENT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - LIBINTL= - LTLIBINTL= - INCINTL= - rpathdirs= - ltrpathdirs= - names_already_handled= - names_next_round='intl ' - while test -n "$names_next_round"; do - names_this_round="$names_next_round" - names_next_round= - for name in $names_this_round; do - already_handled= - for n in $names_already_handled; do - if test "$n" = "$name"; then - already_handled=yes - break - fi - done - if test -z "$already_handled"; then - names_already_handled="$names_already_handled $name" - uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` - eval value=\"\$HAVE_LIB$uppername\" - if test -n "$value"; then - if test "$value" = yes; then - eval value=\"\$LIB$uppername\" - test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value" - eval value=\"\$LTLIB$uppername\" - test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value" - else - : - fi - else - found_dir= - found_la= - found_so= - found_a= - if test $use_additional = yes; then - if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then - found_dir="$additional_libdir" - found_so="$additional_libdir/lib$name.$shlibext" - if test -f "$additional_libdir/lib$name.la"; then - found_la="$additional_libdir/lib$name.la" - fi - else - if test -f "$additional_libdir/lib$name.$libext"; then - found_dir="$additional_libdir" - found_a="$additional_libdir/lib$name.$libext" - if test -f "$additional_libdir/lib$name.la"; then - found_la="$additional_libdir/lib$name.la" - fi - fi - fi - fi - if test "X$found_dir" = "X"; then - for x in $LDFLAGS $LTLIBINTL; do - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" + smbversion=0 + if test ! -z "$SAMBA_CLIENT"; then + case `"$SAMBA_CLIENT" '\\\\nosuchhost.amanda.org\\notashare' -U nosuchuser -N -Tx /dev/null 2>&1` in + *"Unknown host"*) + smbversion=1 + ;; + *"Connection to nosuchhost.amanda.org failed"*) + smbversion=2 + ;; + *) - case "$x" in - -L*) - dir=`echo "X$x" | sed -e 's/^X-L//'` - if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then - found_dir="$dir" - found_so="$dir/lib$name.$shlibext" - if test -f "$dir/lib$name.la"; then - found_la="$dir/lib$name.la" - fi - else - if test -f "$dir/lib$name.$libext"; then - found_dir="$dir" - found_a="$dir/lib$name.$libext" - if test -f "$dir/lib$name.la"; then - found_la="$dir/lib$name.la" - fi - fi - fi - ;; - esac - if test "X$found_dir" != "X"; then - break - fi - done - fi - if test "X$found_dir" != "X"; then - LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name" - if test "X$found_so" != "X"; then - if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/$acl_libdirstem"; then - LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" - else - haveit= - for x in $ltrpathdirs; do - if test "X$x" = "X$found_dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - ltrpathdirs="$ltrpathdirs $found_dir" - fi - if test "$hardcode_direct" = yes; then - LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" - else - if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then - LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" - haveit= - for x in $rpathdirs; do - if test "X$x" = "X$found_dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - rpathdirs="$rpathdirs $found_dir" - fi - else - haveit= - for x in $LDFLAGS $LIBINTL; do + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $SAMBA_CLIENT does not seem to be smbclient, so it will not be used." >&5 +$as_echo "$as_me: WARNING: $SAMBA_CLIENT does not seem to be smbclient, so it will not be used." >&2;} - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" - if test "X$x" = "X-L$found_dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir" - fi - if test "$hardcode_minus_L" != no; then - LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" - else - LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" - fi - fi - fi - fi - else - if test "X$found_a" != "X"; then - LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a" - else - LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name" - fi - fi - additional_includedir= - case "$found_dir" in - */$acl_libdirstem | */$acl_libdirstem/) - basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'` - additional_includedir="$basedir/include" - ;; - esac - if test "X$additional_includedir" != "X"; then - if test "X$additional_includedir" != "X/usr/include"; then - haveit= - if test "X$additional_includedir" = "X/usr/local/include"; then - if test -n "$GCC"; then - case $host_os in - linux* | gnu* | k*bsd*-gnu) haveit=yes;; - esac - fi - fi - if test -z "$haveit"; then - for x in $CPPFLAGS $INCINTL; do + cat <>config.warnings +$SAMBA_CLIENT does not seem to be smbclient, so it will not be used. +AAW_EOF - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" - if test "X$x" = "X-I$additional_includedir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - if test -d "$additional_includedir"; then - INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir" - fi - fi - fi - fi - fi - if test -n "$found_la"; then - save_libdir="$libdir" - case "$found_la" in - */* | *\\*) . "$found_la" ;; - *) . "./$found_la" ;; - esac - libdir="$save_libdir" - for dep in $dependency_libs; do - case "$dep" in - -L*) - additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` - if test "X$additional_libdir" != "X/usr/$acl_libdirstem"; then - haveit= - if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem"; then - if test -n "$GCC"; then - case $host_os in - linux* | gnu* | k*bsd*-gnu) haveit=yes;; - esac - fi - fi - if test -z "$haveit"; then - haveit= - for x in $LDFLAGS $LIBINTL; do + SAMBA_CLIENT= + ;; + esac + if test -n "$SAMBA_CLIENT"; then - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" +cat >>confdefs.h <<_ACEOF +#define SAMBA_CLIENT "$SAMBA_CLIENT" +_ACEOF - if test "X$x" = "X-L$additional_libdir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - if test -d "$additional_libdir"; then - LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir" - fi - fi - haveit= - for x in $LDFLAGS $LTLIBINTL; do - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" +cat >>confdefs.h <<_ACEOF +#define SAMBA_VERSION $smbversion +_ACEOF - if test "X$x" = "X-L$additional_libdir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - if test -d "$additional_libdir"; then - LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir" - fi - fi - fi - fi - ;; - -R*) - dir=`echo "X$dep" | sed -e 's/^X-R//'` - if test "$enable_rpath" != no; then - haveit= - for x in $rpathdirs; do - if test "X$x" = "X$dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - rpathdirs="$rpathdirs $dir" - fi - haveit= - for x in $ltrpathdirs; do - if test "X$x" = "X$dir"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - ltrpathdirs="$ltrpathdirs $dir" - fi - fi - ;; - -l*) - names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` - ;; - *.la) - names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` - ;; - *) - LIBINTL="${LIBINTL}${LIBINTL:+ }$dep" - LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep" - ;; - esac - done - fi - else - LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" - LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name" - fi fi fi - done - done - if test "X$rpathdirs" != "X"; then - if test -n "$hardcode_libdir_separator"; then - alldirs= - for found_dir in $rpathdirs; do - alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" - done - acl_save_libdir="$libdir" - libdir="$alldirs" - eval flag=\"$hardcode_libdir_flag_spec\" - libdir="$acl_save_libdir" - LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" - else - for found_dir in $rpathdirs; do - acl_save_libdir="$libdir" - libdir="$found_dir" - eval flag=\"$hardcode_libdir_flag_spec\" - libdir="$acl_save_libdir" - LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" - done fi - fi - if test "X$ltrpathdirs" != "X"; then - for found_dir in $ltrpathdirs; do - LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir" - done - fi - { $as_echo "$as_me:$LINENO: checking for GNU gettext in libintl" >&5 -$as_echo_n "checking for GNU gettext in libintl... " >&6; } -if test "${gt_cv_func_gnugettext1_libintl+set}" = set; then - $as_echo_n "(cached) " >&6 -else - gt_save_CPPFLAGS="$CPPFLAGS" - CPPFLAGS="$CPPFLAGS $INCINTL" - gt_save_LIBS="$LIBS" - LIBS="$LIBS $LIBINTL" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -extern int _nl_msg_cat_cntr; -extern -#ifdef __cplusplus -"C" -#endif -const char *_nl_expand_alias (const char *); -int -main () -{ -bindtextdomain ("", ""); -return * gettext ("") + _nl_msg_cat_cntr + *_nl_expand_alias ("") - ; - 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 - gt_cv_func_gnugettext1_libintl=yes + if test -n "$SAMBA_CLIENT"; then + WANT_SAMBA_TRUE= + WANT_SAMBA_FALSE='#' else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - gt_cv_func_gnugettext1_libintl=no + WANT_SAMBA_TRUE='#' + WANT_SAMBA_FALSE= 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 "$gt_cv_func_gnugettext1_libintl" != yes && test -n "$LIBICONV"; then - LIBS="$LIBS $LIBICONV" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -extern int _nl_msg_cat_cntr; -extern -#ifdef __cplusplus -"C" -#endif -const char *_nl_expand_alias (const char *); -int -main () -{ -bindtextdomain ("", ""); -return * gettext ("") + _nl_msg_cat_cntr + *_nl_expand_alias ("") - ; - 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 - LIBINTL="$LIBINTL $LIBICONV" - LTLIBINTL="$LTLIBINTL $LTLIBICONV" - gt_cv_func_gnugettext1_libintl=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + USE_RUNDUMP=no -fi + # some systems require rundump unconditionally + case "$host" in + *-ultrix*) USE_RUNDUMP=yes ;; + *-dg-*) USE_RUNDUMP=yes ;; + esac -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - fi - CPPFLAGS="$gt_save_CPPFLAGS" - LIBS="$gt_save_LIBS" -fi -{ $as_echo "$as_me:$LINENO: result: $gt_cv_func_gnugettext1_libintl" >&5 -$as_echo "$gt_cv_func_gnugettext1_libintl" >&6; } - fi - if test "$gt_cv_func_gnugettext1_libc" = "yes" \ - || { test "$gt_cv_func_gnugettext1_libintl" = "yes" \ - && test "$PACKAGE" != gettext-runtime \ - && test "$PACKAGE" != gettext-tools; }; then - gt_use_preinstalled_gnugettext=yes - else - LIBINTL= - LTLIBINTL= - INCINTL= - fi +# Check whether --with-rundump was given. +if test "${with_rundump+set}" = set; then : + withval=$with_rundump; + case "$withval" in + n | no) USE_RUNDUMP=no ;; + y | ye | yes) USE_RUNDUMP=yes ;; + *) as_fn_error $? "You must not supply an argument to --with-rundump option." "$LINENO" 5;; + esac +fi - if test -n "$INTL_MACOSX_LIBS"; then - if test "$gt_use_preinstalled_gnugettext" = "yes" \ - || test "$nls_cv_use_gnu_gettext" = "yes"; then - LIBINTL="$LIBINTL $INTL_MACOSX_LIBS" - LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS" - fi - fi - - if test "$gt_use_preinstalled_gnugettext" = "yes" \ - || test "$nls_cv_use_gnu_gettext" = "yes"; then - -cat >>confdefs.h <<\_ACEOF -#define ENABLE_NLS 1 -_ACEOF + if test x"$USE_RUNDUMP" = x"yes"; then + USE_RUNDUMP=1 - else - USE_NLS=no - fi - fi +$as_echo "#define USE_RUNDUMP 1" >>confdefs.h - { $as_echo "$as_me:$LINENO: checking whether to use NLS" >&5 -$as_echo_n "checking whether to use NLS... " >&6; } - { $as_echo "$as_me:$LINENO: result: $USE_NLS" >&5 -$as_echo "$USE_NLS" >&6; } - if test "$USE_NLS" = "yes"; then - { $as_echo "$as_me:$LINENO: checking where the gettext function comes from" >&5 -$as_echo_n "checking where the gettext function comes from... " >&6; } - if test "$gt_use_preinstalled_gnugettext" = "yes"; then - if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then - gt_source="external libintl" - else - gt_source="libc" - fi else - gt_source="included intl directory" - fi - { $as_echo "$as_me:$LINENO: result: $gt_source" >&5 -$as_echo "$gt_source" >&6; } - fi - - if test "$USE_NLS" = "yes"; then - - if test "$gt_use_preinstalled_gnugettext" = "yes"; then - if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then - { $as_echo "$as_me:$LINENO: checking how to link with libintl" >&5 -$as_echo_n "checking how to link with libintl... " >&6; } - { $as_echo "$as_me:$LINENO: result: $LIBINTL" >&5 -$as_echo "$LIBINTL" >&6; } - - for element in $INCINTL; do - haveit= - for x in $CPPFLAGS; do - - acl_save_prefix="$prefix" - prefix="$acl_final_prefix" - acl_save_exec_prefix="$exec_prefix" - exec_prefix="$acl_final_exec_prefix" - eval x=\"$x\" - exec_prefix="$acl_save_exec_prefix" - prefix="$acl_save_prefix" - - if test "X$x" = "X$element"; then - haveit=yes - break - fi - done - if test -z "$haveit"; then - CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" - fi - done - - fi - - -cat >>confdefs.h <<\_ACEOF -#define HAVE_GETTEXT 1 -_ACEOF - - -cat >>confdefs.h <<\_ACEOF -#define HAVE_DCGETTEXT 1 -_ACEOF - + USE_RUNDUMP= fi - POSUB=po - fi - - - - INTLLIBS="$LIBINTL" - - - - # -# Security (authentication) mechansims +# Look for other programs Amanda will use # - BSD_SECURITY="yes" -# Check whether --with-bsd-security was given. -if test "${with_bsd_security+set}" = set; then - withval=$with_bsd_security; - case "$withval" in - n | no) BSD_SECURITY=no ;; - y | ye | yes) BSD_SECURITY=yes ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --without-bsd-security." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --without-bsd-security." >&2;} - { (exit 1); exit 1; }; } - ;; - esac + # Extract the first word of "grep", so it can be a program name with args. +set dummy grep; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GREP+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GREP in + [\\/]* | ?:[\\/]*) + ac_cv_path_GREP="$GREP" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_GREP="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + test -z "$ac_cv_path_GREP" && ac_cv_path_GREP="grep" + ;; +esac fi - - - USE_AMANDAHOSTS=yes - -# Check whether --with-amandahosts was given. -if test "${with_amandahosts+set}" = set; then - withval=$with_amandahosts; - case "$withval" in - n | no ) USE_AMANDAHOSTS=no ;; - y | ye | yes) USE_AMANDAHOSTS=yes ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --without-amandahosts option." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --without-amandahosts option." >&2;} - { (exit 1); exit 1; }; } - ;; - esac - - +GREP=$ac_cv_path_GREP +if test -n "$GREP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 +$as_echo "$GREP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - if test "x$BSD_SECURITY" = "xyes"; then -cat >>confdefs.h <<\_ACEOF -#define BSD_SECURITY 1 +cat >>confdefs.h <<_ACEOF +#define GREP "$GREP" _ACEOF - if test "x$USE_AMANDAHOSTS" = "xyes"; then - -cat >>confdefs.h <<\_ACEOF -#define USE_AMANDAHOSTS 1 -_ACEOF - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 +$as_echo_n "checking for egrep... " >&6; } +if ${ac_cv_path_EGREP+:} false; 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 + as_fn_arith $ac_count + 1 && ac_count=$as_val + 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 - if test x"$BSD_SECURITY" = x"yes"; then - WANT_BSD_SECURITY_TRUE= - WANT_BSD_SECURITY_FALSE='#' + $ac_path_EGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_EGREP"; then + as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi else - WANT_BSD_SECURITY_TRUE='#' - WANT_BSD_SECURITY_FALSE= + ac_cv_path_EGREP=$EGREP fi - - - - - BSDTCP_SECURITY="yes" - -# Check whether --with-bsdtcp-security was given. -if test "${with_bsdtcp_security+set}" = set; then - withval=$with_bsdtcp_security; - case "$withval" in - n | no) BSDTCP_SECURITY=no ;; - y | ye | yes) BSDTCP_SECURITY=yes ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-bsdtcp-security." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --with-bsdtcp-security." >&2;} - { (exit 1); exit 1; }; } - ;; - esac - + fi fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 +$as_echo "$ac_cv_path_EGREP" >&6; } + EGREP="$ac_cv_path_EGREP" - if test "x$BSDTCP_SECURITY" = "xyes"; then - -cat >>confdefs.h <<\_ACEOF -#define BSDTCP_SECURITY 1 -_ACEOF - - fi - - if test x"$BSDTCP_SECURITY" = x"yes"; then - WANT_BSDTCP_SECURITY_TRUE= - WANT_BSDTCP_SECURITY_FALSE='#' -else - WANT_BSDTCP_SECURITY_TRUE='#' - WANT_BSDTCP_SECURITY_FALSE= -fi - - BSDUDP_SECURITY="no" -# Check whether --with-bsdudp-security was given. -if test "${with_bsdudp_security+set}" = set; then - withval=$with_bsdudp_security; - case "$withval" in - n | no) : ;; - y | ye | yes) BSDUDP_SECURITY=yes ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-bsdudp-security." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --with-bsdudp-security." >&2;} - { (exit 1); exit 1; }; } - ;; - esac + # Extract the first word of "lint", so it can be a program name with args. +set dummy lint; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_AMLINT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $AMLINT in + [\\/]* | ?:[\\/]*) + ac_cv_path_AMLINT="$AMLINT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +as_dummy="/opt/SUNWspro/bin:$SYSLOCPATH" +for as_dir in $as_dummy +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_path_AMLINT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + ;; +esac fi - - - if test "x$BSDUDP_SECURITY" = "xyes"; then - -cat >>confdefs.h <<\_ACEOF -#define BSDUDP_SECURITY 1 -_ACEOF - - fi - - if test x"$BSDUDP_SECURITY" = x"yes"; then - WANT_BSDUDP_SECURITY_TRUE= - WANT_BSDUDP_SECURITY_FALSE='#' +AMLINT=$ac_cv_path_AMLINT +if test -n "$AMLINT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AMLINT" >&5 +$as_echo "$AMLINT" >&6; } else - WANT_BSDUDP_SECURITY_TRUE='#' - WANT_BSDUDP_SECURITY_FALSE= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi + if test ! -z "$AMLINT"; then + $AMLINT -flags 2>&1 | $GREP -- '-errfmt=' > /dev/null + if test $? -eq 0; then + AMLINTFLAGS="-n -s -u -m -x" + AMLINTFLAGS="$AMLINTFLAGS -errchk=%all" + AMLINTFLAGS="$AMLINTFLAGS -errfmt=macro" + AMLINTFLAGS="$AMLINTFLAGS -errhdr=no%/usr/include" + AMLINTFLAGS="$AMLINTFLAGS -errhdr=%user" + AMLINTFLAGS="$AMLINTFLAGS -errsecurity=extended" + AMLINTFLAGS="$AMLINTFLAGS -errtags=yes" + AMLINTFLAGS="$AMLINTFLAGS -Ncheck=%all" + AMLINTFLAGS="$AMLINTFLAGS -Nlevel=2" + AMLINTFLAGS="$AMLINTFLAGS -erroff=E_ASGN_NEVER_USED" + AMLINTFLAGS="$AMLINTFLAGS,E_ASGN_RESET" + AMLINTFLAGS="$AMLINTFLAGS,E_CAST_INT_CONST_TO_SMALL_INT" + AMLINTFLAGS="$AMLINTFLAGS,E_CAST_INT_TO_SMALL_INT" + AMLINTFLAGS="$AMLINTFLAGS,E_CAST_UINT_TO_SIGNED_INT" + AMLINTFLAGS="$AMLINTFLAGS,E_CONSTANT_CONDITION" + AMLINTFLAGS="$AMLINTFLAGS,E_ENUM_UNUSE" + AMLINTFLAGS="$AMLINTFLAGS,E_EXPR_NULL_EFFECT" + AMLINTFLAGS="$AMLINTFLAGS,E_FUNC_RET_ALWAYS_IGNOR" + AMLINTFLAGS="$AMLINTFLAGS,E_FUNC_RET_MAYBE_IGNORED" + AMLINTFLAGS="$AMLINTFLAGS,E_H_C_CHECK0" + AMLINTFLAGS="$AMLINTFLAGS,E_H_C_CHECK1" + AMLINTFLAGS="$AMLINTFLAGS,E_H_C_CHECK2" + AMLINTFLAGS="$AMLINTFLAGS,E_INCL_MNUSD" + AMLINTFLAGS="$AMLINTFLAGS,E_INCL_NUSD" + AMLINTFLAGS="$AMLINTFLAGS,E_MCR_NODIFF" + AMLINTFLAGS="$AMLINTFLAGS,E_NAME_MULTIPLY_DEF" + AMLINTFLAGS="$AMLINTFLAGS,E_P_REF_NULL_PSBL" + AMLINTFLAGS="$AMLINTFLAGS,E_P_REF_SUSP" + AMLINTFLAGS="$AMLINTFLAGS,E_PTRDIFF_OVERFLOW" + AMLINTFLAGS="$AMLINTFLAGS,E_P_USE_NULL_PSBL" + AMLINTFLAGS="$AMLINTFLAGS,E_P_USE_SUSP" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_ACCESS_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_CHDIR_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_CHMOD_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_CREAT_WITHOUT_EXCL" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_EXEC_PATH" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_EXEC_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_FOPEN_MODE" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_GETENV_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_MKDIR_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_PRINTF_VAR_FMT" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_RAND_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_SCANF_VAR_FMT" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_SELECT_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_SHELL_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_STRNCPY_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_UMASK_WARN" + AMLINTFLAGS="$AMLINTFLAGS,E_SEC_USE_AFTER_STAT" + AMLINTFLAGS="$AMLINTFLAGS,E_SIGN_EXTENSION_PSBL" + AMLINTFLAGS="$AMLINTFLAGS,E_TYPEDEF_UNUSE" + AMLINTFLAGS="$AMLINTFLAGS,E_UNCAL_F" + else + AMLINTFLAGS="" + fi + else + # Extract the first word of "splint", so it can be a program name with args. +set dummy splint; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_AMLINT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $AMLINT in + [\\/]* | ?:[\\/]*) + ac_cv_path_AMLINT="$AMLINT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $SYSLOCPATH +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_AMLINT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - - RSH_SECURITY=no - -# Check whether --with-rsh-security was given. -if test "${with_rsh_security+set}" = set; then - withval=$with_rsh_security; - case "$withval" in - n | no) : ;; - y | ye | yes) RSH_SECURITY=yes ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-rsh-security." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --with-rsh-security." >&2;} - { (exit 1); exit 1; }; } - ;; - esac - + ;; +esac fi - - - if test "x$RSH_SECURITY" = "xyes"; then - -cat >>confdefs.h <<\_ACEOF -#define RSH_SECURITY 1 -_ACEOF - - fi - if test x"$RSH_SECURITY" = x"yes"; then - WANT_RSH_SECURITY_TRUE= - WANT_RSH_SECURITY_FALSE='#' +AMLINT=$ac_cv_path_AMLINT +if test -n "$AMLINT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AMLINT" >&5 +$as_echo "$AMLINT" >&6; } else - WANT_RSH_SECURITY_TRUE='#' - WANT_RSH_SECURITY_FALSE= + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi + if test ! -z "$AMLINT"; then + AMLINT="splint" + AMLINTFLAGS='+show-scan +unixlib -weak -globs +usedef +usereleased +impouts -paramimptemp -varuse -warnposix -redef -preproc -fixedformalarray -retval -unrecog -usevarargs -formatcode' + else + AMLINT='echo "Error: LINT is not installed" ; false' + AMLINTFLAGS='' + fi + fi - SSH_SECURITY=yes - -# Check whether --with-ssh-security was given. -if test "${with_ssh_security+set}" = set; then - withval=$with_ssh_security; - case "$withval" in - n | no) SSH_SECURITY=no ;; - y | ye | yes) SSH_SECURITY=yes ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-ssh-security." >&5 -$as_echo "$as_me: error: *** You must not supply an argument to --with-ssh-security." >&2;} - { (exit 1); exit 1; }; } - ;; - esac - -fi - - - if test "x$SSH_SECURITY" = "xyes"; then - # find the SSH binary - for ac_prog in ssh +for ac_prog in flex lex 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_SSH+set}" = set; then +if ${ac_cv_prog_LEX+:} false; then : $as_echo_n "(cached) " >&6 else - case $SSH in - [\\/]* | ?:[\\/]*) - ac_cv_path_SSH="$SSH" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH + if test -n "$LEX"; then + ac_cv_prog_LEX="$LEX" # 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 + 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_SSH="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_prog_LEX="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS - ;; -esac fi -SSH=$ac_cv_path_SSH -if test -n "$SSH"; then - { $as_echo "$as_me:$LINENO: result: $SSH" >&5 -$as_echo "$SSH" >&6; } +fi +LEX=$ac_cv_prog_LEX +if test -n "$LEX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5 +$as_echo "$LEX" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$SSH" && break + test -n "$LEX" && break done +test -n "$LEX" || LEX=":" +if test "x$LEX" != "x:"; then + cat >conftest.l <<_ACEOF +%% +a { ECHO; } +b { REJECT; } +c { yymore (); } +d { yyless (1); } +e { yyless (input () != 0); } +f { unput (yytext[0]); } +. { BEGIN INITIAL; } +%% +#ifdef YYTEXT_POINTER +extern char *yytext; +#endif +int +main (void) +{ + return ! yylex () + ! yywrap (); +} +_ACEOF +{ { ac_try="$LEX conftest.l" +case "(($ac_try" in + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; + *) ac_try_echo=$ac_try;; +esac +eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" +$as_echo "$ac_try_echo"; } >&5 + (eval "$LEX conftest.l") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5 +$as_echo_n "checking lex output file root... " >&6; } +if ${ac_cv_prog_lex_root+:} false; then : + $as_echo_n "(cached) " >&6 +else - # see what options we should use +if test -f lex.yy.c; then + ac_cv_prog_lex_root=lex.yy +elif test -f lexyy.c; then + ac_cv_prog_lex_root=lexyy +else + as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5 +fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5 +$as_echo "$ac_cv_prog_lex_root" >&6; } +LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root -# Check whether --with-ssh-options was given. -if test "${with_ssh_options+set}" = set; then - withval=$with_ssh_options; SSH_OPTIONS="$withval" +if test -z "${LEXLIB+set}"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5 +$as_echo_n "checking lex library... " >&6; } +if ${ac_cv_lib_lex+:} false; then : + $as_echo_n "(cached) " >&6 else - SSH_OPTIONS='' + ac_save_LIBS=$LIBS + ac_cv_lib_lex='none needed' + for ac_lib in '' -lfl -ll; do + LIBS="$ac_lib $ac_save_LIBS" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +`cat $LEX_OUTPUT_ROOT.c` +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_lex=$ac_lib fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + test "$ac_cv_lib_lex" != 'none needed' && break + done + LIBS=$ac_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5 +$as_echo "$ac_cv_lib_lex" >&6; } + test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex +fi - case "$SSH_OPTIONS" in - y | ye | yes | n | no) - { { $as_echo "$as_me:$LINENO: error: *** You must supply an argument to --with-ssh-options." >&5 -$as_echo "$as_me: error: *** You must supply an argument to --with-ssh-options." >&2;} - { (exit 1); exit 1; }; };; - *) : ;; - esac - { $as_echo "$as_me:$LINENO: checking SSH options" >&5 -$as_echo_n "checking SSH options... " >&6; } - # if we didn't get SSH options from the user, figure them out for ourselves - if test -z "$SSH_OPTIONS"; then - case `$SSH -V 2>&1` in - OpenSSH*) SSH_OPTIONS='-x -o BatchMode=yes -o PreferredAuthentications=publickey';; - *) SSH_OPTIONS='-x -o BatchMode=yes' ;; - esac - fi - - # now convert that to a comma-separated list of C strings - eval "set dummy ${SSH_OPTIONS}"; shift - SSH_OPTIONS='' - for i in "${@}"; do - quoted="\"`echo "$i" | sed -e 's/\"/\\\"/'`\"" - SSH_OPTIONS="${SSH_OPTIONS}${SSH_OPTIONS:+, }$quoted"; - done - { $as_echo "$as_me:$LINENO: result: $SSH_OPTIONS" >&5 -$as_echo "$SSH_OPTIONS" >&6; } - - # finally, make the various outputs for all of this - -cat >>confdefs.h <<\_ACEOF -#define SSH_SECURITY 1 -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define SSH "$SSH" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define SSH_OPTIONS $SSH_OPTIONS -_ACEOF - - fi - if test x"$SSH_SECURITY" = x"yes"; then - WANT_SSH_SECURITY_TRUE= - WANT_SSH_SECURITY_FALSE='#' -else - WANT_SSH_SECURITY_TRUE='#' - WANT_SSH_SECURITY_FALSE= -fi - - - - # (note -- don't just substitute SSH_OPTIONS -- shell quoting will break) - - - # Specify --with-krb5-security if Kerberos software is in somewhere - # other than the listed KRB5_SPOTS. We only compile kerberos support in - # if the right files are there. - - KRB5_SECURITY="no" - : ${KRB5_SPOTS="/usr/kerberos /usr/cygnus /usr /opt/kerberos"} - - -# Check whether --with-krb5-security was given. -if test "${with_krb5_security+set}" = set; then - withval=$with_krb5_security; - case "$withval" in - n | no) KRB5_SECURITY=no ;; - y | ye | yes) KRB5_SECURITY=yes ;; - *) KRB5_SPOTS="$KRB5_SECURITY" - KRB5_SECURITY=yes - ;; - esac - - -fi - - - if test "x$KRB5_SECURITY" = "xyes"; then - # if found, force the static versions of these libs (.a) by linking directly - # with the .a files. I don't know how to get -R dependancies checked - # in autoconf at this time. -kashmir - { $as_echo "$as_me:$LINENO: checking for Kerberos V libraries" >&5 -$as_echo_n "checking for Kerberos V libraries... " >&6; } - KRB5_DIR_FOUND="" - for dir in $KRB5_SPOTS; do - for lib in lib lib64; do - k5libdir=${dir}/${lib} - if test \( -f ${k5libdir}/libkrb5.a -o -f ${k5libdir}/libkrb5.so \) -a \( -f ${k5libdir}/libgssapi_krb5.so -o -f ${k5libdir}/libgssapi_krb5.a \) -a \( -f ${k5libdir}/libcom_err.a -o -f ${k5libdir}/libcom_err.so \); then - if test -f ${k5libdir}/libk5crypto.a -o -f ${k5libdir}/libk5crypto.so; then - K5CRYPTO=-lk5crypto - elif test -f ${k5libdir}/libcrypto.a -o -f ${k5libdir}/libcrypto.so; then - K5CRYPTO=-lcrypto - else - K5CRYPTO="" - fi - if test -f ${k5libdir}/libkrb5support.a -o -f ${k5libdir}/libkrb5support.so; then - K5SUPPORT=-lkrb5support - else - K5SUPPORT="" - fi - KRB5_DIR_FOUND=$dir - KRB5_LIBDIR_FOUND=$k5libdir - LIBS="-lgssapi_krb5 -lkrb5 $K5CRYPTO $K5SUPPORT -lcom_err $LIBS" - - break - elif test \( -f ${k5libdir}/libkrb5.a -o -f ${k5libdir}/libkrb5.so \) -a \( -f ${k5libdir}/libasn1.a -o -f ${k5libdir}/libasn1.so \) -a \( -f ${k5libdir}/libgssapi.a -o -f ${k5libdir}/libgssapi.so \); then - LIBS="-lgssapi -lkrb5 -lasn1 $LIBS" - - CPPFLAGS="$CPPFLAGS -DKRB5_HEIMDAL_INCLUDES" - - break - fi - done - done - - if test "$KRB5_DIR_FOUND"; then - { $as_echo "$as_me:$LINENO: result: found in $KRB5_DIR_FOUND" >&5 -$as_echo "found in $KRB5_DIR_FOUND" >&6; } - # - # some OS's, such as NetBSD, stick krb5 includes out of the way... - # should probably just use autoconf to look for various include - # options and set them, but don't quite want to do that until I've - # dug into it a bit more. - # - if test -d "$KRB5_DIR_FOUND/krb5" ; then - CPPFLAGS="$CPPFLAGS -I$KRB5_DIR_FOUND/include/krb5" - - else - CPPFLAGS="$CPPFLAGS -I$KRB5_DIR_FOUND/include" - - fi - -{ $as_echo "$as_me:$LINENO: checking for main in -lkrb5support" >&5 -$as_echo_n "checking for main in -lkrb5support... " >&6; } -if test "${ac_cv_lib_krb5support_main+set}" = set; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5 +$as_echo_n "checking whether yytext is a pointer... " >&6; } +if ${ac_cv_prog_lex_yytext_pointer+:} false; then : $as_echo_n "(cached) " >&6 else - ac_check_lib_save_LIBS=$LIBS -LIBS="-lkrb5support $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + # POSIX says lex can declare yytext either as a pointer or an array; the +# default is implementation-dependent. Figure out which it is, since +# not all implementations provide the %pointer and %array declarations. +ac_cv_prog_lex_yytext_pointer=no +ac_save_LIBS=$LIBS +LIBS="$LEXLIB $ac_save_LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ - -int -main () -{ -return main (); - ; - return 0; -} + #define YYTEXT_POINTER 1 +`cat $LEX_OUTPUT_ROOT.c` _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_krb5support_main=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_krb5support_main=no +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_prog_lex_yytext_pointer=yes fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_save_LIBS -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_krb5support_main" >&5 -$as_echo "$ac_cv_lib_krb5support_main" >&6; } -if test "x$ac_cv_lib_krb5support_main" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define HAVE_LIBKRB5SUPPORT 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5 +$as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; } +if test $ac_cv_prog_lex_yytext_pointer = yes; then - LIBS="-lkrb5support $LIBS" +$as_echo "#define YYTEXT_POINTER 1" >>confdefs.h fi +rm -f conftest.l $LEX_OUTPUT_ROOT.c - - if test "$KRB5_LIBDIR_FOUND" != "$libdir" ; then - LDFLAGS="$LDFLAGS -L$KRB5_LIBDIR_FOUND" - - fi - - -cat >>confdefs.h <<\_ACEOF -#define KRB5_SECURITY 1 -_ACEOF - - else - { $as_echo "$as_me:$LINENO: result: no krb5 system libraries found" >&5 -$as_echo "no krb5 system libraries found" >&6; } - { { $as_echo "$as_me:$LINENO: error: No Kerberos V libraries were found on your system; krb5-security cannot be enabled" >&5 -$as_echo "$as_me: error: No Kerberos V libraries were found on your system; krb5-security cannot be enabled" >&2;} - { (exit 1); exit 1; }; } - KRB5_SECURITY="no" - fi - fi - - if test x"$KRB5_SECURITY" = x"yes"; then - WANT_KRB5_SECURITY_TRUE= - WANT_KRB5_SECURITY_FALSE='#' -else - WANT_KRB5_SECURITY_TRUE='#' - WANT_KRB5_SECURITY_FALSE= +fi +if test "$LEX" = :; then + LEX=${am_missing_run}flex fi - -# -# Dumpers -# + if test x"$LEX" != x""; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lex is broken Solaris (SGU) lex" >&5 +$as_echo_n "checking whether lex is broken Solaris (SGU) lex... " >&6; } + $LEX -V < /dev/null >/dev/null 2>conftest.out + if grep SGU conftest.out >/dev/null; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes - disabled (set LEX=/path/to/lex to use a specific binary)" >&5 +$as_echo "yes - disabled (set LEX=/path/to/lex to use a specific binary)" >&6; } + LEX='echo no lex equivalent available; false' + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + rm conftest.out + fi - for ac_prog in xfsdump -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 + # 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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_XFSDUMP+set}" = set; then +if ${ac_cv_path_AR+:} false; then : $as_echo_n "(cached) " >&6 else - case $XFSDUMP in + case $AR in [\\/]* | ?:[\\/]*) - ac_cv_path_XFSDUMP="$XFSDUMP" # Let the user override the test with a path. + ac_cv_path_AR="$AR" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH +for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_XFSDUMP="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -XFSDUMP=$ac_cv_path_XFSDUMP -if test -n "$XFSDUMP"; then - { $as_echo "$as_me:$LINENO: result: $XFSDUMP" >&5 -$as_echo "$XFSDUMP" >&6; } +AR=$ac_cv_path_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$XFSDUMP" && break -done - for ac_prog in xfsrestore -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 + + + # Extract the first word of "gettext", so it can be a program name with args. +set dummy gettext; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_XFSRESTORE+set}" = set; then +if ${ac_cv_path_GETTEXT+:} false; then : $as_echo_n "(cached) " >&6 else - case $XFSRESTORE in + case $GETTEXT in [\\/]* | ?:[\\/]*) - ac_cv_path_XFSRESTORE="$XFSRESTORE" # Let the user override the test with a path. + ac_cv_path_GETTEXT="$GETTEXT" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH +for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_XFSRESTORE="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_GETTEXT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -XFSRESTORE=$ac_cv_path_XFSRESTORE -if test -n "$XFSRESTORE"; then - { $as_echo "$as_me:$LINENO: result: $XFSRESTORE" >&5 -$as_echo "$XFSRESTORE" >&6; } +GETTEXT=$ac_cv_path_GETTEXT +if test -n "$GETTEXT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GETTEXT" >&5 +$as_echo "$GETTEXT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$XFSRESTORE" && break -done - - if test "$XFSDUMP" -a "$XFSRESTORE"; then - -cat >>confdefs.h <<_ACEOF -#define XFSDUMP "$XFSDUMP" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define XFSRESTORE "$XFSRESTORE" -_ACEOF - - - { $as_echo "$as_me:$LINENO: WARNING: xfsdump causes the setuid-root rundump program to be enabled. To disable it, just #undef XFSDUMP in config/config.h" >&5 -$as_echo "$as_me: WARNING: xfsdump causes the setuid-root rundump program to be enabled. To disable it, just #undef XFSDUMP in config/config.h" >&2;} - - - cat <>config.warnings -xfsdump causes the setuid-root rundump program to be enabled. To disable it, just #undef XFSDUMP in config/config.h -AAW_EOF - - - fi - - - - # Extract the first word of "vxdump", so it can be a program name with args. -set dummy vxdump; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_VXDUMP+set}" = set; then +if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else - case $VXDUMP in - [\\/]* | ?:[\\/]*) - ac_cv_path_VXDUMP="$VXDUMP" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_dummy="$SYSLOCPATH:/usr/lib/fs/vxfs" -for as_dir in $as_dummy + 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 + 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_VXDUMP="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_prog_AWK="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS - ;; -esac fi -VXDUMP=$ac_cv_path_VXDUMP -if test -n "$VXDUMP"; then - { $as_echo "$as_me:$LINENO: result: $VXDUMP" >&5 -$as_echo "$VXDUMP" >&6; } +fi +AWK=$ac_cv_prog_AWK +if test -n "$AWK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 +$as_echo "$AWK" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - # Extract the first word of "vxrestore", so it can be a program name with args. -set dummy vxrestore; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + test -n "$AWK" && break +done + +for ac_prog in 'bison -y' byacc +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_VXRESTORE+set}" = set; then +if ${ac_cv_prog_YACC+:} false; then : $as_echo_n "(cached) " >&6 else - case $VXRESTORE in - [\\/]* | ?:[\\/]*) - ac_cv_path_VXRESTORE="$VXRESTORE" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_dummy="$SYSLOCPATH:/usr/lib/fs/vxfs" -for as_dir in $as_dummy + if test -n "$YACC"; then + ac_cv_prog_YACC="$YACC" # 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 + 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_VXRESTORE="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_prog_YACC="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS - ;; -esac fi -VXRESTORE=$ac_cv_path_VXRESTORE -if test -n "$VXRESTORE"; then - { $as_echo "$as_me:$LINENO: result: $VXRESTORE" >&5 -$as_echo "$VXRESTORE" >&6; } +fi +YACC=$ac_cv_prog_YACC +if test -n "$YACC"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5 +$as_echo "$YACC" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - if test "$VXDUMP" -a "$VXRESTORE"; then - -cat >>confdefs.h <<_ACEOF -#define VXDUMP "$VXDUMP" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define VXRESTORE "$VXRESTORE" -_ACEOF - - fi + test -n "$YACC" && break +done +test -n "$YACC" || YACC="yacc" - # Extract the first word of "vdump", so it can be a program name with args. -set dummy vdump; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + # Extract the first word of "dd", so it can be a program name with args. +set dummy dd; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_VDUMP+set}" = set; then +if ${ac_cv_path_DD+:} false; then : $as_echo_n "(cached) " >&6 else - case $VDUMP in + case $DD in [\\/]* | ?:[\\/]*) - ac_cv_path_VDUMP="$VDUMP" # Let the user override the test with a path. + ac_cv_path_DD="$DD" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH +for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_VDUMP="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_DD="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -VDUMP=$ac_cv_path_VDUMP -if test -n "$VDUMP"; then - { $as_echo "$as_me:$LINENO: result: $VDUMP" >&5 -$as_echo "$VDUMP" >&6; } +DD=$ac_cv_path_DD +if test -n "$DD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DD" >&5 +$as_echo "$DD" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - # Extract the first word of "vrestore", so it can be a program name with args. -set dummy vrestore; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + + + + # Extract the first word of "bash", so it can be a program name with args. +set dummy bash; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_VRESTORE+set}" = set; then +if ${ac_cv_path_BASH+:} false; then : $as_echo_n "(cached) " >&6 else - case $VRESTORE in + case $BASH in [\\/]* | ?:[\\/]*) - ac_cv_path_VRESTORE="$VRESTORE" # Let the user override the test with a path. + ac_cv_path_BASH="$BASH" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH +for as_dir in $SYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_VRESTORE="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -VRESTORE=$ac_cv_path_VRESTORE -if test -n "$VRESTORE"; then - { $as_echo "$as_me:$LINENO: result: $VRESTORE" >&5 -$as_echo "$VRESTORE" >&6; } +BASH=$ac_cv_path_BASH +if test -n "$BASH"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 +$as_echo "$BASH" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - if test "$VDUMP" -a "$VRESTORE"; then - -cat >>confdefs.h <<_ACEOF -#define VDUMP "$VDUMP" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define VRESTORE "$VRESTORE" -_ACEOF - - fi - - - - - - # Set the order of dump programs to look for. Finding the proper file - # system dumping program is problematic. Some systems, notably HP-UX - # and AIX, have both the backup and dump programs. HP-UX can't use the - # the backup program while AIX systems can't use the dump program. So - # a variable is set up here to specify the order of dump programs to - # search for on the system. - DUMP_PROGRAMS="ufsdump dump backup" - DUMP_RETURNS_1= - AIX_BACKUP= - case "$host" in - *-dg-*) - DUMP_PROGRAMS="dump "$DUMP_PROGRAMS - DUMP_RETURNS_1=1 - ;; - *-ibm-aix*) - DUMP_PROGRAMS="backup "$DUMP_PROGRAMS - AIX_BACKUP=1 - -cat >>confdefs.h <<\_ACEOF -#define AIX_BACKUP 1 -_ACEOF - ;; - *-ultrix*) - DUMP_RETURNS_1=1 - ;; - esac - if test -n "$DUMP_RETURNS_1"; then -cat >>confdefs.h <<\_ACEOF -#define DUMP_RETURNS_1 1 -_ACEOF - fi - for ac_prog in $DUMP_PROGRAMS -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 + # Extract the first word of "sort", so it can be a program name with args. +set dummy sort; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_DUMP+set}" = set; then +if ${ac_cv_path_SORT+:} false; then : $as_echo_n "(cached) " >&6 else - case $DUMP in + case $SORT in [\\/]* | ?:[\\/]*) - ac_cv_path_DUMP="$DUMP" # Let the user override the test with a path. + ac_cv_path_SORT="$SORT" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH +for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_DUMP="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS + test -z "$ac_cv_path_SORT" && ac_cv_path_SORT="NONE" ;; esac fi -DUMP=$ac_cv_path_DUMP -if test -n "$DUMP"; then - { $as_echo "$as_me:$LINENO: result: $DUMP" >&5 -$as_echo "$DUMP" >&6; } +SORT=$ac_cv_path_SORT +if test -n "$SORT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 +$as_echo "$SORT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$DUMP" && break -done - for ac_prog in ufsrestore restore + # sort is only needed in the server build + if test x"$SORT" = x"NONE" && $WANT_SERVER; then + as_fn_error $? "Set SORT to the path of the sort program." "$LINENO" 5 + fi + + +cat >>confdefs.h <<_ACEOF +#define SORT_PATH "$SORT" +_ACEOF + + + + + for ac_prog in Mail mailx mail 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_RESTORE+set}" = set; then +if ${ac_cv_path_MAILER+:} false; then : $as_echo_n "(cached) " >&6 else - case $RESTORE in + case $MAILER in [\\/]* | ?:[\\/]*) - ac_cv_path_RESTORE="$RESTORE" # Let the user override the test with a path. + ac_cv_path_MAILER="$MAILER" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH +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 + 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_RESTORE="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_MAILER="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -RESTORE=$ac_cv_path_RESTORE -if test -n "$RESTORE"; then - { $as_echo "$as_me:$LINENO: result: $RESTORE" >&5 -$as_echo "$RESTORE" >&6; } +MAILER=$ac_cv_path_MAILER +if test -n "$MAILER"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAILER" >&5 +$as_echo "$MAILER" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$RESTORE" && break + test -n "$MAILER" && break done +test -n "$MAILER" || MAILER="NONE" + if test x"$MAILER" = x"NONE"; then - # newer versions of GNU tar include a program named 'backup' which - # does *not* implement the expected 'dump' interface. Detect that here - # and pretend we never saw it. - if test -n "$DUMP"; then - if test "`basename $DUMP`" = "backup"; then - backup_gnutar=`$DUMP --version | $GREP "GNU tar"` - if test $? -eq 0; then - DUMP= - fi - fi - fi + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: WARNING: Amanda cannot send mail reports without a mailer." >&5 +$as_echo "$as_me: WARNING: WARNING: Amanda cannot send mail reports without a mailer." >&2;} - if test "$DUMP" -a "$RESTORE"; then -cat >>confdefs.h <<_ACEOF -#define DUMP "$DUMP" -_ACEOF + cat <>config.warnings +WARNING: Amanda cannot send mail reports without a mailer. +AAW_EOF + + DEFAULT_MAILER="" + else + DEFAULT_MAILER="$MAILER" + fi cat >>confdefs.h <<_ACEOF -#define RESTORE "$RESTORE" +#define DEFAULT_MAILER "$DEFAULT_MAILER" _ACEOF - # check for an estimate flag - if test -x $DUMP; then - { $as_echo "$as_me:$LINENO: checking whether $DUMP supports -E or -S for estimates" >&5 -$as_echo_n "checking whether $DUMP supports -E or -S for estimates... " >&6; } -if test "${amanda_cv_dump_estimate+set}" = set; then + + + + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_MT+:} false; then : $as_echo_n "(cached) " >&6 else + case $MT in + [\\/]* | ?:[\\/]*) + ac_cv_path_MT="$MT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $SYSLOCPATH +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_MT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - case "$DUMP" in - *dump) - { ac_try='$DUMP 9Ef /dev/null /dev/null/invalid/fs 2>&1 - | $GREP -v Dumping - | $GREP -v Date - | $GREP -v Label >conftest.d-E 2>&1' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } - cat conftest.d-E >&5 - { ac_try='$DUMP 9Sf /dev/null /dev/null/invalid/fs 2>&1 - | $GREP -v Dumping - | $GREP -v Date - | $GREP -v Label >conftest.d-S 2>&1' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } - cat conftest.d-S >&5 - { ac_try='$DUMP 9f /dev/null /dev/null/invalid/fs 2>&1 - | $GREP -v Dumping - | $GREP -v Date - | $GREP -v Label >conftest.d 2>&1' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } - cat conftest.d >&5 - if { ac_try='cmp conftest.d-E conftest.d 1>&2' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - amanda_cv_dump_estimate=E - elif { ac_try='cmp conftest.d-S conftest.d 1>&2' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - amanda_cv_dump_estimate=S - else - amanda_cv_dump_estimate=no - fi - rm -f conftest.d conftest.d-E conftest.d-S - ;; - *) amanda_cv_dump_estimate=no - ;; - esac - + test -z "$ac_cv_path_MT" && ac_cv_path_MT="mt" + ;; +esac +fi +MT=$ac_cv_path_MT +if test -n "$MT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 +$as_echo "$MT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_dump_estimate" >&5 -$as_echo "$amanda_cv_dump_estimate" >&6; } - else - { $as_echo "$as_me:$LINENO: WARNING: $DUMP is not executable, cannot run -E/-S test" >&5 -$as_echo "$as_me: WARNING: $DUMP is not executable, cannot run -E/-S test" >&2;} - cat <>config.warnings -$DUMP is not executable, cannot run -E/-S test -AAW_EOF + case "$host" in + *-hp-*) MT_FILE_FLAG="-t" ;; + *) MT_FILE_FLAG="-f" ;; + esac - amanda_cv_dump_estimate=no - fi - if test "x$amanda_cv_dump_estimate" != xno; then cat >>confdefs.h <<_ACEOF -#define HAVE_DUMP_ESTIMATE "$amanda_cv_dump_estimate" +#define MT_FILE_FLAG "$MT_FILE_FLAG" _ACEOF - fi -# Check whether --with-dump-honor-nodump was given. -if test "${with_dump_honor_nodump+set}" = set; then - withval=$with_dump_honor_nodump; - if test -x $DUMP; then - { $as_echo "$as_me:$LINENO: checking whether $DUMP supports -h (honor nodump flag)" >&5 -$as_echo_n "checking whether $DUMP supports -h (honor nodump flag)... " >&6; } -if test "${amanda_cv_honor_nodump+set}" = set; then + + # Extract the first word of "mtx", so it can be a program name with args. +set dummy mtx; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_MTX+:} false; then : $as_echo_n "(cached) " >&6 else + case $MTX in + [\\/]* | ?:[\\/]*) + ac_cv_path_MTX="$MTX" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_MTX="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - case "$DUMP" in - *dump) - { ac_try='$DUMP 9hf 0 /dev/null /dev/null/invalid/fs 2>&1 - | $GREP -v Dumping - | $GREP -v Date - | $GREP -v Label >conftest.d-h 2>&1' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } - cat conftest.d-h >&5 - { ac_try='$DUMP 9f /dev/null /dev/null/invalid/fs 2>&1 - | $GREP -v Dumping - | $GREP -v Date - | $GREP -v Label >conftest.d 2>&1' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; } - cat conftest.d >&5 - if { ac_try='diff conftest.d-h conftest.d 1>&2' - { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - amanda_cv_honor_nodump=yes - else - amanda_cv_honor_nodump=no - fi - rm -f conftest.d conftest.d-h - ;; - *) amanda_cv_honor_nodump=no - ;; - esac - + test -z "$ac_cv_path_MTX" && ac_cv_path_MTX="mtx" + ;; +esac fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_honor_nodump" >&5 -$as_echo "$amanda_cv_honor_nodump" >&6; } - else - - { $as_echo "$as_me:$LINENO: WARNING: $DUMP is not executable, cannot run -h test" >&5 -$as_echo "$as_me: WARNING: $DUMP is not executable, cannot run -h test" >&2;} - - - cat <>config.warnings -$DUMP is not executable, cannot run -h test -AAW_EOF - - - amanda_cv_honor_nodump=no - fi - if test "x$amanda_cv_honor_nodump" = xyes; then - -cat >>confdefs.h <<\_ACEOF -#define HAVE_HONOR_NODUMP 1 -_ACEOF - - fi - +MTX=$ac_cv_path_MTX +if test -n "$MTX"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MTX" >&5 +$as_echo "$MTX" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - fi + # Extract the first word of "mount", so it can be a program name with args. +set dummy mount; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_MOUNT+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $MOUNT in + [\\/]* | ?:[\\/]*) + ac_cv_path_MOUNT="$MOUNT" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $LOCSYSPATH +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_MOUNT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + test -z "$ac_cv_path_MOUNT" && ac_cv_path_MOUNT="mount" + ;; +esac +fi +MOUNT=$ac_cv_path_MOUNT +if test -n "$MOUNT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MOUNT" >&5 +$as_echo "$MOUNT" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - # call with -# Check whether --with-gnutar was given. -if test "${with_gnutar+set}" = set; then - withval=$with_gnutar; - # check withval - case "$withval" in - /*) GNUTAR="$withval";; - y|ye|yes) :;; - n|no) GNUTAR=no ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must supply a full pathname to --with-gnutar" >&5 -$as_echo "$as_me: error: *** You must supply a full pathname to --with-gnutar" >&2;} - { (exit 1); exit 1; }; };; - esac - # done -fi - if test "x$GNUTAR" = "xno"; then - GNUTAR= - else - OLD_GNUTAR=$GNUTAR - for gnutar_name in gtar gnutar tar; do - for ac_prog in $gnutar_name -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 + # Extract the first word of "umount", so it can be a program name with args. +set dummy umount; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GNUTAR+set}" = set; then +if ${ac_cv_path_UMOUNT+:} false; then : $as_echo_n "(cached) " >&6 else - case $GNUTAR in + case $UMOUNT in [\\/]* | ?:[\\/]*) - ac_cv_path_GNUTAR="$GNUTAR" # Let the user override the test with a path. + ac_cv_path_UMOUNT="$UMOUNT" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -41558,290 +27792,177 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GNUTAR="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_UMOUNT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS + test -z "$ac_cv_path_UMOUNT" && ac_cv_path_UMOUNT="umount" ;; esac fi -GNUTAR=$ac_cv_path_GNUTAR -if test -n "$GNUTAR"; then - { $as_echo "$as_me:$LINENO: result: $GNUTAR" >&5 -$as_echo "$GNUTAR" >&6; } +UMOUNT=$ac_cv_path_UMOUNT +if test -n "$UMOUNT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UMOUNT" >&5 +$as_echo "$UMOUNT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$GNUTAR" && break -done - - if test -n "$GNUTAR"; then - case `"$GNUTAR" --version 2>&1` in - *GNU*tar* | *Free*paxutils* ) - # OK, it is GNU tar - break - ;; - *) - if test -n "$OLD_GNUTAR"; then - - { $as_echo "$as_me:$LINENO: WARNING: $GNUTAR is not GNU tar, it will be used." >&5 -$as_echo "$as_me: WARNING: $GNUTAR is not GNU tar, it will be used." >&2;} - - - cat <>config.warnings -$GNUTAR is not GNU tar, it will be used. -AAW_EOF - - else - # warning.. - { $as_echo "$as_me:$LINENO: WARNING: $GNUTAR is not GNU tar, so it will not be used." >&5 -$as_echo "$as_me: WARNING: $GNUTAR is not GNU tar, so it will not be used." >&2;} - cat <>config.warnings -$GNUTAR is not GNU tar, so it will not be used. -AAW_EOF + # 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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_UNAME+:} false; 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 $LOCSYSPATH +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:${as_lineno-$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:${as_lineno-$LINENO}: result: $UNAME" >&5 +$as_echo "$UNAME" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - # reset the cache for GNUTAR so AC_PATH_PROGS will search again - GNUTAR='' - unset ac_cv_path_GNUTAR - fi - ;; - esac - fi - done - fi - if test "x$GNUTAR" != "x"; then - # define unquoted cat >>confdefs.h <<_ACEOF -#define GNUTAR "$GNUTAR" +#define UNAME_PATH "$UNAME" _ACEOF - fi - - - - - - - # call with - -# Check whether --with-star was given. -if test "${with_star+set}" = set; then - withval=$with_star; - # check withval - case "$withval" in - /*) STAR="$withval";; - y|ye|yes) :;; - n|no) STAR=no ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must supply a full pathname to --with-star" >&5 -$as_echo "$as_me: error: *** You must supply a full pathname to --with-star" >&2;} - { (exit 1); exit 1; }; };; - esac - # done -fi - if test "x$STAR" = "xno"; then - STAR= - else - OLD_STAR=$STAR - for ac_prog in star + for ac_prog in lpr lp 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_STAR+set}" = set; then +if ${ac_cv_path_LPR+:} false; then : $as_echo_n "(cached) " >&6 else - case $STAR in + case $LPR in [\\/]* | ?:[\\/]*) - ac_cv_path_STAR="$STAR" # Let the user override the test with a path. + ac_cv_path_LPR="$LPR" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH +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 + 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_STAR="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_LPR="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -STAR=$ac_cv_path_STAR -if test -n "$STAR"; then - { $as_echo "$as_me:$LINENO: result: $STAR" >&5 -$as_echo "$STAR" >&6; } +LPR=$ac_cv_path_LPR +if test -n "$LPR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LPR" >&5 +$as_echo "$LPR" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$STAR" && break + test -n "$LPR" && break done - if test -n "$STAR"; then - case `"$STAR" --version 2>/dev/null` in - *star*) - # OK, it is star - break - ;; - *) - if test -n "$OLD_STAR"; then + if test ! -z "$LPR"; then - { $as_echo "$as_me:$LINENO: WARNING: $STAR is not star, it will be used." >&5 -$as_echo "$as_me: WARNING: $STAR is not star, it will be used." >&2;} +$as_echo "#define HAVE_LPR_CMD 1" >>confdefs.h - cat <>config.warnings -$STAR is not star, it will be used. -AAW_EOF + { $as_echo "$as_me:${as_lineno-$LINENO}: checking which flag to use to select a printer" >&5 +$as_echo_n "checking which flag to use to select a printer... " >&6; } +if ${amanda_cv_printer_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + amanda_cv_printer_flag=$LPRFLAG + case "$LPR" in + lpr|*/lpr) amanda_cv_printer_flag="-P";; + lp|*/lp) amanda_cv_printer_flag="-d";; + esac - else - # warning.. +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_printer_flag" >&5 +$as_echo "$amanda_cv_printer_flag" >&6; } + if test -z "$amanda_cv_printer_flag"; then - { $as_echo "$as_me:$LINENO: WARNING: $STAR is not star, so it will not be used." >&5 -$as_echo "$as_me: WARNING: $STAR is not star, so it will not be used." >&2;} + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: WARNING: amanda will always print to the default printer" >&5 +$as_echo "$as_me: WARNING: WARNING: amanda will always print to the default printer" >&2;} cat <>config.warnings -$STAR is not star, so it will not be used. +WARNING: amanda will always print to the default printer AAW_EOF - # reset the cache for STAR so AC_PATH_PROGS will search again - STAR='' - unset ac_cv_path_STAR - fi - ;; - esac fi fi - if test "x$STAR" != "x"; then - # define unquoted - -cat >>confdefs.h <<_ACEOF -#define STAR "$STAR" -_ACEOF - - fi - - - - - - - # call with - -# Check whether --with-suntar was given. -if test "${with_suntar+set}" = set; then - withval=$with_suntar; - # check withval - case "$withval" in - /*) SUNTAR="$withval";; - y|ye|yes) :;; - n|no) SUNTAR=no ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must supply a full pathname to --with-suntar" >&5 -$as_echo "$as_me: error: *** You must supply a full pathname to --with-suntar" >&2;} - { (exit 1); exit 1; }; };; - esac - # done - -else - - if test "x$SUNTAR" == "x"; then - SUNTAR="/usr/sbin/tar" - fi - - -fi - - - if test "x$SUNTAR" = "xno"; then - SUNTAR= - fi - - if test "x$SUNTAR" != "x"; then - # define unquoted - -cat >>confdefs.h <<_ACEOF -#define SUNTAR "$SUNTAR" -_ACEOF - - fi - - - - - - - -# Check whether --with-smbclient was given. -if test "${with_smbclient+set}" = set; then - withval=$with_smbclient; - case "$withval" in - /*) SAMBA_CLIENT="$withval";; - y|ye|yes) :;; - n|no) SAMBA_CLIENT=no ;; - *) { { $as_echo "$as_me:$LINENO: error: *** You must supply a full pathname to --with-smbclient" >&5 -$as_echo "$as_me: error: *** You must supply a full pathname to --with-smbclient" >&2;} - { (exit 1); exit 1; }; };; - esac - - -fi - -# Check whether --with-samba-user was given. -if test "${with_samba_user+set}" = set; then - withval=$with_samba_user; { { $as_echo "$as_me:$LINENO: error: --with-samba-user is no longer supported; place username in 'amandapass'" >&5 -$as_echo "$as_me: error: --with-samba-user is no longer supported; place username in 'amandapass'" >&2;} - { (exit 1); exit 1; }; } -fi - if test "x$SAMBA_CLIENT" != "xno"; then - # Extract the first word of "smbclient", so it can be a program name with args. -set dummy smbclient; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + # Extract the first word of "pcat", so it can be a program name with args. +set dummy pcat; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_SAMBA_CLIENT+set}" = set; then +if ${ac_cv_path_PCAT+:} false; then : $as_echo_n "(cached) " >&6 else - case $SAMBA_CLIENT in + case $PCAT in [\\/]* | ?:[\\/]*) - ac_cv_path_SAMBA_CLIENT="$SAMBA_CLIENT" # Let the user override the test with a path. + ac_cv_path_PCAT="$PCAT" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -41849,129 +27970,44 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_SAMBA_CLIENT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_PCAT="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -SAMBA_CLIENT=$ac_cv_path_SAMBA_CLIENT -if test -n "$SAMBA_CLIENT"; then - { $as_echo "$as_me:$LINENO: result: $SAMBA_CLIENT" >&5 -$as_echo "$SAMBA_CLIENT" >&6; } +PCAT=$ac_cv_path_PCAT +if test -n "$PCAT"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PCAT" >&5 +$as_echo "$PCAT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - smbversion=0 - if test ! -z "$SAMBA_CLIENT"; then - case `"$SAMBA_CLIENT" '\\\\nosuchhost.amanda.org\\notashare' -U nosuchuser -N -Tx /dev/null 2>&1` in - *"Unknown host"*) - smbversion=1 - ;; - *"Connection to nosuchhost.amanda.org failed"*) - smbversion=2 - ;; - *) - - { $as_echo "$as_me:$LINENO: WARNING: $SAMBA_CLIENT does not seem to be smbclient, so it will not be used." >&5 -$as_echo "$as_me: WARNING: $SAMBA_CLIENT does not seem to be smbclient, so it will not be used." >&2;} - - - cat <>config.warnings -$SAMBA_CLIENT does not seem to be smbclient, so it will not be used. -AAW_EOF - - - SAMBA_CLIENT= - ;; - esac - if test -n "$SAMBA_CLIENT"; then - -cat >>confdefs.h <<_ACEOF -#define SAMBA_CLIENT "$SAMBA_CLIENT" -_ACEOF - - -cat >>confdefs.h <<_ACEOF -#define SAMBA_VERSION $smbversion -_ACEOF - - fi - fi - fi - - if test -n "$SAMBA_CLIENT"; then - WANT_SAMBA_TRUE= - WANT_SAMBA_FALSE='#' -else - WANT_SAMBA_TRUE='#' - WANT_SAMBA_FALSE= -fi - - - - USE_RUNDUMP=no - - # some systems require rundump unconditionally - case "$host" in - *-ultrix*) USE_RUNDUMP=yes ;; - *-dg-*) USE_RUNDUMP=yes ;; - esac - - -# Check whether --with-rundump was given. -if test "${with_rundump+set}" = set; then - withval=$with_rundump; - case "$withval" in - n | no) USE_RUNDUMP=no ;; - y | ye | yes) USE_RUNDUMP=yes ;; - *) { { $as_echo "$as_me:$LINENO: error: You must not supply an argument to --with-rundump option." >&5 -$as_echo "$as_me: error: You must not supply an argument to --with-rundump option." >&2;} - { (exit 1); exit 1; }; };; - esac - -fi - - - if test x"$USE_RUNDUMP" = x"yes"; then - USE_RUNDUMP=1 - -cat >>confdefs.h <<\_ACEOF -#define USE_RUNDUMP 1 -_ACEOF - - else - USE_RUNDUMP= - fi - - - -# -# Look for other programs Amanda will use -# - # Extract the first word of "grep", so it can be a program name with args. -set dummy grep; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + for ac_prog in perl5 perl +do + # Extract the first word of "$ac_prog", so it can be a program name with args. +set dummy $ac_prog; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then +if ${ac_cv_path_PERL+:} false; then : $as_echo_n "(cached) " >&6 else - case $GREP in + case $PERL in [\\/]* | ?:[\\/]*) - ac_cv_path_GREP="$GREP" # Let the user override the test with a path. + ac_cv_path_PERL="$PERL" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -41979,547 +28015,377 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GREP="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS - test -z "$ac_cv_path_GREP" && ac_cv_path_GREP="grep" ;; esac fi -GREP=$ac_cv_path_GREP -if test -n "$GREP"; then - { $as_echo "$as_me:$LINENO: result: $GREP" >&5 -$as_echo "$GREP" >&6; } +PERL=$ac_cv_path_PERL +if test -n "$PERL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +$as_echo "$PERL" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - -cat >>confdefs.h <<_ACEOF -#define GREP "$GREP" -_ACEOF + test -n "$PERL" && break +done -{ $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 + # Make sure we have perl +if test -z "$PERL"; then +# Extract the first word of "perl", so it can be a program name with args. +set dummy perl; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_PERL+:} false; 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 + if test -n "$PERL"; then + ac_cv_prog_PERL="$PERL" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_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 + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_PERL="perl" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done IFS=$as_save_IFS - if test -z "$ac_cv_path_EGREP"; then - { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 -$as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} - { (exit 1); exit 1; }; } - fi + +fi +fi +PERL=$ac_cv_prog_PERL +if test -n "$PERL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 +$as_echo "$PERL" >&6; } else - ac_cv_path_EGREP=$EGREP + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } 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" +fi +# Check if version of Perl is sufficient +ac_perl_version="5.6.0" +if test "x$PERL" != "x"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perl version greater than or equal to $ac_perl_version" >&5 +$as_echo_n "checking for perl version greater than or equal to $ac_perl_version... " >&6; } + # NB: It would be nice to log the error if there is one, but we cannot rely + # on autoconf internals + $PERL -e "use $ac_perl_version;" > /dev/null 2>&1 + if test $? -ne 0; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; }; + as_fn_error $? "Amanda requires at least perl 5.6.0" "$LINENO" 5 + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 +$as_echo "ok" >&6; }; - # Extract the first word of "lint", so it can be a program name with args. -set dummy lint; 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_AMLINT+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $AMLINT in - [\\/]* | ?:[\\/]*) - ac_cv_path_AMLINT="$AMLINT" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -as_dummy="/opt/SUNWspro/bin:$SYSLOCPATH" -for as_dir in $as_dummy -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_path_AMLINT="$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 -AMLINT=$ac_cv_path_AMLINT -if test -n "$AMLINT"; then - { $as_echo "$as_me:$LINENO: result: $AMLINT" >&5 -$as_echo "$AMLINT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not find perl" >&5 +$as_echo "$as_me: WARNING: could not find perl" >&2;} fi - if test ! -z "$AMLINT"; then - $AMLINT -flags 2>&1 | $GREP -- '-errfmt=' > /dev/null - if test $? -eq 0; then - AMLINTFLAGS="-n -s -u -m -x" - AMLINTFLAGS="$AMLINTFLAGS -errchk=%all" - AMLINTFLAGS="$AMLINTFLAGS -errfmt=macro" - AMLINTFLAGS="$AMLINTFLAGS -errhdr=no%/usr/include" - AMLINTFLAGS="$AMLINTFLAGS -errhdr=%user" - AMLINTFLAGS="$AMLINTFLAGS -errsecurity=extended" - AMLINTFLAGS="$AMLINTFLAGS -errtags=yes" - AMLINTFLAGS="$AMLINTFLAGS -Ncheck=%all" - AMLINTFLAGS="$AMLINTFLAGS -Nlevel=2" - AMLINTFLAGS="$AMLINTFLAGS -erroff=E_ASGN_NEVER_USED" - AMLINTFLAGS="$AMLINTFLAGS,E_ASGN_RESET" - AMLINTFLAGS="$AMLINTFLAGS,E_CAST_INT_CONST_TO_SMALL_INT" - AMLINTFLAGS="$AMLINTFLAGS,E_CAST_INT_TO_SMALL_INT" - AMLINTFLAGS="$AMLINTFLAGS,E_CAST_UINT_TO_SIGNED_INT" - AMLINTFLAGS="$AMLINTFLAGS,E_CONSTANT_CONDITION" - AMLINTFLAGS="$AMLINTFLAGS,E_ENUM_UNUSE" - AMLINTFLAGS="$AMLINTFLAGS,E_EXPR_NULL_EFFECT" - AMLINTFLAGS="$AMLINTFLAGS,E_FUNC_RET_ALWAYS_IGNOR" - AMLINTFLAGS="$AMLINTFLAGS,E_FUNC_RET_MAYBE_IGNORED" - AMLINTFLAGS="$AMLINTFLAGS,E_H_C_CHECK0" - AMLINTFLAGS="$AMLINTFLAGS,E_H_C_CHECK1" - AMLINTFLAGS="$AMLINTFLAGS,E_H_C_CHECK2" - AMLINTFLAGS="$AMLINTFLAGS,E_INCL_MNUSD" - AMLINTFLAGS="$AMLINTFLAGS,E_INCL_NUSD" - AMLINTFLAGS="$AMLINTFLAGS,E_MCR_NODIFF" - AMLINTFLAGS="$AMLINTFLAGS,E_NAME_MULTIPLY_DEF" - AMLINTFLAGS="$AMLINTFLAGS,E_P_REF_NULL_PSBL" - AMLINTFLAGS="$AMLINTFLAGS,E_P_REF_SUSP" - AMLINTFLAGS="$AMLINTFLAGS,E_PTRDIFF_OVERFLOW" - AMLINTFLAGS="$AMLINTFLAGS,E_P_USE_NULL_PSBL" - AMLINTFLAGS="$AMLINTFLAGS,E_P_USE_SUSP" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_ACCESS_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_CHDIR_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_CHMOD_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_CREAT_WITHOUT_EXCL" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_EXEC_PATH" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_EXEC_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_FOPEN_MODE" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_GETENV_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_MKDIR_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_PRINTF_VAR_FMT" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_RAND_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_SCANF_VAR_FMT" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_SELECT_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_SHELL_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_STRNCPY_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_UMASK_WARN" - AMLINTFLAGS="$AMLINTFLAGS,E_SEC_USE_AFTER_STAT" - AMLINTFLAGS="$AMLINTFLAGS,E_SIGN_EXTENSION_PSBL" - AMLINTFLAGS="$AMLINTFLAGS,E_TYPEDEF_UNUSE" - AMLINTFLAGS="$AMLINTFLAGS,E_UNCAL_F" - else - AMLINTFLAGS="" - fi - else - # Extract the first word of "splint", so it can be a program name with args. -set dummy splint; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + + + for ac_prog in swig +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_AMLINT+set}" = set; then +if ${ac_cv_path_SWIG+:} false; then : $as_echo_n "(cached) " >&6 else - case $AMLINT in + case $SWIG in [\\/]* | ?:[\\/]*) - ac_cv_path_AMLINT="$AMLINT" # Let the user override the test with a path. + ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH +for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_AMLINT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -AMLINT=$ac_cv_path_AMLINT -if test -n "$AMLINT"; then - { $as_echo "$as_me:$LINENO: result: $AMLINT" >&5 -$as_echo "$AMLINT" >&6; } +SWIG=$ac_cv_path_SWIG +if test -n "$SWIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 +$as_echo "$SWIG" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - if test ! -z "$AMLINT"; then - AMLINT="splint" - AMLINTFLAGS='+show-scan +unixlib -weak -globs +usedef +usereleased +impouts -paramimptemp -varuse -warnposix -redef -preproc -fixedformalarray -retval -unrecog -usevarargs -formatcode' - else - AMLINT='echo "Error: LINT is not installed" ; false' - AMLINTFLAGS='' - fi - fi + test -n "$SWIG" && break +done -for ac_prog in flex lex -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 + # 1.3.32 introduces a change in the way empty strings are handled (old versions + # returned undef in Perl, while new versions return an empty Perl string) + # 1.3.39 is required for the %begin block + + # Extract the first word of "swig", so it can be a program name with args. +set dummy swig; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_LEX+set}" = set; then +if ${ac_cv_path_SWIG+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$LEX"; then - ac_cv_prog_LEX="$LEX" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR + case $SWIG in + [\\/]* | ?:[\\/]*) + ac_cv_path_SWIG="$SWIG" # 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 + 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_LEX="$ac_prog" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_SWIG="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS + ;; +esac fi -fi -LEX=$ac_cv_prog_LEX -if test -n "$LEX"; then - { $as_echo "$as_me:$LINENO: result: $LEX" >&5 -$as_echo "$LEX" >&6; } +SWIG=$ac_cv_path_SWIG +if test -n "$SWIG"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SWIG" >&5 +$as_echo "$SWIG" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$LEX" && break -done -test -n "$LEX" || LEX=":" - -if test "x$LEX" != "x:"; then - cat >conftest.l <<_ACEOF -%% -a { ECHO; } -b { REJECT; } -c { yymore (); } -d { yyless (1); } -e { yyless (input () != 0); } -f { unput (yytext[0]); } -. { BEGIN INITIAL; } -%% -#ifdef YYTEXT_POINTER -extern char *yytext; -#endif -int -main (void) -{ - return ! yylex () + ! yywrap (); -} -_ACEOF -{ (ac_try="$LEX conftest.l" -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 "$LEX conftest.l") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } -{ $as_echo "$as_me:$LINENO: checking lex output file root" >&5 -$as_echo_n "checking lex output file root... " >&6; } -if test "${ac_cv_prog_lex_root+set}" = set; then - $as_echo_n "(cached) " >&6 -else - -if test -f lex.yy.c; then - ac_cv_prog_lex_root=lex.yy -elif test -f lexyy.c; then - ac_cv_prog_lex_root=lexyy -else - { { $as_echo "$as_me:$LINENO: error: cannot find output from $LEX; giving up" >&5 -$as_echo "$as_me: error: cannot find output from $LEX; giving up" >&2;} - { (exit 1); exit 1; }; } -fi -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_lex_root" >&5 -$as_echo "$ac_cv_prog_lex_root" >&6; } -LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root - -if test -z "${LEXLIB+set}"; then - { $as_echo "$as_me:$LINENO: checking lex library" >&5 -$as_echo_n "checking lex library... " >&6; } -if test "${ac_cv_lib_lex+set}" = set; then - $as_echo_n "(cached) " >&6 -else - - ac_save_LIBS=$LIBS - ac_cv_lib_lex='none needed' - for ac_lib in '' -lfl -ll; do - LIBS="$ac_lib $ac_save_LIBS" - cat >conftest.$ac_ext <<_ACEOF -`cat $LEX_OUTPUT_ROOT.c` -_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_lex=$ac_lib -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - + if test -z "$SWIG" ; then + SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false' + elif test -n "1.3.39" ; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SWIG version" >&5 +$as_echo_n "checking for SWIG version... " >&6; } + swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'` + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $swig_version" >&5 +$as_echo "$swig_version" >&6; } + if test -n "$swig_version" ; then -fi + # Used to indicate true or false condition + ax_compare_version=false -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext - test "$ac_cv_lib_lex" != 'none needed' && break - done - LIBS=$ac_save_LIBS + # Convert the two version strings to be compared into a format that + # allows a simple string comparison. The end result is that a version + # string of the form 1.12.5-r617 will be converted to the form + # 0001001200050617. In other words, each number is zero padded to four + # digits, and non digits are removed. -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_lex" >&5 -$as_echo "$ac_cv_lib_lex" >&6; } - test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex -fi + ax_compare_version_A=`echo "$swig_version" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ + -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/[^0-9]//g'` -{ $as_echo "$as_me:$LINENO: checking whether yytext is a pointer" >&5 -$as_echo_n "checking whether yytext is a pointer... " >&6; } -if test "${ac_cv_prog_lex_yytext_pointer+set}" = set; then - $as_echo_n "(cached) " >&6 -else - # POSIX says lex can declare yytext either as a pointer or an array; the -# default is implementation-dependent. Figure out which it is, since -# not all implementations provide the %pointer and %array declarations. -ac_cv_prog_lex_yytext_pointer=no -ac_save_LIBS=$LIBS -LIBS="$LEXLIB $ac_save_LIBS" -cat >conftest.$ac_ext <<_ACEOF -#define YYTEXT_POINTER 1 -`cat $LEX_OUTPUT_ROOT.c` -_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_prog_lex_yytext_pointer=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + ax_compare_version_B=`echo "1.3.39" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ + -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ + -e 's/[^0-9]//g'` -fi + ax_compare_version=`echo "x$ax_compare_version_A +x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"` -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -LIBS=$ac_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_lex_yytext_pointer" >&5 -$as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; } -if test $ac_cv_prog_lex_yytext_pointer = yes; then -cat >>confdefs.h <<\_ACEOF -#define YYTEXT_POINTER 1 -_ACEOF + if test "$ax_compare_version" = "true" ; then -fi -rm -f conftest.l $LEX_OUTPUT_ROOT.c + SWIG_LIB=`$SWIG -swiglib` -fi -if test "$LEX" = :; then - LEX=${am_missing_run}flex -fi + else + SWIG='echo "Error: SWIG version >= 1.3.39 is required. You have '"$swig_version"'. You should look at http://www.swig.org" ; false' + fi + else + SWIG='echo "Error: Cannot determine SWIG version. You should look at http://www.swig.org" ; false' + fi + fi - if test x"$LEX" != x""; then - { $as_echo "$as_me:$LINENO: checking whether lex is broken Solaris (SGU) lex" >&5 -$as_echo_n "checking whether lex is broken Solaris (SGU) lex... " >&6; } - $LEX -V < /dev/null >/dev/null 2>conftest.out - if grep SGU conftest.out >/dev/null; then - { $as_echo "$as_me:$LINENO: result: yes - disabled (set LEX=/path/to/lex to use a specific binary)" >&5 -$as_echo "yes - disabled (set LEX=/path/to/lex to use a specific binary)" >&6; } - LEX='echo no lex equivalent available; false' - else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - rm conftest.out - fi - # 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 + # Extract the first word of "ps", so it can be a program name with args. +set dummy ps; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_AR+set}" = set; then +if ${ac_cv_path_PS+:} false; then : $as_echo_n "(cached) " >&6 else - case $AR in + case $PS in [\\/]* | ?:[\\/]*) - ac_cv_path_AR="$AR" # Let the user override the test with a path. + ac_cv_path_PS="$PS" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH +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 + 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_AR="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_PS="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -AR=$ac_cv_path_AR -if test -n "$AR"; then - { $as_echo "$as_me:$LINENO: result: $AR" >&5 -$as_echo "$AR" >&6; } +PS=$ac_cv_path_PS +if test -n "$PS"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PS" >&5 +$as_echo "$PS" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking ps argument to use" >&5 +$as_echo_n "checking ps argument to use... " >&6; } + PS_ARGUMENT= + # ps is *very* non-portable, and across many systems, the same option + # (e.g., -e) can mean different things. So this macro tries to + # special-case most known systems, and makes an effort to detect unknown + # systems + case "$host" in + *-*-solaris*) + PS_ARGUMENT="-eo pid,ppid,comm" + PS_ARGUMENT_ARGS="-eo pid,ppid,comm" + ;; + *-*-linux-*) + PS_ARGUMENT="-eo pid,ppid,command" + PS_ARGUMENT_ARGS="-eo pid,ppid,command" + ;; - # Extract the first word of "gettext", so it can be a program name with args. -set dummy gettext; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 + *-*-*bsd*) + PS_ARGUMENT="-axo pid,ppid,command" + PS_ARGUMENT_ARGS="-axo pid,ppid,command" + ;; + + *-apple-darwin*) + PS_ARGUMENT="-aAco pid,ppid,command" + PS_ARGUMENT_ARGS="-aAo pid,ppid,command" + ;; + + *-pc-cygwin) + # Cygwin is special-cased in Amanda::Process + PS_ARGUMENT=CYGWIN + PS_ARGUMENT_ARGS="-ef" + ;; + + *-*-hpux*) + # HPUX's 'PS' needs the env var UNIX95 to run in "xpg4" mode + PS="UNIX95=1 $PS" + PS_ARGUMENT="-eo pid,ppid,comm" + PS_ARGUMENT_ARGS="-eo pid,ppid,comm" + ;; + + *) + for try in \ + "-axo pid,ppid,command" \ + "-aAco pid,ppid,command" \ + "-eo pid,ppid,comm" + do + ps $try >/dev/null 2>/dev/null + if test $? -eq 0; then + PS_ARGUMENT="$try" + break + fi + done + for try in \ + "-axo pid,ppid,command" \ + "-aAo pid,ppid,command" \ + "-eo pid,ppid,comm" + do + ps $try >/dev/null 2>/dev/null + if test $? -eq 0; then + PS_ARGUMENT_ARGS="$try" + break + fi + done + if test -z "$PS_ARGUMENT" -o -z "$PS_ARGUMENT_ARGS"; then + as_fn_error $? "Can't find ps argument to use." "$LINENO" 5 + fi + ;; + esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PS_ARGUMENT" >&5 +$as_echo "$PS_ARGUMENT" >&6; } + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PS_ARGUMENT_ARGS" >&5 +$as_echo "$PS_ARGUMENT_ARGS" >&6; } + + + + + # Extract the first word of "rpcgen", so it can be a program name with args. +set dummy rpcgen; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_GETTEXT+set}" = set; then +if ${ac_cv_path_RPCGEN+:} false; then : $as_echo_n "(cached) " >&6 else - case $GETTEXT in + case $RPCGEN in [\\/]* | ?:[\\/]*) - ac_cv_path_GETTEXT="$GETTEXT" # Let the user override the test with a path. + ac_cv_path_RPCGEN="$RPCGEN" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -42527,2194 +28393,2103 @@ for as_dir in $LOCSYSPATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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_GETTEXT="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + ac_cv_path_RPCGEN="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; esac fi -GETTEXT=$ac_cv_path_GETTEXT -if test -n "$GETTEXT"; then - { $as_echo "$as_me:$LINENO: result: $GETTEXT" >&5 -$as_echo "$GETTEXT" >&6; } +RPCGEN=$ac_cv_path_RPCGEN +if test -n "$RPCGEN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RPCGEN" >&5 +$as_echo "$RPCGEN" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } 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 -{ $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 +# +# Compiler / system characteristics +# -for ac_prog in 'bison -y' byacc -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_YACC+set}" = set; then +# +# compiler +# +if test $ac_cv_c_compiler_gnu = yes; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 +$as_echo_n "checking whether $CC needs -traditional... " >&6; } +if ${ac_cv_prog_gcc_traditional+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$YACC"; then - ac_cv_prog_YACC="$YACC" # 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_YACC="$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 -YACC=$ac_cv_prog_YACC -if test -n "$YACC"; then - { $as_echo "$as_me:$LINENO: result: $YACC" >&5 -$as_echo "$YACC" >&6; } + ac_pattern="Autoconf.*'x'" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TIOCGETP +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + ac_cv_prog_gcc_traditional=no fi +rm -f conftest* - test -n "$YACC" && break -done -test -n "$YACC" || YACC="yacc" - -{ $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 - + if test $ac_cv_prog_gcc_traditional = no; then + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +Autoconf TCGETA +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "$ac_pattern" >/dev/null 2>&1; then : + ac_cv_prog_gcc_traditional=yes fi +rm -f conftest* - 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; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 +$as_echo "$ac_cv_prog_gcc_traditional" >&6; } + if test $ac_cv_prog_gcc_traditional = yes; then + CC="$CC -traditional" + fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 +$as_echo_n "checking for an ANSI C-conforming const... " >&6; } +if ${ac_cv_c_const+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int +main () +{ +/* FIXME: Include the comments suggested by Paul. */ +#ifndef __cplusplus + /* Ultrix mips cc rejects this. */ + typedef int charset[2]; + const charset cs; + /* SunOS 4.1.1 cc rejects this. */ + char const *const *pcpcc; + char **ppc; + /* NEC SVR4.0.2 mips cc rejects this. */ + struct point {int x, y;}; + static struct point const zero = {0,0}; + /* AIX XL C 1.02.0.0 rejects this. + It does not let you subtract one const X* pointer from another in + an arm of an if-expression whose if-part is not a constant + expression */ + const char *g = "string"; + pcpcc = &g + (g ? g-g : 0); + /* HPUX 7.0 cc rejects these. */ + ++pcpcc; + ppc = (char**) pcpcc; + pcpcc = (char const *const *) ppc; + { /* SCO 3.2v4 cc rejects this. */ + char *t; + char const *s = 0 ? (char *) 0 : (char const *) 0; + *t++ = 0; + if (s) return 0; + } + { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ + int x[] = {25, 17}; + const int *foo = &x[0]; + ++foo; + } + { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ + typedef const int *iptr; + iptr p = 0; + ++p; + } + { /* AIX XL C 1.02.0.0 rejects this saying + "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ + struct s { int j; const int *ap[3]; }; + struct s *b; b->j = 5; + } + { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ + const int foo = 10; + if (!foo) return 0; + } + return !cs[0] && !zero.x; +#endif - # Extract the first word of "dd", so it can be a program name with args. -set dummy dd; 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_DD+set}" = set; then - $as_echo_n "(cached) " >&6 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_const=yes else - case $DD in - [\\/]* | ?:[\\/]*) - ac_cv_path_DD="$DD" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_DD="$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 + ac_cv_c_const=no fi -DD=$ac_cv_path_DD -if test -n "$DD"; then - { $as_echo "$as_me:$LINENO: result: $DD" >&5 -$as_echo "$DD" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 +$as_echo "$ac_cv_c_const" >&6; } +if test $ac_cv_c_const = no; then +$as_echo "#define const /**/" >>confdefs.h +fi - - - # Extract the first word of "bash", so it can be a program name with args. -set dummy bash; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_BASH+set}" = set; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 +$as_echo_n "checking whether byte ordering is bigendian... " >&6; } +if ${ac_cv_c_bigendian+:} false; then : $as_echo_n "(cached) " >&6 else - case $BASH in - [\\/]* | ?:[\\/]*) - ac_cv_path_BASH="$BASH" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSPATH -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_BASH="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 - break 2 - fi -done -done -IFS=$as_save_IFS - - ;; -esac -fi -BASH=$ac_cv_path_BASH -if test -n "$BASH"; then - { $as_echo "$as_me:$LINENO: result: $BASH" >&5 -$as_echo "$BASH" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - + ac_cv_c_bigendian=unknown + # See if we're dealing with a universal compiler. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#ifndef __APPLE_CC__ + not a universal capable compiler + #endif + typedef int dummy; +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # Check for potential -arch flags. It is not universal unless + # there are at least two -arch flags with different values. + ac_arch= + ac_prev= + for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do + if test -n "$ac_prev"; then + case $ac_word in + i?86 | x86_64 | ppc | ppc64) + if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then + ac_arch=$ac_word + else + ac_cv_c_bigendian=universal + break + fi + ;; + esac + ac_prev= + elif test "x$ac_word" = "x-arch"; then + ac_prev=arch + fi + done +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + if test $ac_cv_c_bigendian = unknown; then + # See if sys/param.h defines the BYTE_ORDER macro. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include +int +main () +{ +#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ + && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ + && LITTLE_ENDIAN) + bogus endian macros + #endif + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include + #include +int +main () +{ +#if BYTE_ORDER != BIG_ENDIAN + not big endian + #endif - # Extract the first word of "sort", so it can be a program name with args. -set dummy sort; 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_SORT+set}" = set; then - $as_echo_n "(cached) " >&6 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes else - case $SORT in - [\\/]* | ?:[\\/]*) - ac_cv_path_SORT="$SORT" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_SORT="$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_SORT" && ac_cv_path_SORT="NONE" - ;; -esac + ac_cv_c_bigendian=no fi -SORT=$ac_cv_path_SORT -if test -n "$SORT"; then - { $as_echo "$as_me:$LINENO: result: $SORT" >&5 -$as_echo "$SORT" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi - - - - # sort is only needed in the server build - if test x"$SORT" = x"NONE" && $WANT_SERVER; then - { { $as_echo "$as_me:$LINENO: error: Set SORT to the path of the sort program." >&5 -$as_echo "$as_me: error: Set SORT to the path of the sort program." >&2;} - { (exit 1); exit 1; }; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi + if test $ac_cv_c_bigendian = unknown; then + # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) + bogus endian macros + #endif -cat >>confdefs.h <<_ACEOF -#define SORT_PATH "$SORT" + ; + return 0; +} _ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + # It does; now see whether it defined to _BIG_ENDIAN or not. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include +int +main () +{ +#ifndef _BIG_ENDIAN + not big endian + #endif - - - for ac_prog in Mail mailx mail -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_MAILER+set}" = set; then - $as_echo_n "(cached) " >&6 + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_bigendian=yes else - case $MAILER in - [\\/]* | ?:[\\/]*) - ac_cv_path_MAILER="$MAILER" # 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_MAILER="$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 + ac_cv_c_bigendian=no fi -MAILER=$ac_cv_path_MAILER -if test -n "$MAILER"; then - { $as_echo "$as_me:$LINENO: result: $MAILER" >&5 -$as_echo "$MAILER" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi + if test $ac_cv_c_bigendian = unknown; then + # Compile a test program. + if test "$cross_compiling" = yes; then : + # Try to guess by grepping values from an object file. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +short int ascii_mm[] = + { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; + short int ascii_ii[] = + { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; + int use_ascii (int i) { + return ascii_mm[i] + ascii_ii[i]; + } + short int ebcdic_ii[] = + { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; + short int ebcdic_mm[] = + { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; + int use_ebcdic (int i) { + return ebcdic_mm[i] + ebcdic_ii[i]; + } + extern int foo; +int +main () +{ +return use_ascii (foo) == use_ebcdic (foo); + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then + ac_cv_c_bigendian=yes + fi + if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then + if test "$ac_cv_c_bigendian" = unknown; then + ac_cv_c_bigendian=no + else + # finding both strings is unlikely to happen, but who knows? + ac_cv_c_bigendian=unknown + fi + fi +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ - test -n "$MAILER" && break -done -test -n "$MAILER" || MAILER="NONE" - - if test x"$MAILER" = x"NONE"; then - - { $as_echo "$as_me:$LINENO: WARNING: WARNING: Amanda cannot send mail reports without a mailer." >&5 -$as_echo "$as_me: WARNING: WARNING: Amanda cannot send mail reports without a mailer." >&2;} - - - cat <>config.warnings -WARNING: Amanda cannot send mail reports without a mailer. -AAW_EOF + /* Are we little or big endian? From Harbison&Steele. */ + union + { + long int l; + char c[sizeof (long int)]; + } u; + u.l = 1; + return u.c[sizeof (long int) - 1] == 1; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_bigendian=no +else + ac_cv_c_bigendian=yes +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - DEFAULT_MAILER="" - else - DEFAULT_MAILER="$MAILER" fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 +$as_echo "$ac_cv_c_bigendian" >&6; } + case $ac_cv_c_bigendian in #( + yes) + $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h +;; #( + no) + ;; #( + universal) -cat >>confdefs.h <<_ACEOF -#define DEFAULT_MAILER "$DEFAULT_MAILER" -_ACEOF +$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h + ;; #( + *) + as_fn_error $? "unknown endianness + presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; + esac +# GCC_COMPILER is needed in the gnulib Makefile to silence errors + if test "x$GCC" = "xyes"; then + GCC_COMPILER_TRUE= + GCC_COMPILER_FALSE='#' +else + GCC_COMPILER_TRUE='#' + GCC_COMPILER_FALSE= +fi - # Extract the first word of "mt", so it can be a program name with args. -set dummy mt; 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_MT+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $MT in - [\\/]* | ?:[\\/]*) - ac_cv_path_MT="$MT" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $SYSLOCPATH -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_MT="$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 +# +# Warnings +# - test -z "$ac_cv_path_MT" && ac_cv_path_MT="mt" - ;; -esac -fi -MT=$ac_cv_path_MT -if test -n "$MT"; then - { $as_echo "$as_me:$LINENO: result: $MT" >&5 -$as_echo "$MT" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - case "$host" in - *-hp-*) MT_FILE_FLAG="-t" ;; - *) MT_FILE_FLAG="-f" ;; - esac + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wparentheses" >&5 +$as_echo_n "checking for gcc flag -Wparentheses... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wparentheses[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wparentheses" -cat >>confdefs.h <<_ACEOF -#define MT_FILE_FLAG "$MT_FILE_FLAG" -_ACEOF + else + : + fi - # Extract the first word of "mtx", so it can be a program name with args. -set dummy mtx; 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_MTX+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $MTX in - [\\/]* | ?:[\\/]*) - ac_cv_path_MTX="$MTX" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_MTX="$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_MTX" && ac_cv_path_MTX="mtx" - ;; -esac -fi -MTX=$ac_cv_path_MTX -if test -n "$MTX"; then - { $as_echo "$as_me:$LINENO: result: $MTX" >&5 -$as_echo "$MTX" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wdeclaration-after-statement" >&5 +$as_echo_n "checking for gcc flag -Wdeclaration-after-statement... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wdeclaration-after-statement[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } -fi + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wdeclaration-after-statement" + else + : + fi + - # Extract the first word of "mount", so it can be a program name with args. -set dummy mount; 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_MOUNT+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $MOUNT in - [\\/]* | ?:[\\/]*) - ac_cv_path_MOUNT="$MOUNT" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_MOUNT="$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_MOUNT" && ac_cv_path_MOUNT="mount" - ;; -esac -fi -MOUNT=$ac_cv_path_MOUNT -if test -n "$MOUNT"; then - { $as_echo "$as_me:$LINENO: result: $MOUNT" >&5 -$as_echo "$MOUNT" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wmissing-prototypes" >&5 +$as_echo_n "checking for gcc flag -Wmissing-prototypes... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wmissing-prototypes[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wmissing-prototypes" + else + : + fi - # Extract the first word of "umount", so it can be a program name with args. -set dummy umount; 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_UMOUNT+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $UMOUNT in - [\\/]* | ?:[\\/]*) - ac_cv_path_UMOUNT="$UMOUNT" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_UMOUNT="$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_UMOUNT" && ac_cv_path_UMOUNT="umount" - ;; -esac -fi -UMOUNT=$ac_cv_path_UMOUNT -if test -n "$UMOUNT"; then - { $as_echo "$as_me:$LINENO: result: $UMOUNT" >&5 -$as_echo "$UMOUNT" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wstrict-prototypes" >&5 +$as_echo_n "checking for gcc flag -Wstrict-prototypes... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wstrict-prototypes[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wstrict-prototypes" + else + : + fi - for ac_prog in lpr lp -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_LPR+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $LPR in - [\\/]* | ?:[\\/]*) - ac_cv_path_LPR="$LPR" # 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_LPR="$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 -LPR=$ac_cv_path_LPR -if test -n "$LPR"; then - { $as_echo "$as_me:$LINENO: result: $LPR" >&5 -$as_echo "$LPR" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - test -n "$LPR" && break -done - if test ! -z "$LPR"; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_LPR_CMD 1 -_ACEOF + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wmissing-declarations" >&5 +$as_echo_n "checking for gcc flag -Wmissing-declarations... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wmissing-declarations[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wmissing-declarations" - { $as_echo "$as_me:$LINENO: checking which flag to use to select a printer" >&5 -$as_echo_n "checking which flag to use to select a printer... " >&6; } -if test "${amanda_cv_printer_flag+set}" = set; then - $as_echo_n "(cached) " >&6 -else - amanda_cv_printer_flag=$LPRFLAG - case "$LPR" in - lpr|*/lpr) amanda_cv_printer_flag="-P";; - lp|*/lp) amanda_cv_printer_flag="-d";; - esac + else + : + fi -fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_printer_flag" >&5 -$as_echo "$amanda_cv_printer_flag" >&6; } - if test -z "$amanda_cv_printer_flag"; then - { $as_echo "$as_me:$LINENO: WARNING: WARNING: amanda will always print to the default printer" >&5 -$as_echo "$as_me: WARNING: WARNING: amanda will always print to the default printer" >&2;} - cat <>config.warnings -WARNING: amanda will always print to the default printer -AAW_EOF + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wformat" >&5 +$as_echo_n "checking for gcc flag -Wformat... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wformat[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wformat" + else + : + fi - # Extract the first word of "pcat", so it can be a program name with args. -set dummy pcat; 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_PCAT+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $PCAT in - [\\/]* | ?:[\\/]*) - ac_cv_path_PCAT="$PCAT" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_PCAT="$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 -PCAT=$ac_cv_path_PCAT -if test -n "$PCAT"; then - { $as_echo "$as_me:$LINENO: result: $PCAT" >&5 -$as_echo "$PCAT" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wformat-security" >&5 +$as_echo_n "checking for gcc flag -Wformat-security... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wformat-security[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } -fi + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wformat-security" + else + : + fi - for ac_prog in perl5 perl -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PERL+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $PERL in - [\\/]* | ?:[\\/]*) - ac_cv_path_PERL="$PERL" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_PERL="$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 -PERL=$ac_cv_path_PERL -if test -n "$PERL"; then - { $as_echo "$as_me:$LINENO: result: $PERL" >&5 -$as_echo "$PERL" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi - test -n "$PERL" && break -done + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wsign-compare" >&5 +$as_echo_n "checking for gcc flag -Wsign-compare... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wsign-compare[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi - # Make sure we have perl -if test -z "$PERL"; then -# Extract the first word of "perl", so it can be a program name with args. -set dummy perl; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_PERL+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test -n "$PERL"; then - ac_cv_prog_PERL="$PERL" # Let the user override the test. -else -as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $PATH -do - IFS=$as_save_IFS - test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do - if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then - ac_cv_prog_PERL="perl" - $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 x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wsign-compare" -fi -fi -PERL=$ac_cv_prog_PERL -if test -n "$PERL"; then - { $as_echo "$as_me:$LINENO: result: $PERL" >&5 -$as_echo "$PERL" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } -fi + else + : + fi -fi -# Check if version of Perl is sufficient -ac_perl_version="5.6.0" -if test "x$PERL" != "x"; then - { $as_echo "$as_me:$LINENO: checking for perl version greater than or equal to $ac_perl_version" >&5 -$as_echo_n "checking for perl version greater than or equal to $ac_perl_version... " >&6; } - # NB: It would be nice to log the error if there is one, but we cannot rely - # on autoconf internals - $PERL -e "use $ac_perl_version;" > /dev/null 2>&1 - if test $? -ne 0; then - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; }; - { { $as_echo "$as_me:$LINENO: error: Amanda requires at least perl 5.6.0" >&5 -$as_echo "$as_me: error: Amanda requires at least perl 5.6.0" >&2;} - { (exit 1); exit 1; }; } - else - { $as_echo "$as_me:$LINENO: result: ok" >&5 -$as_echo "ok" >&6; }; - fi -else - { $as_echo "$as_me:$LINENO: WARNING: could not find perl" >&5 -$as_echo "$as_me: WARNING: could not find perl" >&2;} -fi + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wfloat-equal" >&5 +$as_echo_n "checking for gcc flag -Wfloat-equal... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wfloat-equal[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wfloat-equal" + else + : + fi - for ac_prog in swig -do - # Extract the first word of "$ac_prog", so it can be a program name with args. -set dummy $ac_prog; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 -$as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_SWIG+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $SWIG in - [\\/]* | ?:[\\/]*) - ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path. - ;; - *) - as_save_IFS=$IFS; IFS=$PATH_SEPARATOR -for as_dir in $LOCSYSPATH -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_SWIG="$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 -SWIG=$ac_cv_path_SWIG -if test -n "$SWIG"; then - { $as_echo "$as_me:$LINENO: result: $SWIG" >&5 -$as_echo "$SWIG" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wold-style-definition" >&5 +$as_echo_n "checking for gcc flag -Wold-style-definition... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wold-style-definition[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } -fi + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wold-style-definition" - test -n "$SWIG" && break -done + else + : + fi - # 1.3.32 introduces a change in the way empty strings are handled (old versions - # returned undef in Perl, while new versions return an empty Perl string) - # 1.3.39 is required for the %begin block - # Extract the first word of "swig", so it can be a program name with args. -set dummy swig; 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_SWIG+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $SWIG in - [\\/]* | ?:[\\/]*) - ac_cv_path_SWIG="$SWIG" # 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_SWIG="$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 for -W'warning', then add the 'no-' version. - ;; -esac -fi -SWIG=$ac_cv_path_SWIG -if test -n "$SWIG"; then - { $as_echo "$as_me:$LINENO: result: $SWIG" >&5 -$as_echo "$SWIG" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wstrict-aliasing" >&5 +$as_echo_n "checking for gcc flag -Wstrict-aliasing... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wstrict-aliasing[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } -fi + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wno-strict-aliasing" - if test -z "$SWIG" ; then - SWIG='echo "Error: SWIG is not installed. You should look at http://www.swig.org" ; false' - elif test -n "1.3.39" ; then - { $as_echo "$as_me:$LINENO: checking for SWIG version" >&5 -$as_echo_n "checking for SWIG version... " >&6; } - swig_version=`$SWIG -version 2>&1 | grep 'SWIG Version' | sed 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/\1/g'` - { $as_echo "$as_me:$LINENO: result: $swig_version" >&5 -$as_echo "$swig_version" >&6; } - if test -n "$swig_version" ; then - # Used to indicate true or false condition - ax_compare_version=false + else + : + fi - # Convert the two version strings to be compared into a format that - # allows a simple string comparison. The end result is that a version - # string of the form 1.12.5-r617 will be converted to the form - # 0001001200050617. In other words, each number is zero padded to four - # digits, and non digits are removed. - ax_compare_version_A=`echo "$swig_version" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ - -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/[^0-9]//g'` + # test for -W'warning', then add the 'no-' version. - ax_compare_version_B=`echo "1.3.39" | sed -e 's/\([0-9]*\)/Z\1Z/g' \ - -e 's/Z\([0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/Z\([0-9][0-9][0-9]\)Z/Z0\1Z/g' \ - -e 's/[^0-9]//g'` - ax_compare_version=`echo "x$ax_compare_version_A -x$ax_compare_version_B" | sed 's/^ *//' | sort -r | sed "s/x${ax_compare_version_A}/true/;s/x${ax_compare_version_B}/false/;1q"` + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Wunknown-pragmas" >&5 +$as_echo_n "checking for gcc flag -Wunknown-pragmas... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Wunknown-pragmas[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wno-unknown-pragmas" - if test "$ax_compare_version" = "true" ; then + else + : + fi + + + + # Check whether --enable-werror was given. +if test "${enable_werror+set}" = set; then : + enableval=$enable_werror; + case "$enableval" in + "" | y | ye | yes) + + + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc flag -Werror" >&5 +$as_echo_n "checking for gcc flag -Werror... " >&6; } + if test "x$GCC" = "xyes"; then + (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || + $CC -v --help 2>&1) | + $EGREP -- '[^[:alnum:]]-Werror[^[:alnum:]-]' 2>&1 > /dev/null + if test $? -eq 0; then + found_warning=yes + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + else + found_warning=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (not using gcc)" >&5 +$as_echo "no (not using gcc)" >&6; } + fi + + if test x"$found_warning" = x"yes"; then + AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Werror" - SWIG_LIB=`$SWIG -swiglib` else - SWIG='echo "Error: SWIG version >= 1.3.39 is required. You have '"$swig_version"'. You should look at http://www.swig.org" ; false' + : + fi - fi - else - SWIG='echo "Error: Cannot determine SWIG version. You should look at http://www.swig.org" ; false' - fi - fi + ;; + esac +fi - # Extract the first word of "ps", so it can be a program name with args. -set dummy ps; 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_PS+set}" = set; then - $as_echo_n "(cached) " >&6 -else - case $PS in - [\\/]* | ?:[\\/]*) - ac_cv_path_PS="$PS" # 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_PS="$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 + # Check whether --enable-swig-error was given. +if test "${enable_swig_error+set}" = set; then : + enableval=$enable_swig_error; + case "$enableval" in + "" | y | ye | yes) + AMANDA_SWIG_PERL_CFLAGS=-Werror + ;; + *n | no) + AMANDA_SWIG_PERL_CFLAGS= + ;; + esac - ;; -esac fi -PS=$ac_cv_path_PS -if test -n "$PS"; then - { $as_echo "$as_me:$LINENO: result: $PS" >&5 -$as_echo "$PS" >&6; } -else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + + + + +# +# Libtool +# +case `pwd` in + *\ * | *\ *) + { $as_echo "$as_me:${as_lineno-$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.4' +macro_revision='1.3293' + + + + + + + + + + + + + +ltmain="$ac_aux_dir/ltmain.sh" + +# Backslashify 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' + +ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO +ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 +$as_echo_n "checking how to print strings... " >&6; } +# Test print first, because it will be a builtin if present. +if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ + test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='print -r --' +elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then + ECHO='printf %s\n' +else + # Use this function as a fallback that always works. + func_fallback_echo () + { + eval 'cat <<_LTECHO_EOF +$1 +_LTECHO_EOF' + } + ECHO='func_fallback_echo' fi +# func_echo_all arg... +# Invoke $ECHO with all args, space-separated. +func_echo_all () +{ + $ECHO "" +} - { $as_echo "$as_me:$LINENO: checking ps argument to use" >&5 -$as_echo_n "checking ps argument to use... " >&6; } - PS_ARGUMENT= +case "$ECHO" in + printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 +$as_echo "printf" >&6; } ;; + print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 +$as_echo "print -r" >&6; } ;; + *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 +$as_echo "cat" >&6; } ;; +esac - # ps is *very* non-portable, and across many systems, the same option - # (e.g., -e) can mean different things. So this macro tries to - # special-case most known systems, and makes an effort to detect unknown - # systems - case "$host" in - *-*-solaris*) - PS_ARGUMENT="-eo pid,ppid,comm" - PS_ARGUMENT_ARGS="-eo pid,ppid,comm" - ;; - *-*-linux-*) - PS_ARGUMENT="-eo pid,ppid,command" - PS_ARGUMENT_ARGS="-eo pid,ppid,command" - ;; - *-*-*bsd*) - PS_ARGUMENT="-axo pid,ppid,command" - PS_ARGUMENT_ARGS="-axo pid,ppid,command" - ;; - *-apple-darwin*) - PS_ARGUMENT="-aAco pid,ppid,command" - PS_ARGUMENT_ARGS="-aAo pid,ppid,command" - ;; - *-pc-cygwin) - # Cygwin is special-cased in Amanda::Process - PS_ARGUMENT=CYGWIN - PS_ARGUMENT_ARGS="-ef" - ;; - *-*-hpux*) - # HPUX's 'PS' needs the env var UNIX95 to run in "xpg4" mode - PS="UNIX95=1 $PS" - PS_ARGUMENT="-eo pid,ppid,comm" - PS_ARGUMENT_ARGS="-eo pid,ppid,comm" - ;; - *) - for try in \ - "-axo pid,ppid,command" \ - "-aAco pid,ppid,command" \ - "-eo pid,ppid,comm" - do - ps $try >/dev/null 2>/dev/null - if test $? -eq 0; then - PS_ARGUMENT="$try" - break - fi - done - for try in \ - "-axo pid,ppid,command" \ - "-aAo pid,ppid,command" \ - "-eo pid,ppid,comm" - do - ps $try >/dev/null 2>/dev/null - if test $? -eq 0; then - PS_ARGUMENT_ARGS="$try" - break - fi - done - if test -z "$PS_ARGUMENT" -o -z "$PS_ARGUMENT_ARGS"; then - { { $as_echo "$as_me:$LINENO: error: Can't find ps argument to use." >&5 -$as_echo "$as_me: error: Can't find ps argument to use." >&2;} - { (exit 1); exit 1; }; } - fi - ;; - esac - { $as_echo "$as_me:$LINENO: result: $PS_ARGUMENT" >&5 -$as_echo "$PS_ARGUMENT" >&6; } - { $as_echo "$as_me:$LINENO: result: $PS_ARGUMENT_ARGS" >&5 -$as_echo "$PS_ARGUMENT_ARGS" >&6; } - # Extract the first word of "rpcgen", so it can be a program name with args. -set dummy rpcgen; 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_RPCGEN+set}" = set; then + +{ $as_echo "$as_me:${as_lineno-$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 ${ac_cv_path_SED+:} false; then : $as_echo_n "(cached) " >&6 else - case $RPCGEN in - [\\/]* | ?:[\\/]*) - ac_cv_path_RPCGEN="$RPCGEN" # Let the user override the test with a path. - ;; - *) + 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 + { ac_script=; unset 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 $LOCSYSPATH +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_RPCGEN="$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 - - ;; + 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 + as_fn_arith $ac_count + 1 && ac_count=$as_val + 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 -fi -RPCGEN=$ac_cv_path_RPCGEN -if test -n "$RPCGEN"; then - { $as_echo "$as_me:$LINENO: result: $RPCGEN" >&5 -$as_echo "$RPCGEN" >&6; } + + $ac_path_SED_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_SED"; then + as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 + fi else - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } + ac_cv_path_SED=$SED fi +fi +{ $as_echo "$as_me:${as_lineno-$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//" -# -# Compiler / system characteristics -# -# -# compiler -# -if test $ac_cv_c_compiler_gnu = yes; then - { $as_echo "$as_me:$LINENO: checking whether $CC needs -traditional" >&5 -$as_echo_n "checking whether $CC needs -traditional... " >&6; } -if test "${ac_cv_prog_gcc_traditional+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_pattern="Autoconf.*'x'" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -Autoconf TIOCGETP -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "$ac_pattern" >/dev/null 2>&1; then - ac_cv_prog_gcc_traditional=yes -else - ac_cv_prog_gcc_traditional=no -fi -rm -f conftest* - if test $ac_cv_prog_gcc_traditional = no; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -Autoconf TCGETA -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "$ac_pattern" >/dev/null 2>&1; then - ac_cv_prog_gcc_traditional=yes -fi -rm -f conftest* - fi -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gcc_traditional" >&5 -$as_echo "$ac_cv_prog_gcc_traditional" >&6; } - if test $ac_cv_prog_gcc_traditional = yes; then - CC="$CC -traditional" - fi -fi -{ $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5 -$as_echo_n "checking for an ANSI C-conforming const... " >&6; } -if test "${ac_cv_c_const+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 () -{ -/* FIXME: Include the comments suggested by Paul. */ -#ifndef __cplusplus - /* Ultrix mips cc rejects this. */ - typedef int charset[2]; - const charset cs; - /* SunOS 4.1.1 cc rejects this. */ - char const *const *pcpcc; - char **ppc; - /* NEC SVR4.0.2 mips cc rejects this. */ - struct point {int x, y;}; - static struct point const zero = {0,0}; - /* AIX XL C 1.02.0.0 rejects this. - It does not let you subtract one const X* pointer from another in - an arm of an if-expression whose if-part is not a constant - expression */ - const char *g = "string"; - pcpcc = &g + (g ? g-g : 0); - /* HPUX 7.0 cc rejects these. */ - ++pcpcc; - ppc = (char**) pcpcc; - pcpcc = (char const *const *) ppc; - { /* SCO 3.2v4 cc rejects this. */ - char *t; - char const *s = 0 ? (char *) 0 : (char const *) 0; - *t++ = 0; - if (s) return 0; - } - { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ - int x[] = {25, 17}; - const int *foo = &x[0]; - ++foo; - } - { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ - typedef const int *iptr; - iptr p = 0; - ++p; - } - { /* AIX XL C 1.02.0.0 rejects this saying - "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ - struct s { int j; const int *ap[3]; }; - struct s *b; b->j = 5; - } - { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ - const int foo = 10; - if (!foo) return 0; - } - return !cs[0] && !zero.x; -#endif - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_const=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 +$as_echo_n "checking for fgrep... " >&6; } +if ${ac_cv_path_FGREP+:} false; then : + $as_echo_n "(cached) " >&6 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + 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 + as_fn_arith $ac_count + 1 && ac_count=$as_val + 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_cv_c_const=no + $ac_path_FGREP_found && break 3 + done + done + done +IFS=$as_save_IFS + if test -z "$ac_cv_path_FGREP"; then + as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 + fi +else + ac_cv_path_FGREP=$FGREP fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5 -$as_echo "$ac_cv_c_const" >&6; } -if test $ac_cv_c_const = no; then - -cat >>confdefs.h <<\_ACEOF -#define const /**/ -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 +$as_echo "$ac_cv_path_FGREP" >&6; } + FGREP="$ac_cv_path_FGREP" -fi +test -z "$GREP" && GREP=grep - { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5 -$as_echo_n "checking whether byte ordering is bigendian... " >&6; } -if test "${ac_cv_c_bigendian+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_c_bigendian=unknown - # See if we're dealing with a universal compiler. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#ifndef __APPLE_CC__ - not a universal capable compiler - #endif - typedef int dummy; -_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 - # Check for potential -arch flags. It is not universal unless - # there are some -arch flags. Note that *ppc* also matches - # ppc64. This check is also rather less than ideal. - case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in #( - *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;; - esac -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 - if test $ac_cv_c_bigendian = unknown; then - # See if sys/param.h defines the BYTE_ORDER macro. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #include -int -main () -{ -#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ - && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ - && LITTLE_ENDIAN) - bogus endian macros - #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 - # It does; now see whether it defined to BIG_ENDIAN or not. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include - #include -int -main () -{ -#if BYTE_ORDER != BIG_ENDIAN - not big endian - #endif - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_bigendian=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_c_bigendian=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - fi - if test $ac_cv_c_bigendian = unknown; then - # See if defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) - bogus endian macros - #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 - # It does; now see whether it defined to _BIG_ENDIAN or not. - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -int -main () -{ -#ifndef _BIG_ENDIAN - not big endian - #endif - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_c_bigendian=yes +# 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 - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_c_bigendian=no + with_gnu_ld=no fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_prog=ld +if test "$GCC" = yes; then + # Check if gcc -print-prog-name=ld gives a path. + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: checking for GNU ld" >&5 +$as_echo_n "checking for GNU ld... " >&6; } else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 +$as_echo_n "checking for non-GNU ld... " >&6; } fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +if ${lt_cv_path_LD+:} false; 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 conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -short int ascii_mm[] = - { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; - short int ascii_ii[] = - { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; - int use_ascii (int i) { - return ascii_mm[i] + ascii_ii[i]; - } - short int ebcdic_ii[] = - { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; - short int ebcdic_mm[] = - { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; - int use_ebcdic (int i) { - return ebcdic_mm[i] + ebcdic_ii[i]; - } - extern int foo; - -int -main () -{ -return use_ascii (foo) == use_ebcdic (foo); - ; - 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 - if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then - ac_cv_c_bigendian=yes - fi - if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then - if test "$ac_cv_c_bigendian" = unknown; then - ac_cv_c_bigendian=no - else - # finding both strings is unlikely to happen, but who knows? - ac_cv_c_bigendian=unknown - fi - fi + done + IFS="$lt_save_ifs" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - + lt_cv_path_LD="$LD" # Let the user override the test with a path. +fi fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ - - /* Are we little or big endian? From Harbison&Steele. */ - union - { - long int l; - char c[sizeof (long int)]; - } u; - u.l = 1; - return u.c[sizeof (long int) - 1] == 1; - - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_c_bigendian=no +LD="$lt_cv_path_LD" +if test -n "$LD"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 +$as_echo "$LD" >&6; } 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_c_bigendian=yes -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - - - fi +test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 +$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } +if ${lt_cv_prog_gnu_ld+:} false; 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 "$ac_cv_c_bigendian" >&6; } - case $ac_cv_c_bigendian in #( - yes) - cat >>confdefs.h <<\_ACEOF -#define WORDS_BIGENDIAN 1 -_ACEOF -;; #( - no) - ;; #( - universal) - -cat >>confdefs.h <<\_ACEOF -#define AC_APPLE_UNIVERSAL_BUILD 1 -_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 +$as_echo "$lt_cv_prog_gnu_ld" >&6; } +with_gnu_ld=$lt_cv_prog_gnu_ld - ;; #( - *) - { { $as_echo "$as_me:$LINENO: error: unknown endianness - presetting ac_cv_c_bigendian=no (or yes) will help" >&5 -$as_echo "$as_me: error: unknown endianness - presetting ac_cv_c_bigendian=no (or yes) will help" >&2;} - { (exit 1); exit 1; }; } ;; - esac -# GCC_COMPILER is needed in the gnulib Makefile to silence errors - if test "x$GCC" = "xyes"; then - GCC_COMPILER_TRUE= - GCC_COMPILER_FALSE='#' -else - GCC_COMPILER_TRUE='#' - GCC_COMPILER_FALSE= -fi -# -# Warnings -# - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wparentheses" >&5 -$as_echo_n "checking for gcc flag -Wparentheses... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wparentheses[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wparentheses" - +{ $as_echo "$as_me:${as_lineno-$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 ${lt_cv_path_NM+:} false; 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:${as_lineno-$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 "$DUMPBIN"; then : + # Let the user override the test. + else + if test -n "$ac_tool_prefix"; then + for ac_prog in dumpbin "link -dump" + 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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DUMPBIN+:} false; 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:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - else - : - fi +fi +fi +DUMPBIN=$ac_cv_prog_DUMPBIN +if test -n "$DUMPBIN"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 +$as_echo "$DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$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 "link -dump" +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; 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:${as_lineno-$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:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 +$as_echo "$ac_ct_DUMPBIN" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + test -n "$ac_ct_DUMPBIN" && break +done - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wdeclaration-after-statement" >&5 -$as_echo_n "checking for gcc flag -Wdeclaration-after-statement... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wdeclaration-after-statement[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi + if test "x$ac_ct_DUMPBIN" = x; then + DUMPBIN=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$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 x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wdeclaration-after-statement" + case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + *COFF*) + DUMPBIN="$DUMPBIN -symbols" + ;; + *) + DUMPBIN=: + ;; + esac + fi + if test "$DUMPBIN" != ":"; then + NM="$DUMPBIN" + fi +fi +test -z "$NM" && NM=nm - else - : - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 +$as_echo_n "checking the name lister ($NM) interface... " >&6; } +if ${lt_cv_nm_interface+:} false; 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:$LINENO: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 + (eval echo "\"\$as_me:$LINENO: 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:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 +$as_echo "$lt_cv_nm_interface" >&6; } - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wmissing-prototypes" >&5 -$as_echo_n "checking for gcc flag -Wmissing-prototypes... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wmissing-prototypes[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 +{ $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wmissing-prototypes" - +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 +$as_echo "no, using $LN_S" >&6; } +fi - else - : - fi +# find the maximum length of command line arguments +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 +$as_echo_n "checking the maximum length of command line arguments... " >&6; } +if ${lt_cv_sys_max_cmd_len+:} false; 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; + ;; + mint*) + # On MiNT this can take a long time and run out of memory. + 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; + ;; - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wstrict-prototypes" >&5 -$as_echo_n "checking for gcc flag -Wstrict-prototypes... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wstrict-prototypes[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi + netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + # This has been around since 386BSD, at least. Likely further. + if test -x /sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` + elif test -x /usr/sbin/sysctl; then + lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } + lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi + # And add a safety zone + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` + lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` + ;; - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wstrict-prototypes" - + 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"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ + = "X$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:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 +$as_echo "$lt_cv_sys_max_cmd_len" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 +$as_echo "none" >&6; } +fi +max_cmd_len=$lt_cv_sys_max_cmd_len - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wmissing-declarations" >&5 -$as_echo_n "checking for gcc flag -Wmissing-declarations... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wmissing-declarations[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wmissing-declarations" - - else - : - fi +: ${CP="cp -f"} +: ${MV="mv -f"} +: ${RM="rm -f"} +{ $as_echo "$as_me:${as_lineno-$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%"$_lt_dummy"}, \ + = c,a/b,b/c, \ + && eval 'test $(( 1 + 1 )) -eq 2 \ + && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ + && xsi_shell=yes +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 +$as_echo "$xsi_shell" >&6; } +{ $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 +$as_echo "$lt_shell_append" >&6; } - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wformat" >&5 -$as_echo_n "checking for gcc flag -Wformat... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wformat[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi +if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then + lt_unset=unset +else + lt_unset=false +fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wformat" - else - : - 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 gcc flag -Wformat-security" >&5 -$as_echo_n "checking for gcc flag -Wformat-security... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wformat-security[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wformat-security" - else - : - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 +$as_echo_n "checking how to convert $build file names to $host format... " >&6; } +if ${lt_cv_to_host_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 + ;; + esac + ;; + *-*-cygwin* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin + ;; + *-*-cygwin* ) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; + * ) # otherwise, assume *nix + lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin + ;; + esac + ;; + * ) # unhandled hosts (and "normal" native builds) + lt_cv_to_host_file_cmd=func_convert_file_noop + ;; +esac +fi +to_host_file_cmd=$lt_cv_to_host_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 +$as_echo "$lt_cv_to_host_file_cmd" >&6; } - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wsign-compare" >&5 -$as_echo_n "checking for gcc flag -Wsign-compare... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wsign-compare[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wsign-compare" - else - : - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 +$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } +if ${lt_cv_to_tool_file_cmd+:} false; then : + $as_echo_n "(cached) " >&6 +else + #assume ordinary cross tools, or native build. +lt_cv_to_tool_file_cmd=func_convert_file_noop +case $host in + *-*-mingw* ) + case $build in + *-*-mingw* ) # actually msys + lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 + ;; + esac + ;; +esac +fi +to_tool_file_cmd=$lt_cv_to_tool_file_cmd +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 +$as_echo "$lt_cv_to_tool_file_cmd" >&6; } - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wfloat-equal" >&5 -$as_echo_n "checking for gcc flag -Wfloat-equal... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wfloat-equal[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wfloat-equal" - +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 +$as_echo_n "checking for $LD option to reload object files... " >&6; } +if ${lt_cv_ld_reload_flag+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_reload_flag='-r' +fi +{ $as_echo "$as_me:${as_lineno-$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 + cygwin* | mingw* | pw32* | cegcc*) + if test "$GCC" != yes; then + reload_cmds=false + fi + ;; + darwin*) + if test "$GCC" = yes; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' else - : + reload_cmds='$LD$reload_flag -o $output$reload_objs' fi + ;; +esac - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wold-style-definition" >&5 -$as_echo_n "checking for gcc flag -Wold-style-definition... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wold-style-definition[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 + + + +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_OBJDUMP+:} false; 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:${as_lineno-$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:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 +$as_echo "$OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi +fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wold-style-definition" +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; 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:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - else - : - fi +fi +fi +ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP +if test -n "$ac_ct_OBJDUMP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 +$as_echo "$ac_ct_OBJDUMP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$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 - # test for -W'warning', then add the 'no-' version. - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wstrict-aliasing" >&5 -$as_echo_n "checking for gcc flag -Wstrict-aliasing... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wstrict-aliasing[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wno-strict-aliasing" - else - : - fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 +$as_echo_n "checking how to recognize dependent libraries... " >&6; } +if ${lt_cv_deplibs_check_method+:} false; 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. - # test for -W'warning', then add the 'no-' version. +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 + ;; - { $as_echo "$as_me:$LINENO: checking for gcc flag -Wunknown-pragmas" >&5 -$as_echo_n "checking for gcc flag -Wunknown-pragmas... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Wunknown-pragmas[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi +cygwin*) + # func_win32_libid is a shell function defined in ltmain.sh + lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' + lt_cv_file_magic_cmd='func_win32_libid' + ;; - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Wno-unknown-pragmas" +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. + # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. + if ( test "$lt_cv_nm_interface" = "BSD nm" && 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 + # Keep this pattern in sync with the one in func_win32_libid. + lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' + 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' + ;; - else - : - fi +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 + ;; - # Check whether --enable-werror was given. -if test "${enable_werror+set}" = set; then - enableval=$enable_werror; - case "$enableval" in - "" | y | ye | yes) +haiku*) + 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])(-bit)?( [LM]SB)? 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 + ;; - { $as_echo "$as_me:$LINENO: checking for gcc flag -Werror" >&5 -$as_echo_n "checking for gcc flag -Werror... " >&6; } - if test "x$GCC" = "xyes"; then - (gcc --help={target,optimizers,warnings,undocumented,params,c} 2>&1 || - $CC -v --help 2>&1) | - $EGREP -- '[^[:alnum:]]-Werror[^[:alnum:]-]' 2>&1 > /dev/null - if test $? -eq 0; then - found_warning=yes - { $as_echo "$as_me:$LINENO: result: yes" >&5 -$as_echo "yes" >&6; } - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no" >&5 -$as_echo "no" >&6; } - fi - else - found_warning=no - { $as_echo "$as_me:$LINENO: result: no (not using gcc)" >&5 -$as_echo "no (not using gcc)" >&6; } - fi +# This must be Linux ELF. +linux* | k*bsd*-gnu | kopensolaris*-gnu) + lt_cv_deplibs_check_method=pass_all + ;; - if test x"$found_warning" = x"yes"; then - AMANDA_WARNING_CFLAGS="$AMANDA_WARNING_CFLAGS -Werror" +netbsd*) + if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' + else + lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' + fi + ;; +newos6*) + lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' + lt_cv_file_magic_cmd=/usr/bin/file + lt_cv_file_magic_test_file=/usr/lib/libnls.so + ;; - else - : - fi +*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 + ;; - ;; - esac +osf3* | osf4* | osf5*) + lt_cv_deplibs_check_method=pass_all + ;; -fi +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 + ;; - # Check whether --enable-swig-error was given. -if test "${enable_swig_error+set}" = set; then - enableval=$enable_swig_error; - case "$enableval" in - "" | y | ye | yes) - AMANDA_SWIG_PERL_CFLAGS=-Werror - ;; - *n | no) - AMANDA_SWIG_PERL_CFLAGS= - ;; - esac +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:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 +$as_echo "$lt_cv_deplibs_check_method" >&6; } +file_magic_glob= +want_nocaseglob=no +if test "$build" = "$host"; then + case $host_os in + mingw* | pw32*) + if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then + want_nocaseglob=yes + else + file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` + fi + ;; + esac fi +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 -# -# Libtool -# -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.4' -macro_revision='1.2976' @@ -44728,162 +30503,103 @@ macro_revision='1.2976' -ltmain="$ac_aux_dir/ltmain.sh" -{ $as_echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5 -$as_echo_n "checking for a sed that does not truncate output... " >&6; } -if test "${ac_cv_path_SED+set}" = set; then + + +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. +set dummy ${ac_tool_prefix}dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_DLLTOOL+:} false; 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 + if test -n "$DLLTOOL"; then + ac_cv_prog_DLLTOOL="$DLLTOOL" # 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_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 + if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then + ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done IFS=$as_save_IFS - if test -z "$ac_cv_path_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//" - - - - - - - - - +fi +DLLTOOL=$ac_cv_prog_DLLTOOL +if test -n "$DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 +$as_echo "$DLLTOOL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi -{ $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 +fi +if test -z "$ac_cv_prog_DLLTOOL"; then + ac_ct_DLLTOOL=$DLLTOOL + # Extract the first word of "dlltool", so it can be a program name with args. +set dummy dlltool; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; 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 + if test -n "$ac_ct_DLLTOOL"; then + ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # 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_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 + 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_DLLTOOL="dlltool" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi done + done IFS=$as_save_IFS - if test -z "$ac_cv_path_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 + +fi +fi +ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL +if test -n "$ac_ct_DLLTOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 +$as_echo "$ac_ct_DLLTOOL" >&6; } else - ac_cv_path_FGREP=$FGREP + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - fi + if test "x$ac_ct_DLLTOOL" = x; then + DLLTOOL="false" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$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 + DLLTOOL=$ac_ct_DLLTOOL + fi +else + DLLTOOL="$ac_cv_prog_DLLTOOL" 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 "$DLLTOOL" && DLLTOOL=dlltool -test -z "$GREP" && GREP=grep @@ -44893,122 +30609,37 @@ 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 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 +$as_echo_n "checking how to associate runtime and link libraries... " >&6; } +if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : + $as_echo_n "(cached) " >&6 else - with_gnu_ld=no -fi + lt_cv_sharedlib_from_linklib_cmd='unknown' -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 +case $host_os in +cygwin* | mingw* | pw32* | cegcc*) + # two different shell functions defined in ltmain.sh + # decide which to use based on capabilities of $DLLTOOL + case `$DLLTOOL --help 2>&1` in + *--identify-strict*) + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) - # If it is relative, then search for the first ld in PATH. - with_gnu_ld=unknown + lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; 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 - +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 +$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } +sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd +test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO @@ -45016,881 +30647,312 @@ 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" +if test -n "$ac_tool_prefix"; then + for ac_prog in ar 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_DUMPBIN+set}" = set; then +if ${ac_cv_prog_AR+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$DUMPBIN"; then - ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. + 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 + 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 + ac_cv_prog_AR="$ac_tool_prefix$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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; } +AR=$ac_cv_prog_AR +if test -n "$AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 +$as_echo "$AR" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$DUMPBIN" && break + test -n "$AR" && break done fi -if test -z "$DUMPBIN"; then - ac_ct_DUMPBIN=$DUMPBIN - for ac_prog in "dumpbin -symbols" "link -dump -symbols" +if test -z "$AR"; then + ac_ct_AR=$AR + for ac_prog in ar 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 "$as_me:${as_lineno-$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 +if ${ac_cv_prog_ac_ct_AR+:} false; 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. + 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 + 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 + ac_cv_prog_ac_ct_AR="$ac_prog" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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; } +ac_ct_AR=$ac_cv_prog_ac_ct_AR +if test -n "$ac_ct_AR"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 +$as_echo "$ac_ct_AR" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$ac_ct_DUMPBIN" && break + test -n "$ac_ct_AR" && break done - if test "x$ac_ct_DUMPBIN" = x; then - DUMPBIN=":" + 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:${as_lineno-$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" + AR=$ac_ct_AR fi fi -test -z "$NM" && NM=nm +: ${AR=ar} +: ${AR_FLAGS=cru} -{ $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:45193: $ac_compile\"" >&5) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&5 - (eval echo "\"\$as_me:45196: $NM \\\"conftest.$ac_objext\\\"\"" >&5) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&5 - (eval echo "\"\$as_me:45199: 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*) - # 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; - ;; +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 +$as_echo_n "checking for archiver @FILE support... " >&6; } +if ${lt_cv_ar_at_file+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ar_at_file=no + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ - 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` - ;; +int +main () +{ - interix*) - # We know the value 262144 and hardcode it with a safety zone (like BSD) - lt_cv_sys_max_cmd_len=196608 - ;; + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + echo conftest.$ac_objext > conftest.lst + lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -eq 0; then + # Ensure the archiver fails upon bogus file names. + rm -f conftest.$ac_objext libconftest.a + { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 + (eval $lt_ar_try) 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + if test "$ac_status" -ne 0; then + lt_cv_ar_at_file=@ + fi + fi + rm -f conftest.* libconftest.a - 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 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 +$as_echo "$lt_cv_ar_at_file" >&6; } -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; } +if test "x$lt_cv_ar_at_file" = xno; then + archiver_list_spec= else - { $as_echo "$as_me:$LINENO: result: none" >&5 -$as_echo "none" >&6; } + archiver_list_spec=$lt_cv_ar_at_file 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 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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_STRIP+:} false; 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:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then - lt_unset=unset +fi +fi +STRIP=$ac_cv_prog_STRIP +if test -n "$STRIP"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 +$as_echo "$STRIP" >&6; } else - lt_unset=false + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_STRIP+:} false; 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:${as_lineno-$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:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 +$as_echo "$ac_ct_STRIP" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +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' - ;; + if test "x$ac_ct_STRIP" = x; then + STRIP=":" + else + case $cross_compiling:$ac_tool_warned in +yes:) +{ $as_echo "$as_me:${as_lineno-$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 - - - - - - - - - -{ $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 + STRIP=$ac_ct_STRIP + fi else - lt_cv_ld_reload_flag='-r' + STRIP="$ac_cv_prog_STRIP" 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 +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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_RANLIB+:} false; 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:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - - -{ $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 - ;; - -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) - lt_cv_deplibs_check_method=pass_all - ;; - -netbsd*) - if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' - else - lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' - fi - ;; - -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 +fi +RANLIB=$ac_cv_prog_RANLIB +if test -n "$RANLIB"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 +$as_echo "$RANLIB" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi fi @@ -45898,9 +30960,9 @@ 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 "$as_me:${as_lineno-$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 +if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_RANLIB"; then @@ -45911,24 +30973,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 $as_echo "$ac_ct_RANLIB" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -45937,7 +30999,7 @@ fi 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:${as_lineno-$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 @@ -45971,6 +31033,18 @@ if test -n "$RANLIB"; then old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi +case $host_os in + darwin*) + lock_old_archive_extraction=yes ;; + *) + lock_old_archive_extraction=no ;; +esac + + + + + + @@ -46015,9 +31089,9 @@ 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 "$as_me:${as_lineno-$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 +if ${lt_cv_sys_global_symbol_pipe+:} false; then : $as_echo_n "(cached) " >&6 else @@ -46035,7 +31109,7 @@ case $host_os in aix*) symcode='[BCDT]' ;; -cygwin* | mingw* | pw32*) +cygwin* | mingw* | pw32* | cegcc*) symcode='[ABCDGISTW]' ;; hpux*) @@ -46078,8 +31152,8 @@ esac 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'" +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= @@ -46115,6 +31189,7 @@ for ac_symprfx in "" "_"; do else lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi + lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no @@ -46133,18 +31208,18 @@ void nm_test_func(void){} int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; 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 + if { { eval echo "\"\$as_me\":${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" @@ -46156,6 +31231,18 @@ _LT_EOF if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext +/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ +#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) +/* DATA imports from DLLs on WIN32 con't be const, because runtime + relocations are performed -- see ld's documentation on pseudo-relocs. */ +# define LT_DLSYM_CONST +#elif defined(__osf__) +/* This system does not cope well with relocations in const data. */ +# define LT_DLSYM_CONST +#else +# define LT_DLSYM_CONST const +#endif + #ifdef __cplusplus extern "C" { #endif @@ -46167,7 +31254,7 @@ _LT_EOF cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ -const struct { +LT_DLSYM_CONST struct { const char *name; void *address; } @@ -46193,19 +31280,19 @@ static const void *lt_preloaded_setup() { _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext - lt_save_LIBS="$LIBS" - lt_save_CFLAGS="$CFLAGS" + lt_globsym_save_LIBS=$LIBS + lt_globsym_save_CFLAGS=$CFLAGS LIBS="conftstm.$ac_objext" CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" - if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && test -s conftest${ac_exeext}; then pipe_works=yes fi - LIBS="$lt_save_LIBS" - CFLAGS="$lt_save_CFLAGS" + LIBS=$lt_globsym_save_LIBS + CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&5 fi @@ -46235,13 +31322,23 @@ 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 "$as_me:${as_lineno-$LINENO}: result: failed" >&5 $as_echo "failed" >&6; } else - { $as_echo "$as_me:$LINENO: result: ok" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 $as_echo "ok" >&6; } fi +# Response file support. +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + nm_file_list_spec='@' +elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then + nm_file_list_spec='@' +fi + + + + @@ -46258,13 +31355,52 @@ fi + + + + + + + +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 +$as_echo_n "checking for sysroot... " >&6; } + +# Check whether --with-sysroot was given. +if test "${with_sysroot+set}" = set; then : + withval=$with_sysroot; +else + with_sysroot=no +fi + + +lt_sysroot= +case ${with_sysroot} in #( + yes) + if test "$GCC" = yes; then + lt_sysroot=`$CC --print-sysroot 2>/dev/null` + fi + ;; #( + /*) + lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` + ;; #( + no|'') + ;; #( + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5 +$as_echo "${with_sysroot}" >&6; } + as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 + ;; +esac + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 +$as_echo "${lt_sysroot:-no}" >&6; } # Check whether --enable-libtool-lock was given. -if test "${enable_libtool_lock+set}" = set; then +if test "${enable_libtool_lock+set}" = set; then : enableval=$enable_libtool_lock; fi @@ -46276,11 +31412,11 @@ 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 + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE="32" @@ -46294,12 +31430,12 @@ ia64-*-hpux*) ;; *-*-irix6*) # Find out which ABI we are using. - echo '#line 46297 "configure"' > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + echo '#line '$LINENO' "configure"' > conftest.$ac_ext + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then if test "$lt_cv_prog_gnu_ld" = yes; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) @@ -46333,11 +31469,11 @@ 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 + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then case `/usr/bin/file conftest.o` in *32-bit*) case $host in @@ -46386,9 +31522,9 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # 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 "$as_me:${as_lineno-$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 +if ${lt_cv_cc_needs_belf+:} false; then : $as_echo_n "(cached) " >&6 else ac_ext=c @@ -46397,11 +31533,7 @@ 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -46412,38 +31544,13 @@ 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 ac_fn_c_try_link "$LINENO"; 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 + 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 +rm -f core 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' @@ -46451,7 +31558,7 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $ ac_compiler_gnu=$ac_cv_c_compiler_gnu fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5 +{ $as_echo "$as_me:${as_lineno-$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 @@ -46461,11 +31568,11 @@ $as_echo "$lt_cv_cc_needs_belf" >&6; } sparc*-*solaris*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then case `/usr/bin/file conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in @@ -46485,135 +31592,252 @@ 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 +if test -n "$ac_tool_prefix"; then + # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. +set dummy ${ac_tool_prefix}mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_DSYMUTIL+set}" = set; then +if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$DSYMUTIL"; then - ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. + if test -n "$MANIFEST_TOOL"; then + ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # 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 + 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 + ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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; } +MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL +if test -n "$MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 +$as_echo "$MANIFEST_TOOL" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$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 +if test -z "$ac_cv_prog_MANIFEST_TOOL"; then + ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL + # Extract the first word of "mt", so it can be a program name with args. +set dummy mt; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then +if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$ac_ct_DSYMUTIL"; then - ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. + if test -n "$ac_ct_MANIFEST_TOOL"; then + ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # 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 + 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 + ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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; } +ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL +if test -n "$ac_ct_MANIFEST_TOOL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 +$as_echo "$ac_ct_MANIFEST_TOOL" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - if test "x$ac_ct_DSYMUTIL" = x; then - DSYMUTIL=":" + if test "x$ac_ct_MANIFEST_TOOL" = x; then + MANIFEST_TOOL=":" 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:${as_lineno-$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 + MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL fi else - DSYMUTIL="$ac_cv_prog_DSYMUTIL" + MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" +fi + +test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 +$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } +if ${lt_cv_path_mainfest_tool+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_path_mainfest_tool=no + echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 + $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out + cat conftest.err >&5 + if $GREP 'Manifest Tool' conftest.out > /dev/null; then + lt_cv_path_mainfest_tool=yes + fi + rm -f conftest* fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 +$as_echo "$lt_cv_path_mainfest_tool" >&6; } +if test "x$lt_cv_path_mainfest_tool" != xyes; then + MANIFEST_TOOL=: +fi + + + + + + case $host_os in + rhapsody* | darwin*) 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 + # 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:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_NMEDIT+set}" = set; then +if ${ac_cv_prog_DSYMUTIL+:} false; then : $as_echo_n "(cached) " >&6 else - if test -n "$NMEDIT"; then - ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. + if test -n "$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 + 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 + ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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; } +DSYMUTIL=$ac_cv_prog_DSYMUTIL +if test -n "$DSYMUTIL"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 +$as_echo "$DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; 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:${as_lineno-$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:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 +$as_echo "$ac_ct_DSYMUTIL" >&6; } +else + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$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:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_NMEDIT+:} false; 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:${as_lineno-$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:${as_lineno-$LINENO}: result: $NMEDIT" >&5 +$as_echo "$NMEDIT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46623,9 +31847,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then +if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_NMEDIT"; then @@ -46636,24 +31860,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 $as_echo "$ac_ct_NMEDIT" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46662,7 +31886,7 @@ fi 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:${as_lineno-$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 @@ -46675,9 +31899,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_LIPO+set}" = set; then +if ${ac_cv_prog_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$LIPO"; then @@ -46688,24 +31912,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 $as_echo "$LIPO" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46715,9 +31939,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_LIPO+set}" = set; then +if ${ac_cv_prog_ac_ct_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_LIPO"; then @@ -46728,24 +31952,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 $as_echo "$ac_ct_LIPO" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46754,7 +31978,7 @@ fi 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:${as_lineno-$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 @@ -46767,9 +31991,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OTOOL+set}" = set; then +if ${ac_cv_prog_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL"; then @@ -46780,24 +32004,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 $as_echo "$OTOOL" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46807,9 +32031,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_OTOOL+set}" = set; then +if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL"; then @@ -46820,24 +32044,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 $as_echo "$ac_ct_OTOOL" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46846,7 +32070,7 @@ fi 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:${as_lineno-$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 @@ -46859,9 +32083,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_OTOOL64+set}" = set; then +if ${ac_cv_prog_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL64"; then @@ -46872,24 +32096,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 $as_echo "$OTOOL64" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46899,9 +32123,9 @@ 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 "$as_me:${as_lineno-$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 +if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL64"; then @@ -46912,24 +32136,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 $as_echo "$ac_ct_OTOOL64" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -46938,7 +32162,7 @@ fi 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:${as_lineno-$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 @@ -46974,9 +32198,9 @@ fi - { $as_echo "$as_me:$LINENO: checking for -single_module linker flag" >&5 + { $as_echo "$as_me:${as_lineno-$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 +if ${lt_cv_apple_cc_single_mod+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_apple_cc_single_mod=no @@ -47001,22 +32225,18 @@ else rm -f conftest.* fi fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5 +{ $as_echo "$as_me:${as_lineno-$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 "$as_me:${as_lineno-$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 +if ${lt_cv_ld_exported_symbols_list+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -47027,43 +32247,50 @@ 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 ac_fn_c_try_link "$LINENO"; 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 + 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 +rm -f core conftest.err conftest.$ac_objext \ + 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 "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 +$as_echo_n "checking for -force_load linker flag... " >&6; } +if ${lt_cv_ld_force_load+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_ld_force_load=no + cat > conftest.c << _LT_EOF +int forced_loaded() { return 2;} +_LT_EOF + echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 + $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 + echo "$AR cru libconftest.a conftest.o" >&5 + $AR cru libconftest.a conftest.o 2>&5 + echo "$RANLIB libconftest.a" >&5 + $RANLIB libconftest.a 2>&5 + cat > conftest.c << _LT_EOF +int main() { return 0;} +_LT_EOF + echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 + $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err + _lt_result=$? + if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then + lt_cv_ld_force_load=yes + else + cat conftest.err >&5 + fi + rm -f conftest.err libconftest.a conftest conftest.c + rm -rf conftest.dSYM + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 +$as_echo "$lt_cv_ld_force_load" >&6; } case $host_os in rhapsody* | darwin1.[012]) _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; @@ -47091,7 +32318,7 @@ $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' fi - if test "$DSYMUTIL" != ":"; then + if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= @@ -47099,62 +32326,13 @@ $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } ;; esac - for ac_header in dlfcn.h -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 -$as_echo_n "checking for $ac_header... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default - -#include <$ac_header> -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - eval "$as_ac_Header=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_Header=no" -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default +" +if test "x$ac_cv_header_dlfcn_h" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +#define HAVE_DLFCN_H 1 _ACEOF fi @@ -47163,6 +32341,8 @@ done + + # Set options @@ -47174,7 +32354,7 @@ done # Check whether --enable-shared was given. -if test "${enable_shared+set}" = set; then +if test "${enable_shared+set}" = set; then : enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; @@ -47205,7 +32385,7 @@ fi # Check whether --enable-static was given. -if test "${enable_static+set}" = set; then +if test "${enable_static+set}" = set; then : enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; @@ -47237,7 +32417,7 @@ fi # Check whether --with-pic was given. -if test "${with_pic+set}" = set; then +if test "${with_pic+set}" = set; then : withval=$with_pic; pic_mode="$withval" else pic_mode=default @@ -47253,7 +32433,7 @@ test -z "$pic_mode" && pic_mode=default # Check whether --enable-fast-install was given. -if test "${enable_fast_install+set}" = set; then +if test "${enable_fast_install+set}" = set; then : enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; @@ -47313,6 +32493,7 @@ LIBTOOL='$(SHELL) $(top_builddir)/libtool' + test -z "$LN_S" && LN_S="ln -s" @@ -47334,9 +32515,9 @@ if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi -{ $as_echo "$as_me:$LINENO: checking for objdir" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 $as_echo_n "checking for objdir... " >&6; } -if test "${lt_cv_objdir+set}" = set; then +if ${lt_cv_objdir+:} false; then : $as_echo_n "(cached) " >&6 else rm -f .libs 2>/dev/null @@ -47349,7 +32530,7 @@ else fi rmdir .libs 2>/dev/null fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 $as_echo "$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir @@ -47364,19 +32545,6 @@ _ACEOF - - - - - - - - - - - - - case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some @@ -47389,23 +32557,6 @@ aix3*) ;; 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 @@ -47434,7 +32585,7 @@ for cc_temp in $compiler""; do *) break;; esac done -cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` +cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` # Only perform the check for file, if the check method requires it @@ -47442,9 +32593,9 @@ 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 "$as_me:${as_lineno-$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 +if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in @@ -47495,10 +32646,10 @@ 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 "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -47508,9 +32659,9 @@ 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 "$as_me:${as_lineno-$LINENO}: checking for file" >&5 $as_echo_n "checking for file... " >&6; } -if test "${lt_cv_path_MAGIC_CMD+set}" = set; then +if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in @@ -47561,10 +32712,10 @@ 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 "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -47643,11 +32794,16 @@ if test -n "$compiler"; then lt_prog_compiler_no_builtin_flag= if test "$GCC" = yes; then - lt_prog_compiler_no_builtin_flag=' -fno-builtin' + case $cc_basename in + nvcc*) + lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; + *) + lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; + esac - { $as_echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 + { $as_echo "$as_me:${as_lineno-$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 +if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_rtti_exceptions=no @@ -47663,15 +32819,15 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:47666: $lt_compile\"" >&5) + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:47670: \$? = $ac_status" >&5 + echo "$as_me:$LINENO: \$? = $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 + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/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 @@ -47680,7 +32836,7 @@ else $RM conftest* fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 +{ $as_echo "$as_me:${as_lineno-$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 @@ -47700,8 +32856,6 @@ fi 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,' @@ -47735,7 +32889,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; } # PIC is the default for these OSes. ;; - mingw* | cygwin* | pw32* | os2*) + 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 @@ -47749,11 +32903,18 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; } lt_prog_compiler_pic='-fno-common' ;; + haiku*) + # PIC is the default for Haiku. + # The "-static" flag exists, but is broken. + lt_prog_compiler_static= + ;; + hpux*) - # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but - # not for PA HP-UX. + # 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*|ia64*) + hppa*64*) # +Z the default ;; *) @@ -47790,6 +32951,13 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; } lt_prog_compiler_pic='-fPIC' ;; esac + + case $cc_basename in + nvcc*) # Cuda Compiler Driver 2.2 + lt_prog_compiler_wl='-Xlinker ' + lt_prog_compiler_pic='-Xcompiler -fPIC' + ;; + esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in @@ -47803,7 +32971,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; } fi ;; - mingw* | cygwin* | pw32* | os2*) + 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' @@ -47831,14 +32999,34 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; } lt_prog_compiler_static='-non_shared' ;; - linux* | k*bsd*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu) case $cc_basename in - icc* | ecc* | ifort*) + # 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' ;; - pgcc* | pgf77* | pgf90* | pgf95*) + # 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' + ;; + nagfor*) + # NAG Fortran compiler + lt_prog_compiler_wl='-Wl,-Wl,,' + lt_prog_compiler_pic='-PIC' + lt_prog_compiler_static='-Bstatic' + ;; + pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl='-Wl,' @@ -47850,25 +33038,25 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; } # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; - xl*) - # IBM XL C 8.0/Fortran 10.1 on PPC + xl* | bgxl* | bgf* | mpixl*) + # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene 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 + *Sun\ F* | *Sun*Fortran*) + # 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='-Wl,' + lt_prog_compiler_wl='' ;; - *Sun\ F*) - # Sun Fortran 8.3 passes all unrecognized flags to the linker + *Sun\ C*) + # Sun C 5.9 lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' - lt_prog_compiler_wl='' + lt_prog_compiler_wl='-Wl,' ;; esac ;; @@ -47900,7 +33088,7 @@ $as_echo_n "checking for $compiler option to produce PIC... " >&6; } lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' case $cc_basename in - f77* | f90* | f95*) + f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) lt_prog_compiler_wl='-Qoption ld ';; *) lt_prog_compiler_wl='-Wl,';; @@ -47957,21 +33145,25 @@ case $host_os in lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" ;; esac -{ $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5 -$as_echo "$lt_prog_compiler_pic" >&6; } - - - - +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 +$as_echo_n "checking for $compiler option to produce PIC... " >&6; } +if ${lt_cv_prog_compiler_pic+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler_pic=$lt_prog_compiler_pic +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 +$as_echo "$lt_cv_prog_compiler_pic" >&6; } +lt_prog_compiler_pic=$lt_cv_prog_compiler_pic # # 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 "$as_me:${as_lineno-$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 +if ${lt_cv_prog_compiler_pic_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_works=no @@ -47987,15 +33179,15 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:47990: $lt_compile\"" >&5) + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 - echo "$as_me:47994: \$? = $ac_status" >&5 + echo "$as_me:$LINENO: \$? = $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 + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/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 @@ -48004,7 +33196,7 @@ else $RM conftest* fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5 +{ $as_echo "$as_me:${as_lineno-$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 @@ -48024,13 +33216,18 @@ 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 "$as_me:${as_lineno-$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 +if ${lt_cv_prog_compiler_static_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_static_works=no @@ -48043,7 +33240,7 @@ else 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 + $ECHO "$_lt_linker_boilerplate" | $SED '/^$/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 @@ -48056,7 +33253,7 @@ else LDFLAGS="$save_LDFLAGS" fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5 +{ $as_echo "$as_me:${as_lineno-$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 @@ -48071,9 +33268,9 @@ fi - { $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 + { $as_echo "$as_me:${as_lineno-$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 +if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no @@ -48092,16 +33289,16 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:48095: $lt_compile\"" >&5) + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:48099: \$? = $ac_status" >&5 + echo "$as_me:$LINENO: \$? = $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 + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/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 @@ -48118,7 +33315,7 @@ else $RM conftest* fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } @@ -48126,9 +33323,9 @@ $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 "$as_me:${as_lineno-$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 +if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no @@ -48147,16 +33344,16 @@ else -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` - (eval echo "\"\$as_me:48150: $lt_compile\"" >&5) + (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 - echo "$as_me:48154: \$? = $ac_status" >&5 + echo "$as_me:$LINENO: \$? = $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 + $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/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 @@ -48173,7 +33370,7 @@ else $RM conftest* fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } @@ -48182,7 +33379,7 @@ $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 "$as_me:${as_lineno-$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* @@ -48190,10 +33387,10 @@ $as_echo_n "checking if we can lock with hard links... " >&6; } 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 "$as_me:${as_lineno-$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:${as_lineno-$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 @@ -48206,7 +33403,7 @@ fi - { $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 + { $as_echo "$as_me:${as_lineno-$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= @@ -48251,7 +33448,7 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie extract_expsyms_cmds= case $host_os in - cygwin* | mingw* | pw32*) + 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++. @@ -48269,7 +33466,33 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie esac ld_shlibs=yes + + # On some targets, GNU ld is compatible enough with the native linker + # that we're better off using the native interface for both. + lt_use_gnu_ld_interface=no if test "$with_gnu_ld" = yes; then + case $host_os in + aix*) + # The AIX port of GNU ld has always aspired to compatibility + # with the native linker. However, as the warning in the GNU ld + # block says, versions before 2.19.5* couldn't really create working + # shared libraries, regardless of the interface used. + case `$LD -v 2>&1` in + *\ \(GNU\ Binutils\)\ 2.19.5*) ;; + *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; + *\ \(GNU\ Binutils\)\ [3-9]*) ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + ;; + *) + lt_use_gnu_ld_interface=yes + ;; + esac + fi + + if test "$lt_use_gnu_ld_interface" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' @@ -48287,6 +33510,7 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie 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 ... @@ -48302,11 +33526,12 @@ $as_echo_n "checking whether the $compiler linker ($LD) supports shared librarie ld_shlibs=no cat <<_LT_EOF 1>&2 -*** Warning: the GNU linker, at least up to release 2.9.1, is reported +*** Warning: the GNU linker, at least up to release 2.19, 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. +*** really care for shared libraries, you may want to install binutils +*** 2.20 or above, or modify your PATH so that a non-GNU linker is found. +*** You will then need to restart the configuration process. _LT_EOF fi @@ -48338,14 +33563,16 @@ _LT_EOF fi ;; - cygwin* | mingw* | pw32*) + 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' + export_dynamic_flag_spec='${wl}--export-all-symbols' 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' + export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' + exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' 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' @@ -48363,6 +33590,11 @@ _LT_EOF fi ;; + haiku*) + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + link_all_deplibs=yes + ;; + interix[3-9]*) hardcode_direct=no hardcode_shlibpath_var=no @@ -48378,7 +33610,7 @@ _LT_EOF 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) + gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test "$host_os" = linux-dietlibc; then case $cc_basename in @@ -48388,15 +33620,16 @@ _LT_EOF if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test "$tmp_diet" = no then - tmp_addflag= + tmp_addflag=' $pic_flag' 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' + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$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' + pgf77* | pgf90* | pgf95* | pgfortran*) + # 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; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; @@ -48404,13 +33637,20 @@ _LT_EOF tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; - xl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) + lf95*) # Lahey Fortran 8.1 + whole_archive_flag_spec= + tmp_sharedflag='--shared' ;; + xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; + nvcc*) # Cuda Compiler Driver 2.2 + whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + compiler_needs_object=yes + ;; 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' + whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' compiler_needs_object=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 @@ -48426,17 +33666,17 @@ _LT_EOF fi case $cc_basename in - xlf*) + xlf* | bgf* | bgxlf* | mpixlf*) # 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' + archive_cmds='$LD -shared $libobjs $deplibs $linker_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' + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac @@ -48450,8 +33690,8 @@ _LT_EOF 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' + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; @@ -48469,8 +33709,8 @@ _LT_EOF _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' + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi @@ -48516,8 +33756,8 @@ _LT_EOF *) 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' + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi @@ -48557,8 +33797,10 @@ _LT_EOF 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 + # Also, AIX nm treats weak defined symbols like other global + # defined symbols, whereas GNU nm marks them as "W". 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' + export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (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 @@ -48635,6 +33877,7 @@ _LT_EOF 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 @@ -48644,11 +33887,13 @@ _LT_EOF 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 + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -48659,54 +33904,34 @@ 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 ac_fn_c_try_link "$LINENO"; 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"` + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_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 "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi fi -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi + aix_libpath=$lt_cv_aix_libpath_ +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" + archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' @@ -48715,11 +33940,13 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 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 + if test "${lt_cv_aix_libpath+set}" = set; then + aix_libpath=$lt_cv_aix_libpath +else + if ${lt_cv_aix_libpath_+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int @@ -48730,59 +33957,44 @@ 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 ac_fn_c_try_link "$LINENO"; 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"` + lt_aix_libpath_sed=' + /Import File Strings/,/^$/ { + /^0/ { + s/^0 *\([^ ]*\) *$/\1/ + p + } + }' + lt_cv_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 "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` + fi fi -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + if test -z "$lt_cv_aix_libpath_"; then + lt_cv_aix_libpath_="/usr/lib:/lib" + fi fi -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi + aix_libpath=$lt_cv_aix_libpath_ +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' + if test "$with_gnu_ld" = yes; then + # We only use this code for GNU lds that support --whole-archive. + whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + else + # Exported symbols can be pulled into shared objects from archives + whole_archive_flag_spec='$convenience' + fi 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' @@ -48809,25 +34021,68 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi export_dynamic_flag_spec=-rdynamic ;; - cygwin* | mingw* | pw32*) + 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 + case $cc_basename in + cl*) + # Native MSVC + hardcode_libdir_flag_spec=' ' + allow_undefined_flag=unsupported + always_export_symbols=yes + file_list_spec='@' + # 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 $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' + archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then + sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; + else + sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' + # The linker will not automatically build a static lib if we build a DLL. + # _LT_TAGVAR(old_archive_from_new_cmds, )='true' + 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' + # Don't use ranlib + old_postinstall_cmds='chmod 644 $oldlib' + postlink_cmds='lt_outputfile="@OUTPUT@"~ + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile="$lt_outputfile.exe" + lt_tool_outputfile="$lt_tool_outputfile.exe" + ;; + esac~ + if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' + ;; + *) + # Assume MSVC wrapper + 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 `func_echo_all "$deplibs" | $SED '\''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' + enable_shared_with_static_runtimes=yes + ;; + esac ;; darwin* | rhapsody*) @@ -48837,11 +34092,19 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported - whole_archive_flag_spec='' + if test "$lt_cv_ld_force_load" = "yes"; then + whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + else + whole_archive_flag_spec='' + fi link_all_deplibs=yes allow_undefined_flag="$_lt_dar_allow_undefined" - if test "$GCC" = "yes"; then - output_verbose_link_cmd=echo + 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=func_echo_all 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}" @@ -48884,7 +34147,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) - archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no @@ -48892,7 +34155,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 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' + archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${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 @@ -48907,8 +34170,8 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi ;; 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' + if test "$GCC" = yes && test "$with_gnu_ld" = no; then + archive_cmds='$CC -shared $pic_flag ${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 @@ -48926,16 +34189,16 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi ;; hpux11*) - if test "$GCC" = yes -a "$with_gnu_ld" = no; then + if test "$GCC" = yes && test "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) - archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + archive_cmds='$CC -shared $pic_flag ${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' + archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else @@ -48947,7 +34210,46 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi 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' + + # Older versions of the 11.00 compiler do not understand -b yet + # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 +$as_echo_n "checking if $CC understands -b... " >&6; } +if ${lt_cv_prog_compiler__b+:} false; then : + $as_echo_n "(cached) " >&6 +else + lt_cv_prog_compiler__b=no + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -b" + 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 "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp + $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 + if diff conftest.exp conftest.er2 >/dev/null; then + lt_cv_prog_compiler__b=yes + fi + else + lt_cv_prog_compiler__b=yes + fi + fi + $RM -r conftest* + LDFLAGS="$save_LDFLAGS" + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 +$as_echo "$lt_cv_prog_compiler__b" >&6; } + +if test x"$lt_cv_prog_compiler__b" = xyes; then + archive_cmds='$CC -b ${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 + ;; esac fi @@ -48975,52 +34277,39 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; 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' + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${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) {} + # This should be the same for all languages, so no per-tag cache variable. + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 +$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } +if ${lt_cv_irix_exported_symbol+:} false; then : + $as_echo_n "(cached) " >&6 +else + save_LDFLAGS="$LDFLAGS" + LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +int foo (void) { 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 - 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' - +if ac_fn_c_try_link "$LINENO"; then : + lt_cv_irix_exported_symbol=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - + lt_cv_irix_exported_symbol=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" +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS="$save_LDFLAGS" +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 +$as_echo "$lt_cv_irix_exported_symbol" >&6; } + if test "$lt_cv_irix_exported_symbol" = yes; then + archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + fi 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' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -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' @@ -49082,17 +34371,17 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ 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' + 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' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${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' + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' @@ -49102,13 +34391,13 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ 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' + archive_cmds='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${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='$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_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-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; 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' + $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' @@ -49121,9 +34410,9 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ 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_cmds='$CC -shared $pic_flag ${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' + $CC -shared $pic_flag ${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"*) @@ -49272,7 +34561,7 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ fi fi -{ $as_echo "$as_me:$LINENO: result: $ld_shlibs" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 $as_echo "$ld_shlibs" >&6; } test "$ld_shlibs" = no && can_build_shared=no @@ -49309,46 +34598,52 @@ x|xyes) # 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 "$as_me:${as_lineno-$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 ${lt_cv_archive_cmds_need_lc+:} false; then : + $as_echo_n "(cached) " >&6 +else + $RM conftest* + echo "$lt_simple_compile_test_code" > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + if { { eval echo "\"\$as_me\":${as_lineno-$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 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } 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\":${as_lineno-$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; } + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } + then + lt_cv_archive_cmds_need_lc=no + else + lt_cv_archive_cmds_need_lc=yes + fi + allow_undefined_flag=$lt_save_allow_undefined_flag + else + cat conftest.err 1>&5 + fi + $RM conftest* + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 +$as_echo "$lt_cv_archive_cmds_need_lc" >&6; } + archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc ;; esac fi @@ -49511,7 +34806,7 @@ esac - { $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 $as_echo_n "checking dynamic linker characteristics... " >&6; } if test "$GCC" = yes; then @@ -49519,16 +34814,23 @@ if test "$GCC" = yes; then 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 + case $host_os in + mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; + *) lt_sed_strip_eq="s,=/,/,g" ;; + esac + lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` + case $lt_search_path_spec in + *\;*) # 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 + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` + ;; + *) + lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` + ;; + esac # 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= @@ -49541,7 +34843,7 @@ if test "$GCC" = yes; then 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 ' + lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS=" "; FS="/|\n";} { lt_foo=""; lt_count=0; @@ -49561,7 +34863,13 @@ BEGIN {RS=" "; FS="/|\n";} { 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` + # AWK program above erroneously prepends '/' to C:/dos/paths + # for these hosts. + case $host_os in + mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ + $SED 's,/\([A-Za-z]:\),\1,g'` ;; + esac + sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi @@ -49649,7 +34957,7 @@ amigaos*) 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' + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''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 ;; @@ -49674,14 +34982,15 @@ bsdi[45]*) # libtool to hard-code these into programs ;; -cygwin* | mingw* | pw32*) +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*) + case $GCC,$cc_basename in + yes,*) + # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ @@ -49702,36 +35011,83 @@ cygwin* | mingw* | pw32*) 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" + + sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" ;; - mingw*) + 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 + dynamic_linker='Win32 ld.exe' + ;; + + *,cl*) + # Native MSVC + libname_spec='$name' + soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' + library_names_spec='${libname}.dll.lib' + + case $build_os in + mingw*) + sys_lib_search_path_spec= + lt_save_ifs=$IFS + IFS=';' + for lt_path in $LIB + do + IFS=$lt_save_ifs + # Let DOS variable expansion print the short 8.3 style file name. + lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` + sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" + done + IFS=$lt_save_ifs + # Convert to MSYS style. + sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` + ;; + cygwin*) + # Convert to unix form, then to dos form, then back to unix form + # but this time dos style (no spaces!) so that the unix form looks + # like /cygdrive/c/PROGRA~1:/cygdr... + sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` + sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` + sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` + ;; + *) + sys_lib_search_path_spec="$LIB" + if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then + # It is most probably a Windows format PATH. + 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 + # FIXME: find the short name or the path components, as spaces are + # common. (e.g. "Program Files" -> "PROGRA~1") + ;; + esac + + # 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 + dynamic_linker='Win32 link.exe' ;; *) + # Assume MSVC wrapper library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' + dynamic_linker='Win32 ld.exe' ;; esac - dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; @@ -49775,14 +35131,7 @@ freebsd* | dragonfly*) *) objformat=elf ;; esac fi - # Handle Gentoo/FreeBSD as it was Linux - case $host_vendor in - gentoo) - version_type=linux ;; - *) - version_type=freebsd-$objformat ;; - esac - + 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}' @@ -49793,12 +35142,6 @@ freebsd* | dragonfly*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; - linux) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - need_lib_prefix=no - need_version=no - ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in @@ -49831,6 +35174,19 @@ gnu*) hardcode_into_libs=yes ;; +haiku*) + version_type=linux + need_lib_prefix=no + need_version=no + dynamic_linker="$host_os runtime_loader" + 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=LIBRARY_PATH + shlibpath_overrides_runpath=yes + sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' + 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. @@ -49873,8 +35229,10 @@ hpux9* | hpux10* | hpux11*) soname_spec='${libname}${release}${shared_ext}$major' ;; esac - # HP-UX runs *really* slowly unless shared libraries are mode 555. + # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' + # or fails outright, so override atomically: + install_override_mode=555 ;; interix[3-9]*) @@ -49932,7 +35290,7 @@ linux*oldld* | linux*aout* | linux*coff*) ;; # This must be Linux ELF. -linux* | k*bsd*-gnu) +linux* | k*bsd*-gnu | kopensolaris*-gnu) version_type=linux need_lib_prefix=no need_version=no @@ -49941,1883 +35299,268 @@ linux* | k*bsd*-gnu) 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' - ;; - -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_name_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*) - 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 50955 "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 - -#ifdef __cplusplus -extern "C" void exit (int); -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - else - puts (dlerror ()); - - exit (status); -} -_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 51055 "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 - -#ifdef __cplusplus -extern "C" void exit (int); -#endif - -void fnord() { int i=42;} -int main () -{ - void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); - int status = $lt_dlunknown; - - if (self) - { - if (dlsym (self,"fnord")) status = $lt_dlno_uscore; - else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; - /* dlclose (self); */ - } - else - puts (dlerror ()); - - exit (status); -} -_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: - - - - - # Check whether --enable-static-binary was given. -if test "${enable_static_binary+set}" = set; then - enableval=$enable_static_binary; - case "$enableval" in - "" | y | ye | yes) - AMANDA_STATIC_LDFLAGS=-static - if test x"$enable_static" = x"no"; then - { { $as_echo "$as_me:$LINENO: error: *** --enable-static-binary is incompatible with --disable-static" >&5 -$as_echo "$as_me: error: *** --enable-static-binary is incompatible with --disable-static" >&2;} - { (exit 1); exit 1; }; } - fi - ;; - *n | no) - AMANDA_STATIC_LDFLAGS= - ;; - esac - -fi - - - - -# -# headers -# - - - - - -ac_header_dirent=no -for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do - as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5 -$as_echo_n "checking for $ac_hdr that defines DIR... " >&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. */ -#include -#include <$ac_hdr> - -int -main () -{ -if ((DIR *) 0) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - 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_hdr" | $as_tr_cpp` 1 -_ACEOF - -ac_header_dirent=$ac_hdr; break -fi - -done -# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. -if test $ac_header_dirent = dirent.h; then - { $as_echo "$as_me:$LINENO: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' dir; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_opendir=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then - : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -fi - -else - { $as_echo "$as_me:$LINENO: checking for library containing opendir" >&5 -$as_echo_n "checking for library containing opendir... " >&6; } -if test "${ac_cv_search_opendir+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_func_search_save_LIBS=$LIBS -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char opendir (); -int -main () -{ -return opendir (); - ; - return 0; -} -_ACEOF -for ac_lib in '' x; do - if test -z "$ac_lib"; then - ac_res="none required" - else - ac_res=-l$ac_lib - LIBS="-l$ac_lib $ac_func_search_save_LIBS" - fi - rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - ac_cv_search_opendir=$ac_res -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext - if test "${ac_cv_search_opendir+set}" = set; then - break -fi -done -if test "${ac_cv_search_opendir+set}" = set; then - : -else - ac_cv_search_opendir=no -fi -rm conftest.$ac_ext -LIBS=$ac_func_search_save_LIBS -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 -$as_echo "$ac_cv_search_opendir" >&6; } -ac_res=$ac_cv_search_opendir -if test "$ac_res" != no; then - test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - -fi - -fi - -{ $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 - -{ $as_echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5 -$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } -if test "${ac_cv_header_time+set}" = set; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include -#include -#include - -int -main () -{ -if ((struct tm *) 0) -return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_cv_header_time=yes + # Some binutils ld are patched to set DT_RUNPATH + if ${lt_cv_shlibpath_overrides_runpath+:} false; then : + $as_echo_n "(cached) " >&6 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + lt_cv_shlibpath_overrides_runpath=no + save_LDFLAGS=$LDFLAGS + save_libdir=$libdir + eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ + LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ - ac_cv_header_time=no + ; + return 0; +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : + lt_cv_shlibpath_overrides_runpath=yes fi +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext + LDFLAGS=$save_LDFLAGS + libdir=$save_libdir -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5 -$as_echo "$ac_cv_header_time" >&6; } -if test $ac_cv_header_time = yes; then -cat >>confdefs.h <<\_ACEOF -#define TIME_WITH_SYS_TIME 1 -_ACEOF + shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath -fi + # 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 + # Add ABI-specific directories to the system library path. + sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" + # 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;s/"//g;/^$/d' | tr '\n' ' '` + sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" + fi + # We used to test for /lib/ld.so.1 and disable shared libraries on + # powerpc, because MkLinux only supported shared libraries with the + # GNU dynamic linker. Since this was broken with cross compilers, + # most powerpc-linux boxes support dynamic linking these days and + # people can always --disable-shared, the test was removed, and we + # assume the GNU/Linux dynamic linker is in use. + dynamic_linker='GNU/Linux ld.so' + ;; +netbsd*) + version_type=sunos + need_lib_prefix=no + need_version=no + if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + dynamic_linker='NetBSD (a.out) ld.so' + else + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + dynamic_linker='NetBSD ld.elf_so' + fi + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + hardcode_into_libs=yes + ;; +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:${as_lineno-$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 @@ -51828,3372 +35571,1432 @@ fi -for ac_header in grp.h \ - libc.h \ - libgen.h \ - limits.h \ - math.h \ - netinet/in.h \ - regex.h \ - stdarg.h \ - stdlib.h \ - strings.h \ - rpc/rpc.h \ - sys/file.h \ - sys/ioctl.h \ - sys/ipc.h \ - sys/mntent.h \ - sys/param.h \ - sys/select.h \ - sys/stat.h \ - sys/shm.h \ - sys/time.h \ - sys/types.h \ - sys/uio.h \ - syslog.h \ - time.h \ - unistd.h \ -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 -$as_echo_n "checking for $ac_header... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -fi -ac_res=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 -$as_echo_n "checking $ac_header usability... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -#include <$ac_header> -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_header_compiler=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_header_compiler=no -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } -# Is the header present? -{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 -$as_echo_n "checking $ac_header presence... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$ac_header> -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - ac_header_preproc=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_header_preproc=no -fi -rm -f conftest.err conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} - ;; -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 -cat >>confdefs.h <<\_ACEOF -#define HAVE_AMANDA_H 1 -_ACEOF -cat >>confdefs.h <<\_ACEOF -#define HAVE_UTIL_H 1 -_ACEOF -cat >>confdefs.h <<\_ACEOF -#define USE_GETTEXT 1 -_ACEOF -# -# Types -# -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of int" >&5 -$as_echo_n "checking size of int... " >&6; } -if test "${ac_cv_sizeof_int+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (int))) >= 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (int))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (int))) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (int))) >= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (int))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr '(' $ac_mid ')' + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_int=$ac_lo;; -'') if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (int) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (int) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_int=0 - fi ;; -esac -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 -static long int longval () { return (long int) (sizeof (int)); } -static unsigned long int ulongval () { return (long int) (sizeof (int)); } -#include -#include -int -main () -{ - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (int))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (int)))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (int)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_int=`cat conftest.val` -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 ) -if test "$ac_cv_type_int" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (int) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (int) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_int=0 - fi -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 -rm -f conftest.val -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5 -$as_echo "$ac_cv_sizeof_int" >&6; } -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INT $ac_cv_sizeof_int -_ACEOF -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of long" >&5 -$as_echo_n "checking size of long... " >&6; } -if test "${ac_cv_sizeof_long+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr '(' $ac_mid ')' + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_long=$ac_lo;; -'') if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_long=0 - fi ;; -esac -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 -static long int longval () { return (long int) (sizeof (long)); } -static unsigned long int ulongval () { return (long int) (sizeof (long)); } -#include -#include -int -main () -{ - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (long))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (long)))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (long)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_long=`cat conftest.val` -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 ) -if test "$ac_cv_type_long" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_long=0 - fi -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 -rm -f conftest.val -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5 -$as_echo "$ac_cv_sizeof_long" >&6; } -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG $ac_cv_sizeof_long -_ACEOF -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of long long" >&5 -$as_echo_n "checking size of long long... " >&6; } -if test "${ac_cv_sizeof_long_long+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long long))) >= 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long long))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long long))) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long long))) >= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= + + + + + + + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: result: $hardcode_action" >&5 +$as_echo "$hardcode_action" >&6; } -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +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 -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (long long))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid + + + + + if test "x$enable_dlopen" != xyes; then + enable_dlopen=unknown + enable_dlopen_self=unknown + enable_dlopen_self_static=unknown else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + lt_cv_dlopen=no + lt_cv_dlopen_libs= - ac_lo=`expr '(' $ac_mid ')' + 1` -fi + case $host_os in + beos*) + lt_cv_dlopen="load_add_on" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes + ;; -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_long_long=$ac_lo;; -'') if test "$ac_cv_type_long_long" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_long_long=0 - fi ;; -esac + 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:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; 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 + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default -static long int longval () { return (long int) (sizeof (long long)); } -static unsigned long int ulongval () { return (long int) (sizeof (long long)); } -#include -#include + +/* 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 () { - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (long long))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (long long)))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (long long)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - +return dlopen (); ; return 0; } _ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_long_long=`cat conftest.val` +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -if test "$ac_cv_type_long_long" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (long long) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_long_long=0 - fi -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + ac_cv_lib_dl_dlopen=no fi -rm -f conftest.val +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long" >&5 -$as_echo "$ac_cv_sizeof_long_long" >&6; } - - +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" +else -cat >>confdefs.h <<_ACEOF -#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long -_ACEOF + lt_cv_dlopen="dyld" + lt_cv_dlopen_libs= + lt_cv_dlopen_self=yes +fi -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of intmax_t" >&5 -$as_echo_n "checking size of intmax_t... " >&6; } -if test "${ac_cv_sizeof_intmax_t+set}" = set; then + ;; + + *) + ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" +if test "x$ac_cv_func_shl_load" = xyes; then : + lt_cv_dlopen="shl_load" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 +$as_echo_n "checking for shl_load in -ldld... " >&6; } +if ${ac_cv_lib_dld_shl_load+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default + +/* 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 () { -static int test_array [1 - 2 * !(((long int) (sizeof (intmax_t))) >= 0)]; -test_array [0] = 0 - +return shl_load (); ; 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_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dld_shl_load=yes +else + ac_cv_lib_dld_shl_load=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$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" = xyes; then : + lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" +else + ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" +if test "x$ac_cv_func_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 +$as_echo_n "checking for dlopen in -ldl... " >&6; } +if ${ac_cv_lib_dl_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldl $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default + +/* 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 () { -static int test_array [1 - 2 * !(((long int) (sizeof (intmax_t))) <= $ac_mid)]; -test_array [0] = 0 - +return dlopen (); ; 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_hi=$ac_mid; break +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_dl_dlopen=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` + ac_cv_lib_dl_dlopen=no fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 +$as_echo "$ac_cv_lib_dl_dlopen" >&6; } +if test "x$ac_cv_lib_dl_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 +$as_echo_n "checking for dlopen in -lsvld... " >&6; } +if ${ac_cv_lib_svld_dlopen+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-lsvld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default + +/* 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 () { -static int test_array [1 - 2 * !(((long int) (sizeof (intmax_t))) < 0)]; -test_array [0] = 0 - +return dlopen (); ; 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_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ac_cv_lib_svld_dlopen=yes +else + ac_cv_lib_svld_dlopen=no +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 +$as_echo "$ac_cv_lib_svld_dlopen" >&6; } +if test "x$ac_cv_lib_svld_dlopen" = xyes; then : + lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" +else + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 +$as_echo_n "checking for dld_link in -ldld... " >&6; } +if ${ac_cv_lib_dld_dld_link+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_check_lib_save_LIBS=$LIBS +LIBS="-ldld $LIBS" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default + +/* 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 () { -static int test_array [1 - 2 * !(((long int) (sizeof (intmax_t))) >= $ac_mid)]; -test_array [0] = 0 - +return dld_link (); ; 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_lo=$ac_mid; break +if ac_fn_c_try_link "$LINENO"; 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 -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext +LIBS=$ac_check_lib_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$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" = xyes; then : + lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" +fi + - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (intmax_t))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +fi + - ac_lo=`expr '(' $ac_mid ')' + 1` fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_intmax_t=$ac_lo;; -'') if test "$ac_cv_type_intmax_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (intmax_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (intmax_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_intmax_t=0 - fi ;; -esac + ;; + 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:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 +$as_echo_n "checking whether a program can dlopen itself... " >&6; } +if ${lt_cv_dlopen_self+:} false; 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 -static long int longval () { return (long int) (sizeof (intmax_t)); } -static unsigned long int ulongval () { return (long int) (sizeof (intmax_t)); } + 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 $LINENO "configure" +#include "confdefs.h" + +#if HAVE_DLFCN_H +#include +#endif + #include -#include -int -main () + +#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 + +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () { + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (intmax_t))) < 0) + if (self) { - long int i = longval (); - if (i != ((long int) (sizeof (intmax_t)))) - return 1; - fprintf (f, "%ld", i); + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ } else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (intmax_t)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; + puts (dlerror ()); - ; - return 0; + return status; } -_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 +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_intmax_t=`cat conftest.val` -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 ) -if test "$ac_cv_type_intmax_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (intmax_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (intmax_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_intmax_t=0 - fi -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && 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 -f conftest.val +rm -fr conftest* + + fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_intmax_t" >&5 -$as_echo "$ac_cv_sizeof_intmax_t" >&6; } +{ $as_echo "$as_me:${as_lineno-$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:${as_lineno-$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 ${lt_cv_dlopen_self_static+:} false; 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 $LINENO "configure" +#include "confdefs.h" +#if HAVE_DLFCN_H +#include +#endif -cat >>confdefs.h <<_ACEOF -#define SIZEOF_INTMAX_T $ac_cv_sizeof_intmax_t -_ACEOF +#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 -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of off_t" >&5 -$as_echo_n "checking size of off_t... " >&6; } -if test "${ac_cv_sizeof_off_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)]; -test_array [0] = 0 +/* 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 - ; - 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_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () +/* When -fvisbility=hidden is used, assume the code has been annotated + correspondingly for the symbols needed. */ +#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +int fnord () __attribute__((visibility("default"))); +#endif + +int fnord () { return 42; } +int main () { -static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)]; -test_array [0] = 0 + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); + int status = $lt_dlunknown; - ; - return 0; + if (self) + { + if (dlsym (self,"fnord")) status = $lt_dlno_uscore; + else + { + if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; + else puts (dlerror ()); + } + /* dlclose (self); */ + } + else + puts (dlerror ()); + + return status; } -_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 +_LT_EOF + if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 + (eval $ac_link) 2>&5 ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; } && 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* + - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` fi +{ $as_echo "$as_me:${as_lineno-$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 + + + + + + + + + + + + + -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break +striplib= +old_striplib= +{ $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` +# 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:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + fi + ;; + *) + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + ;; + esac fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr '(' $ac_mid ')' + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_off_t=$ac_lo;; -'') if test "$ac_cv_type_off_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_off_t=0 - fi ;; -esac -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 -static long int longval () { return (long int) (sizeof (off_t)); } -static unsigned long int ulongval () { return (long int) (sizeof (off_t)); } -#include -#include -int -main () -{ - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (off_t))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (off_t)))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (off_t)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_off_t=`cat conftest.val` -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 ) -if test "$ac_cv_type_off_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (off_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_off_t=0 - fi -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 -rm -f conftest.val -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5 -$as_echo "$ac_cv_sizeof_off_t" >&6; } + # Report which library types will actually be built + { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 +$as_echo_n "checking if libtool supports shared libraries... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 +$as_echo "$can_build_shared" >&6; } -cat >>confdefs.h <<_ACEOF -#define SIZEOF_OFF_T $ac_cv_sizeof_off_t -_ACEOF + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: result: $enable_shared" >&5 +$as_echo "$enable_shared" >&6; } + + { $as_echo "$as_me:${as_lineno-$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:${as_lineno-$LINENO}: result: $enable_static" >&5 +$as_echo "$enable_static" >&6; } -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of size_t" >&5 -$as_echo_n "checking size of size_t... " >&6; } -if test "${ac_cv_sizeof_size_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 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 core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +CC="$lt_save_CC" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo= ac_hi= -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_lo=`expr '(' $ac_mid ')' + 1` -fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_size_t=$ac_lo;; -'') if test "$ac_cv_type_size_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (size_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_size_t=0 - fi ;; -esac -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 -static long int longval () { return (long int) (sizeof (size_t)); } -static unsigned long int ulongval () { return (long int) (sizeof (size_t)); } -#include -#include -int -main () -{ - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (size_t))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (size_t)))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (size_t)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - ; - return 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_size_t=`cat conftest.val` -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 + ac_config_commands="$ac_config_commands libtool" -( exit $ac_status ) -if test "$ac_cv_type_size_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (size_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_size_t=0 - fi -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 -rm -f conftest.val -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5 -$as_echo "$ac_cv_sizeof_size_t" >&6; } -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t -_ACEOF +# Only expand once: -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of ssize_t" >&5 -$as_echo_n "checking size of ssize_t... " >&6; } -if test "${ac_cv_sizeof_ssize_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ssize_t))) >= 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ssize_t))) <= $ac_mid)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + # Check whether --enable-static-binary was given. +if test "${enable_static_binary+set}" = set; then : + enableval=$enable_static_binary; + case "$enableval" in + "" | y | ye | yes) + AMANDA_STATIC_LDFLAGS=-static + if test x"$enable_static" = x"no"; then + as_fn_error $? "*** --enable-static-binary is incompatible with --disable-static" "$LINENO" 5 + fi + ;; + *n | no) + AMANDA_STATIC_LDFLAGS= + ;; + esac - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (ssize_t))) < 0)]; -test_array [0] = 0 - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + +# +# headers +# +ac_header_dirent=no +for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do + as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 +$as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } +if eval \${$as_ac_Header+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default +#include +#include <$ac_hdr> + int main () { -static int test_array [1 - 2 * !(((long int) (sizeof (ssize_t))) >= $ac_mid)]; -test_array [0] = 0 - +if ((DIR *) 0) +return 0; ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=$ac_mid; break +if ac_fn_c_try_compile "$LINENO"; then : + eval "$as_ac_Header=yes" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` + eval "$as_ac_Header=no" fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_lo= ac_hi= fi +eval ac_res=\$$as_ac_Header + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 +$as_echo "$ac_res" >&6; } +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 +_ACEOF -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_header_dirent=$ac_hdr; break fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +done +# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. +if test $ac_header_dirent = dirent.h; then + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default + +/* 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 opendir (); int main () { -static int test_array [1 - 2 * !(((long int) (sizeof (ssize_t))) <= $ac_mid)]; -test_array [0] = 0 - +return opendir (); ; 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_hi=$ac_mid +for ac_lib in '' dir; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res +fi +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break +fi +done +if ${ac_cv_search_opendir+:} false; then : + else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" - ac_lo=`expr '(' $ac_mid ')' + 1` fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -done -case $ac_lo in -?*) ac_cv_sizeof_ssize_t=$ac_lo;; -'') if test "$ac_cv_type_ssize_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (ssize_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (ssize_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_ssize_t=0 - fi ;; -esac else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 +$as_echo_n "checking for library containing opendir... " >&6; } +if ${ac_cv_search_opendir+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_func_search_save_LIBS=$LIBS +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default -static long int longval () { return (long int) (sizeof (ssize_t)); } -static unsigned long int ulongval () { return (long int) (sizeof (ssize_t)); } -#include -#include + +/* 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 opendir (); int main () { - - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (ssize_t))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (ssize_t)))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (ssize_t)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; - +return opendir (); ; return 0; } _ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_ssize_t=`cat conftest.val` -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 ) -if test "$ac_cv_type_ssize_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 -$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (ssize_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (ssize_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } - else - ac_cv_sizeof_ssize_t=0 - fi -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +for ac_lib in '' x; do + if test -z "$ac_lib"; then + ac_res="none required" + else + ac_res=-l$ac_lib + LIBS="-l$ac_lib $ac_func_search_save_LIBS" + fi + if ac_fn_c_try_link "$LINENO"; then : + ac_cv_search_opendir=$ac_res fi -rm -f conftest.val +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext + if ${ac_cv_search_opendir+:} false; then : + break fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_ssize_t" >&5 -$as_echo "$ac_cv_sizeof_ssize_t" >&6; } - +done +if ${ac_cv_search_opendir+:} false; then : +else + ac_cv_search_opendir=no +fi +rm conftest.$ac_ext +LIBS=$ac_func_search_save_LIBS +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 +$as_echo "$ac_cv_search_opendir" >&6; } +ac_res=$ac_cv_search_opendir +if test "$ac_res" != no; then : + test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" -cat >>confdefs.h <<_ACEOF -#define SIZEOF_SSIZE_T $ac_cv_sizeof_ssize_t -_ACEOF +fi +fi -# The cast to long int works around a bug in the HP C Compiler -# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects -# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. -# This bug is HP SR number 8606223364. -{ $as_echo "$as_me:$LINENO: checking size of time_t" >&5 -$as_echo_n "checking size of time_t... " >&6; } -if test "${ac_cv_sizeof_time_t+set}" = set; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 +$as_echo_n "checking for ANSI C header files... " >&6; } +if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then - # Depending upon the size, compute the lo and hi bounds. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default +#include +#include +#include +#include + int main () { -static int test_array [1 - 2 * !(((long int) (sizeof (time_t))) >= 0)]; -test_array [0] = 0 ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_lo=0 ac_mid=0 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_stdc=yes +else + 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 confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (time_t))) <= $ac_mid)]; -test_array [0] = 0 +#include - ; - 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_hi=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "memchr" >/dev/null 2>&1; then : - ac_lo=`expr $ac_mid + 1` - if test $ac_lo -le $ac_mid; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid + 1` +else + ac_cv_header_stdc=no fi +rm -f conftest* -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +fi - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +if test $ac_cv_header_stdc = yes; then + # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default -int -main () -{ -static int test_array [1 - 2 * !(((long int) (sizeof (time_t))) < 0)]; -test_array [0] = 0 +#include - ; - 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_hi=-1 ac_mid=-1 - while :; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "free" >/dev/null 2>&1; then : + +else + ac_cv_header_stdc=no +fi +rm -f conftest* + +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 confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default +#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 () { -static int test_array [1 - 2 * !(((long int) (sizeof (time_t))) >= $ac_mid)]; -test_array [0] = 0 - - ; + 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_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_lo=$ac_mid; break -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_hi=`expr '(' $ac_mid ')' - 1` - if test $ac_mid -le $ac_hi; then - ac_lo= ac_hi= - break - fi - ac_mid=`expr 2 '*' $ac_mid` -fi +if ac_fn_c_try_run "$LINENO"; then : -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - done else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + ac_cv_header_stdc=no +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - ac_lo= ac_hi= fi +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 +$as_echo "$ac_cv_header_stdc" >&6; } +if test $ac_cv_header_stdc = yes; then + +$as_echo "#define STDC_HEADERS 1" >>confdefs.h -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -# Binary search between lo and hi bounds. -while test "x$ac_lo" != "x$ac_hi"; do - ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo` - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 +$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } +if ${ac_cv_header_time+:} false; then : + $as_echo_n "(cached) " >&6 +else + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -$ac_includes_default +#include +#include +#include + int main () { -static int test_array [1 - 2 * !(((long int) (sizeof (time_t))) <= $ac_mid)]; -test_array [0] = 0 - +if ((struct tm *) 0) +return 0; ; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_hi=$ac_mid +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_header_time=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + ac_cv_header_time=no +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 +$as_echo "$ac_cv_header_time" >&6; } +if test $ac_cv_header_time = yes; then + +$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h + +fi + +for ac_header in grp.h \ + libc.h \ + libgen.h \ + limits.h \ + math.h \ + netinet/in.h \ + regex.h \ + stdarg.h \ + stdlib.h \ + strings.h \ + rpc/rpc.h \ + sys/file.h \ + sys/ioctl.h \ + sys/ipc.h \ + sys/mntent.h \ + sys/param.h \ + sys/select.h \ + sys/stat.h \ + sys/shm.h \ + sys/time.h \ + sys/types.h \ + sys/uio.h \ + syslog.h \ + time.h \ + unistd.h \ + +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : + cat >>confdefs.h <<_ACEOF +#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 +_ACEOF - ac_lo=`expr '(' $ac_mid ')' + 1` fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done -case $ac_lo in -?*) ac_cv_sizeof_time_t=$ac_lo;; -'') if test "$ac_cv_type_time_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 + + +$as_echo "#define HAVE_AMANDA_H 1" >>confdefs.h + + +$as_echo "#define HAVE_UTIL_H 1" >>confdefs.h + + + +$as_echo "#define USE_GETTEXT 1" >>confdefs.h + + +# +# Types +# +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 +$as_echo_n "checking size of int... " >&6; } +if ${ac_cv_sizeof_int+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_int" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } +as_fn_error 77 "cannot compute sizeof (int) +See \`config.log' for more details" "$LINENO" 5; } else - ac_cv_sizeof_time_t=0 - fi ;; -esac -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 -static long int longval () { return (long int) (sizeof (time_t)); } -static unsigned long int ulongval () { return (long int) (sizeof (time_t)); } -#include -#include -int -main () -{ + ac_cv_sizeof_int=0 + fi +fi - FILE *f = fopen ("conftest.val", "w"); - if (! f) - return 1; - if (((long int) (sizeof (time_t))) < 0) - { - long int i = longval (); - if (i != ((long int) (sizeof (time_t)))) - return 1; - fprintf (f, "%ld", i); - } - else - { - unsigned long int i = ulongval (); - if (i != ((long int) (sizeof (time_t)))) - return 1; - fprintf (f, "%lu", i); - } - /* Do not output a trailing newline, as this causes \r\n confusion - on some platforms. */ - return ferror (f) || fclose (f) != 0; +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 +$as_echo "$ac_cv_sizeof_int" >&6; } - ; - return 0; -} + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INT $ac_cv_sizeof_int _ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_sizeof_time_t=`cat conftest.val` + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 +$as_echo_n "checking size of long... " >&6; } +if ${ac_cv_sizeof_long+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (long) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_long=0 + fi +fi + +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 +$as_echo "$ac_cv_sizeof_long" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_LONG $ac_cv_sizeof_long +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 +$as_echo_n "checking size of long long... " >&6; } +if ${ac_cv_sizeof_long_long+:} false; then : + $as_echo_n "(cached) " >&6 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 + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : -( exit $ac_status ) -if test "$ac_cv_type_time_t" = yes; then - { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5 +else + if test "$ac_cv_type_long_long" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} -{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&5 -$as_echo "$as_me: error: cannot compute sizeof (time_t) -See \`config.log' for more details." >&2;} - { (exit 77); exit 77; }; }; } +as_fn_error 77 "cannot compute sizeof (long long) +See \`config.log' for more details" "$LINENO" 5; } else - ac_cv_sizeof_time_t=0 + ac_cv_sizeof_long_long=0 fi 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 -rm -f conftest.val + fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_time_t" >&5 -$as_echo "$ac_cv_sizeof_time_t" >&6; } +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 +$as_echo "$ac_cv_sizeof_long_long" >&6; } cat >>confdefs.h <<_ACEOF -#define SIZEOF_TIME_T $ac_cv_sizeof_time_t +#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long _ACEOF -{ $as_echo "$as_me:$LINENO: checking for off_t" >&5 -$as_echo_n "checking for off_t... " >&6; } -if test "${ac_cv_type_off_t+set}" = set; then +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of intmax_t" >&5 +$as_echo_n "checking size of intmax_t... " >&6; } +if ${ac_cv_sizeof_intmax_t+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_type_off_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof (off_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof ((off_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (intmax_t))" "ac_cv_sizeof_intmax_t" "$ac_includes_default"; then : + else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + if test "$ac_cv_type_intmax_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (intmax_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_intmax_t=0 + fi +fi - ac_cv_type_off_t=yes fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_intmax_t" >&5 +$as_echo "$ac_cv_sizeof_intmax_t" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_INTMAX_T $ac_cv_sizeof_intmax_t +_ACEOF -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5 +$as_echo_n "checking size of off_t... " >&6; } +if ${ac_cv_sizeof_off_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"; then : +else + if test "$ac_cv_type_off_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (off_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_off_t=0 + fi fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_off_t" >&5 -$as_echo "$ac_cv_type_off_t" >&6; } -if test "x$ac_cv_type_off_t" = x""yes; then - : -else +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5 +$as_echo "$ac_cv_sizeof_off_t" >&6; } + + cat >>confdefs.h <<_ACEOF -#define off_t long int +#define SIZEOF_OFF_T $ac_cv_sizeof_off_t _ACEOF -fi -{ $as_echo "$as_me:$LINENO: checking for pid_t" >&5 -$as_echo_n "checking for pid_t... " >&6; } -if test "${ac_cv_type_pid_t+set}" = set; then +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 +$as_echo_n "checking size of size_t... " >&6; } +if ${ac_cv_sizeof_size_t+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_type_pid_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof (pid_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof ((pid_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then : + else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + if test "$ac_cv_type_size_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (size_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_size_t=0 + fi +fi - ac_cv_type_pid_t=yes fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 +$as_echo "$ac_cv_sizeof_size_t" >&6; } -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +cat >>confdefs.h <<_ACEOF +#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t +_ACEOF + + +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of ssize_t" >&5 +$as_echo_n "checking size of ssize_t... " >&6; } +if ${ac_cv_sizeof_ssize_t+:} false; then : + $as_echo_n "(cached) " >&6 +else + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (ssize_t))" "ac_cv_sizeof_ssize_t" "$ac_includes_default"; then : + +else + if test "$ac_cv_type_ssize_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (ssize_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_ssize_t=0 + fi fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5 -$as_echo "$ac_cv_type_pid_t" >&6; } -if test "x$ac_cv_type_pid_t" = x""yes; then - : -else +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_ssize_t" >&5 +$as_echo "$ac_cv_sizeof_ssize_t" >&6; } + + cat >>confdefs.h <<_ACEOF -#define pid_t int +#define SIZEOF_SSIZE_T $ac_cv_sizeof_ssize_t _ACEOF -fi -{ $as_echo "$as_me:$LINENO: checking for size_t" >&5 -$as_echo_n "checking for size_t... " >&6; } -if test "${ac_cv_type_size_t+set}" = set; then +# The cast to long int works around a bug in the HP C Compiler +# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects +# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. +# This bug is HP SR number 8606223364. +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 +$as_echo_n "checking size of time_t... " >&6; } +if ${ac_cv_sizeof_time_t+:} false; then : $as_echo_n "(cached) " >&6 else - ac_cv_type_size_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof (size_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -int -main () -{ -if (sizeof ((size_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : + if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" "$ac_includes_default"; then : + else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + if test "$ac_cv_type_time_t" = yes; then + { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 +$as_echo "$as_me: error: in \`$ac_pwd':" >&2;} +as_fn_error 77 "cannot compute sizeof (time_t) +See \`config.log' for more details" "$LINENO" 5; } + else + ac_cv_sizeof_time_t=0 + fi +fi - ac_cv_type_size_t=yes fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 +$as_echo "$ac_cv_sizeof_time_t" >&6; } + + + +cat >>confdefs.h <<_ACEOF +#define SIZEOF_TIME_T $ac_cv_sizeof_time_t +_ACEOF + + +ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" +if test "x$ac_cv_type_off_t" = xyes; then : -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +cat >>confdefs.h <<_ACEOF +#define off_t long int +_ACEOF fi -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext +ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" +if test "x$ac_cv_type_pid_t" = xyes; then : + +else + +cat >>confdefs.h <<_ACEOF +#define pid_t int +_ACEOF + fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5 -$as_echo "$ac_cv_type_size_t" >&6; } -if test "x$ac_cv_type_size_t" = x""yes; then - : + +ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" +if test "x$ac_cv_type_size_t" = xyes; then : + else cat >>confdefs.h <<_ACEOF @@ -55202,22 +37005,18 @@ _ACEOF fi -{ $as_echo "$as_me:$LINENO: checking for uid_t in sys/types.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 $as_echo_n "checking for uid_t in sys/types.h... " >&6; } -if test "${ac_cv_type_uid_t+set}" = set; then +if ${ac_cv_type_uid_t+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "uid_t" >/dev/null 2>&1; then + $EGREP "uid_t" >/dev/null 2>&1; then : ac_cv_type_uid_t=yes else ac_cv_type_uid_t=no @@ -55225,31 +37024,23 @@ fi rm -f conftest* fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_uid_t" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 $as_echo "$ac_cv_type_uid_t" >&6; } if test $ac_cv_type_uid_t = no; then -cat >>confdefs.h <<\_ACEOF -#define uid_t int -_ACEOF +$as_echo "#define uid_t int" >>confdefs.h -cat >>confdefs.h <<\_ACEOF -#define gid_t int -_ACEOF +$as_echo "#define gid_t int" >>confdefs.h fi -{ $as_echo "$as_me:$LINENO: checking return type of signal handlers" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 $as_echo_n "checking return type of signal handlers... " >&6; } -if test "${ac_cv_type_signal+set}" = set; then +if ${ac_cv_type_signal+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -55262,35 +37053,14 @@ return *(signal (0, 0)) (0) == 1; return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_type_signal=int else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_signal=void + ac_cv_type_signal=void fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 $as_echo "$ac_cv_type_signal" >&6; } cat >>confdefs.h <<_ACEOF @@ -55298,16 +37068,12 @@ cat >>confdefs.h <<_ACEOF _ACEOF -{ $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } -if test "${ac_cv_struct_tm+set}" = set; then +if ${ac_cv_struct_tm+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -55322,49 +37088,26 @@ struct tm tm; 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 +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_struct_tm=time.h else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_struct_tm=sys/time.h + ac_cv_struct_tm=sys/time.h fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 $as_echo "$ac_cv_struct_tm" >&6; } if test $ac_cv_struct_tm = sys/time.h; then -cat >>confdefs.h <<\_ACEOF -#define TM_IN_SYS_TIME 1 -_ACEOF +$as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h fi ## lifted from config/gnulib/socklen.m4 - { $as_echo "$as_me:$LINENO: checking for socklen_t equivalent" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5 $as_echo_n "checking for socklen_t equivalent... " >&6; } - if test "${gl_cv_socklen_t_equiv+set}" = set; then + if ${gl_cv_socklen_t_equiv+:} false; then : $as_echo_n "(cached) " >&6 else # Systems have either "struct sockaddr *" or @@ -55372,11 +37115,7 @@ else gl_cv_socklen_t_equiv= for arg2 in "struct sockaddr" void; do for t in socklen_t int size_t "unsigned int" "long int" "unsigned long int"; do - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include @@ -55391,32 +37130,9 @@ $t len; 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 +if ac_fn_c_try_compile "$LINENO"; then : gl_cv_socklen_t_equiv="$t" -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 test "$gl_cv_socklen_t_equiv" != "" && break done @@ -55430,7 +37146,7 @@ fi if test "$gl_cv_socklen_t_equiv" = ""; then gl_cv_socklen_t_equiv=socklen_t fi - { $as_echo "$as_me:$LINENO: result: $gl_cv_socklen_t_equiv" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5 $as_echo "$gl_cv_socklen_t_equiv" >&6; } @@ -55441,64 +37157,7 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking for sa_family_t" >&5 -$as_echo_n "checking for sa_family_t... " >&6; } -if test "${ac_cv_type_sa_family_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_sa_family_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef STDC_HEADERS -#include -#include -#endif -#include - - - -int -main () -{ -if (sizeof (sa_family_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" " #ifdef HAVE_SYS_TYPES_H #include #endif @@ -55509,62 +37168,13 @@ cat >>conftest.$ac_ext <<_ACEOF #include +" +if test "x$ac_cv_type_sa_family_t" = xyes; then : -int -main () -{ -if (sizeof ((sa_family_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_sa_family_t=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_sa_family_t" >&5 -$as_echo "$ac_cv_type_sa_family_t" >&6; } -if test "x$ac_cv_type_sa_family_t" = x""yes; then - : else -cat >>confdefs.h <<\_ACEOF -#define sa_family_t unsigned short -_ACEOF +$as_echo "#define sa_family_t unsigned short" >>confdefs.h fi @@ -55572,64 +37182,7 @@ fi - { $as_echo "$as_me:$LINENO: checking for in_port_t" >&5 -$as_echo_n "checking for in_port_t... " >&6; } -if test "${ac_cv_type_in_port_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_in_port_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef STDC_HEADERS -#include -#include -#endif -#include - - - -int -main () -{ -if (sizeof (in_port_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" " #ifdef HAVE_SYS_TYPES_H #include #endif @@ -55640,208 +37193,25 @@ cat >>conftest.$ac_ext <<_ACEOF #include +" +if test "x$ac_cv_type_in_port_t" = xyes; then : -int -main () -{ -if (sizeof ((in_port_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_in_port_t=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_in_port_t" >&5 -$as_echo "$ac_cv_type_in_port_t" >&6; } -if test "x$ac_cv_type_in_port_t" = x""yes; then - : -else - - -cat >>confdefs.h <<\_ACEOF -#define in_port_t unsigned short -_ACEOF - - -fi - - - - - - -for ac_header in sys/wait.h wait.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; } +$as_echo "#define in_port_t unsigned short" >>confdefs.h -# 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;} - ;; -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 + for ac_header in sys/wait.h wait.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -55850,17 +37220,13 @@ fi done - { $as_echo "$as_me:$LINENO: checking whether wait uses union wait" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wait uses union wait" >&5 $as_echo_n "checking whether wait uses union wait... " >&6; } -if test "${cf_cv_arg_union_wait+set}" = set; then +if ${cf_cv_arg_union_wait+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -55888,185 +37254,28 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : cf_cv_arg_union_wait=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cf_cv_arg_union_wait=no + cf_cv_arg_union_wait=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $cf_cv_arg_union_wait" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cf_cv_arg_union_wait" >&5 $as_echo "$cf_cv_arg_union_wait" >&6; } if test $cf_cv_arg_union_wait = yes; then -cat >>confdefs.h <<\_ACEOF -#define WAIT_USES_UNION 1 -_ACEOF +$as_echo "#define WAIT_USES_UNION 1" >>confdefs.h fi - - -for ac_header in sys/wait.h wait.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;} - - ;; -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 + for ac_header in sys/wait.h wait.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -56075,17 +37284,13 @@ fi done - { $as_echo "$as_me:$LINENO: checking whether wait uses int" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wait uses int" >&5 $as_echo_n "checking whether wait uses int... " >&6; } -if test "${cf_cv_arg_int+set}" = set; then +if ${cf_cv_arg_int+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -56113,41 +37318,18 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : cf_cv_arg_int=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - cf_cv_arg_int=no + cf_cv_arg_int=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $cf_cv_arg_int" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cf_cv_arg_int" >&5 $as_echo "$cf_cv_arg_int" >&6; } if test $cf_cv_arg_int = yes; then -cat >>confdefs.h <<\_ACEOF -#define WAIT_USES_INT 1 -_ACEOF +$as_echo "#define WAIT_USES_INT 1" >>confdefs.h fi @@ -56156,19 +37338,14 @@ fi # Libraries # # cur_colr is on some HP's - -{ $as_echo "$as_me:$LINENO: checking for main in -lcur_colr" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lcur_colr" >&5 $as_echo_n "checking for main in -lcur_colr... " >&6; } -if test "${ac_cv_lib_cur_colr_main+set}" = set; then +if ${ac_cv_lib_cur_colr_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lcur_colr $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -56180,43 +37357,18 @@ return main (); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_cur_colr_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_cur_colr_main=no + ac_cv_lib_cur_colr_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_cur_colr_main" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cur_colr_main" >&5 $as_echo "$ac_cv_lib_cur_colr_main" >&6; } -if test "x$ac_cv_lib_cur_colr_main" = x""yes; then +if test "x$ac_cv_lib_cur_colr_main" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBCUR_COLR 1 _ACEOF @@ -56225,19 +37377,14 @@ _ACEOF fi - -{ $as_echo "$as_me:$LINENO: checking for main in -lintl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lintl" >&5 $as_echo_n "checking for main in -lintl... " >&6; } -if test "${ac_cv_lib_intl_main+set}" = set; then +if ${ac_cv_lib_intl_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -56249,43 +37396,18 @@ return main (); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_intl_main=no + ac_cv_lib_intl_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_intl_main" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_main" >&5 $as_echo "$ac_cv_lib_intl_main" >&6; } -if test "x$ac_cv_lib_intl_main" = x""yes; then +if test "x$ac_cv_lib_intl_main" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBINTL 1 _ACEOF @@ -56298,19 +37420,14 @@ fi # Make sure we don't use -lnsl and -lsun on Irix systems. case "$host" in *sgi-irix*) - -{ $as_echo "$as_me:$LINENO: checking for main in -lsocket" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lsocket" >&5 $as_echo_n "checking for main in -lsocket... " >&6; } -if test "${ac_cv_lib_socket_main+set}" = set; then +if ${ac_cv_lib_socket_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsocket $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -56322,43 +37439,18 @@ return main (); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_socket_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_socket_main=no + ac_cv_lib_socket_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_main" >&5 $as_echo "$ac_cv_lib_socket_main" >&6; } -if test "x$ac_cv_lib_socket_main" = x""yes; then +if test "x$ac_cv_lib_socket_main" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBSOCKET 1 _ACEOF @@ -56369,19 +37461,14 @@ fi ;; *) - -{ $as_echo "$as_me:$LINENO: checking for main in -lresolv" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lresolv" >&5 $as_echo_n "checking for main in -lresolv... " >&6; } -if test "${ac_cv_lib_resolv_main+set}" = set; then +if ${ac_cv_lib_resolv_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lresolv $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -56393,43 +37480,18 @@ return main (); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_resolv_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_resolv_main=no + ac_cv_lib_resolv_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_main" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_main" >&5 $as_echo "$ac_cv_lib_resolv_main" >&6; } -if test "x$ac_cv_lib_resolv_main" = x""yes; then +if test "x$ac_cv_lib_resolv_main" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBRESOLV 1 _ACEOF @@ -56438,19 +37500,14 @@ _ACEOF fi - -{ $as_echo "$as_me:$LINENO: checking for main in -lnsl" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lnsl" >&5 $as_echo_n "checking for main in -lnsl... " >&6; } -if test "${ac_cv_lib_nsl_main+set}" = set; then +if ${ac_cv_lib_nsl_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lnsl $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -56462,43 +37519,18 @@ return main (); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_nsl_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_nsl_main=no + ac_cv_lib_nsl_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_main" >&5 $as_echo "$ac_cv_lib_nsl_main" >&6; } -if test "x$ac_cv_lib_nsl_main" = x""yes; then +if test "x$ac_cv_lib_nsl_main" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBNSL 1 _ACEOF @@ -56507,19 +37539,14 @@ _ACEOF fi - -{ $as_echo "$as_me:$LINENO: checking for main in -lsocket" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lsocket" >&5 $as_echo_n "checking for main in -lsocket... " >&6; } -if test "${ac_cv_lib_socket_main+set}" = set; then +if ${ac_cv_lib_socket_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsocket $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -56531,43 +37558,18 @@ return main (); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_socket_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_socket_main=no + ac_cv_lib_socket_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_main" >&5 $as_echo "$ac_cv_lib_socket_main" >&6; } -if test "x$ac_cv_lib_socket_main" = x""yes; then +if test "x$ac_cv_lib_socket_main" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBSOCKET 1 _ACEOF @@ -56576,19 +37578,14 @@ _ACEOF fi - -{ $as_echo "$as_me:$LINENO: checking for main in -lsun" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lsun" >&5 $as_echo_n "checking for main in -lsun... " >&6; } -if test "${ac_cv_lib_sun_main+set}" = set; then +if ${ac_cv_lib_sun_main+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsun $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ @@ -56600,43 +37597,18 @@ return main (); return 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then +if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_sun_main=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_sun_main=no + ac_cv_lib_sun_main=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_sun_main" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sun_main" >&5 $as_echo "$ac_cv_lib_sun_main" >&6; } -if test "x$ac_cv_lib_sun_main" = x""yes; then +if test "x$ac_cv_lib_sun_main" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBSUN 1 _ACEOF @@ -56655,7 +37627,8 @@ fi - # if any of the precious variables are set, disable the pkg-config run + # if any of the precious variables are set, disable the pkg-config run. + # Further, if any is specified, all must be specified. explicit_glib=no test x"$GLIB_CFLAGS" = x"" || explicit_glib=yes test x"$GLIB_LIBS" = x"" || explicit_glib=yes @@ -56668,9 +37641,9 @@ fi # system-specific search paths. # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PKG_CONFIG+set}" = set; then +if ${ac_cv_path_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $PKG_CONFIG in @@ -56684,14 +37657,14 @@ for as_dir in $as_dummy do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; @@ -56699,10 +37672,10 @@ esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then - { $as_echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -56722,7 +37695,7 @@ fi esac # Check whether --enable-glibtest was given. -if test "${enable_glibtest+set}" = set; then +if test "${enable_glibtest+set}" = set; then : enableval=$enable_glibtest; else enable_glibtest=yes @@ -56753,13 +37726,17 @@ fi + + + + if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_PKG_CONFIG+set}" = set; then +if ${ac_cv_path_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $PKG_CONFIG in @@ -56772,14 +37749,14 @@ 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 + for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; @@ -56787,10 +37764,10 @@ esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then - { $as_echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -56800,9 +37777,9 @@ if test -z "$ac_cv_path_PKG_CONFIG"; then ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then +if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $ac_pt_PKG_CONFIG in @@ -56815,14 +37792,14 @@ 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 + for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; @@ -56830,10 +37807,10 @@ esac fi ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then - { $as_echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 $as_echo "$ac_pt_PKG_CONFIG" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -56842,7 +37819,7 @@ fi 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:${as_lineno-$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 @@ -56855,17 +37832,16 @@ fi fi if test -n "$PKG_CONFIG"; then _pkg_min_version=0.7 - { $as_echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then - { $as_echo "$as_me:$LINENO: result: yes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } PKG_CONFIG="" fi - fi no_glib="" @@ -56876,7 +37852,7 @@ fi fi min_glib_version=2.2.0 - { $as_echo "$as_me:$LINENO: checking for GLIB - version >= $min_glib_version" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLIB - version >= $min_glib_version" >&5 $as_echo_n "checking for GLIB - version >= $min_glib_version... " >&6; } if test x$PKG_CONFIG != xno ; then @@ -56912,14 +37888,10 @@ $as_echo_n "checking for GLIB - version >= $min_glib_version... " >&6; } CFLAGS="$CFLAGS $GLIB_CFLAGS" LIBS="$GLIB_LIBS $LIBS" rm -f conf.glibtest - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : echo $ac_n "cross compiling; assumed OK... $ac_c" else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -56929,14 +37901,14 @@ cat >>conftest.$ac_ext <<_ACEOF int main () { - int major, minor, micro; + unsigned int major, minor, micro; char *tmp_version; - system ("touch conf.glibtest"); + fclose (fopen ("conf.glibtest", "w")); /* HP/UX 9 (%@#!) writes to sscanf strings */ tmp_version = g_strdup("$min_glib_version"); - if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, µ) != 3) { + if (sscanf(tmp_version, "%u.%u.%u", &major, &minor, µ) != 3) { printf("%s, bad version string\n", "$min_glib_version"); exit(1); } @@ -56975,9 +37947,9 @@ main () } else { - printf("\n*** An old version of GLIB (%d.%d.%d) was found.\n", + printf("\n*** An old version of GLIB (%u.%u.%u) was found.\n", glib_major_version, glib_minor_version, glib_micro_version); - printf("*** You need a version of GLIB newer than %d.%d.%d. The latest version of\n", + printf("*** You need a version of GLIB newer than %u.%u.%u. The latest version of\n", major, minor, micro); printf("*** GLIB is always available from ftp://ftp.gtk.org.\n"); printf("***\n"); @@ -56994,52 +37966,25 @@ main () } _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 +if ac_fn_c_try_run "$LINENO"; then : -( exit $ac_status ) -no_glib=yes +else + no_glib=yes fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - CFLAGS="$ac_save_CFLAGS" LIBS="$ac_save_LIBS" fi fi if test "x$no_glib" = x ; then - { $as_echo "$as_me:$LINENO: result: yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version)" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version)" >&5 $as_echo "yes (version $glib_config_major_version.$glib_config_minor_version.$glib_config_micro_version)" >&6; } : else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if test "$PKG_CONFIG" = "no" ; then echo "*** A new enough version of pkg-config was not found." @@ -57053,11 +37998,7 @@ $as_echo "no" >&6; } ac_save_LIBS="$LIBS" CFLAGS="$CFLAGS $GLIB_CFLAGS" LIBS="$LIBS $GLIB_LIBS" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -57071,27 +38012,7 @@ 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 ac_fn_c_try_link "$LINENO"; then : echo "*** The test program compiled, but did not run. This usually means" echo "*** that the run-time linker is not finding GLIB or finding the wrong" echo "*** version of GLIB. If it is not finding GLIB, you'll need to set your" @@ -57102,16 +38023,11 @@ $as_echo "$ac_try_echo") >&5 echo "*** If you have an old version installed, it is best to remove it, although" echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH" else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - echo "*** The test program failed to compile or link. See the file config.log for the" + echo "*** The test program failed to compile or link. See the file config.log for the" echo "*** exact error that occured. This usually means GLIB is incorrectly installed." fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CFLAGS="$ac_save_CFLAGS" LIBS="$ac_save_LIBS" fi @@ -57122,9 +38038,7 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ GOBJECT_QUERY="" GLIB_MKENUMS="" - { { $as_echo "$as_me:$LINENO: error: glib not found or too old; See http://wiki.zmanda.com/index.php/Installation for help" >&5 -$as_echo "$as_me: error: glib not found or too old; See http://wiki.zmanda.com/index.php/Installation for help" >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "glib not found or too old; See http://wiki.zmanda.com/index.php/Installation for help" "$LINENO" 5 fi @@ -57135,9 +38049,16 @@ $as_echo "$as_me: error: glib not found or too old; See http://wiki.zmanda.com/i rm -f conf.glibtest else - { { $as_echo "$as_me:$LINENO: error: explicit glib" >&5 -$as_echo "$as_me: error: explicit glib" >&2;} - { (exit 1); exit 1; }; } + # Confirm that all GLIB_ variables are set + if test ! x"$GLIB_CFLAGS" = x"" && \ + test ! x"$GLIB_LIBS" = x"" && \ + test ! x"$GLIB_GENMARSHAL" = x"" && \ + test ! x"$GOBJECT_QUERY" = x"" && \ + test ! x"$GLIB_MKENUMS" = x""; then + : + else + as_fn_error $? "Not all precious glib variables were set." "$LINENO" 5 + fi fi # GLIB_CPPFLAGS is not set by autoconf, yet GLIB_CFLAGS contains what GLIB_CPPFLAGS should contain. @@ -57149,13 +38070,11 @@ $as_echo "$as_me: error: explicit glib" >&2;} # Check whether --with-readline was given. -if test "${with_readline+set}" = set; then +if test "${with_readline+set}" = set; then : withval=$with_readline; case "$withval" in y | ye | yes | n | no) : ;; - *) { { $as_echo "$as_me:$LINENO: error: *** --with-readline does not take a value" >&5 -$as_echo "$as_me: error: *** --with-readline does not take a value" >&2;} - { (exit 1); exit 1; }; } + *) as_fn_error $? "*** --with-readline does not take a value" "$LINENO" 5 esac want_readline="$withval" @@ -57169,9 +38088,9 @@ fi # unless the user said "no", look for readline. if test x"$want_readline" != x"no"; then - { $as_echo "$as_me:$LINENO: checking for a readline compatible library" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a readline compatible library" >&5 $as_echo_n "checking for a readline compatible library... " >&6; } -if test "${ax_cv_lib_readline+set}" = set; then +if ${ax_cv_lib_readline+:} false; then : $as_echo_n "(cached) " >&6 else @@ -57184,11 +38103,7 @@ else TRY_LIB="-l$readline_lib -l$termcap_lib" fi LIBS="$ORIG_LIBS $TRY_LIB" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -57204,40 +38119,13 @@ main () return readline (); ; 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 - ax_cv_lib_readline="$TRY_LIB" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - +} +_ACEOF +if ac_fn_c_try_link "$LINENO"; then : + ax_cv_lib_readline="$TRY_LIB" fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext if test -n "$ax_cv_lib_readline"; then break fi @@ -57252,7 +38140,7 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ LIBS="$ORIG_LIBS" fi -{ $as_echo "$as_me:$LINENO: result: $ax_cv_lib_readline" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_lib_readline" >&5 $as_echo "$ax_cv_lib_readline" >&6; } if test "$ax_cv_lib_readline" != "no"; then @@ -57260,149 +38148,13 @@ $as_echo "$ax_cv_lib_readline" >&6; } LIBS="$LIBS $ax_cv_lib_readline" READLINE_LIBS="$ax_cv_lib_readline" -cat >>confdefs.h <<\_ACEOF -#define HAVE_LIBREADLINE 1 -_ACEOF - - - -for ac_header in readline.h readline/readline.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;} - - ;; -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; } +$as_echo "#define HAVE_LIBREADLINE 1" >>confdefs.h -fi -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_header in readline.h readline/readline.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -57411,18 +38163,14 @@ fi done - { $as_echo "$as_me:$LINENO: checking whether readline supports history" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5 $as_echo_n "checking whether readline supports history... " >&6; } -if test "${ax_cv_lib_readline_history+set}" = set; then +if ${ax_cv_lib_readline_history+:} false; then : $as_echo_n "(cached) " >&6 else ax_cv_lib_readline_history="no" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -57440,187 +38188,24 @@ return add_history (); 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 ac_fn_c_try_link "$LINENO"; then : ax_cv_lib_readline_history="yes" -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 +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ax_cv_lib_readline_history" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_lib_readline_history" >&5 $as_echo "$ax_cv_lib_readline_history" >&6; } if test "$ax_cv_lib_readline_history" = "yes"; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_READLINE_HISTORY 1 -_ACEOF - - - -for ac_header in history.h readline/history.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;} - - ;; -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; } +$as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h -fi -as_val=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + for ac_header in history.h readline/history.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -57635,28 +38220,21 @@ done else # no readline. if the user *really* wanted it, bail out. if test x"$want_readline" = x"yes"; then - { { $as_echo "$as_me:$LINENO: error: *** No readline implementation found. Try using --with-libraries and --with-includes" >&5 -$as_echo "$as_me: error: *** No readline implementation found. Try using --with-libraries and --with-includes" >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "*** No readline implementation found. Try using --with-libraries and --with-includes" "$LINENO" 5 fi READLINE_LIBS="" fi fi - -{ $as_echo "$as_me:$LINENO: checking for modf in -lm" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for modf in -lm" >&5 $as_echo_n "checking for modf in -lm... " >&6; } -if test "${ac_cv_lib_m_modf+set}" = set; then +if ${ac_cv_lib_m_modf+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -57674,43 +38252,18 @@ return modf (); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_m_modf=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_m_modf=no + ac_cv_lib_m_modf=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_modf" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_modf" >&5 $as_echo "$ac_cv_lib_m_modf" >&6; } -if test "x$ac_cv_lib_m_modf" = x""yes; then +if test "x$ac_cv_lib_m_modf" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBM 1 _ACEOF @@ -57720,226 +38273,14 @@ _ACEOF fi - if test "${ac_cv_header_execinfo_h+set}" = set; then - { $as_echo "$as_me:$LINENO: checking for execinfo.h" >&5 -$as_echo_n "checking for execinfo.h... " >&6; } -if test "${ac_cv_header_execinfo_h+set}" = set; then - $as_echo_n "(cached) " >&6 -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_execinfo_h" >&5 -$as_echo "$ac_cv_header_execinfo_h" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking execinfo.h usability" >&5 -$as_echo_n "checking execinfo.h 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 -_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 execinfo.h presence" >&5 -$as_echo_n "checking execinfo.h 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 -_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: execinfo.h: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: execinfo.h: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: execinfo.h: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: execinfo.h: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: execinfo.h: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: execinfo.h: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: execinfo.h: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: execinfo.h: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: execinfo.h: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: execinfo.h: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: execinfo.h: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: execinfo.h: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: execinfo.h: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: execinfo.h: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: execinfo.h: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: execinfo.h: in the future, the compiler will take precedence" >&2;} - - ;; -esac -{ $as_echo "$as_me:$LINENO: checking for execinfo.h" >&5 -$as_echo_n "checking for execinfo.h... " >&6; } -if test "${ac_cv_header_execinfo_h+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_header_execinfo_h=$ac_header_preproc -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_execinfo_h" >&5 -$as_echo "$ac_cv_header_execinfo_h" >&6; } - -fi -if test "x$ac_cv_header_execinfo_h" = x""yes; then - - { $as_echo "$as_me:$LINENO: checking for backtrace_symbols_fd" >&5 -$as_echo_n "checking for backtrace_symbols_fd... " >&6; } -if test "${ac_cv_func_backtrace_symbols_fd+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 backtrace_symbols_fd to an innocuous variant, in case declares backtrace_symbols_fd. - For example, HP-UX 11i declares gettimeofday. */ -#define backtrace_symbols_fd innocuous_backtrace_symbols_fd - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char backtrace_symbols_fd (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef backtrace_symbols_fd - -/* 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 backtrace_symbols_fd (); -/* 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_backtrace_symbols_fd || defined __stub___backtrace_symbols_fd -choke me -#endif - -int -main () -{ -return backtrace_symbols_fd (); - ; - 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_backtrace_symbols_fd=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_backtrace_symbols_fd=no -fi + ac_fn_c_check_header_mongrel "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default" +if test "x$ac_cv_header_execinfo_h" = xyes; then : -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_backtrace_symbols_fd" >&5 -$as_echo "$ac_cv_func_backtrace_symbols_fd" >&6; } -if test "x$ac_cv_func_backtrace_symbols_fd" = x""yes; then + ac_fn_c_check_func "$LINENO" "backtrace_symbols_fd" "ac_cv_func_backtrace_symbols_fd" +if test "x$ac_cv_func_backtrace_symbols_fd" = xyes; then : -cat >>confdefs.h <<\_ACEOF -#define HAVE_GLIBC_BACKTRACE 1 -_ACEOF +$as_echo "#define HAVE_GLIBC_BACKTRACE 1" >>confdefs.h fi @@ -57961,111 +38302,21 @@ fi # ice_have_accept=no - for ac_func in accept -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "accept" "ac_cv_func_accept" +if test "x$ac_cv_func_accept" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ACCEPT 1 _ACEOF ice_have_accept=yes fi done if test "${ice_have_accept}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for accept declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for accept declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for accept declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_accept_decl+set}" = set; then +if ${ice_cv_have_accept_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -58074,17 +38325,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}accept[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}accept[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_accept_decl=yes fi rm -f conftest* @@ -58093,17 +38340,13 @@ if test "$ice_cv_have_accept_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}accept[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}accept[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_accept_decl=yes fi rm -f conftest* @@ -58115,7 +38358,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_accept_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_accept_decl" >&5 $as_echo "$ice_cv_have_accept_decl" >&6; } if test "$ice_cv_have_accept_decl" = yes; then @@ -58128,16 +38371,12 @@ fi # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works # for constant arguments. Useless! -{ $as_echo "$as_me:$LINENO: checking for working alloca.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 $as_echo_n "checking for working alloca.h... " >&6; } -if test "${ac_cv_working_alloca_h+set}" = set; then +if ${ac_cv_working_alloca_h+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -58149,59 +38388,28 @@ char *p = (char *) alloca (2 * sizeof (int)); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_working_alloca_h=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_working_alloca_h=no + ac_cv_working_alloca_h=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_working_alloca_h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 $as_echo "$ac_cv_working_alloca_h" >&6; } if test $ac_cv_working_alloca_h = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_ALLOCA_H 1 -_ACEOF +$as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h fi -{ $as_echo "$as_me:$LINENO: checking for alloca" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 $as_echo_n "checking for alloca... " >&6; } -if test "${ac_cv_func_alloca_works+set}" = set; then +if ${ac_cv_func_alloca_works+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __GNUC__ # define alloca __builtin_alloca @@ -58217,7 +38425,7 @@ cat >>conftest.$ac_ext <<_ACEOF #pragma alloca # else # ifndef alloca /* predefined by HP cc +Olibcalls */ -char *alloca (); +void *alloca (size_t); # endif # endif # endif @@ -58233,47 +38441,20 @@ char *p = (char *) alloca (1); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_func_alloca_works=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_alloca_works=no + ac_cv_func_alloca_works=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_alloca_works" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 $as_echo "$ac_cv_func_alloca_works" >&6; } if test $ac_cv_func_alloca_works = yes; then -cat >>confdefs.h <<\_ACEOF -#define HAVE_ALLOCA 1 -_ACEOF +$as_echo "#define HAVE_ALLOCA 1" >>confdefs.h else # The SVR3 libPW and SVR4 libucb both contain incompatible functions @@ -58283,21 +38464,15 @@ else ALLOCA=\${LIBOBJDIR}alloca.$ac_objext -cat >>confdefs.h <<\_ACEOF -#define C_ALLOCA 1 -_ACEOF +$as_echo "#define C_ALLOCA 1" >>confdefs.h -{ $as_echo "$as_me:$LINENO: checking whether \`alloca.c' needs Cray hooks" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } -if test "${ac_cv_os_cray+set}" = set; then +if ${ac_cv_os_cray+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined CRAY && ! defined CRAY2 webecray @@ -58307,7 +38482,7 @@ wenotbecray _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "webecray" >/dev/null 2>&1; then + $EGREP "webecray" >/dev/null 2>&1; then : ac_cv_os_cray=yes else ac_cv_os_cray=no @@ -58315,101 +38490,13 @@ fi rm -f conftest* fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 $as_echo "$ac_cv_os_cray" >&6; } if test $ac_cv_os_cray = yes; then for ac_func in _getb67 GETB67 getb67; do as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define CRAY_STACKSEG_END $ac_func @@ -58421,19 +38508,15 @@ fi done fi -{ $as_echo "$as_me:$LINENO: checking stack direction for C alloca" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 $as_echo_n "checking stack direction for C alloca... " >&6; } -if test "${ac_cv_c_stack_direction+set}" = set; then +if ${ac_cv_c_stack_direction+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : ac_cv_c_stack_direction=0 else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int @@ -58445,160 +38528,42 @@ find_stack_direction () { addr = &dummy; return find_stack_direction (); - } - else - return (&dummy > addr) ? 1 : -1; -} - -int -main () -{ - return find_stack_direction () < 0; -} -_ACEOF -rm -f conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { ac_try='./conftest$ac_exeext' - { (case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; }; then - ac_cv_c_stack_direction=1 -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_c_stack_direction=-1 -fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext -fi - - -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5 -$as_echo "$ac_cv_c_stack_direction" >&6; } - -cat >>confdefs.h <<_ACEOF -#define STACK_DIRECTION $ac_cv_c_stack_direction -_ACEOF - - -fi - - -for ac_func in atexit -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif + } + else + return (&dummy > addr) ? 1 : -1; +} int main () { -return $ac_func (); - ; - return 0; + return find_stack_direction () < 0; } _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" +if ac_fn_c_try_run "$LINENO"; then : + ac_cv_c_stack_direction=1 else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 + ac_cv_c_stack_direction=-1 +fi +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext +fi - eval "$as_ac_var=no" fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 +$as_echo "$ac_cv_c_stack_direction" >&6; } +cat >>confdefs.h <<_ACEOF +#define STACK_DIRECTION $ac_cv_c_stack_direction +_ACEOF + -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + +for ac_func in atexit +do : + ac_fn_c_check_func "$LINENO" "atexit" "ac_cv_func_atexit" +if test "x$ac_cv_func_atexit" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ATEXIT 1 _ACEOF fi @@ -58606,111 +38571,21 @@ done ice_have_atof=no - for ac_func in atof -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "atof" "ac_cv_func_atof" +if test "x$ac_cv_func_atof" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ATOF 1 _ACEOF ice_have_atof=yes fi done if test "${ice_have_atof}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for atof declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for atof declaration in stdlib.h" >&5 $as_echo_n "checking for atof declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_atof_decl+set}" = set; then +if ${ice_cv_have_atof_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -58719,17 +38594,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}atof[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}atof[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_atof_decl=yes fi rm -f conftest* @@ -58738,17 +38609,13 @@ if test "$ice_cv_have_atof_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}atof[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}atof[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_atof_decl=yes fi rm -f conftest* @@ -58760,7 +38627,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_atof_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_atof_decl" >&5 $as_echo "$ice_cv_have_atof_decl" >&6; } if test "$ice_cv_have_atof_decl" = yes; then @@ -58773,111 +38640,21 @@ fi ice_have_atol=no - for ac_func in atol -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "atol" "ac_cv_func_atol" +if test "x$ac_cv_func_atol" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ATOL 1 _ACEOF ice_have_atol=yes fi done if test "${ice_have_atol}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for atol declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for atol declaration in stdlib.h" >&5 $as_echo_n "checking for atol declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_atol_decl+set}" = set; then +if ${ice_cv_have_atol_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -58886,17 +38663,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}atol[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}atol[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_atol_decl=yes fi rm -f conftest* @@ -58905,17 +38678,13 @@ if test "$ice_cv_have_atol_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}atol[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}atol[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_atol_decl=yes fi rm -f conftest* @@ -58927,7 +38696,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_atol_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_atol_decl" >&5 $as_echo "$ice_cv_have_atol_decl" >&6; } if test "$ice_cv_have_atol_decl" = yes; then @@ -58940,111 +38709,21 @@ fi ice_have_atoll=no - for ac_func in atoll -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "atoll" "ac_cv_func_atoll" +if test "x$ac_cv_func_atoll" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ATOLL 1 _ACEOF ice_have_atoll=yes fi done if test "${ice_have_atoll}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for atoll declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for atoll declaration in stdlib.h" >&5 $as_echo_n "checking for atoll declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_atoll_decl+set}" = set; then +if ${ice_cv_have_atoll_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -59053,17 +38732,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}atoll[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}atoll[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_atoll_decl=yes fi rm -f conftest* @@ -59072,17 +38747,13 @@ if test "$ice_cv_have_atoll_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}atoll[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}atoll[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_atoll_decl=yes fi rm -f conftest* @@ -59094,7 +38765,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_atoll_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_atoll_decl" >&5 $as_echo "$ice_cv_have_atoll_decl" >&6; } if test "$ice_cv_have_atoll_decl" = yes; then @@ -59107,111 +38778,21 @@ fi ice_have_strtol=no - for ac_func in strtol -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "strtol" "ac_cv_func_strtol" +if test "x$ac_cv_func_strtol" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_STRTOL 1 _ACEOF ice_have_strtol=yes fi done if test "${ice_have_strtol}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for strtol declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strtol declaration in stdlib.h" >&5 $as_echo_n "checking for strtol declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_strtol_decl+set}" = set; then +if ${ice_cv_have_strtol_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -59220,17 +38801,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strtol[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strtol[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_strtol_decl=yes fi rm -f conftest* @@ -59239,17 +38816,13 @@ if test "$ice_cv_have_strtol_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strtol[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strtol[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_strtol_decl=yes fi rm -f conftest* @@ -59261,7 +38834,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_strtol_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_strtol_decl" >&5 $as_echo "$ice_cv_have_strtol_decl" >&6; } if test "$ice_cv_have_strtol_decl" = yes; then @@ -59274,111 +38847,21 @@ fi ice_have_strtoll=no - for ac_func in strtoll -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll" +if test "x$ac_cv_func_strtoll" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_STRTOLL 1 _ACEOF ice_have_strtoll=yes fi done if test "${ice_have_strtoll}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for strtoll declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strtoll declaration in stdlib.h" >&5 $as_echo_n "checking for strtoll declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_strtoll_decl+set}" = set; then +if ${ice_cv_have_strtoll_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -59387,17 +38870,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strtoll[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strtoll[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_strtoll_decl=yes fi rm -f conftest* @@ -59406,17 +38885,13 @@ if test "$ice_cv_have_strtoll_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strtoll[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strtoll[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_strtoll_decl=yes fi rm -f conftest* @@ -59428,7 +38903,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_strtoll_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_strtoll_decl" >&5 $as_echo "$ice_cv_have_strtoll_decl" >&6; } if test "$ice_cv_have_strtoll_decl" = yes; then @@ -59439,102 +38914,12 @@ _ACEOF fi fi - for ac_func in basename -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "basename" "ac_cv_func_basename" +if test "x$ac_cv_func_basename" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_BASENAME 1 _ACEOF fi @@ -59542,111 +38927,21 @@ done ice_have_bind=no - for ac_func in bind -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "bind" "ac_cv_func_bind" +if test "x$ac_cv_func_bind" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_BIND 1 _ACEOF ice_have_bind=yes fi done if test "${ice_have_bind}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for bind declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for bind declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for bind declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_bind_decl+set}" = set; then +if ${ice_cv_have_bind_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -59655,17 +38950,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}bind[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}bind[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_bind_decl=yes fi rm -f conftest* @@ -59674,17 +38965,13 @@ if test "$ice_cv_have_bind_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}bind[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}bind[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_bind_decl=yes fi rm -f conftest* @@ -59696,124 +38983,34 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_bind_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_bind_decl" >&5 $as_echo "$ice_cv_have_bind_decl" >&6; } if test "$ice_cv_have_bind_decl" = yes; then -cat >>confdefs.h <<_ACEOF -#define HAVE_BIND_DECL 1 -_ACEOF - -fi -fi - - -ice_have_bcopy=no - -for ac_func in bcopy -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +cat >>confdefs.h <<_ACEOF +#define HAVE_BIND_DECL 1 +_ACEOF - eval "$as_ac_var=no" fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + + +ice_have_bcopy=no +for ac_func in bcopy +do : + ac_fn_c_check_func "$LINENO" "bcopy" "ac_cv_func_bcopy" +if test "x$ac_cv_func_bcopy" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_BCOPY 1 _ACEOF ice_have_bcopy=yes fi done if test "${ice_have_bcopy}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for bcopy declaration in string.h strings.h stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for bcopy declaration in string.h strings.h stdlib.h" >&5 $as_echo_n "checking for bcopy declaration in string.h strings.h stdlib.h... " >&6; } -if test "${ice_cv_have_bcopy_decl+set}" = set; then +if ${ice_cv_have_bcopy_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -59822,17 +39019,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in string.h strings.h stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}bcopy[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}bcopy[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_bcopy_decl=yes fi rm -f conftest* @@ -59841,17 +39034,13 @@ if test "$ice_cv_have_bcopy_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}bcopy[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}bcopy[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_bcopy_decl=yes fi rm -f conftest* @@ -59863,7 +39052,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_bcopy_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_bcopy_decl" >&5 $as_echo "$ice_cv_have_bcopy_decl" >&6; } if test "$ice_cv_have_bcopy_decl" = yes; then @@ -59876,111 +39065,21 @@ fi ice_have_bzero=no - for ac_func in bzero -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "bzero" "ac_cv_func_bzero" +if test "x$ac_cv_func_bzero" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_BZERO 1 _ACEOF ice_have_bzero=yes fi done if test "${ice_have_bzero}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for bzero declaration in string.h strings.h stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for bzero declaration in string.h strings.h stdlib.h" >&5 $as_echo_n "checking for bzero declaration in string.h strings.h stdlib.h... " >&6; } -if test "${ice_cv_have_bzero_decl+set}" = set; then +if ${ice_cv_have_bzero_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -59989,17 +39088,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in string.h strings.h stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}bzero[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}bzero[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_bzero_decl=yes fi rm -f conftest* @@ -60008,17 +39103,13 @@ if test "$ice_cv_have_bzero_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}bzero[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}bzero[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_bzero_decl=yes fi rm -f conftest* @@ -60030,7 +39121,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_bzero_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_bzero_decl" >&5 $as_echo "$ice_cv_have_bzero_decl" >&6; } if test "$ice_cv_have_bzero_decl" = yes; then @@ -60041,19 +39132,15 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: checking whether closedir returns void" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether closedir returns void" >&5 $as_echo_n "checking whether closedir returns void... " >&6; } -if test "${ac_cv_func_closedir_void+set}" = set; then +if ${ac_cv_func_closedir_void+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then + if test "$cross_compiling" = yes; then : ac_cv_func_closedir_void=yes else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default #include <$ac_header_dirent> @@ -60069,160 +39156,41 @@ return closedir (opendir (".")) != 0; 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 +if ac_fn_c_try_run "$LINENO"; then : ac_cv_func_closedir_void=no else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_func_closedir_void=yes + ac_cv_func_closedir_void=yes fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_closedir_void" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_closedir_void" >&5 $as_echo "$ac_cv_func_closedir_void" >&6; } if test $ac_cv_func_closedir_void = yes; then -cat >>confdefs.h <<\_ACEOF -#define CLOSEDIR_VOID 1 -_ACEOF +$as_echo "#define CLOSEDIR_VOID 1" >>confdefs.h fi ice_have_closelog=no - for ac_func in closelog -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "closelog" "ac_cv_func_closelog" +if test "x$ac_cv_func_closelog" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_CLOSELOG 1 _ACEOF ice_have_closelog=yes fi done if test "${ice_have_closelog}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for closelog declaration in syslog.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for closelog declaration in syslog.h" >&5 $as_echo_n "checking for closelog declaration in syslog.h... " >&6; } -if test "${ice_cv_have_closelog_decl+set}" = set; then +if ${ice_cv_have_closelog_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -60231,17 +39199,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in syslog.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}closelog[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}closelog[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_closelog_decl=yes fi rm -f conftest* @@ -60250,17 +39214,13 @@ if test "$ice_cv_have_closelog_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}closelog[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}closelog[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_closelog_decl=yes fi rm -f conftest* @@ -60272,7 +39232,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_closelog_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_closelog_decl" >&5 $as_echo "$ice_cv_have_closelog_decl" >&6; } if test "$ice_cv_have_closelog_decl" = yes; then @@ -60285,111 +39245,21 @@ fi ice_have_connect=no - for ac_func in connect -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "connect" "ac_cv_func_connect" +if test "x$ac_cv_func_connect" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_CONNECT 1 _ACEOF ice_have_connect=yes fi done if test "${ice_have_connect}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for connect declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for connect declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_connect_decl+set}" = set; then +if ${ice_cv_have_connect_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -60398,17 +39268,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}connect[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}connect[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_connect_decl=yes fi rm -f conftest* @@ -60417,17 +39283,13 @@ if test "$ice_cv_have_connect_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}connect[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}connect[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_connect_decl=yes fi rm -f conftest* @@ -60439,7 +39301,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_connect_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_connect_decl" >&5 $as_echo "$ice_cv_have_connect_decl" >&6; } if test "$ice_cv_have_connect_decl" = yes; then @@ -60452,111 +39314,21 @@ fi ice_have_fclose=no - for ac_func in fclose -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "fclose" "ac_cv_func_fclose" +if test "x$ac_cv_func_fclose" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FCLOSE 1 _ACEOF ice_have_fclose=yes fi done if test "${ice_have_fclose}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fclose declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fclose declaration in stdio.h" >&5 $as_echo_n "checking for fclose declaration in stdio.h... " >&6; } -if test "${ice_cv_have_fclose_decl+set}" = set; then +if ${ice_cv_have_fclose_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -60565,17 +39337,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fclose[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fclose[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fclose_decl=yes fi rm -f conftest* @@ -60584,17 +39352,13 @@ if test "$ice_cv_have_fclose_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fclose[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fclose[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fclose_decl=yes fi rm -f conftest* @@ -60606,7 +39370,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fclose_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fclose_decl" >&5 $as_echo "$ice_cv_have_fclose_decl" >&6; } if test "$ice_cv_have_fclose_decl" = yes; then @@ -60619,111 +39383,21 @@ fi ice_have_fflush=no - for ac_func in fflush -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "fflush" "ac_cv_func_fflush" +if test "x$ac_cv_func_fflush" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FFLUSH 1 _ACEOF ice_have_fflush=yes fi done if test "${ice_have_fflush}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fflush declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fflush declaration in stdio.h" >&5 $as_echo_n "checking for fflush declaration in stdio.h... " >&6; } -if test "${ice_cv_have_fflush_decl+set}" = set; then +if ${ice_cv_have_fflush_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -60732,17 +39406,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fflush[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fflush[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fflush_decl=yes fi rm -f conftest* @@ -60751,17 +39421,13 @@ if test "$ice_cv_have_fflush_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fflush[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fflush[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fflush_decl=yes fi rm -f conftest* @@ -60773,7 +39439,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fflush_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fflush_decl" >&5 $as_echo "$ice_cv_have_fflush_decl" >&6; } if test "$ice_cv_have_fflush_decl" = yes; then @@ -60786,111 +39452,21 @@ fi ice_have_fprintf=no - for ac_func in fprintf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "fprintf" "ac_cv_func_fprintf" +if test "x$ac_cv_func_fprintf" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FPRINTF 1 _ACEOF ice_have_fprintf=yes fi done if test "${ice_have_fprintf}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fprintf declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fprintf declaration in stdio.h" >&5 $as_echo_n "checking for fprintf declaration in stdio.h... " >&6; } -if test "${ice_cv_have_fprintf_decl+set}" = set; then +if ${ice_cv_have_fprintf_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -60899,17 +39475,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fprintf[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fprintf[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fprintf_decl=yes fi rm -f conftest* @@ -60918,17 +39490,13 @@ if test "$ice_cv_have_fprintf_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fprintf_decl=yes fi rm -f conftest* @@ -60940,7 +39508,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fprintf_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fprintf_decl" >&5 $as_echo "$ice_cv_have_fprintf_decl" >&6; } if test "$ice_cv_have_fprintf_decl" = yes; then @@ -60953,111 +39521,21 @@ fi ice_have_fputc=no - for ac_func in fputc -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "fputc" "ac_cv_func_fputc" +if test "x$ac_cv_func_fputc" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FPUTC 1 _ACEOF ice_have_fputc=yes fi done if test "${ice_have_fputc}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fputc declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fputc declaration in stdio.h" >&5 $as_echo_n "checking for fputc declaration in stdio.h... " >&6; } -if test "${ice_cv_have_fputc_decl+set}" = set; then +if ${ice_cv_have_fputc_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -61066,17 +39544,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fputc[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fputc[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fputc_decl=yes fi rm -f conftest* @@ -61085,17 +39559,13 @@ if test "$ice_cv_have_fputc_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fputc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fputc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fputc_decl=yes fi rm -f conftest* @@ -61107,7 +39577,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fputc_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fputc_decl" >&5 $as_echo "$ice_cv_have_fputc_decl" >&6; } if test "$ice_cv_have_fputc_decl" = yes; then @@ -61118,113 +39588,23 @@ _ACEOF fi fi - -ice_have_fputs=no - -for ac_func in fputs -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + +ice_have_fputs=no +for ac_func in fputs +do : + ac_fn_c_check_func "$LINENO" "fputs" "ac_cv_func_fputs" +if test "x$ac_cv_func_fputs" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FPUTS 1 _ACEOF ice_have_fputs=yes fi done if test "${ice_have_fputs}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fputs declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fputs declaration in stdio.h" >&5 $as_echo_n "checking for fputs declaration in stdio.h... " >&6; } -if test "${ice_cv_have_fputs_decl+set}" = set; then +if ${ice_cv_have_fputs_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -61233,17 +39613,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fputs[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fputs[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fputs_decl=yes fi rm -f conftest* @@ -61252,17 +39628,13 @@ if test "$ice_cv_have_fputs_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fputs[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fputs[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fputs_decl=yes fi rm -f conftest* @@ -61274,7 +39646,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fputs_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fputs_decl" >&5 $as_echo "$ice_cv_have_fputs_decl" >&6; } if test "$ice_cv_have_fputs_decl" = yes; then @@ -61287,111 +39659,21 @@ fi ice_have_fread=no - for ac_func in fread -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "fread" "ac_cv_func_fread" +if test "x$ac_cv_func_fread" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FREAD 1 _ACEOF ice_have_fread=yes fi done if test "${ice_have_fread}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fread declaration in stdio.h stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fread declaration in stdio.h stdlib.h" >&5 $as_echo_n "checking for fread declaration in stdio.h stdlib.h... " >&6; } -if test "${ice_cv_have_fread_decl+set}" = set; then +if ${ice_cv_have_fread_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -61400,17 +39682,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fread[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fread[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fread_decl=yes fi rm -f conftest* @@ -61419,17 +39697,13 @@ if test "$ice_cv_have_fread_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fread[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fread[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fread_decl=yes fi rm -f conftest* @@ -61441,7 +39715,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fread_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fread_decl" >&5 $as_echo "$ice_cv_have_fread_decl" >&6; } if test "$ice_cv_have_fread_decl" = yes; then @@ -61454,111 +39728,21 @@ fi ice_have_fseek=no - for ac_func in fseek -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "fseek" "ac_cv_func_fseek" +if test "x$ac_cv_func_fseek" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FSEEK 1 _ACEOF ice_have_fseek=yes fi done if test "${ice_have_fseek}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fseek declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fseek declaration in stdio.h" >&5 $as_echo_n "checking for fseek declaration in stdio.h... " >&6; } -if test "${ice_cv_have_fseek_decl+set}" = set; then +if ${ice_cv_have_fseek_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -61567,17 +39751,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fseek[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fseek[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fseek_decl=yes fi rm -f conftest* @@ -61586,17 +39766,13 @@ if test "$ice_cv_have_fseek_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fseek[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fseek[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fseek_decl=yes fi rm -f conftest* @@ -61608,7 +39784,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fseek_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fseek_decl" >&5 $as_echo "$ice_cv_have_fseek_decl" >&6; } if test "$ice_cv_have_fseek_decl" = yes; then @@ -61621,111 +39797,21 @@ fi ice_have_fwrite=no - for ac_func in fwrite -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "fwrite" "ac_cv_func_fwrite" +if test "x$ac_cv_func_fwrite" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_FWRITE 1 _ACEOF ice_have_fwrite=yes fi done if test "${ice_have_fwrite}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for fwrite declaration in stdio.h stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fwrite declaration in stdio.h stdlib.h" >&5 $as_echo_n "checking for fwrite declaration in stdio.h stdlib.h... " >&6; } -if test "${ice_cv_have_fwrite_decl+set}" = set; then +if ${ice_cv_have_fwrite_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -61734,17 +39820,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fwrite[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fwrite[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_fwrite_decl=yes fi rm -f conftest* @@ -61753,17 +39835,13 @@ if test "$ice_cv_have_fwrite_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}fwrite[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}fwrite[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_fwrite_decl=yes fi rm -f conftest* @@ -61775,7 +39853,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_fwrite_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_fwrite_decl" >&5 $as_echo "$ice_cv_have_fwrite_decl" >&6; } if test "$ice_cv_have_fwrite_decl" = yes; then @@ -61786,203 +39864,23 @@ _ACEOF fi fi - for ac_func in getgrgid_r -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "getgrgid_r" "ac_cv_func_getgrgid_r" +if test "x$ac_cv_func_getgrgid_r" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETGRGID_R 1 _ACEOF fi done - for ac_func in getpwuid_r -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "getpwuid_r" "ac_cv_func_getpwuid_r" +if test "x$ac_cv_func_getpwuid_r" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETPWUID_R 1 _ACEOF fi @@ -61990,111 +39888,21 @@ done ice_have_gethostname=no - for ac_func in gethostname -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "gethostname" "ac_cv_func_gethostname" +if test "x$ac_cv_func_gethostname" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETHOSTNAME 1 _ACEOF ice_have_gethostname=yes fi done if test "${ice_have_gethostname}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for gethostname declaration in unistd.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostname declaration in unistd.h" >&5 $as_echo_n "checking for gethostname declaration in unistd.h... " >&6; } -if test "${ice_cv_have_gethostname_decl+set}" = set; then +if ${ice_cv_have_gethostname_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -62103,17 +39911,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in unistd.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}gethostname[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}gethostname[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_gethostname_decl=yes fi rm -f conftest* @@ -62122,17 +39926,13 @@ if test "$ice_cv_have_gethostname_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}gethostname[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}gethostname[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_gethostname_decl=yes fi rm -f conftest* @@ -62144,7 +39944,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_gethostname_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_gethostname_decl" >&5 $as_echo "$ice_cv_have_gethostname_decl" >&6; } if test "$ice_cv_have_gethostname_decl" = yes; then @@ -62157,111 +39957,21 @@ fi ice_have_getopt=no - for ac_func in getopt -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "getopt" "ac_cv_func_getopt" +if test "x$ac_cv_func_getopt" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETOPT 1 _ACEOF ice_have_getopt=yes fi done if test "${ice_have_getopt}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for getopt declaration in stdlib.h unistd.h libc.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getopt declaration in stdlib.h unistd.h libc.h" >&5 $as_echo_n "checking for getopt declaration in stdlib.h unistd.h libc.h... " >&6; } -if test "${ice_cv_have_getopt_decl+set}" = set; then +if ${ice_cv_have_getopt_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -62270,17 +39980,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h unistd.h libc.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getopt[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getopt[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_getopt_decl=yes fi rm -f conftest* @@ -62289,17 +39995,13 @@ if test "$ice_cv_have_getopt_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getopt[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getopt[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_getopt_decl=yes fi rm -f conftest* @@ -62311,7 +40013,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_getopt_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_getopt_decl" >&5 $as_echo "$ice_cv_have_getopt_decl" >&6; } if test "$ice_cv_have_getopt_decl" = yes; then @@ -62324,111 +40026,21 @@ fi ice_have_getpeername=no - for ac_func in getpeername -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "getpeername" "ac_cv_func_getpeername" +if test "x$ac_cv_func_getpeername" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETPEERNAME 1 _ACEOF ice_have_getpeername=yes fi done if test "${ice_have_getpeername}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for getpeername declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpeername declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for getpeername declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_getpeername_decl+set}" = set; then +if ${ice_cv_have_getpeername_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -62437,17 +40049,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getpeername[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getpeername[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_getpeername_decl=yes fi rm -f conftest* @@ -62456,136 +40064,47 @@ if test "$ice_cv_have_getpeername_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getpeername[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getpeername[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_getpeername_decl=yes fi rm -f conftest* if test "$ice_cv_have_getpeername_decl" = yes; then break -fi -done - -fi - -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_getpeername_decl" >&5 -$as_echo "$ice_cv_have_getpeername_decl" >&6; } -if test "$ice_cv_have_getpeername_decl" = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_GETPEERNAME_DECL 1 -_ACEOF - -fi -fi - -{ $as_echo "$as_me:$LINENO: checking for getpgrp" >&5 -$as_echo_n "checking for getpgrp... " >&6; } -if test "${ac_cv_func_getpgrp+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 getpgrp to an innocuous variant, in case declares getpgrp. - For example, HP-UX 11i declares gettimeofday. */ -#define getpgrp innocuous_getpgrp - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char getpgrp (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif +fi +done -#undef getpgrp +fi -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char getpgrp (); -/* 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_getpgrp || defined __stub___getpgrp -choke me -#endif +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_getpeername_decl" >&5 +$as_echo "$ice_cv_have_getpeername_decl" >&6; } +if test "$ice_cv_have_getpeername_decl" = yes; then -int -main () -{ -return getpgrp (); - ; - return 0; -} +cat >>confdefs.h <<_ACEOF +#define HAVE_GETPEERNAME_DECL 1 _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_getpgrp=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - ac_cv_func_getpgrp=no fi +fi + +ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" +if test "x$ac_cv_func_getpgrp" = xyes; then : -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_getpgrp" >&5 -$as_echo "$ac_cv_func_getpgrp" >&6; } -{ $as_echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; } -if test "${ac_cv_func_getpgrp_void+set}" = set; then +if ${ac_cv_func_getpgrp_void+:} false; then : $as_echo_n "(cached) " >&6 else # Use it with a single arg. -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int @@ -62596,152 +40115,39 @@ getpgrp (0); return 0; } _ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then +if ac_fn_c_try_compile "$LINENO"; then : ac_cv_func_getpgrp_void=no else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_getpgrp_void=yes + ac_cv_func_getpgrp_void=yes fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5 $as_echo "$ac_cv_func_getpgrp_void" >&6; } if test $ac_cv_func_getpgrp_void = yes; then -cat >>confdefs.h <<\_ACEOF -#define GETPGRP_VOID 1 -_ACEOF +$as_echo "#define GETPGRP_VOID 1" >>confdefs.h fi ice_have_getsockname=no - for ac_func in getsockname -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "getsockname" "ac_cv_func_getsockname" +if test "x$ac_cv_func_getsockname" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETSOCKNAME 1 _ACEOF ice_have_getsockname=yes fi done if test "${ice_have_getsockname}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for getsockname declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getsockname declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for getsockname declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_getsockname_decl+set}" = set; then +if ${ice_cv_have_getsockname_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -62750,17 +40156,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getsockname[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getsockname[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_getsockname_decl=yes fi rm -f conftest* @@ -62769,17 +40171,13 @@ if test "$ice_cv_have_getsockname_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getsockname[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getsockname[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_getsockname_decl=yes fi rm -f conftest* @@ -62791,7 +40189,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_getsockname_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_getsockname_decl" >&5 $as_echo "$ice_cv_have_getsockname_decl" >&6; } if test "$ice_cv_have_getsockname_decl" = yes; then @@ -62804,111 +40202,21 @@ fi ice_have_getsockopt=no - for ac_func in getsockopt -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "getsockopt" "ac_cv_func_getsockopt" +if test "x$ac_cv_func_getsockopt" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_GETSOCKOPT 1 _ACEOF ice_have_getsockopt=yes fi done if test "${ice_have_getsockopt}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for getsockopt declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for getsockopt declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for getsockopt declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_getsockopt_decl+set}" = set; then +if ${ice_cv_have_getsockopt_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -62917,17 +40225,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getsockopt[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getsockopt[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_getsockopt_decl=yes fi rm -f conftest* @@ -62936,17 +40240,13 @@ if test "$ice_cv_have_getsockopt_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}getsockopt[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}getsockopt[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_getsockopt_decl=yes fi rm -f conftest* @@ -62958,7 +40258,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_getsockopt_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_getsockopt_decl" >&5 $as_echo "$ice_cv_have_getsockopt_decl" >&6; } if test "$ice_cv_have_getsockopt_decl" = yes; then @@ -62971,111 +40271,21 @@ fi ice_have_initgroups=no - for ac_func in initgroups -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "initgroups" "ac_cv_func_initgroups" +if test "x$ac_cv_func_initgroups" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_INITGROUPS 1 _ACEOF ice_have_initgroups=yes fi done if test "${ice_have_initgroups}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for initgroups declaration in grp.h sys/types.h unistd.h libc.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for initgroups declaration in grp.h sys/types.h unistd.h libc.h" >&5 $as_echo_n "checking for initgroups declaration in grp.h sys/types.h unistd.h libc.h... " >&6; } -if test "${ice_cv_have_initgroups_decl+set}" = set; then +if ${ice_cv_have_initgroups_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -63084,17 +40294,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in grp.h sys/types.h unistd.h libc.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}initgroups[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}initgroups[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_initgroups_decl=yes fi rm -f conftest* @@ -63103,17 +40309,13 @@ if test "$ice_cv_have_initgroups_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}initgroups[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}initgroups[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_initgroups_decl=yes fi rm -f conftest* @@ -63125,7 +40327,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_initgroups_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_initgroups_decl" >&5 $as_echo "$ice_cv_have_initgroups_decl" >&6; } if test "$ice_cv_have_initgroups_decl" = yes; then @@ -63138,111 +40340,21 @@ fi ice_have_ioctl=no - for ac_func in ioctl -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "ioctl" "ac_cv_func_ioctl" +if test "x$ac_cv_func_ioctl" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_IOCTL 1 _ACEOF ice_have_ioctl=yes fi done if test "${ice_have_ioctl}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for ioctl declaration in sys/ioctl.h unistd.h libc.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ioctl declaration in sys/ioctl.h unistd.h libc.h" >&5 $as_echo_n "checking for ioctl declaration in sys/ioctl.h unistd.h libc.h... " >&6; } -if test "${ice_cv_have_ioctl_decl+set}" = set; then +if ${ice_cv_have_ioctl_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -63251,17 +40363,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/ioctl.h unistd.h libc.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}ioctl[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}ioctl[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_ioctl_decl=yes fi rm -f conftest* @@ -63270,17 +40378,13 @@ if test "$ice_cv_have_ioctl_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}ioctl[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}ioctl[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_ioctl_decl=yes fi rm -f conftest* @@ -63292,7 +40396,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_ioctl_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_ioctl_decl" >&5 $as_echo "$ice_cv_have_ioctl_decl" >&6; } if test "$ice_cv_have_ioctl_decl" = yes; then @@ -63305,111 +40409,21 @@ fi ice_have_isnormal=no - for ac_func in isnormal -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "isnormal" "ac_cv_func_isnormal" +if test "x$ac_cv_func_isnormal" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ISNORMAL 1 _ACEOF ice_have_isnormal=yes fi done if test "${ice_have_isnormal}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for isnormal declaration in math.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for isnormal declaration in math.h" >&5 $as_echo_n "checking for isnormal declaration in math.h... " >&6; } -if test "${ice_cv_have_isnormal_decl+set}" = set; then +if ${ice_cv_have_isnormal_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -63418,17 +40432,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in math.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}isnormal[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}isnormal[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_isnormal_decl=yes fi rm -f conftest* @@ -63437,17 +40447,13 @@ if test "$ice_cv_have_isnormal_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}isnormal[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}isnormal[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_isnormal_decl=yes fi rm -f conftest* @@ -63459,7 +40465,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_isnormal_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_isnormal_decl" >&5 $as_echo "$ice_cv_have_isnormal_decl" >&6; } if test "$ice_cv_have_isnormal_decl" = yes; then @@ -63472,111 +40478,21 @@ fi ice_have_listen=no - for ac_func in listen -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "listen" "ac_cv_func_listen" +if test "x$ac_cv_func_listen" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_LISTEN 1 _ACEOF ice_have_listen=yes fi done if test "${ice_have_listen}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for listen declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for listen declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for listen declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_listen_decl+set}" = set; then +if ${ice_cv_have_listen_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -63585,17 +40501,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}listen[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}listen[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_listen_decl=yes fi rm -f conftest* @@ -63604,17 +40516,13 @@ if test "$ice_cv_have_listen_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}listen[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}listen[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_listen_decl=yes fi rm -f conftest* @@ -63626,7 +40534,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_listen_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_listen_decl" >&5 $as_echo "$ice_cv_have_listen_decl" >&6; } if test "$ice_cv_have_listen_decl" = yes; then @@ -63639,111 +40547,21 @@ fi ice_have_lstat=no - for ac_func in lstat -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "lstat" "ac_cv_func_lstat" +if test "x$ac_cv_func_lstat" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_LSTAT 1 _ACEOF ice_have_lstat=yes fi done if test "${ice_have_lstat}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for lstat declaration in sys/types.h sys/stat.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for lstat declaration in sys/types.h sys/stat.h" >&5 $as_echo_n "checking for lstat declaration in sys/types.h sys/stat.h... " >&6; } -if test "${ice_cv_have_lstat_decl+set}" = set; then +if ${ice_cv_have_lstat_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -63752,17 +40570,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/stat.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}lstat[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}lstat[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_lstat_decl=yes fi rm -f conftest* @@ -63771,146 +40585,52 @@ if test "$ice_cv_have_lstat_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}lstat[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}lstat[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_lstat_decl=yes fi rm -f conftest* -if test "$ice_cv_have_lstat_decl" = yes; then - break -fi -done - -fi - -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_lstat_decl" >&5 -$as_echo "$ice_cv_have_lstat_decl" >&6; } -if test "$ice_cv_have_lstat_decl" = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_LSTAT_DECL 1 -_ACEOF - -fi -fi - - -ice_have_malloc=no - -for ac_func in malloc -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func +if test "$ice_cv_have_lstat_decl" = yes; then + break +fi +done -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif +fi -int -main () -{ -return $ac_func (); - ; - return 0; -} +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_lstat_decl" >&5 +$as_echo "$ice_cv_have_lstat_decl" >&6; } +if test "$ice_cv_have_lstat_decl" = yes; then + +cat >>confdefs.h <<_ACEOF +#define HAVE_LSTAT_DECL 1 _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_ac_var=no" fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + + +ice_have_malloc=no +for ac_func in malloc +do : + ac_fn_c_check_func "$LINENO" "malloc" "ac_cv_func_malloc" +if test "x$ac_cv_func_malloc" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_MALLOC 1 _ACEOF ice_have_malloc=yes fi done if test "${ice_have_malloc}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for malloc declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for malloc declaration in stdlib.h" >&5 $as_echo_n "checking for malloc declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_malloc_decl+set}" = set; then +if ${ice_cv_have_malloc_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -63919,17 +40639,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}malloc[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}malloc[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_malloc_decl=yes fi rm -f conftest* @@ -63938,17 +40654,13 @@ if test "$ice_cv_have_malloc_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}malloc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}malloc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_malloc_decl=yes fi rm -f conftest* @@ -63960,7 +40672,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_malloc_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_malloc_decl" >&5 $as_echo "$ice_cv_have_malloc_decl" >&6; } if test "$ice_cv_have_malloc_decl" = yes; then @@ -63973,111 +40685,21 @@ fi ice_have_memmove=no - for ac_func in memmove -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" +if test "x$ac_cv_func_memmove" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_MEMMOVE 1 _ACEOF ice_have_memmove=yes fi done if test "${ice_have_memmove}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for memmove declaration in string.h strings.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for memmove declaration in string.h strings.h" >&5 $as_echo_n "checking for memmove declaration in string.h strings.h... " >&6; } -if test "${ice_cv_have_memmove_decl+set}" = set; then +if ${ice_cv_have_memmove_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -64086,17 +40708,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in string.h strings.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}memmove[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}memmove[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_memmove_decl=yes fi rm -f conftest* @@ -64105,17 +40723,13 @@ if test "$ice_cv_have_memmove_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}memmove[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}memmove[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_memmove_decl=yes fi rm -f conftest* @@ -64127,7 +40741,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_memmove_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_memmove_decl" >&5 $as_echo "$ice_cv_have_memmove_decl" >&6; } if test "$ice_cv_have_memmove_decl" = yes; then @@ -64140,111 +40754,21 @@ fi ice_have_memset=no - for ac_func in memset -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "memset" "ac_cv_func_memset" +if test "x$ac_cv_func_memset" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_MEMSET 1 _ACEOF ice_have_memset=yes fi done if test "${ice_have_memset}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for memset declaration in string.h strings.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for memset declaration in string.h strings.h" >&5 $as_echo_n "checking for memset declaration in string.h strings.h... " >&6; } -if test "${ice_cv_have_memset_decl+set}" = set; then +if ${ice_cv_have_memset_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -64253,17 +40777,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in string.h strings.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}memset[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}memset[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_memset_decl=yes fi rm -f conftest* @@ -64272,17 +40792,13 @@ if test "$ice_cv_have_memset_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}memset[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}memset[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_memset_decl=yes fi rm -f conftest* @@ -64294,7 +40810,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_memset_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_memset_decl" >&5 $as_echo "$ice_cv_have_memset_decl" >&6; } if test "$ice_cv_have_memset_decl" = yes; then @@ -64307,111 +40823,21 @@ fi ice_have_mkstemp=no - for ac_func in mkstemp -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "mkstemp" "ac_cv_func_mkstemp" +if test "x$ac_cv_func_mkstemp" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_MKSTEMP 1 _ACEOF ice_have_mkstemp=yes fi done if test "${ice_have_mkstemp}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for mkstemp declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for mkstemp declaration in stdlib.h" >&5 $as_echo_n "checking for mkstemp declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_mkstemp_decl+set}" = set; then +if ${ice_cv_have_mkstemp_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -64420,17 +40846,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}mkstemp[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}mkstemp[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_mkstemp_decl=yes fi rm -f conftest* @@ -64439,17 +40861,13 @@ if test "$ice_cv_have_mkstemp_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}mkstemp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}mkstemp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_mkstemp_decl=yes fi rm -f conftest* @@ -64461,7 +40879,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_mkstemp_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_mkstemp_decl" >&5 $as_echo "$ice_cv_have_mkstemp_decl" >&6; } if test "$ice_cv_have_mkstemp_decl" = yes; then @@ -64474,111 +40892,21 @@ fi ice_have_mktemp=no - for ac_func in mktemp -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "mktemp" "ac_cv_func_mktemp" +if test "x$ac_cv_func_mktemp" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_MKTEMP 1 _ACEOF ice_have_mktemp=yes fi done if test "${ice_have_mktemp}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for mktemp declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for mktemp declaration in stdlib.h" >&5 $as_echo_n "checking for mktemp declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_mktemp_decl+set}" = set; then +if ${ice_cv_have_mktemp_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -64587,17 +40915,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}mktemp[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}mktemp[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_mktemp_decl=yes fi rm -f conftest* @@ -64606,17 +40930,13 @@ if test "$ice_cv_have_mktemp_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}mktemp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}mktemp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_mktemp_decl=yes fi rm -f conftest* @@ -64628,7 +40948,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_mktemp_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_mktemp_decl" >&5 $as_echo "$ice_cv_have_mktemp_decl" >&6; } if test "$ice_cv_have_mktemp_decl" = yes; then @@ -64641,111 +40961,21 @@ fi ice_have_mktime=no - for ac_func in mktime -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "mktime" "ac_cv_func_mktime" +if test "x$ac_cv_func_mktime" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_MKTIME 1 _ACEOF ice_have_mktime=yes fi done if test "${ice_have_mktime}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for mktime declaration in time.h sys/time.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for mktime declaration in time.h sys/time.h" >&5 $as_echo_n "checking for mktime declaration in time.h sys/time.h... " >&6; } -if test "${ice_cv_have_mktime_decl+set}" = set; then +if ${ice_cv_have_mktime_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -64754,17 +40984,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in time.h sys/time.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}mktime[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}mktime[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_mktime_decl=yes fi rm -f conftest* @@ -64773,17 +40999,13 @@ if test "$ice_cv_have_mktime_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}mktime[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}mktime[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_mktime_decl=yes fi rm -f conftest* @@ -64795,7 +41017,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_mktime_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_mktime_decl" >&5 $as_echo "$ice_cv_have_mktime_decl" >&6; } if test "$ice_cv_have_mktime_decl" = yes; then @@ -64806,102 +41028,12 @@ _ACEOF fi fi - for ac_func in on_exit -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "on_exit" "ac_cv_func_on_exit" +if test "x$ac_cv_func_on_exit" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_ON_EXIT 1 _ACEOF fi @@ -64909,111 +41041,21 @@ done ice_have_openlog=no - for ac_func in openlog -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "openlog" "ac_cv_func_openlog" +if test "x$ac_cv_func_openlog" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_OPENLOG 1 _ACEOF ice_have_openlog=yes fi done if test "${ice_have_openlog}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for openlog declaration in syslog.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for openlog declaration in syslog.h" >&5 $as_echo_n "checking for openlog declaration in syslog.h... " >&6; } -if test "${ice_cv_have_openlog_decl+set}" = set; then +if ${ice_cv_have_openlog_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -65022,17 +41064,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in syslog.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}openlog[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}openlog[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_openlog_decl=yes fi rm -f conftest* @@ -65041,17 +41079,13 @@ if test "$ice_cv_have_openlog_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}openlog[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}openlog[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_openlog_decl=yes fi rm -f conftest* @@ -65063,124 +41097,34 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_openlog_decl" >&5 -$as_echo "$ice_cv_have_openlog_decl" >&6; } -if test "$ice_cv_have_openlog_decl" = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_OPENLOG_DECL 1 -_ACEOF - -fi -fi - - -ice_have_pclose=no - -for ac_func in pclose -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_openlog_decl" >&5 +$as_echo "$ice_cv_have_openlog_decl" >&6; } +if test "$ice_cv_have_openlog_decl" = yes; then + +cat >>confdefs.h <<_ACEOF +#define HAVE_OPENLOG_DECL 1 _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_ac_var=no" fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + + +ice_have_pclose=no +for ac_func in pclose +do : + ac_fn_c_check_func "$LINENO" "pclose" "ac_cv_func_pclose" +if test "x$ac_cv_func_pclose" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_PCLOSE 1 _ACEOF ice_have_pclose=yes fi done if test "${ice_have_pclose}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for pclose declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for pclose declaration in stdio.h" >&5 $as_echo_n "checking for pclose declaration in stdio.h... " >&6; } -if test "${ice_cv_have_pclose_decl+set}" = set; then +if ${ice_cv_have_pclose_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -65189,17 +41133,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}pclose[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}pclose[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_pclose_decl=yes fi rm -f conftest* @@ -65208,17 +41148,13 @@ if test "$ice_cv_have_pclose_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}pclose[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}pclose[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_pclose_decl=yes fi rm -f conftest* @@ -65230,7 +41166,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_pclose_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_pclose_decl" >&5 $as_echo "$ice_cv_have_pclose_decl" >&6; } if test "$ice_cv_have_pclose_decl" = yes; then @@ -65243,111 +41179,21 @@ fi ice_have_perror=no - for ac_func in perror -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "perror" "ac_cv_func_perror" +if test "x$ac_cv_func_perror" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_PERROR 1 _ACEOF ice_have_perror=yes fi done if test "${ice_have_perror}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for perror declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for perror declaration in stdio.h" >&5 $as_echo_n "checking for perror declaration in stdio.h... " >&6; } -if test "${ice_cv_have_perror_decl+set}" = set; then +if ${ice_cv_have_perror_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -65356,17 +41202,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}perror[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}perror[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_perror_decl=yes fi rm -f conftest* @@ -65375,17 +41217,13 @@ if test "$ice_cv_have_perror_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}perror[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}perror[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_perror_decl=yes fi rm -f conftest* @@ -65397,7 +41235,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_perror_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_perror_decl" >&5 $as_echo "$ice_cv_have_perror_decl" >&6; } if test "$ice_cv_have_perror_decl" = yes; then @@ -65410,111 +41248,21 @@ fi ice_have_printf=no - for ac_func in printf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "printf" "ac_cv_func_printf" +if test "x$ac_cv_func_printf" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_PRINTF 1 _ACEOF ice_have_printf=yes fi done if test "${ice_have_printf}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for printf declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for printf declaration in stdio.h" >&5 $as_echo_n "checking for printf declaration in stdio.h... " >&6; } -if test "${ice_cv_have_printf_decl+set}" = set; then +if ${ice_cv_have_printf_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -65523,17 +41271,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}printf[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}printf[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_printf_decl=yes fi rm -f conftest* @@ -65542,17 +41286,13 @@ if test "$ice_cv_have_printf_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}printf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}printf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_printf_decl=yes fi rm -f conftest* @@ -65564,7 +41304,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_printf_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_printf_decl" >&5 $as_echo "$ice_cv_have_printf_decl" >&6; } if test "$ice_cv_have_printf_decl" = yes; then @@ -65575,102 +41315,12 @@ _ACEOF fi fi - for ac_func in putenv -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "putenv" "ac_cv_func_putenv" +if test "x$ac_cv_func_putenv" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_PUTENV 1 _ACEOF fi @@ -65678,111 +41328,21 @@ done ice_have_puts=no - for ac_func in puts -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "puts" "ac_cv_func_puts" +if test "x$ac_cv_func_puts" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_PUTS 1 _ACEOF ice_have_puts=yes fi done if test "${ice_have_puts}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for puts declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for puts declaration in stdio.h" >&5 $as_echo_n "checking for puts declaration in stdio.h... " >&6; } -if test "${ice_cv_have_puts_decl+set}" = set; then +if ${ice_cv_have_puts_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -65791,17 +41351,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}puts[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}puts[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_puts_decl=yes fi rm -f conftest* @@ -65810,17 +41366,13 @@ if test "$ice_cv_have_puts_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}puts[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}puts[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_puts_decl=yes fi rm -f conftest* @@ -65832,7 +41384,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_puts_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_puts_decl" >&5 $as_echo "$ice_cv_have_puts_decl" >&6; } if test "$ice_cv_have_puts_decl" = yes; then @@ -65845,111 +41397,21 @@ fi ice_have_realloc=no - for ac_func in realloc -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "realloc" "ac_cv_func_realloc" +if test "x$ac_cv_func_realloc" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_REALLOC 1 _ACEOF ice_have_realloc=yes fi done if test "${ice_have_realloc}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for realloc declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for realloc declaration in stdlib.h" >&5 $as_echo_n "checking for realloc declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_realloc_decl+set}" = set; then +if ${ice_cv_have_realloc_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -65958,17 +41420,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}realloc[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}realloc[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_realloc_decl=yes fi rm -f conftest* @@ -65977,17 +41435,13 @@ if test "$ice_cv_have_realloc_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}realloc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}realloc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_realloc_decl=yes fi rm -f conftest* @@ -65999,7 +41453,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_realloc_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_realloc_decl" >&5 $as_echo "$ice_cv_have_realloc_decl" >&6; } if test "$ice_cv_have_realloc_decl" = yes; then @@ -66012,111 +41466,21 @@ fi ice_have_recvfrom=no - for ac_func in recvfrom -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "recvfrom" "ac_cv_func_recvfrom" +if test "x$ac_cv_func_recvfrom" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_RECVFROM 1 _ACEOF ice_have_recvfrom=yes fi done if test "${ice_have_recvfrom}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for recvfrom declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for recvfrom declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for recvfrom declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_recvfrom_decl+set}" = set; then +if ${ice_cv_have_recvfrom_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -66125,17 +41489,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}recvfrom[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}recvfrom[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_recvfrom_decl=yes fi rm -f conftest* @@ -66144,17 +41504,13 @@ if test "$ice_cv_have_recvfrom_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}recvfrom[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}recvfrom[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_recvfrom_decl=yes fi rm -f conftest* @@ -66166,7 +41522,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_recvfrom_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_recvfrom_decl" >&5 $as_echo "$ice_cv_have_recvfrom_decl" >&6; } if test "$ice_cv_have_recvfrom_decl" = yes; then @@ -66179,111 +41535,21 @@ fi ice_have_remove=no - for ac_func in remove -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "remove" "ac_cv_func_remove" +if test "x$ac_cv_func_remove" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_REMOVE 1 _ACEOF ice_have_remove=yes fi done if test "${ice_have_remove}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for remove declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove declaration in stdio.h" >&5 $as_echo_n "checking for remove declaration in stdio.h... " >&6; } -if test "${ice_cv_have_remove_decl+set}" = set; then +if ${ice_cv_have_remove_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -66292,17 +41558,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}remove[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}remove[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_remove_decl=yes fi rm -f conftest* @@ -66311,17 +41573,13 @@ if test "$ice_cv_have_remove_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}remove[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}remove[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_remove_decl=yes fi rm -f conftest* @@ -66333,124 +41591,34 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_remove_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_remove_decl" >&5 $as_echo "$ice_cv_have_remove_decl" >&6; } if test "$ice_cv_have_remove_decl" = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_REMOVE_DECL 1 -_ACEOF - -fi -fi - - -ice_have_rename=no - -for ac_func in rename -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +_ACEOF - eval "$as_ac_var=no" fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + + +ice_have_rename=no +for ac_func in rename +do : + ac_fn_c_check_func "$LINENO" "rename" "ac_cv_func_rename" +if test "x$ac_cv_func_rename" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_RENAME 1 _ACEOF ice_have_rename=yes fi done if test "${ice_have_rename}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for rename declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rename declaration in stdio.h" >&5 $as_echo_n "checking for rename declaration in stdio.h... " >&6; } -if test "${ice_cv_have_rename_decl+set}" = set; then +if ${ice_cv_have_rename_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -66459,17 +41627,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}rename[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}rename[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_rename_decl=yes fi rm -f conftest* @@ -66478,17 +41642,13 @@ if test "$ice_cv_have_rename_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}rename[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}rename[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_rename_decl=yes fi rm -f conftest* @@ -66500,7 +41660,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_rename_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_rename_decl" >&5 $as_echo "$ice_cv_have_rename_decl" >&6; } if test "$ice_cv_have_rename_decl" = yes; then @@ -66513,111 +41673,21 @@ fi ice_have_rewind=no - for ac_func in rewind -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "rewind" "ac_cv_func_rewind" +if test "x$ac_cv_func_rewind" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_REWIND 1 _ACEOF ice_have_rewind=yes fi done if test "${ice_have_rewind}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for rewind declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for rewind declaration in stdio.h" >&5 $as_echo_n "checking for rewind declaration in stdio.h... " >&6; } -if test "${ice_cv_have_rewind_decl+set}" = set; then +if ${ice_cv_have_rewind_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -66626,17 +41696,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}rewind[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}rewind[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_rewind_decl=yes fi rm -f conftest* @@ -66645,17 +41711,13 @@ if test "$ice_cv_have_rewind_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}rewind[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}rewind[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_rewind_decl=yes fi rm -f conftest* @@ -66667,7 +41729,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_rewind_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_rewind_decl" >&5 $as_echo "$ice_cv_have_rewind_decl" >&6; } if test "$ice_cv_have_rewind_decl" = yes; then @@ -66680,111 +41742,21 @@ fi ice_have_ruserok=no - for ac_func in ruserok -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "ruserok" "ac_cv_func_ruserok" +if test "x$ac_cv_func_ruserok" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_RUSEROK 1 _ACEOF ice_have_ruserok=yes fi done if test "${ice_have_ruserok}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for ruserok declaration in netdb.h sys/socket.h libc.h unistd.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ruserok declaration in netdb.h sys/socket.h libc.h unistd.h" >&5 $as_echo_n "checking for ruserok declaration in netdb.h sys/socket.h libc.h unistd.h... " >&6; } -if test "${ice_cv_have_ruserok_decl+set}" = set; then +if ${ice_cv_have_ruserok_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -66793,17 +41765,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in netdb.h sys/socket.h libc.h unistd.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}ruserok[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}ruserok[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_ruserok_decl=yes fi rm -f conftest* @@ -66812,17 +41780,13 @@ if test "$ice_cv_have_ruserok_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}ruserok[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}ruserok[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_ruserok_decl=yes fi rm -f conftest* @@ -66834,7 +41798,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_ruserok_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_ruserok_decl" >&5 $as_echo "$ice_cv_have_ruserok_decl" >&6; } if test "$ice_cv_have_ruserok_decl" = yes; then @@ -66847,111 +41811,21 @@ fi ice_have_select=no - for ac_func in select -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "select" "ac_cv_func_select" +if test "x$ac_cv_func_select" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SELECT 1 _ACEOF ice_have_select=yes fi done if test "${ice_have_select}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for select declaration in sys/types.h sys/socket.h sys/select.h time.h sys/time.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for select declaration in sys/types.h sys/socket.h sys/select.h time.h sys/time.h" >&5 $as_echo_n "checking for select declaration in sys/types.h sys/socket.h sys/select.h time.h sys/time.h... " >&6; } -if test "${ice_cv_have_select_decl+set}" = set; then +if ${ice_cv_have_select_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -66960,17 +41834,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h sys/select.h time.h sys/time.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}select[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}select[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_select_decl=yes fi rm -f conftest* @@ -66979,17 +41849,13 @@ if test "$ice_cv_have_select_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}select[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}select[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_select_decl=yes fi rm -f conftest* @@ -67001,7 +41867,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_select_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_select_decl" >&5 $as_echo "$ice_cv_have_select_decl" >&6; } if test "$ice_cv_have_select_decl" = yes; then @@ -67014,153 +41880,16 @@ fi - - - - - -for ac_header in sys/time.h \ + for ac_header in sys/time.h \ sys/types.h \ sys/select.h \ sys/socket.h \ unistd.h \ -do -as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5 -$as_echo_n "checking for $ac_header... " >&6; } -if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -fi -ac_res=`eval 'as_val=${'$as_ac_Header'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -else - # Is the header compilable? -{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5 -$as_echo_n "checking $ac_header usability... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -$ac_includes_default -#include <$ac_header> -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - ac_header_compiler=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_compiler=no -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 -$as_echo "$ac_header_compiler" >&6; } - -# Is the header present? -{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5 -$as_echo_n "checking $ac_header presence... " >&6; } -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$ac_header> -_ACEOF -if { (ac_try="$ac_cpp conftest.$ac_ext" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } >/dev/null && { - test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || - test ! -s conftest.err - }; then - ac_header_preproc=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_header_preproc=no -fi - -rm -f conftest.err conftest.$ac_ext -{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 -$as_echo "$ac_header_preproc" >&6; } - -# So? What about this header? -case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in - yes:no: ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 -$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} - ac_header_preproc=yes - ;; - no:yes:* ) - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 -$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 -$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 -$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 -$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 -$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} - { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 -$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} - - ;; -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 +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -67170,9 +41899,9 @@ fi done - { $as_echo "$as_me:$LINENO: checking for select() argument type" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for select() argument type" >&5 $as_echo_n "checking for select() argument type... " >&6; } -if test "${amanda_cv_select_arg_type+set}" = set; then +if ${amanda_cv_select_arg_type+:} false; then : $as_echo_n "(cached) " >&6 else @@ -67245,7 +41974,7 @@ EOF fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_select_arg_type" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_select_arg_type" >&5 $as_echo "$amanda_cv_select_arg_type" >&6; } cat >>confdefs.h <<_ACEOF @@ -67256,111 +41985,21 @@ _ACEOF ice_have_sendto=no - for ac_func in sendto -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "sendto" "ac_cv_func_sendto" +if test "x$ac_cv_func_sendto" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SENDTO 1 _ACEOF ice_have_sendto=yes fi done if test "${ice_have_sendto}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for sendto declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sendto declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for sendto declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_sendto_decl+set}" = set; then +if ${ice_cv_have_sendto_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -67369,17 +42008,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}sendto[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}sendto[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_sendto_decl=yes fi rm -f conftest* @@ -67388,17 +42023,13 @@ if test "$ice_cv_have_sendto_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}sendto[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}sendto[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_sendto_decl=yes fi rm -f conftest* @@ -67410,7 +42041,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_sendto_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_sendto_decl" >&5 $as_echo "$ice_cv_have_sendto_decl" >&6; } if test "$ice_cv_have_sendto_decl" = yes; then @@ -67423,111 +42054,21 @@ fi ice_have_setegid=no - for ac_func in setegid -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "setegid" "ac_cv_func_setegid" +if test "x$ac_cv_func_setegid" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SETEGID 1 _ACEOF ice_have_setegid=yes fi done if test "${ice_have_setegid}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for setegid declaration in unistd.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for setegid declaration in unistd.h" >&5 $as_echo_n "checking for setegid declaration in unistd.h... " >&6; } -if test "${ice_cv_have_setegid_decl+set}" = set; then +if ${ice_cv_have_setegid_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -67536,17 +42077,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in unistd.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setegid[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setegid[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_setegid_decl=yes fi rm -f conftest* @@ -67555,17 +42092,13 @@ if test "$ice_cv_have_setegid_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setegid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setegid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_setegid_decl=yes fi rm -f conftest* @@ -67577,7 +42110,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_setegid_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_setegid_decl" >&5 $as_echo "$ice_cv_have_setegid_decl" >&6; } if test "$ice_cv_have_setegid_decl" = yes; then @@ -67590,111 +42123,21 @@ fi ice_have_seteuid=no - for ac_func in seteuid -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "seteuid" "ac_cv_func_seteuid" +if test "x$ac_cv_func_seteuid" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SETEUID 1 _ACEOF ice_have_seteuid=yes fi done if test "${ice_have_seteuid}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for seteuid declaration in unistd.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for seteuid declaration in unistd.h" >&5 $as_echo_n "checking for seteuid declaration in unistd.h... " >&6; } -if test "${ice_cv_have_seteuid_decl+set}" = set; then +if ${ice_cv_have_seteuid_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -67703,17 +42146,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in unistd.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}seteuid[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}seteuid[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_seteuid_decl=yes fi rm -f conftest* @@ -67722,146 +42161,52 @@ if test "$ice_cv_have_seteuid_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}seteuid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}seteuid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_seteuid_decl=yes fi -rm -f conftest* - -if test "$ice_cv_have_seteuid_decl" = yes; then - break -fi -done - -fi - -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_seteuid_decl" >&5 -$as_echo "$ice_cv_have_seteuid_decl" >&6; } -if test "$ice_cv_have_seteuid_decl" = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_SETEUID_DECL 1 -_ACEOF - -fi -fi - - -ice_have_setresgid=no - -for ac_func in setresgid -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +rm -f conftest* - eval "$as_ac_var=no" +if test "$ice_cv_have_seteuid_decl" = yes; then + break fi +done -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_seteuid_decl" >&5 +$as_echo "$ice_cv_have_seteuid_decl" >&6; } +if test "$ice_cv_have_seteuid_decl" = yes; then + +cat >>confdefs.h <<_ACEOF +#define HAVE_SETEUID_DECL 1 +_ACEOF + +fi +fi + + +ice_have_setresgid=no +for ac_func in setresgid +do : + ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid" +if test "x$ac_cv_func_setresgid" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SETRESGID 1 _ACEOF ice_have_setresgid=yes fi done if test "${ice_have_setresgid}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for setresgid declaration in unistd.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for setresgid declaration in unistd.h" >&5 $as_echo_n "checking for setresgid declaration in unistd.h... " >&6; } -if test "${ice_cv_have_setresgid_decl+set}" = set; then +if ${ice_cv_have_setresgid_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -67870,17 +42215,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in unistd.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setresgid[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setresgid[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_setresgid_decl=yes fi rm -f conftest* @@ -67889,17 +42230,13 @@ if test "$ice_cv_have_setresgid_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setresgid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setresgid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_setresgid_decl=yes fi rm -f conftest* @@ -67911,7 +42248,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_setresgid_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_setresgid_decl" >&5 $as_echo "$ice_cv_have_setresgid_decl" >&6; } if test "$ice_cv_have_setresgid_decl" = yes; then @@ -67924,111 +42261,21 @@ fi ice_have_setresuid=no - for ac_func in setresuid -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid" +if test "x$ac_cv_func_setresuid" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SETRESUID 1 _ACEOF ice_have_setresuid=yes fi done if test "${ice_have_setresuid}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for setresuid declaration in unistd.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for setresuid declaration in unistd.h" >&5 $as_echo_n "checking for setresuid declaration in unistd.h... " >&6; } -if test "${ice_cv_have_setresuid_decl+set}" = set; then +if ${ice_cv_have_setresuid_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -68037,17 +42284,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in unistd.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setresuid[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setresuid[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_setresuid_decl=yes fi rm -f conftest* @@ -68056,17 +42299,13 @@ if test "$ice_cv_have_setresuid_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setresuid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setresuid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_setresuid_decl=yes fi rm -f conftest* @@ -68078,7 +42317,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_setresuid_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_setresuid_decl" >&5 $as_echo "$ice_cv_have_setresuid_decl" >&6; } if test "$ice_cv_have_setresuid_decl" = yes; then @@ -68091,111 +42330,21 @@ fi ice_have_snprintf=no - for ac_func in snprintf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf" +if test "x$ac_cv_func_snprintf" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SNPRINTF 1 _ACEOF ice_have_snprintf=yes fi done if test "${ice_have_snprintf}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for snprintf declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for snprintf declaration in stdio.h" >&5 $as_echo_n "checking for snprintf declaration in stdio.h... " >&6; } -if test "${ice_cv_have_snprintf_decl+set}" = set; then +if ${ice_cv_have_snprintf_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -68204,17 +42353,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}snprintf[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}snprintf[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_snprintf_decl=yes fi rm -f conftest* @@ -68223,17 +42368,13 @@ if test "$ice_cv_have_snprintf_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}snprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}snprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_snprintf_decl=yes fi rm -f conftest* @@ -68245,7 +42386,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_snprintf_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_snprintf_decl" >&5 $as_echo "$ice_cv_have_snprintf_decl" >&6; } if test "$ice_cv_have_snprintf_decl" = yes; then @@ -68258,111 +42399,21 @@ fi ice_have_vsnprintf=no - for ac_func in vsnprintf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf" +if test "x$ac_cv_func_vsnprintf" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_VSNPRINTF 1 _ACEOF ice_have_vsnprintf=yes fi done if test "${ice_have_vsnprintf}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for vsnprintf declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for vsnprintf declaration in stdio.h" >&5 $as_echo_n "checking for vsnprintf declaration in stdio.h... " >&6; } -if test "${ice_cv_have_vsnprintf_decl+set}" = set; then +if ${ice_cv_have_vsnprintf_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -68371,17 +42422,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}vsnprintf[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}vsnprintf[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_vsnprintf_decl=yes fi rm -f conftest* @@ -68390,17 +42437,13 @@ if test "$ice_cv_have_vsnprintf_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}vsnprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}vsnprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_vsnprintf_decl=yes fi rm -f conftest* @@ -68412,7 +42455,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_vsnprintf_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_vsnprintf_decl" >&5 $as_echo "$ice_cv_have_vsnprintf_decl" >&6; } if test "$ice_cv_have_vsnprintf_decl" = yes; then @@ -68424,205 +42467,29 @@ fi fi - { $as_echo "$as_me:$LINENO: checking for setpgid" >&5 -$as_echo_n "checking for setpgid... " >&6; } -if test "${ac_cv_func_setpgid+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 setpgid to an innocuous variant, in case declares setpgid. - For example, HP-UX 11i declares gettimeofday. */ -#define setpgid innocuous_setpgid - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char setpgid (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef setpgid - -/* 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 setpgid (); -/* 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_setpgid || defined __stub___setpgid -choke me -#endif - -int -main () -{ -return setpgid (); - ; - 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_setpgid=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_setpgid=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_setpgid" >&5 -$as_echo "$ac_cv_func_setpgid" >&6; } -if test "x$ac_cv_func_setpgid" = x""yes; then + ac_fn_c_check_func "$LINENO" "setpgid" "ac_cv_func_setpgid" +if test "x$ac_cv_func_setpgid" = xyes; then : -cat >>confdefs.h <<\_ACEOF -#define HAVE_SETPGID 1 -_ACEOF +$as_echo "#define HAVE_SETPGID 1" >>confdefs.h ice_have_setpgid=no - for ac_func in setpgid -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "setpgid" "ac_cv_func_setpgid" +if test "x$ac_cv_func_setpgid" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SETPGID 1 _ACEOF ice_have_setpgid=yes fi done if test "${ice_have_setpgid}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for setpgid declaration in sys/types.h unistd.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for setpgid declaration in sys/types.h unistd.h" >&5 $as_echo_n "checking for setpgid declaration in sys/types.h unistd.h... " >&6; } -if test "${ice_cv_have_setpgid_decl+set}" = set; then +if ${ice_cv_have_setpgid_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -68631,17 +42498,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h unistd.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setpgid[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setpgid[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_setpgid_decl=yes fi rm -f conftest* @@ -68650,17 +42513,13 @@ if test "$ice_cv_have_setpgid_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setpgid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setpgid[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_setpgid_decl=yes fi rm -f conftest* @@ -68672,7 +42531,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_setpgid_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_setpgid_decl" >&5 $as_echo "$ice_cv_have_setpgid_decl" >&6; } if test "$ice_cv_have_setpgid_decl" = yes; then @@ -68687,107 +42546,17 @@ fi fi -{ $as_echo "$as_me:$LINENO: checking for setpgrp" >&5 -$as_echo_n "checking for setpgrp... " >&6; } -if test "${ac_cv_func_setpgrp+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 setpgrp to an innocuous variant, in case declares setpgrp. - For example, HP-UX 11i declares gettimeofday. */ -#define setpgrp innocuous_setpgrp - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char setpgrp (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef setpgrp - -/* 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 setpgrp (); -/* 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_setpgrp || defined __stub___setpgrp -choke me -#endif - -int -main () -{ -return setpgrp (); - ; - 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_setpgrp=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_setpgrp=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_setpgrp" >&5 -$as_echo "$ac_cv_func_setpgrp" >&6; } -if test "x$ac_cv_func_setpgrp" = x""yes; then - { $as_echo "$as_me:$LINENO: checking whether setpgrp takes no argument" >&5 +ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" +if test "x$ac_cv_func_setpgrp" = xyes; then : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setpgrp takes no argument" >&5 $as_echo_n "checking whether setpgrp takes no argument... " >&6; } -if test "${ac_cv_func_setpgrp_void+set}" = set; then +if ${ac_cv_func_setpgrp_void+:} false; then : $as_echo_n "(cached) " >&6 else - if test "$cross_compiling" = yes; then - { { $as_echo "$as_me:$LINENO: error: cannot check setpgrp when cross compiling" >&5 -$as_echo "$as_me: error: cannot check setpgrp when cross compiling" >&2;} - { (exit 1); exit 1; }; } + if test "$cross_compiling" = yes; then : + as_fn_error $? "cannot check setpgrp when cross compiling" "$LINENO" 5 else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $ac_includes_default int @@ -68801,50 +42570,21 @@ main () 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 +if ac_fn_c_try_run "$LINENO"; then : ac_cv_func_setpgrp_void=no else - $as_echo "$as_me: program exited with status $ac_status" >&5 -$as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - -( exit $ac_status ) -ac_cv_func_setpgrp_void=yes + ac_cv_func_setpgrp_void=yes fi -rm -rf conftest.dSYM -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext +rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ + conftest.$ac_objext conftest.beam conftest.$ac_ext fi - fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_setpgrp_void" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_setpgrp_void" >&5 $as_echo "$ac_cv_func_setpgrp_void" >&6; } if test $ac_cv_func_setpgrp_void = yes; then -cat >>confdefs.h <<\_ACEOF -#define SETPGRP_VOID 1 -_ACEOF +$as_echo "#define SETPGRP_VOID 1" >>confdefs.h fi @@ -68852,111 +42592,21 @@ fi ice_have_setpgrp=no - for ac_func in setpgrp -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "setpgrp" "ac_cv_func_setpgrp" +if test "x$ac_cv_func_setpgrp" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SETPGRP 1 _ACEOF ice_have_setpgrp=yes fi done if test "${ice_have_setpgrp}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for setpgrp declaration in sys/types.h unistd.h libc.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for setpgrp declaration in sys/types.h unistd.h libc.h" >&5 $as_echo_n "checking for setpgrp declaration in sys/types.h unistd.h libc.h... " >&6; } -if test "${ice_cv_have_setpgrp_decl+set}" = set; then +if ${ice_cv_have_setpgrp_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -68965,17 +42615,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h unistd.h libc.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setpgrp[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setpgrp[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_setpgrp_decl=yes fi rm -f conftest* @@ -68984,17 +42630,13 @@ if test "$ice_cv_have_setpgrp_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setpgrp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setpgrp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_setpgrp_decl=yes fi rm -f conftest* @@ -69006,7 +42648,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_setpgrp_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_setpgrp_decl" >&5 $as_echo "$ice_cv_have_setpgrp_decl" >&6; } if test "$ice_cv_have_setpgrp_decl" = yes; then @@ -69019,111 +42661,21 @@ fi ice_have_setsockopt=no - for ac_func in setsockopt -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "setsockopt" "ac_cv_func_setsockopt" +if test "x$ac_cv_func_setsockopt" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SETSOCKOPT 1 _ACEOF ice_have_setsockopt=yes fi done if test "${ice_have_setsockopt}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for setsockopt declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for setsockopt declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for setsockopt declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_setsockopt_decl+set}" = set; then +if ${ice_cv_have_setsockopt_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -69132,17 +42684,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setsockopt[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setsockopt[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_setsockopt_decl=yes fi rm -f conftest* @@ -69151,17 +42699,13 @@ if test "$ice_cv_have_setsockopt_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}setsockopt[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}setsockopt[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_setsockopt_decl=yes fi rm -f conftest* @@ -69173,7 +42717,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_setsockopt_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_setsockopt_decl" >&5 $as_echo "$ice_cv_have_setsockopt_decl" >&6; } if test "$ice_cv_have_setsockopt_decl" = yes; then @@ -69184,102 +42728,11 @@ _ACEOF fi fi - - - for ac_func in sigaction sigemptyset sigvec -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` +ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" +if eval test \"x\$"$as_ac_var"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF @@ -69289,111 +42742,21 @@ done ice_have_socket=no - for ac_func in socket -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket" +if test "x$ac_cv_func_socket" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SOCKET 1 _ACEOF ice_have_socket=yes fi done if test "${ice_have_socket}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for socket declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for socket declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_socket_decl+set}" = set; then +if ${ice_cv_have_socket_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -69402,17 +42765,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}socket[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}socket[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_socket_decl=yes fi rm -f conftest* @@ -69421,17 +42780,13 @@ if test "$ice_cv_have_socket_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}socket[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}socket[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_socket_decl=yes fi rm -f conftest* @@ -69443,7 +42798,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_socket_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_socket_decl" >&5 $as_echo "$ice_cv_have_socket_decl" >&6; } if test "$ice_cv_have_socket_decl" = yes; then @@ -69456,111 +42811,21 @@ fi ice_have_socketpair=no - for ac_func in socketpair -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair" +if test "x$ac_cv_func_socketpair" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SOCKETPAIR 1 _ACEOF ice_have_socketpair=yes fi done if test "${ice_have_socketpair}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for socketpair declaration in sys/types.h sys/socket.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for socketpair declaration in sys/types.h sys/socket.h" >&5 $as_echo_n "checking for socketpair declaration in sys/types.h sys/socket.h... " >&6; } -if test "${ice_cv_have_socketpair_decl+set}" = set; then +if ${ice_cv_have_socketpair_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -69569,17 +42834,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in sys/types.h sys/socket.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}socketpair[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}socketpair[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_socketpair_decl=yes fi rm -f conftest* @@ -69588,17 +42849,13 @@ if test "$ice_cv_have_socketpair_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}socketpair[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}socketpair[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_socketpair_decl=yes fi rm -f conftest* @@ -69610,7 +42867,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_socketpair_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_socketpair_decl" >&5 $as_echo "$ice_cv_have_socketpair_decl" >&6; } if test "$ice_cv_have_socketpair_decl" = yes; then @@ -69623,111 +42880,21 @@ fi ice_have_sscanf=no - for ac_func in sscanf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "sscanf" "ac_cv_func_sscanf" +if test "x$ac_cv_func_sscanf" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SSCANF 1 _ACEOF ice_have_sscanf=yes fi done if test "${ice_have_sscanf}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for sscanf declaration in stdio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sscanf declaration in stdio.h" >&5 $as_echo_n "checking for sscanf declaration in stdio.h... " >&6; } -if test "${ice_cv_have_sscanf_decl+set}" = set; then +if ${ice_cv_have_sscanf_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -69736,17 +42903,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}sscanf[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}sscanf[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_sscanf_decl=yes fi rm -f conftest* @@ -69755,17 +42918,13 @@ if test "$ice_cv_have_sscanf_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}sscanf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}sscanf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_sscanf_decl=yes fi rm -f conftest* @@ -69777,7 +42936,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_sscanf_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_sscanf_decl" >&5 $as_echo "$ice_cv_have_sscanf_decl" >&6; } if test "$ice_cv_have_sscanf_decl" = yes; then @@ -69790,111 +42949,21 @@ fi ice_have_strerror=no - for ac_func in strerror -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror" +if test "x$ac_cv_func_strerror" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_STRERROR 1 _ACEOF ice_have_strerror=yes fi done if test "${ice_have_strerror}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for strerror declaration in string.h strings.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strerror declaration in string.h strings.h" >&5 $as_echo_n "checking for strerror declaration in string.h strings.h... " >&6; } -if test "${ice_cv_have_strerror_decl+set}" = set; then +if ${ice_cv_have_strerror_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -69903,17 +42972,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in string.h strings.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strerror[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strerror[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_strerror_decl=yes fi rm -f conftest* @@ -69922,17 +42987,13 @@ if test "$ice_cv_have_strerror_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strerror[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strerror[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_strerror_decl=yes fi rm -f conftest* @@ -69944,7 +43005,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_strerror_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_strerror_decl" >&5 $as_echo "$ice_cv_have_strerror_decl" >&6; } if test "$ice_cv_have_strerror_decl" = yes; then @@ -69955,118 +43016,24 @@ _ACEOF fi fi - for ac_func in strftime -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime" +if test "x$ac_cv_func_strftime" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_STRFTIME 1 _ACEOF else # strftime is in -lintl on SCO UNIX. -{ $as_echo "$as_me:$LINENO: checking for strftime in -lintl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5 $as_echo_n "checking for strftime in -lintl... " >&6; } -if test "${ac_cv_lib_intl_strftime+set}" = set; then +if ${ac_cv_lib_intl_strftime+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lintl $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -70084,46 +43051,19 @@ return strftime (); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_intl_strftime=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_intl_strftime=no + ac_cv_lib_intl_strftime=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5 $as_echo "$ac_cv_lib_intl_strftime" >&6; } -if test "x$ac_cv_lib_intl_strftime" = x""yes; then - cat >>confdefs.h <<\_ACEOF -#define HAVE_STRFTIME 1 -_ACEOF +if test "x$ac_cv_lib_intl_strftime" = xyes; then : + $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h LIBS="-lintl $LIBS" fi @@ -70133,111 +43073,21 @@ done ice_have_strftime=no - for ac_func in strftime -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime" +if test "x$ac_cv_func_strftime" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_STRFTIME 1 _ACEOF ice_have_strftime=yes fi done if test "${ice_have_strftime}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for strftime declaration in time.h sys/time.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime declaration in time.h sys/time.h" >&5 $as_echo_n "checking for strftime declaration in time.h sys/time.h... " >&6; } -if test "${ice_cv_have_strftime_decl+set}" = set; then +if ${ice_cv_have_strftime_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -70246,17 +43096,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in time.h sys/time.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strftime[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strftime[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_strftime_decl=yes fi rm -f conftest* @@ -70265,146 +43111,52 @@ if test "$ice_cv_have_strftime_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strftime[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strftime[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_strftime_decl=yes -fi -rm -f conftest* - -if test "$ice_cv_have_strftime_decl" = yes; then - break -fi -done - -fi - -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_strftime_decl" >&5 -$as_echo "$ice_cv_have_strftime_decl" >&6; } -if test "$ice_cv_have_strftime_decl" = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_STRFTIME_DECL 1 -_ACEOF - -fi -fi - - -ice_have_strncasecmp=no - -for ac_func in strncasecmp -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 +fi +rm -f conftest* - eval "$as_ac_var=no" +if test "$ice_cv_have_strftime_decl" = yes; then + break fi +done -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_strftime_decl" >&5 +$as_echo "$ice_cv_have_strftime_decl" >&6; } +if test "$ice_cv_have_strftime_decl" = yes; then + +cat >>confdefs.h <<_ACEOF +#define HAVE_STRFTIME_DECL 1 +_ACEOF + +fi +fi + + +ice_have_strncasecmp=no +for ac_func in strncasecmp +do : + ac_fn_c_check_func "$LINENO" "strncasecmp" "ac_cv_func_strncasecmp" +if test "x$ac_cv_func_strncasecmp" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_STRNCASECMP 1 _ACEOF ice_have_strncasecmp=yes fi done if test "${ice_have_strncasecmp}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for strncasecmp declaration in string.h strings.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strncasecmp declaration in string.h strings.h" >&5 $as_echo_n "checking for strncasecmp declaration in string.h strings.h... " >&6; } -if test "${ice_cv_have_strncasecmp_decl+set}" = set; then +if ${ice_cv_have_strncasecmp_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -70413,17 +43165,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in string.h strings.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strncasecmp[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strncasecmp[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_strncasecmp_decl=yes fi rm -f conftest* @@ -70432,17 +43180,13 @@ if test "$ice_cv_have_strncasecmp_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strncasecmp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strncasecmp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_strncasecmp_decl=yes fi rm -f conftest* @@ -70454,7 +43198,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_strncasecmp_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_strncasecmp_decl" >&5 $as_echo "$ice_cv_have_strncasecmp_decl" >&6; } if test "$ice_cv_have_strncasecmp_decl" = yes; then @@ -70467,111 +43211,21 @@ fi ice_have_syslog=no - for ac_func in syslog -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "syslog" "ac_cv_func_syslog" +if test "x$ac_cv_func_syslog" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SYSLOG 1 _ACEOF ice_have_syslog=yes fi done if test "${ice_have_syslog}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for syslog declaration in syslog.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for syslog declaration in syslog.h" >&5 $as_echo_n "checking for syslog declaration in syslog.h... " >&6; } -if test "${ice_cv_have_syslog_decl+set}" = set; then +if ${ice_cv_have_syslog_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -70580,17 +43234,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in syslog.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}syslog[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}syslog[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_syslog_decl=yes fi rm -f conftest* @@ -70599,17 +43249,13 @@ if test "$ice_cv_have_syslog_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}syslog[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}syslog[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_syslog_decl=yes fi rm -f conftest* @@ -70621,7 +43267,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_syslog_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_syslog_decl" >&5 $as_echo "$ice_cv_have_syslog_decl" >&6; } if test "$ice_cv_have_syslog_decl" = yes; then @@ -70634,111 +43280,21 @@ fi ice_have_system=no - for ac_func in system -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "system" "ac_cv_func_system" +if test "x$ac_cv_func_system" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_SYSTEM 1 _ACEOF ice_have_system=yes fi done if test "${ice_have_system}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for system declaration in stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for system declaration in stdlib.h" >&5 $as_echo_n "checking for system declaration in stdlib.h... " >&6; } -if test "${ice_cv_have_system_decl+set}" = set; then +if ${ice_cv_have_system_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -70747,17 +43303,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}system[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}system[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_system_decl=yes fi rm -f conftest* @@ -70766,17 +43318,13 @@ if test "$ice_cv_have_system_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}system[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}system[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_system_decl=yes fi rm -f conftest* @@ -70788,7 +43336,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_system_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_system_decl" >&5 $as_echo "$ice_cv_have_system_decl" >&6; } if test "$ice_cv_have_system_decl" = yes; then @@ -70801,111 +43349,21 @@ fi ice_have_time=no - for ac_func in time -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "time" "ac_cv_func_time" +if test "x$ac_cv_func_time" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_TIME 1 _ACEOF ice_have_time=yes fi done if test "${ice_have_time}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for time declaration in time.h sys/time.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for time declaration in time.h sys/time.h" >&5 $as_echo_n "checking for time declaration in time.h sys/time.h... " >&6; } -if test "${ice_cv_have_time_decl+set}" = set; then +if ${ice_cv_have_time_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -70914,17 +43372,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in time.h sys/time.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}time[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}time[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_time_decl=yes fi rm -f conftest* @@ -70933,17 +43387,13 @@ if test "$ice_cv_have_time_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}time[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}time[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_time_decl=yes fi rm -f conftest* @@ -70955,7 +43405,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_time_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_time_decl" >&5 $as_echo "$ice_cv_have_time_decl" >&6; } if test "$ice_cv_have_time_decl" = yes; then @@ -70968,111 +43418,21 @@ fi ice_have_tolower=no - for ac_func in tolower -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "tolower" "ac_cv_func_tolower" +if test "x$ac_cv_func_tolower" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_TOLOWER 1 _ACEOF ice_have_tolower=yes fi done if test "${ice_have_tolower}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for tolower declaration in ctype.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for tolower declaration in ctype.h" >&5 $as_echo_n "checking for tolower declaration in ctype.h... " >&6; } -if test "${ice_cv_have_tolower_decl+set}" = set; then +if ${ice_cv_have_tolower_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -71081,17 +43441,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in ctype.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}tolower[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}tolower[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_tolower_decl=yes fi rm -f conftest* @@ -71100,17 +43456,13 @@ if test "$ice_cv_have_tolower_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}tolower[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}tolower[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_tolower_decl=yes fi rm -f conftest* @@ -71122,7 +43474,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_tolower_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_tolower_decl" >&5 $as_echo "$ice_cv_have_tolower_decl" >&6; } if test "$ice_cv_have_tolower_decl" = yes; then @@ -71135,111 +43487,21 @@ fi ice_have_toupper=no - for ac_func in toupper -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "toupper" "ac_cv_func_toupper" +if test "x$ac_cv_func_toupper" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_TOUPPER 1 _ACEOF ice_have_toupper=yes fi done if test "${ice_have_toupper}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for toupper declaration in ctype.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for toupper declaration in ctype.h" >&5 $as_echo_n "checking for toupper declaration in ctype.h... " >&6; } -if test "${ice_cv_have_toupper_decl+set}" = set; then +if ${ice_cv_have_toupper_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -71248,17 +43510,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in ctype.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}toupper[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}toupper[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_toupper_decl=yes fi rm -f conftest* @@ -71267,414 +43525,132 @@ if test "$ice_cv_have_toupper_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}toupper[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}toupper[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_toupper_decl=yes fi rm -f conftest* -if test "$ice_cv_have_toupper_decl" = yes; then - break -fi -done - -fi - -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_toupper_decl" >&5 -$as_echo "$ice_cv_have_toupper_decl" >&6; } -if test "$ice_cv_have_toupper_decl" = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_TOUPPER_DECL 1 -_ACEOF - -fi -fi - - -ice_have_ungetc=no - -for ac_func in ungetc -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 -_ACEOF - ice_have_ungetc=yes -fi -done - -if test "${ice_have_ungetc}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for ungetc declaration in stdio.h" >&5 -$as_echo_n "checking for ungetc declaration in stdio.h... " >&6; } -if test "${ice_cv_have_ungetc_decl+set}" = set; then - $as_echo_n "(cached) " >&6 -else - -ice_cv_have_ungetc_decl=no -ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' -ice_re_word='(^|[^a-zA-Z0-9_])' -for header in stdio.h; do -# Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$header> - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}ungetc[ ]*\(" >/dev/null 2>&1; then - ice_cv_have_ungetc_decl=yes -fi -rm -f conftest* - -if test "$ice_cv_have_ungetc_decl" = yes; then - break -fi -# Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -#include <$header> - -_ACEOF -if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}ungetc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then - ice_cv_have_ungetc_decl=yes -fi -rm -f conftest* - -if test "$ice_cv_have_ungetc_decl" = yes; then - break -fi -done - -fi - -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_ungetc_decl" >&5 -$as_echo "$ice_cv_have_ungetc_decl" >&6; } -if test "$ice_cv_have_ungetc_decl" = yes; then - -cat >>confdefs.h <<_ACEOF -#define HAVE_UNGETC_DECL 1 -_ACEOF - -fi -fi - - -for ac_func in unsetenv -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" +if test "$ice_cv_have_toupper_decl" = yes; then + break fi +done -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then - cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 + +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_toupper_decl" >&5 +$as_echo "$ice_cv_have_toupper_decl" >&6; } +if test "$ice_cv_have_toupper_decl" = yes; then + +cat >>confdefs.h <<_ACEOF +#define HAVE_TOUPPER_DECL 1 _ACEOF fi -done +fi -ice_have_vfprintf=no +ice_have_ungetc=no +for ac_func in ungetc +do : + ac_fn_c_check_func "$LINENO" "ungetc" "ac_cv_func_ungetc" +if test "x$ac_cv_func_ungetc" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_UNGETC 1 +_ACEOF + ice_have_ungetc=yes +fi +done -for ac_func in vfprintf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then +if test "${ice_have_ungetc}" = yes; then +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ungetc declaration in stdio.h" >&5 +$as_echo_n "checking for ungetc declaration in stdio.h... " >&6; } +if ${ice_cv_have_ungetc_decl+:} false; then : $as_echo_n "(cached) " >&6 else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ + +ice_cv_have_ungetc_decl=no +ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' +ice_re_word='(^|[^a-zA-Z0-9_])' +for header in stdio.h; do +# Check for ordinary declaration +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ +#include <$header> + _ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "${ice_re_word}ungetc[ ]*\(" >/dev/null 2>&1; then : + ice_cv_have_ungetc_decl=yes +fi +rm -f conftest* + +if test "$ice_cv_have_ungetc_decl" = yes; then + break +fi +# Check for "fixed" declaration like "getpid _PARAMS((int))" +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func +#include <$header> -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ +_ACEOF +if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | + $EGREP "${ice_re_word}ungetc[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : + ice_cv_have_ungetc_decl=yes +fi +rm -f conftest* -#ifdef __STDC__ -# include -#else -# include -#endif +if test "$ice_cv_have_ungetc_decl" = yes; then + break +fi +done -#undef $ac_func +fi -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_ungetc_decl" >&5 +$as_echo "$ice_cv_have_ungetc_decl" >&6; } +if test "$ice_cv_have_ungetc_decl" = yes; then -int -main () -{ -return $ac_func (); - ; - return 0; -} +cat >>confdefs.h <<_ACEOF +#define HAVE_UNGETC_DECL 1 _ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - eval "$as_ac_var=no" fi +fi + +for ac_func in unsetenv +do : + ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv" +if test "x$ac_cv_func_unsetenv" = xyes; then : + cat >>confdefs.h <<_ACEOF +#define HAVE_UNSETENV 1 +_ACEOF -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +done + + +ice_have_vfprintf=no +for ac_func in vfprintf +do : + ac_fn_c_check_func "$LINENO" "vfprintf" "ac_cv_func_vfprintf" +if test "x$ac_cv_func_vfprintf" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_VFPRINTF 1 _ACEOF ice_have_vfprintf=yes fi done if test "${ice_have_vfprintf}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for vfprintf declaration in stdio.h stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for vfprintf declaration in stdio.h stdlib.h" >&5 $as_echo_n "checking for vfprintf declaration in stdio.h stdlib.h... " >&6; } -if test "${ice_cv_have_vfprintf_decl+set}" = set; then +if ${ice_cv_have_vfprintf_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -71683,17 +43659,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}vfprintf[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}vfprintf[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_vfprintf_decl=yes fi rm -f conftest* @@ -71702,17 +43674,13 @@ if test "$ice_cv_have_vfprintf_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}vfprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}vfprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_vfprintf_decl=yes fi rm -f conftest* @@ -71724,7 +43692,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_vfprintf_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_vfprintf_decl" >&5 $as_echo "$ice_cv_have_vfprintf_decl" >&6; } if test "$ice_cv_have_vfprintf_decl" = yes; then @@ -71737,111 +43705,21 @@ fi ice_have_vprintf=no - for ac_func in vprintf -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" +if test "x$ac_cv_func_vprintf" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_VPRINTF 1 _ACEOF ice_have_vprintf=yes fi done if test "${ice_have_vprintf}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for vprintf declaration in stdio.h stdlib.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for vprintf declaration in stdio.h stdlib.h" >&5 $as_echo_n "checking for vprintf declaration in stdio.h stdlib.h... " >&6; } -if test "${ice_cv_have_vprintf_decl+set}" = set; then +if ${ice_cv_have_vprintf_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -71850,17 +43728,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in stdio.h stdlib.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}vprintf[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}vprintf[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_vprintf_decl=yes fi rm -f conftest* @@ -71869,17 +43743,13 @@ if test "$ice_cv_have_vprintf_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}vprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}vprintf[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_vprintf_decl=yes fi rm -f conftest* @@ -71891,7 +43761,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_vprintf_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_vprintf_decl" >&5 $as_echo "$ice_cv_have_vprintf_decl" >&6; } if test "$ice_cv_have_vprintf_decl" = yes; then @@ -71902,199 +43772,28 @@ _ACEOF fi fi -{ $as_echo "$as_me:$LINENO: checking for wait4" >&5 -$as_echo_n "checking for wait4... " >&6; } -if test "${ac_cv_func_wait4+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 wait4 to an innocuous variant, in case declares wait4. - For example, HP-UX 11i declares gettimeofday. */ -#define wait4 innocuous_wait4 - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char wait4 (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef wait4 - -/* 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 wait4 (); -/* 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_wait4 || defined __stub___wait4 -choke me -#endif - -int -main () -{ -return wait4 (); - ; - 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_wait4=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_wait4=no -fi +ac_fn_c_check_func "$LINENO" "wait4" "ac_cv_func_wait4" +if test "x$ac_cv_func_wait4" = xyes; then : -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_wait4" >&5 -$as_echo "$ac_cv_func_wait4" >&6; } ice_have_writev=no - for ac_func in writev -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "writev" "ac_cv_func_writev" +if test "x$ac_cv_func_writev" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_WRITEV 1 _ACEOF ice_have_writev=yes fi done if test "${ice_have_writev}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for writev declaration in unistd.h sys/uio.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for writev declaration in unistd.h sys/uio.h" >&5 $as_echo_n "checking for writev declaration in unistd.h sys/uio.h... " >&6; } -if test "${ice_cv_have_writev_decl+set}" = set; then +if ${ice_cv_have_writev_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -72103,17 +43802,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in unistd.h sys/uio.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}writev[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}writev[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_writev_decl=yes fi rm -f conftest* @@ -72122,17 +43817,13 @@ if test "$ice_cv_have_writev_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}writev[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}writev[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_writev_decl=yes fi rm -f conftest* @@ -72144,7 +43835,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_writev_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_writev_decl" >&5 $as_echo "$ice_cv_have_writev_decl" >&6; } if test "$ice_cv_have_writev_decl" = yes; then @@ -72157,111 +43848,21 @@ fi ice_have_strcasecmp=no - for ac_func in strcasecmp -do -as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` -{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5 -$as_echo_n "checking for $ac_func... " >&6; } -if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then - $as_echo_n "(cached) " >&6 -else - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ -/* Define $ac_func to an innocuous variant, in case declares $ac_func. - For example, HP-UX 11i declares gettimeofday. */ -#define $ac_func innocuous_$ac_func - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char $ac_func (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef $ac_func - -/* Override any GCC internal prototype to avoid an error. - Use char because int might match the return type of a GCC - builtin and then its argument prototype would still apply. */ -#ifdef __cplusplus -extern "C" -#endif -char $ac_func (); -/* The GNU C library defines this for functions which it implements - to always fail with ENOSYS. Some functions are actually named - something starting with __ and the normal name is an alias. */ -#if defined __stub_$ac_func || defined __stub___$ac_func -choke me -#endif - -int -main () -{ -return $ac_func (); - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext conftest$ac_exeext -if { (ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_link") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest$ac_exeext && { - test "$cross_compiling" = yes || - $as_test_x conftest$ac_exeext - }; then - eval "$as_ac_var=yes" -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - eval "$as_ac_var=no" -fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext -fi -ac_res=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - { $as_echo "$as_me:$LINENO: result: $ac_res" >&5 -$as_echo "$ac_res" >&6; } -as_val=`eval 'as_val=${'$as_ac_var'} - $as_echo "$as_val"'` - if test "x$as_val" = x""yes; then +do : + ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp" +if test "x$ac_cv_func_strcasecmp" = xyes; then : cat >>confdefs.h <<_ACEOF -#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 +#define HAVE_STRCASECMP 1 _ACEOF ice_have_strcasecmp=yes fi done if test "${ice_have_strcasecmp}" = yes; then -{ $as_echo "$as_me:$LINENO: checking for strcasecmp declaration in string.h strings.h" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for strcasecmp declaration in string.h strings.h" >&5 $as_echo_n "checking for strcasecmp declaration in string.h strings.h... " >&6; } -if test "${ice_cv_have_strcasecmp_decl+set}" = set; then +if ${ice_cv_have_strcasecmp_decl+:} false; then : $as_echo_n "(cached) " >&6 else @@ -72270,17 +43871,13 @@ ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*' ice_re_word='(^|[^a-zA-Z0-9_])' for header in string.h strings.h; do # Check for ordinary declaration -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strcasecmp[ ]*\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strcasecmp[ ]*\(" >/dev/null 2>&1; then : ice_cv_have_strcasecmp_decl=yes fi rm -f conftest* @@ -72289,17 +43886,13 @@ if test "$ice_cv_have_strcasecmp_decl" = yes; then break fi # Check for "fixed" declaration like "getpid _PARAMS((int))" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$header> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | - $EGREP "${ice_re_word}strcasecmp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then + $EGREP "${ice_re_word}strcasecmp[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then : ice_cv_have_strcasecmp_decl=yes fi rm -f conftest* @@ -72311,7 +43904,7 @@ done fi -{ $as_echo "$as_me:$LINENO: result: $ice_cv_have_strcasecmp_decl" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ice_cv_have_strcasecmp_decl" >&5 $as_echo "$ice_cv_have_strcasecmp_decl" >&6; } if test "$ice_cv_have_strcasecmp_decl" = yes; then @@ -72344,29 +43937,12 @@ fi - - - - - - - - - - - - - - - - - # Check whether --with-libcurl was given. -if test "${with_libcurl+set}" = set; then +if test "${with_libcurl+set}" = set; then : withval=$with_libcurl; _libcurl_with=$withval else _libcurl_with=yes @@ -72379,9 +43955,9 @@ fi 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 "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_AWK+set}" = set; then +if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then @@ -72392,24 +43968,24 @@ 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 + 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 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -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 "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -72427,9 +44003,9 @@ done _libcurl_ldflags="-L$withval/lib" # Extract the first word of "curl-config", so it can be a program name with args. set dummy curl-config; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path__libcurl_config+set}" = set; then +if ${ac_cv_path__libcurl_config+:} false; then : $as_echo_n "(cached) " >&6 else case $_libcurl_config in @@ -72442,14 +44018,14 @@ for as_dir in "$withval/bin" do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. - for ac_exec_ext in '' $ac_executable_extensions; do + 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__libcurl_config="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; @@ -72457,10 +44033,10 @@ esac fi _libcurl_config=$ac_cv_path__libcurl_config if test -n "$_libcurl_config"; then - { $as_echo "$as_me:$LINENO: result: $_libcurl_config" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_libcurl_config" >&5 $as_echo "$_libcurl_config" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -72468,9 +44044,9 @@ fi else # Extract the first word of "curl-config", so it can be a program name with args. set dummy curl-config; ac_word=$2 -{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_path__libcurl_config+set}" = set; then +if ${ac_cv_path__libcurl_config+:} false; then : $as_echo_n "(cached) " >&6 else case $_libcurl_config in @@ -72483,14 +44059,14 @@ 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 + 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__libcurl_config="$as_dir/$ac_word$ac_exec_ext" - $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done -done + done IFS=$as_save_IFS ;; @@ -72498,10 +44074,10 @@ esac fi _libcurl_config=$ac_cv_path__libcurl_config if test -n "$_libcurl_config"; then - { $as_echo "$as_me:$LINENO: result: $_libcurl_config" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_libcurl_config" >&5 $as_echo "$_libcurl_config" >&6; } else - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi @@ -72509,23 +44085,23 @@ fi fi if test x$_libcurl_config != "x" ; then - { $as_echo "$as_me:$LINENO: checking for the version of libcurl" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the version of libcurl" >&5 $as_echo_n "checking for the version of libcurl... " >&6; } -if test "${libcurl_cv_lib_curl_version+set}" = set; then +if ${libcurl_cv_lib_curl_version+:} false; then : $as_echo_n "(cached) " >&6 else libcurl_cv_lib_curl_version=`$_libcurl_config --version | $AWK '{print $2}'` fi -{ $as_echo "$as_me:$LINENO: result: $libcurl_cv_lib_curl_version" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_curl_version" >&5 $as_echo "$libcurl_cv_lib_curl_version" >&6; } _libcurl_version=`echo $libcurl_cv_lib_curl_version | $_libcurl_version_parse` _libcurl_wanted=`echo 7.10.0 | $_libcurl_version_parse` if test $_libcurl_wanted -gt 0 ; then - { $as_echo "$as_me:$LINENO: checking for libcurl >= version 7.10.0" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libcurl >= version 7.10.0" >&5 $as_echo_n "checking for libcurl >= version 7.10.0... " >&6; } -if test "${libcurl_cv_lib_version_ok+set}" = set; then +if ${libcurl_cv_lib_version_ok+:} false; then : $as_echo_n "(cached) " >&6 else @@ -72536,7 +44112,7 @@ else fi fi -{ $as_echo "$as_me:$LINENO: result: $libcurl_cv_lib_version_ok" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_version_ok" >&5 $as_echo "$libcurl_cv_lib_version_ok" >&6; } fi @@ -72577,9 +44153,9 @@ $as_echo "$libcurl_cv_lib_version_ok" >&6; } # link line (or failing that, "-lcurl") is enough. LIBCURL=${LIBCURL-"$_libcurl_ldflags -lcurl"} - { $as_echo "$as_me:$LINENO: checking whether libcurl is usable" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libcurl is usable" >&5 $as_echo_n "checking whether libcurl is usable... " >&6; } -if test "${libcurl_cv_lib_curl_usable+set}" = set; then +if ${libcurl_cv_lib_curl_usable+:} false; then : $as_echo_n "(cached) " >&6 else @@ -72588,11 +44164,7 @@ else _libcurl_save_libs=$LIBS LIBS="$LIBCURL $LIBS" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int @@ -72614,38 +44186,13 @@ x=CURLOPT_VERBOSE; 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 ac_fn_c_try_link "$LINENO"; then : libcurl_cv_lib_curl_usable=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - libcurl_cv_lib_curl_usable=no + libcurl_cv_lib_curl_usable=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext CPPFLAGS=$_libcurl_save_cppflags LIBS=$_libcurl_save_libs @@ -72653,7 +44200,7 @@ rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ unset _libcurl_save_libs fi -{ $as_echo "$as_me:$LINENO: result: $libcurl_cv_lib_curl_usable" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_curl_usable" >&5 $as_echo "$libcurl_cv_lib_curl_usable" >&6; } if test $libcurl_cv_lib_curl_usable = yes ; then @@ -72666,98 +44213,12 @@ $as_echo "$libcurl_cv_lib_curl_usable" >&6; } _libcurl_save_libs=$LIBS LIBS="$LIBS $LIBCURL" - { $as_echo "$as_me:$LINENO: checking for curl_free" >&5 -$as_echo_n "checking for curl_free... " >&6; } -if test "${ac_cv_func_curl_free+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 curl_free to an innocuous variant, in case declares curl_free. - For example, HP-UX 11i declares gettimeofday. */ -#define curl_free innocuous_curl_free - -/* System header to define __stub macros and hopefully few prototypes, - which can conflict with char curl_free (); below. - Prefer to if __STDC__ is defined, since - exists even on freestanding compilers. */ - -#ifdef __STDC__ -# include -#else -# include -#endif - -#undef curl_free - -/* 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 curl_free (); -/* 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_curl_free || defined __stub___curl_free -choke me -#endif - -int -main () -{ -return curl_free (); - ; - 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_curl_free=yes -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_func_curl_free=no -fi + ac_fn_c_check_func "$LINENO" "curl_free" "ac_cv_func_curl_free" +if test "x$ac_cv_func_curl_free" = xyes; then : -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_curl_free" >&5 -$as_echo "$ac_cv_func_curl_free" >&6; } -if test "x$ac_cv_func_curl_free" = x""yes; then - : else -cat >>confdefs.h <<\_ACEOF -#define curl_free free -_ACEOF +$as_echo "#define curl_free free" >>confdefs.h fi @@ -72768,9 +44229,7 @@ fi unset _libcurl_save_libs -cat >>confdefs.h <<\_ACEOF -#define HAVE_LIBCURL 1 -_ACEOF +$as_echo "#define HAVE_LIBCURL 1" >>confdefs.h @@ -72842,64 +44301,7 @@ _ACEOF - { $as_echo "$as_me:$LINENO: checking for curl_off_t" >&5 -$as_echo_n "checking for curl_off_t... " >&6; } -if test "${ac_cv_type_curl_off_t+set}" = set; then - $as_echo_n "(cached) " >&6 -else - ac_cv_type_curl_off_t=no -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - -#ifdef HAVE_SYS_TYPES_H -#include -#endif -#ifdef STDC_HEADERS -#include -#include -#endif -#include - - - -int -main () -{ -if (sizeof (curl_off_t)) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF -/* end confdefs.h. */ - + ac_fn_c_check_type "$LINENO" "curl_off_t" "ac_cv_type_curl_off_t" " #ifdef HAVE_SYS_TYPES_H #include #endif @@ -72910,62 +44312,13 @@ cat >>conftest.$ac_ext <<_ACEOF #include +" +if test "x$ac_cv_type_curl_off_t" = xyes; then : -int -main () -{ -if (sizeof ((curl_off_t))) - return 0; - ; - return 0; -} -_ACEOF -rm -f conftest.$ac_objext -if { (ac_try="$ac_compile" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\"" -$as_echo "$ac_try_echo") >&5 - (eval "$ac_compile") 2>conftest.er1 - ac_status=$? - grep -v '^ *+' conftest.er1 >conftest.err - rm -f conftest.er1 - cat conftest.err >&5 - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && { - test -z "$ac_c_werror_flag" || - test ! -s conftest.err - } && test -s conftest.$ac_objext; then - : -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_type_curl_off_t=yes -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - -fi - -rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext -fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_curl_off_t" >&5 -$as_echo "$ac_cv_type_curl_off_t" >&6; } -if test "x$ac_cv_type_curl_off_t" = x""yes; then - : else -cat >>confdefs.h <<\_ACEOF -#define curl_off_t off_t -_ACEOF +$as_echo "#define curl_off_t off_t" >>confdefs.h fi @@ -72990,19 +44343,14 @@ fi HAVE_HMAC=yes - -{ $as_echo "$as_me:$LINENO: checking for HMAC_CTX_init in -lcrypto" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HMAC_CTX_init in -lcrypto" >&5 $as_echo_n "checking for HMAC_CTX_init in -lcrypto... " >&6; } -if test "${ac_cv_lib_crypto_HMAC_CTX_init+set}" = set; then +if ${ac_cv_lib_crypto_HMAC_CTX_init+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lcrypto $LIBS" -cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF +cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. @@ -73020,43 +44368,18 @@ return HMAC_CTX_init (); 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 ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_crypto_HMAC_CTX_init=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_cv_lib_crypto_HMAC_CTX_init=no + ac_cv_lib_crypto_HMAC_CTX_init=no fi - -rm -rf conftest.dSYM -rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ - conftest$ac_exeext conftest.$ac_ext +rm -f core conftest.err conftest.$ac_objext \ + conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi -{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_HMAC_CTX_init" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_HMAC_CTX_init" >&5 $as_echo "$ac_cv_lib_crypto_HMAC_CTX_init" >&6; } -if test "x$ac_cv_lib_crypto_HMAC_CTX_init" = x""yes; then +if test "x$ac_cv_lib_crypto_HMAC_CTX_init" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBCRYPTO 1 _ACEOF @@ -73069,146 +44392,11 @@ fi found_hmac_h=no - - - -for ac_header in openssl/hmac.h crypto/hmac.h hmac.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;} - - ;; -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 + for ac_header in openssl/hmac.h crypto/hmac.h hmac.h +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -73226,14 +44414,14 @@ done # Check whether --enable-s3-device was given. -if test "${enable_s3_device+set}" = set; then +if test "${enable_s3_device+set}" = set; then : enableval=$enable_s3_device; WANT_S3_DEVICE=$enableval else WANT_S3_DEVICE=maybe fi - { $as_echo "$as_me:$LINENO: checking whether to include the Amazon S3 device" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to include the Amazon S3 device" >&5 $as_echo_n "checking whether to include the Amazon S3 device... " >&6; } # if the user didn't specify 'no', then check for support if test x"$WANT_S3_DEVICE" != x"no"; then @@ -73243,17 +44431,15 @@ $as_echo_n "checking whether to include the Amazon S3 device... " >&6; } # no support -- if the user explicitly enabled the device, # then this is an error if test x"$WANT_S3_DEVICE" = x"yes"; then - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } - { { $as_echo "$as_me:$LINENO: error: Cannot build the Amazon S3 device: one or more prerequisites are missing." >&5 -$as_echo "$as_me: error: Cannot build the Amazon S3 device: one or more prerequisites are missing." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "Cannot build the Amazon S3 device: one or more prerequisites are missing." "$LINENO" 5 else WANT_S3_DEVICE=no fi fi fi - { $as_echo "$as_me:$LINENO: result: $WANT_S3_DEVICE" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WANT_S3_DEVICE" >&5 $as_echo "$WANT_S3_DEVICE" >&6; } if test x"$WANT_S3_DEVICE" = x"yes"; then @@ -73268,157 +44454,20 @@ fi # Now handle any setup for S3, if we want it. if test x"$WANT_S3_DEVICE" = x"yes"; then -cat >>confdefs.h <<\_ACEOF -#define WANT_S3_DEVICE /**/ -_ACEOF +$as_echo "#define WANT_S3_DEVICE /**/" >>confdefs.h fi - - - -for ac_header in \ + for ac_header in \ linux/zftape.h \ sys/tape.h \ sys/mtio.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;} - - ;; -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 +do : + as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` +ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" +if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF @@ -73429,17 +44478,13 @@ done # check for MTIOCTOP, an indicator of POSIX tape support - { $as_echo "$as_me:$LINENO: checking for MTIOCTOP" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MTIOCTOP" >&5 $as_echo_n "checking for MTIOCTOP... " >&6; } -if test "${amanda_cv_HAVE_MTIOCTOP+set}" = set; then +if ${amanda_cv_HAVE_MTIOCTOP+:} false; 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 + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef HAVE_SYS_TAPE_H @@ -73460,47 +44505,24 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : amanda_cv_HAVE_MTIOCTOP=yes else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - amanda_cv_HAVE_MTIOCTOP=no + amanda_cv_HAVE_MTIOCTOP=no fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext HAVE_MTIOCTOP=$amanda_cv_HAVE_MTIOCTOP fi -{ $as_echo "$as_me:$LINENO: result: $amanda_cv_HAVE_MTIOCTOP" >&5 +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $amanda_cv_HAVE_MTIOCTOP" >&5 $as_echo "$amanda_cv_HAVE_MTIOCTOP" >&6; } # maybe we have no tape device at all (e.g., Mac OS X)? if test x"$HAVE_MTIOCTOP" = x"yes"; then want_tape_device=yes -cat >>confdefs.h <<\_ACEOF -#define WANT_TAPE_DEVICE 1 -_ACEOF +$as_echo "#define WANT_TAPE_DEVICE 1" >>confdefs.h fi if test -n "$want_tape_device"; then @@ -73515,13 +44537,9 @@ fi # # Check for various "mt status" related structure elements. # - { $as_echo "$as_me:$LINENO: checking for mt_flags mtget structure element" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mt_flags mtget structure element" >&5 $as_echo_n "checking for mt_flags mtget structure element... " >&6; } - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -73541,53 +44559,26 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:$LINENO: result: yes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } -cat >>confdefs.h <<\_ACEOF -#define HAVE_MT_FLAGS 1 -_ACEOF +$as_echo "#define HAVE_MT_FLAGS 1" >>confdefs.h else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - { $as_echo "$as_me:$LINENO: checking for mt_fileno mtget structure element" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mt_fileno mtget structure element" >&5 $as_echo_n "checking for mt_fileno mtget structure element... " >&6; } mt_fileno_result="found" - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -73607,52 +44598,25 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:$LINENO: result: yes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } -cat >>confdefs.h <<\_ACEOF -#define HAVE_MT_FILENO 1 -_ACEOF +$as_echo "#define HAVE_MT_FILENO 1" >>confdefs.h else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - { $as_echo "$as_me:$LINENO: checking for mt_blkno mtget structure element" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mt_blkno mtget structure element" >&5 $as_echo_n "checking for mt_blkno mtget structure element... " >&6; } - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -73672,52 +44636,25 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:$LINENO: result: yes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } -cat >>confdefs.h <<\_ACEOF -#define HAVE_MT_BLKNO 1 -_ACEOF +$as_echo "#define HAVE_MT_BLKNO 1" >>confdefs.h else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - { $as_echo "$as_me:$LINENO: checking for mt_dsreg mtget structure element" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mt_dsreg mtget structure element" >&5 $as_echo_n "checking for mt_dsreg mtget structure element... " >&6; } - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -73737,52 +44674,25 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:$LINENO: result: yes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } -cat >>confdefs.h <<\_ACEOF -#define HAVE_MT_DSREG 1 -_ACEOF +$as_echo "#define HAVE_MT_DSREG 1" >>confdefs.h else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext - { $as_echo "$as_me:$LINENO: checking for mt_erreg mtget structure element" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mt_erreg mtget structure element" >&5 $as_echo_n "checking for mt_erreg mtget structure element... " >&6; } - cat >conftest.$ac_ext <<_ACEOF -/* confdefs.h. */ -_ACEOF -cat confdefs.h >>conftest.$ac_ext -cat >>conftest.$ac_ext <<_ACEOF + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include @@ -73802,65 +44712,40 @@ 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 +if ac_fn_c_try_compile "$LINENO"; then : - { $as_echo "$as_me:$LINENO: result: yes" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } -cat >>confdefs.h <<\_ACEOF -#define HAVE_MT_ERREG 1 -_ACEOF +$as_echo "#define HAVE_MT_ERREG 1" >>confdefs.h else - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - { $as_echo "$as_me:$LINENO: result: no" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext case "$host" in *linux*) -cat >>confdefs.h <<\_ACEOF -#define DEFAULT_TAPE_NON_BLOCKING_OPEN 1 -_ACEOF +$as_echo "#define DEFAULT_TAPE_NON_BLOCKING_OPEN 1" >>confdefs.h ;; esac # Check whether --enable-dvdrw-device was given. -if test "${enable_dvdrw_device+set}" = set; then +if test "${enable_dvdrw_device+set}" = set; then : enableval=$enable_dvdrw_device; WANT_DVDRW_DEVICE=$enableval else WANT_DVDRW_DEVICE=yes fi - { $as_echo "$as_me:$LINENO: checking whether to include the DVD-RW device" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to include the DVD-RW device" >&5 $as_echo_n "checking whether to include the DVD-RW device... " >&6; } - { $as_echo "$as_me:$LINENO: result: $WANT_DVDRW_DEVICE" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WANT_DVDRW_DEVICE" >&5 $as_echo "$WANT_DVDRW_DEVICE" >&6; } if test x"$WANT_DVDRW_DEVICE" = x"yes"; then @@ -73875,9 +44760,7 @@ fi # Now handle any setup for DVDRW, if we want it. if test x"$WANT_DVDRW_DEVICE" = x"yes"; then -cat >>confdefs.h <<\_ACEOF -#define WANT_DVDRW_DEVICE /**/ -_ACEOF +$as_echo "#define WANT_DVDRW_DEVICE /**/" >>confdefs.h fi @@ -73885,7 +44768,7 @@ _ACEOF # Check whether --enable-ndmp-device was given. -if test "${enable_ndmp_device+set}" = set; then +if test "${enable_ndmp_device+set}" = set; then : enableval=$enable_ndmp_device; WANT_NDMP_DEVICE=$enableval else WANT_NDMP_DEVICE=$WANT_NDMP @@ -73893,16 +44776,12 @@ fi if test x"$WANT_NDMP" != x"true" -a x"$WANT_NDMP_DEVICE" = x"true"; then - { { $as_echo "$as_me:$LINENO: error: NDMP support is required to build the ndmp device (--with-ndmp)" >&5 -$as_echo "$as_me: error: NDMP support is required to build the ndmp device (--with-ndmp)" >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "NDMP support is required to build the ndmp device (--with-ndmp)" "$LINENO" 5 fi if test x"$WANT_NDMP_DEVICE" = x"true"; then -cat >>confdefs.h <<\_ACEOF -#define WANT_NDMP_DEVICE 1 -_ACEOF +$as_echo "#define WANT_NDMP_DEVICE 1" >>confdefs.h fi @@ -73947,13 +44826,13 @@ _ACEOF 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 + *_cv_*) { $as_echo "$as_me:${as_lineno-$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 ;; + *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done @@ -73961,8 +44840,8 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; (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 \). + # `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" @@ -73984,12 +44863,23 @@ $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&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 + if test "x$cache_file" != "x/dev/null"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} - cat confcache >$cache_file + if test ! -f "$cache_file" || test -h "$cache_file"; then + cat confcache >"$cache_file" + else + case $cache_file in #( + */* | ?:*) + mv -f confcache "$cache_file"$$ && + mv -f "$cache_file"$$ "$cache_file" ;; #( + *) + mv -f confcache "$cache_file" ;; + esac + fi + fi else - { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5 + { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi @@ -74003,14 +44893,15 @@ DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= +U= 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' + as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" + as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs @@ -74026,25 +44917,16 @@ else fi if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"AMDEP\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"AMDEP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"am__fastdepCC\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"am__fastdepCC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"GL_COND_LIBTOOL\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"GL_COND_LIBTOOL\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi gl_libobjs= @@ -74079,231 +44961,139 @@ fi if test -z "${WANT_AS_NEEDED_TRUE}" && test -z "${WANT_AS_NEEDED_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_AS_NEEDED\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_AS_NEEDED\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_AS_NEEDED\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${CHECK_USERID_TRUE}" && test -z "${CHECK_USERID_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"CHECK_USERID\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"CHECK_USERID\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"CHECK_USERID\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_SETUID_CLIENT_TRUE}" && test -z "${WANT_SETUID_CLIENT_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_SETUID_CLIENT\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_SETUID_CLIENT\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_SETUID_CLIENT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_INSTALLPERMS_TRUE}" && test -z "${WANT_INSTALLPERMS_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_INSTALLPERMS\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_INSTALLPERMS\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_INSTALLPERMS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${SYNTAX_CHECKS_TRUE}" && test -z "${SYNTAX_CHECKS_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"SYNTAX_CHECKS\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"SYNTAX_CHECKS\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"SYNTAX_CHECKS\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_CLIENT_TRUE}" && test -z "${WANT_CLIENT_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_CLIENT\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_CLIENT\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_CLIENT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_RESTORE_TRUE}" && test -z "${WANT_RESTORE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_RESTORE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_RESTORE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_RESTORE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_SERVER_TRUE}" && test -z "${WANT_SERVER_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_SERVER\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_SERVER\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_SERVER\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_RECOVER_TRUE}" && test -z "${WANT_RECOVER_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_RECOVER\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_RECOVER\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_RECOVER\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_NDMP_TRUE}" && test -z "${WANT_NDMP_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_NDMP\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_NDMP\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_NDMP\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_TAPE_TRUE}" && test -z "${WANT_TAPE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_TAPE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_TAPE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_TAPE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_AMPLOT_TRUE}" && test -z "${WANT_AMPLOT_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_AMPLOT\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_AMPLOT\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_AMPLOT\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${ENABLE_MANPAGE_BUILD_TRUE}" && test -z "${ENABLE_MANPAGE_BUILD_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"ENABLE_MANPAGE_BUILD\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"ENABLE_MANPAGE_BUILD\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"ENABLE_MANPAGE_BUILD\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_AMFLOCK_POSIX_TRUE}" && test -z "${WANT_AMFLOCK_POSIX_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_AMFLOCK_POSIX\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_AMFLOCK_POSIX\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_AMFLOCK_POSIX\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_AMFLOCK_FLOCK_TRUE}" && test -z "${WANT_AMFLOCK_FLOCK_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_AMFLOCK_FLOCK\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_AMFLOCK_FLOCK\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_AMFLOCK_FLOCK\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_AMFLOCK_LOCKF_TRUE}" && test -z "${WANT_AMFLOCK_LOCKF_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_AMFLOCK_LOCKF\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_AMFLOCK_LOCKF\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_AMFLOCK_LOCKF\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_AMFLOCK_LNLOCK_TRUE}" && test -z "${WANT_AMFLOCK_LNLOCK_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_AMFLOCK_LNLOCK\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_AMFLOCK_LNLOCK\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_AMFLOCK_LNLOCK\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_CYGWIN_COPY_PERL_DLL_TRUE}" && test -z "${WANT_CYGWIN_COPY_PERL_DLL_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_CYGWIN_COPY_PERL_DLL\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_CYGWIN_COPY_PERL_DLL\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_CYGWIN_COPY_PERL_DLL\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_MANDATORY_THREAD_CHECK_TRUE}" && test -z "${WANT_MANDATORY_THREAD_CHECK_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_MANDATORY_THREAD_CHECK\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_MANDATORY_THREAD_CHECK\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_MANDATORY_THREAD_CHECK\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_BSD_SECURITY_TRUE}" && test -z "${WANT_BSD_SECURITY_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_BSD_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_BSD_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_BSD_SECURITY\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_BSDTCP_SECURITY_TRUE}" && test -z "${WANT_BSDTCP_SECURITY_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_BSDTCP_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_BSDTCP_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_BSDTCP_SECURITY\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_BSDUDP_SECURITY_TRUE}" && test -z "${WANT_BSDUDP_SECURITY_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_BSDUDP_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_BSDUDP_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_BSDUDP_SECURITY\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_RSH_SECURITY_TRUE}" && test -z "${WANT_RSH_SECURITY_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_RSH_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_RSH_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_RSH_SECURITY\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_SSH_SECURITY_TRUE}" && test -z "${WANT_SSH_SECURITY_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_SSH_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_SSH_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_SSH_SECURITY\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_KRB5_SECURITY_TRUE}" && test -z "${WANT_KRB5_SECURITY_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_KRB5_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_KRB5_SECURITY\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_KRB5_SECURITY\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_SAMBA_TRUE}" && test -z "${WANT_SAMBA_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_SAMBA\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_SAMBA\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_SAMBA\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${GCC_COMPILER_TRUE}" && test -z "${GCC_COMPILER_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"GCC_COMPILER\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"GCC_COMPILER\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"GCC_COMPILER\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_S3_DEVICE_TRUE}" && test -z "${WANT_S3_DEVICE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_S3_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_S3_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_S3_DEVICE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_TAPE_DEVICE_TRUE}" && test -z "${WANT_TAPE_DEVICE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_TAPE_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_TAPE_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_TAPE_DEVICE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_DVDRW_DEVICE_TRUE}" && test -z "${WANT_DVDRW_DEVICE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_DVDRW_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_DVDRW_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_DVDRW_DEVICE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${WANT_NDMP_DEVICE_TRUE}" && test -z "${WANT_NDMP_DEVICE_FALSE}"; then - { { $as_echo "$as_me:$LINENO: error: conditional \"WANT_NDMP_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&5 -$as_echo "$as_me: error: conditional \"WANT_NDMP_DEVICE\" was never defined. -Usually this means the macro was only invoked conditionally." >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "conditional \"WANT_NDMP_DEVICE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi -: ${CONFIG_STATUS=./config.status} +: "${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:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} -cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +as_write_fail=0 +cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. @@ -74313,17 +45103,18 @@ cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 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. ## -## --------------------- ## +SHELL=\${CONFIG_SHELL-$SHELL} +export SHELL +_ASEOF +cat >>$CONFIG_STATUS <<\_ASEOF || as_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 +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 @@ -74331,23 +45122,15 @@ if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else - case `(set -o) 2>/dev/null` in - *posix*) set -o posix ;; + 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 @@ -74355,7 +45138,13 @@ export as_nl 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 +# Prefer a ksh shell builtin over an external printf program on Solaris, +# but without wasting forks for bash or zsh. +if test -z "$BASH_VERSION$ZSH_VERSION" \ + && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then + as_echo='print -r --' + as_echo_n='print -rn --' +elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else @@ -74366,7 +45155,7 @@ else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; - case $arg in + case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; @@ -74389,13 +45178,6 @@ if test "${PATH_SEPARATOR+set}" != set; then } 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 @@ -74405,15 +45187,16 @@ fi IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. -case $0 in +as_myself= +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 + test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break + done IFS=$as_save_IFS ;; @@ -74425,12 +45208,16 @@ if test "x$as_myself" = x; then 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; } + 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 +# Unset variables that we do not need and which cause bugs (e.g. in +# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" +# suppresses any "Segmentation fault" message there. '((' could +# trigger a bug in pdksh 5.2.14. +for as_var in BASH_ENV ENV MAIL MAILPATH +do eval test x\${$as_var+set} = xset \ + && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' @@ -74442,7 +45229,89 @@ export LC_ALL LANGUAGE=C export LANGUAGE -# Required to use basename. +# CDPATH. +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH + + +# as_fn_error STATUS ERROR [LINENO LOG_FD] +# ---------------------------------------- +# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are +# provided, also output the error to LOG_FD, referencing LINENO. Then exit the +# script with STATUS, using 1 if that was 0. +as_fn_error () +{ + as_status=$1; test $as_status -eq 0 && as_status=1 + if test "$4"; then + as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack + $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 + fi + $as_echo "$as_me: error: $2" >&2 + as_fn_exit $as_status +} # as_fn_error + + +# as_fn_set_status STATUS +# ----------------------- +# Set $? to STATUS, without forking. +as_fn_set_status () +{ + return $1 +} # as_fn_set_status + +# as_fn_exit STATUS +# ----------------- +# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. +as_fn_exit () +{ + set +e + as_fn_set_status $1 + exit $1 +} # as_fn_exit + +# as_fn_unset VAR +# --------------- +# Portably unset VAR. +as_fn_unset () +{ + { eval $1=; unset $1;} +} +as_unset=as_fn_unset +# as_fn_append VAR VALUE +# ---------------------- +# Append the text in VALUE to the end of the definition contained in VAR. Take +# advantage of any shell optimizations that allow amortized linear growth over +# repeated appends, instead of the typical quadratic growth present in naive +# implementations. +if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : + eval 'as_fn_append () + { + eval $1+=\$2 + }' +else + as_fn_append () + { + eval $1=\$$1\$2 + } +fi # as_fn_append + +# as_fn_arith ARG... +# ------------------ +# Perform arithmetic evaluation on the ARGs, and store the result in the +# global $as_val. Take advantage of shells that can avoid forks. The arguments +# must be portable across $(()) and expr. +if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : + eval 'as_fn_arith () + { + as_val=$(( $* )) + }' +else + as_fn_arith () + { + as_val=`expr "$@" || test $? -eq 1` + } +fi # as_fn_arith + + if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr @@ -74456,8 +45325,12 @@ else as_basename=false fi +if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then + as_dirname=dirname +else + as_dirname=false +fi -# Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ @@ -74477,76 +45350,25 @@ $as_echo X/"$0" | } 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 +# 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 ECHO_C= ECHO_N= ECHO_T= -case `echo -n x` in +case `echo -n x` in #((((( -n*) - case `echo 'x\c'` in + case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. - *) ECHO_C='\c';; + xy) ECHO_C='\c';; + *) echo `echo ksh88 bug on AIX 6.1` > /dev/null + ECHO_T=' ';; 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 @@ -74575,8 +45397,56 @@ fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null + +# as_fn_mkdir_p +# ------------- +# Create "$as_dir" as a directory, including parents if necessary. +as_fn_mkdir_p () +{ + + case $as_dir in #( + -*) as_dir=./$as_dir;; + esac + test -d "$as_dir" || eval $as_mkdir_p || { + 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_fn_error $? "cannot create directory $as_dir" + + +} # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then - as_mkdir_p=: + as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false @@ -74595,10 +45465,10 @@ else if test -d "$1"; then test -d "$1/."; else - case $1 in + case $1 in #( -*)set "./$1";; esac; - case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in + case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' @@ -74613,13 +45483,19 @@ as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 +## ----------------------------------- ## +## Main body of $CONFIG_STATUS script. ## +## ----------------------------------- ## +_ASEOF +test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 -# Save the log message, to keep $[0] and so on meaningful, and to +cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=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 $as_me, which was -generated by GNU Autoconf 2.63. Invocation command line was +generated by GNU Autoconf 2.68. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS @@ -74651,13 +45527,15 @@ _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ -\`$as_me' instantiates files from templates according to the -current configuration. +\`$as_me' instantiates files and other configuration actions +from templates according to the current configuration. Unless the files +and actions are specified as TAGs, all are instantiated by default. -Usage: $0 [OPTION]... [FILE]... +Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit + --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files @@ -74676,16 +45554,17 @@ $config_headers Configuration commands: $config_commands -Report bugs to ." +Report bugs to the package provider." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 +ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ config.status -configured by $0, generated by GNU Autoconf 2.63, - with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" +configured by $0, generated by GNU Autoconf 2.68, + with options \\"\$ac_cs_config\\" -Copyright (C) 2008 Free Software Foundation, Inc. +Copyright (C) 2010 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." @@ -74703,11 +45582,16 @@ 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=`expr "X$1" : 'X\([^=]*\)='` + ac_optarg= + ac_shift=: + ;; *) ac_option=$1 ac_optarg=$2 @@ -74721,27 +45605,29 @@ do ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) $as_echo "$ac_cs_version"; exit ;; + --config | --confi | --conf | --con | --co | --c ) + $as_echo "$ac_cs_config"; 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"` ;; + '') as_fn_error $? "missing file argument" ;; esac - CONFIG_FILES="$CONFIG_FILES '$ac_optarg'" + as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac - CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'" + as_fn_append CONFIG_HEADERS " '$ac_optarg'" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header - { $as_echo "$as_me: error: ambiguous option: $1 -Try \`$0 --help' for more information." >&2 - { (exit 1); exit 1; }; };; + as_fn_error $? "ambiguous option: \`$1' +Try \`$0 --help' for more information.";; --help | --hel | -h ) $as_echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ @@ -74749,11 +45635,10 @@ Try \`$0 --help' for more information." >&2 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; }; } ;; + -*) as_fn_error $? "unrecognized option: \`$1' +Try \`$0 --help' for more information." ;; - *) ac_config_targets="$ac_config_targets $1" + *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac @@ -74811,130 +45696,153 @@ AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" 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"`' -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"`' +macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' +macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' +enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' +enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' +pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' +enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' +SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' +ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' +host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' +host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' +host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' +build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' +build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' +build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' +SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' +Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' +GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' +EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' +FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' +LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' +NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' +LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' +max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' +ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' +exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' +lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' +lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' +lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' +lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' +lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' +reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' +reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' +OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' +deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' +file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' +file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' +want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' +DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' +sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' +AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' +AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' +archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' +STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' +RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' +old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' +old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' +lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' +CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' +CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' +compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' +GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' +nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' +lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' +objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' +MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' +lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' +lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' +need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' +MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' +DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' +NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' +LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' +OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' +OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' +libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' +shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' +extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' +enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' +export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' +whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' +compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' +old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' +old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' +archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' +archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' +module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' +module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' +with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' +allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' +no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`' +hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' +hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' +hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' +hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' +hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' +hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' +inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' +link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' +always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' +export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' +exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' +include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' +prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' +postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' +file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' +variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' +need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' +need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' +version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' +runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' +shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' +libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' +library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' +soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' +install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' +postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' +postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' +finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' +finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' +hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' +sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' +sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`' +hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' +enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' +enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' +old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' +striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' +# A function that is used when there is no print builtin or printf. +func_fallback_echo () +{ + eval 'cat <<_LTECHO_EOF +\$1 +_LTECHO_EOF' +} + # Quote evaled strings. -for var in SED \ +for var in SHELL \ +ECHO \ +SED \ GREP \ EGREP \ FGREP \ @@ -74944,10 +45852,16 @@ LN_S \ lt_SP2NL \ lt_NL2SP \ reload_flag \ +OBJDUMP \ deplibs_check_method \ file_magic_cmd \ +file_magic_glob \ +want_nocaseglob \ +DLLTOOL \ +sharedlib_from_linklib_cmd \ AR \ AR_FLAGS \ +archiver_list_spec \ STRIP \ RANLIB \ CC \ @@ -74957,14 +45871,14 @@ 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 \ +nm_file_list_spec \ lt_prog_compiler_no_builtin_flag \ -lt_prog_compiler_wl \ lt_prog_compiler_pic \ +lt_prog_compiler_wl \ lt_prog_compiler_static \ lt_cv_prog_compiler_c_o \ need_locks \ +MANIFEST_TOOL \ DSYMUTIL \ NMEDIT \ LIPO \ @@ -74980,7 +45894,6 @@ 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 \ @@ -74988,12 +45901,13 @@ variables_saved_for_relink \ libname_spec \ library_names_spec \ soname_spec \ +install_override_mode \ finish_eval \ old_striplib \ striplib; do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -75015,14 +45929,15 @@ module_cmds \ module_expsym_cmds \ export_symbols_cmds \ prelink_cmds \ +postlink_cmds \ postinstall_cmds \ postuninstall_cmds \ finish_cmds \ sys_lib_search_path_spec \ sys_lib_dlsearch_path_spec; do - case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in + case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -75030,12 +45945,6 @@ sys_lib_dlsearch_path_spec; do 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' @@ -75092,9 +46001,7 @@ do "server-src/Makefile") CONFIG_FILES="$CONFIG_FILES server-src/Makefile" ;; "xfer-src/Makefile") CONFIG_FILES="$CONFIG_FILES xfer-src/Makefile" ;; - *) { { $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; }; };; + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done @@ -75117,26 +46024,24 @@ fi # after its creation but before its name has been assigned to `$tmp'. $debug || { - tmp= + tmp= ac_tmp= trap 'exit_status=$? - { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status + : "${ac_tmp:=$tmp}" + { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status ' 0 - trap '{ (exit 1); exit 1; }' 1 2 13 15 + trap 'as_fn_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" + 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; } -} +} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 +ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. @@ -75144,7 +46049,13 @@ $debug || if test -n "$CONFIG_FILES"; then -ac_cr=' ' +ac_cr=`echo X | tr X '\015'` +# On cygwin, bash can eat \r inside `` if the user requested igncr. +# But we know of no other shell where ac_cr would be empty at this +# point, so we can use a bashism as a fallback. +if test "x$ac_cr" = x; then + eval ac_cr=\$\'\\r\' +fi 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' @@ -75152,7 +46063,7 @@ else ac_cs_awk_cr=$ac_cr fi -echo 'BEGIN {' >"$tmp/subs1.awk" && +echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF @@ -75161,24 +46072,18 @@ _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 '$'` + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 +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; }; } + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 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; }; } + as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi @@ -75186,7 +46091,7 @@ done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 -cat >>"\$tmp/subs1.awk" <<\\_ACAWK && +cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h @@ -75200,7 +46105,7 @@ s/'"$ac_delim"'$// t delim :nl h -s/\(.\{148\}\).*/\1/ +s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p @@ -75214,7 +46119,7 @@ s/.\{148\}// t nl :delim h -s/\(.\{148\}\).*/\1/ +s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p @@ -75234,7 +46139,7 @@ t delim rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK -cat >>"\$tmp/subs1.awk" <<_ACAWK && +cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" @@ -75266,23 +46171,29 @@ 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; }; } +fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ + || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF -# VPATH may cause trouble with some makes, so we remove $(srcdir), -# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and +# VPATH may cause trouble with some makes, so we remove sole $(srcdir), +# ${srcdir} and @srcdir@ entries 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/ + ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ +h +s/// +s/^/:/ +s/[ ]*$/:/ +s/:\$(srcdir):/:/g +s/:\${srcdir}:/:/g +s/:@srcdir@:/:/g +s/^:*// s/:*$// +x +s/\(=[ ]*\).*/\1/ +G +s/\n// s/^[^=]*=[ ]*$// }' fi @@ -75294,7 +46205,7 @@ fi # test -n "$CONFIG_FILES" # No need to generate them if there are no CONFIG_HEADERS. # This happens for instance with `./config.status Makefile'. if test -n "$CONFIG_HEADERS"; then -cat >"$tmp/defines.awk" <<\_ACAWK || +cat >"$ac_tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF @@ -75306,13 +46217,11 @@ _ACEOF # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do - ac_t=`sed -n "/$ac_delim/p" confdefs.h` - if test -z "$ac_t"; then + ac_tt=`sed -n "/$ac_delim/p" confdefs.h` + if test -z "$ac_tt"; then break elif $ac_last_try; then - { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5 -$as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi @@ -75397,9 +46306,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 - { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5 -$as_echo "$as_me: error: could not setup config headers machinery" >&2;} - { (exit 1); exit 1; }; } + as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 fi # test -n "$CONFIG_HEADERS" @@ -75412,9 +46319,7 @@ do 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; }; };; + :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac @@ -75433,7 +46338,7 @@ $as_echo "$as_me: error: invalid tag $ac_tag" >&2;} for ac_f do case $ac_f in - -) ac_f="$tmp/stdin";; + -) ac_f="$ac_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 `:'. @@ -75442,12 +46347,10 @@ $as_echo "$as_me: error: invalid tag $ac_tag" >&2;} [\\/$]*) 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; }; };; + as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac - ac_file_inputs="$ac_file_inputs '$ac_f'" + as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't @@ -75458,7 +46361,7 @@ $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;} `' 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:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. @@ -75470,10 +46373,8 @@ $as_echo "$as_me: creating $ac_file" >&6;} 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; }; } ;; + *:-:* | *:-) cat >"$ac_tmp/stdin" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac @@ -75501,47 +46402,7 @@ $as_echo X"$ac_file" | 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; }; }; } + as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in @@ -75598,7 +46459,6 @@ 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 @@ -75608,12 +46468,11 @@ ac_sed_dataroot=' /@docdir@/p /@infodir@/p /@localedir@/p -/@mandir@/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:${as_lineno-$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 @@ -75623,7 +46482,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g - s&\\\${datarootdir}&$datarootdir&g' ;; + s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF @@ -75651,27 +46510,24 @@ 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; }; } +eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ + >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && - { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && - { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && - { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' -which seems to be undefined. Please make sure it is defined." >&5 + { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && + { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ + "$ac_tmp/out"`; test -z "$ac_out"; } && + { $as_echo "$as_me:${as_lineno-$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;} +which seems to be undefined. Please make sure it is defined" >&2;} - rm -f "$tmp/stdin" + rm -f "$ac_tmp/stdin" case $ac_file in - -) cat "$tmp/out" && rm -f "$tmp/out";; - *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; + -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; + *) rm -f "$ac_file" && mv "$ac_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; }; } + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; :H) # @@ -75680,27 +46536,21 @@ $as_echo "$as_me: error: could not create $ac_file" >&2;} if test x"$ac_file" != x-; then { $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" - } >"$tmp/config.h" \ - || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 -$as_echo "$as_me: error: could not create $ac_file" >&2;} - { (exit 1); exit 1; }; } - if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then - { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5 + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" + } >"$ac_tmp/config.h" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 + if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then + { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" - mv "$tmp/config.h" "$ac_file" \ - || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5 -$as_echo "$as_me: error: could not create $ac_file" >&2;} - { (exit 1); exit 1; }; } + mv "$ac_tmp/config.h" "$ac_file" \ + || as_fn_error $? "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ - && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ - || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5 -$as_echo "$as_me: error: could not create -" >&2;} - { (exit 1); exit 1; }; } + && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ + || as_fn_error $? "could not create -" "$LINENO" 5 fi # Compute "$ac_file"'s index in $config_headers. _am_arg="$ac_file" @@ -75738,7 +46588,7 @@ $as_echo X"$_am_arg" | s/.*/./; q'`/stamp-h$_am_stamp_count ;; - :C) { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5 + :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac @@ -75833,47 +46683,7 @@ $as_echo X"$file" | q } s/.*/./; q'` - { as_dir=$dirpart/$fdir - case $as_dir in #( - -*) as_dir=./$as_dir;; - esac - test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { - as_dirs= - while :; do - case $as_dir in #( - *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( - *) as_qdir=$as_dir;; - esac - as_dirs="'$as_qdir' $as_dirs" - as_dir=`$as_dirname -- "$as_dir" || -$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ - X"$as_dir" : 'X\(//\)[^/]' \| \ - X"$as_dir" : 'X\(//\)$' \| \ - X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || -$as_echo X"$as_dir" | - sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ - s//\1/ - q - } - /^X\(\/\/\)[^/].*/{ - s//\1/ - q - } - /^X\(\/\/\)$/{ - s//\1/ - q - } - /^X\(\/\).*/{ - s//\1/ - q - } - s/.*/./; q'` - test -d "$as_dir" && break - done - test -z "$as_dirs" || eval "mkdir $as_dirs" - } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 -$as_echo "$as_me: error: cannot create directory $as_dir" >&2;} - { (exit 1); exit 1; }; }; } + as_dir=$dirpart/$fdir; as_fn_mkdir_p # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done @@ -76014,7 +46824,8 @@ $as_echo "$as_me: error: cannot create directory $as_dir" >&2;} # 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. +# 2006, 2007, 2008, 2009, 2010 Free Software Foundation, +# Inc. # Written by Gordon Matzigkeit, 1996 # # This file is part of GNU Libtool. @@ -76062,6 +46873,12 @@ pic_mode=$pic_mode # Whether or not to optimize for fast installation. fast_install=$enable_fast_install +# Shell to use when invoking shell scripts. +SHELL=$lt_SHELL + +# An echo program that protects backslashes. +ECHO=$lt_ECHO + # The host system. host_alias=$host_alias host=$host @@ -76111,20 +46928,42 @@ 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 +# convert \$build file names to \$host format. +to_host_file_cmd=$lt_cv_to_host_file_cmd + +# convert \$build files to toolchain format. +to_tool_file_cmd=$lt_cv_to_tool_file_cmd + +# 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". +# Command to use when deplibs_check_method = "file_magic". file_magic_cmd=$lt_file_magic_cmd +# How to find potential files when deplibs_check_method = "file_magic". +file_magic_glob=$lt_file_magic_glob + +# Find potential files using nocaseglob when deplibs_check_method = "file_magic". +want_nocaseglob=$lt_want_nocaseglob + +# DLL creation program. +DLLTOOL=$lt_DLLTOOL + +# Command to associate shared and link libraries. +sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd + # The archiver. AR=$lt_AR + +# Flags to create an archive. AR_FLAGS=$lt_AR_FLAGS +# How to feed a file listing to the archiver. +archiver_list_spec=$lt_archiver_list_spec + # A symbol stripping program. STRIP=$lt_STRIP @@ -76133,6 +46972,9 @@ RANLIB=$lt_RANLIB old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds +# Whether to use a lock for old archive extraction. +lock_old_archive_extraction=$lock_old_archive_extraction + # A C compiler. LTCC=$lt_CC @@ -76151,14 +46993,14 @@ 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 +# Specify filename containing input files for \$NM. +nm_file_list_spec=$lt_nm_file_list_spec -# Shell to use when invoking shell scripts. -SHELL=$lt_SHELL +# The root where to search for dependent libraries,and in which our libraries should be installed. +lt_sysroot=$lt_sysroot -# An echo program that does not interpret backslashes. -ECHO=$lt_ECHO +# The name of the directory that contains temporary libtool files. +objdir=$objdir # Used to examine libraries when file_magic_cmd begins with "file". MAGIC_CMD=$MAGIC_CMD @@ -76166,6 +47008,9 @@ MAGIC_CMD=$MAGIC_CMD # Must we lock files when doing compilation? need_locks=$lt_need_locks +# Manifest tool. +MANIFEST_TOOL=$lt_MANIFEST_TOOL + # Tool to manipulate archived DWARF debug symbol files on Mac OS X. DSYMUTIL=$lt_DSYMUTIL @@ -76222,6 +47067,9 @@ library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec +# Permission mode override for installation of shared libraries. +install_override_mode=$lt_install_override_mode + # Command to use after installation of a shared archive. postinstall_cmds=$lt_postinstall_cmds @@ -76261,6 +47109,10 @@ striplib=$lt_striplib # The linker used to build libraries. LD=$lt_LD +# How to create reloadable object files. +reload_flag=$lt_reload_flag +reload_cmds=$lt_reload_cmds + # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds @@ -76273,12 +47125,12 @@ 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 +# How to pass a linker flag through the compiler. +wl=$lt_lt_prog_compiler_wl + # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static @@ -76365,9 +47217,6 @@ 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 @@ -76383,6 +47232,9 @@ include_expsyms=$lt_include_expsyms # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds +# Commands necessary for finishing linking programs. +postlink_cmds=$lt_postlink_cmds + # Specify filename containing input files. file_list_spec=$lt_file_list_spec @@ -76415,212 +47267,169 @@ ltmain="$ac_aux_dir/ltmain.sh" # 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" || + sed '$q' "$ltmain" >> "$cfgfile" \ + || (rm -f "$cfgfile"; exit 1) + + if test x"$xsi_shell" = xyes; then + sed -e '/^func_dirname ()$/,/^} # func_dirname /c\ +func_dirname ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +} # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_basename ()$/,/^} # func_basename /c\ +func_basename ()\ +{\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\ +func_dirname_and_basename ()\ +{\ +\ case ${1} in\ +\ */*) func_dirname_result="${1%/*}${2}" ;;\ +\ * ) func_dirname_result="${3}" ;;\ +\ esac\ +\ func_basename_result="${1##*/}"\ +} # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_stripname ()$/,/^} # func_stripname /c\ +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}"}\ +} # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\ +func_split_long_opt ()\ +{\ +\ func_split_long_opt_name=${1%%=*}\ +\ func_split_long_opt_arg=${1#*=}\ +} # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\ +func_split_short_opt ()\ +{\ +\ func_split_short_opt_arg=${1#??}\ +\ func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\ +} # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\ +func_lo2o ()\ +{\ +\ case ${1} in\ +\ *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\ +\ *) func_lo2o_result=${1} ;;\ +\ esac\ +} # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_xform ()$/,/^} # func_xform /c\ +func_xform ()\ +{\ + func_xform_result=${1%.*}.lo\ +} # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_arith ()$/,/^} # func_arith /c\ +func_arith ()\ +{\ + func_arith_result=$(( $* ))\ +} # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_len ()$/,/^} # func_len /c\ +func_len ()\ +{\ + func_len_result=${#1}\ +} # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + +fi + +if test x"$lt_shell_append" = xyes; then + sed -e '/^func_append ()$/,/^} # func_append /c\ +func_append ()\ +{\ + eval "${1}+=\\${2}"\ +} # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\ +func_append_quoted ()\ +{\ +\ func_quote_for_eval "${2}"\ +\ eval "${1}+=\\\\ \\$func_quote_for_eval_result"\ +} # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") +test 0 -eq $? || _lt_function_replace_fail=: + + + # Save a `func_append' function call where possible by direct use of '+=' + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +else + # Save a `func_append' function call even when '+=' is not available + sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ + && mv -f "$cfgfile.tmp" "$cfgfile" \ + || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") + test 0 -eq $? || _lt_function_replace_fail=: +fi + +if test x"$_lt_function_replace_fail" = x":"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5 +$as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;} +fi + + + mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" @@ -76630,15 +47439,12 @@ _LT_EOF done # for ac_tag -{ (exit 0); exit 0; } +as_fn_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; }; } + as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. @@ -76659,10 +47465,10 @@ if test "$no_create" != yes; then 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; } + $ac_cs_success || as_fn_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:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi diff --git a/configure.in b/configure.in index ee614a5..1030009 100644 --- a/configure.in +++ b/configure.in @@ -138,6 +138,7 @@ AMANDA_PROG_MT AMANDA_PROG_MTX AMANDA_PROG_MOUNT AMANDA_PROG_UMOUNT +AMANDA_PROG_UNAME AMANDA_PROG_LPR AMANDA_PROG_PCAT AMANDA_PROG_PERL diff --git a/device-src/Makefile.in b/device-src/Makefile.in index a2e5435..3900ade 100644 --- a/device-src/Makefile.in +++ b/device-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -451,6 +451,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -883,6 +884,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -932,6 +934,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -940,6 +943,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -947,6 +951,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1091,6 +1097,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1124,6 +1131,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1166,7 +1174,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/device-src/amdevcheck.pl b/device-src/amdevcheck.pl index 03c50f2..7839264 100644 --- a/device-src/amdevcheck.pl +++ b/device-src/amdevcheck.pl @@ -93,8 +93,10 @@ my $getproplist; my $device_name; my $print_label; +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'help|usage|?' => \&usage, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, 'properties:s' => \$getproplist, diff --git a/device-src/amtapetype.pl b/device-src/amtapetype.pl index bbc7d32..ef40d57 100644 --- a/device-src/amtapetype.pl +++ b/device-src/amtapetype.pl @@ -671,8 +671,10 @@ config_init(0, undef); my $config_overrides = new_config_overrides($#ARGV+1); +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'help|usage|?|h' => \&usage, 'c' => \$opt_only_compression, 'b=s' => sub { diff --git a/device-src/device.c b/device-src/device.c index 921b948..f0258d5 100644 --- a/device-src/device.c +++ b/device-src/device.c @@ -881,8 +881,12 @@ property_set_block_size_fn( g_assert(block_size >= 0); /* int -> gsize (unsigned) */ if ((gsize)block_size < self->min_block_size - || (gsize)block_size > self->max_block_size) + || (gsize)block_size > self->max_block_size) { + device_set_error(self, + g_strdup_printf("Error setting BLOCK-SIZE property to '%zu', it must be between %zu and %zu", (gsize)block_size, self->min_block_size, self->max_block_size), + DEVICE_STATUS_DEVICE_ERROR); return FALSE; + } self->block_size = block_size; self->block_size_surety = surety; diff --git a/device-src/device.h b/device-src/device.h index d7104ff..57f6b37 100644 --- a/device-src/device.h +++ b/device-src/device.h @@ -132,6 +132,7 @@ typedef struct Device { gsize min_block_size; gsize max_block_size; gsize block_size; + gsize header_block_size; /* surety and source for the block size; if you set block_size directly, * set these, too! */ diff --git a/device-src/dvdrw-device.c b/device-src/dvdrw-device.c index 128e05f..5bc0fc1 100644 --- a/device-src/dvdrw-device.c +++ b/device-src/dvdrw-device.c @@ -690,7 +690,6 @@ execute_command(DvdRwDevice *self, gchar **argv, gint *result) gint errnum = 0; GError *error = NULL; gboolean success; - int signum = 0; /* g_debug("Executing: %s", argv[0]); */ @@ -701,7 +700,6 @@ execute_command(DvdRwDevice *self, gchar **argv, gint *result) if (WIFSIGNALED(errnum)) { success = FALSE; - signum = WTERMSIG(errnum); } else if (WIFEXITED(errnum)) { success = (WEXITSTATUS(errnum) == 0); } else { diff --git a/device-src/ndmp-device.c b/device-src/ndmp-device.c index 0e0c998..f4e39bd 100644 --- a/device-src/ndmp-device.c +++ b/device-src/ndmp-device.c @@ -1628,8 +1628,12 @@ ndmp_device_set_read_block_size_fn(Device *p_self, DevicePropertyBase *base G_GN if (read_block_size != 0 && ((gsize)read_block_size < p_self->block_size || - (gsize)read_block_size > p_self->max_block_size)) + (gsize)read_block_size > p_self->max_block_size)) { + device_set_error(p_self, + g_strdup_printf("Error setting READ-BLOCk-SIZE property to '%zu', it must be between %zu and %zu", read_block_size, p_self->block_size, p_self->max_block_size), + DEVICE_STATUS_DEVICE_ERROR); return FALSE; + } self->read_block_size = read_block_size; @@ -1816,10 +1820,8 @@ ndmp_device_factory( char *device_node) { Device *rval; - NdmpDevice * ndmp_rval; g_assert(0 == strcmp(device_type, NDMP_DEVICE_NAME)); rval = DEVICE(g_object_new(TYPE_NDMP_DEVICE, NULL)); - ndmp_rval = (NdmpDevice *)rval; device_open_device(rval, device_name, device_type, device_node); return rval; diff --git a/device-src/null-device.c b/device-src/null-device.c index f7898e2..3f1bf34 100644 --- a/device-src/null-device.c +++ b/device-src/null-device.c @@ -242,6 +242,7 @@ null_device_start (Device * pself, DeviceAccessMode mode, if (mode == ACCESS_WRITE) { pself->volume_label = newstralloc(pself->volume_label, label); pself->volume_time = newstralloc(pself->volume_time, timestamp); + pself->header_block_size = 32768; return TRUE; } else { device_set_error(pself, diff --git a/device-src/rait-device.c b/device-src/rait-device.c index e8e8f2e..dda81fb 100644 --- a/device-src/rait-device.c +++ b/device-src/rait-device.c @@ -28,7 +28,7 @@ #include "glib-util.h" #include "device.h" #include "fileheader.h" -#include "semaphore.h" +#include "amsemaphore.h" /* Just a note about the failure mode of different operations: - Recovers from a failure (enters degraded mode) @@ -115,7 +115,7 @@ typedef struct RaitDevicePrivate_s { /* value of this semaphore is the number of threaded operations * in progress */ - semaphore_t *threads_sem; + amsemaphore_t *threads_sem; #endif } RaitDevicePrivate; @@ -286,7 +286,7 @@ rait_device_finalize(GObject *obj_self) } if (PRIVATE(self)->threads_sem) - semaphore_free(PRIVATE(self)->threads_sem); + amsemaphore_free(PRIVATE(self)->threads_sem); #endif amfree(self->private); } @@ -426,7 +426,7 @@ static gpointer rait_thread_pool_func(gpointer data) { inf->data = NULL; /* indicate that we're finished; will not block */ - semaphore_down(inf->private->threads_sem); + amsemaphore_down(inf->private->threads_sem); } } g_mutex_unlock(inf->mutex); @@ -437,7 +437,7 @@ static void do_thread_pool_op(RaitDevice *self, GFunc func, GPtrArray * ops) { guint i; if (PRIVATE(self)->threads_sem == NULL) - PRIVATE(self)->threads_sem = semaphore_new_with_value(0); + PRIVATE(self)->threads_sem = amsemaphore_new_with_value(0); if (PRIVATE(self)->threads == NULL) PRIVATE(self)->threads = g_array_sized_new(FALSE, TRUE, @@ -449,7 +449,7 @@ static void do_thread_pool_op(RaitDevice *self, GFunc func, GPtrArray * ops) { g_array_set_size(PRIVATE(self)->threads, ops->len); /* the semaphore will hit zero when each thread has decremented it */ - semaphore_force_set(PRIVATE(self)->threads_sem, ops->len); + amsemaphore_force_set(PRIVATE(self)->threads_sem, ops->len); for (i = 0; i < ops->len; i++) { ThreadInfo *inf = &g_array_index(PRIVATE(self)->threads, ThreadInfo, i); @@ -469,7 +469,7 @@ static void do_thread_pool_op(RaitDevice *self, GFunc func, GPtrArray * ops) { } /* wait until semaphore hits zero */ - semaphore_wait_empty(PRIVATE(self)->threads_sem); + amsemaphore_wait_empty(PRIVATE(self)->threads_sem); } #else /* USE_INTERNAL_THREADPOOL */ @@ -1134,6 +1134,7 @@ static DeviceStatusFlags rait_device_read_label(Device * dself) { if (first_success->volume_header != NULL) { dself->volume_header = dumpfile_copy(first_success->volume_header); } + dself->header_block_size = first_success->header_block_size; } g_ptr_array_free_full(ops); @@ -1300,6 +1301,12 @@ rait_device_start (Device * dself, DeviceAccessMode mode, char * label, } } + if (total_status == DEVICE_STATUS_SUCCESS) { + StartOp * op = g_ptr_array_index(ops, 0); + Device *child = op->base.child; + dself->header_block_size = child->header_block_size; + } + amfree(label_from_device); g_ptr_array_free_full(ops); @@ -1309,7 +1316,6 @@ rait_device_start (Device * dself, DeviceAccessMode mode, char * label, device_set_error(dself, failure_errmsgs, total_status); return FALSE; } - amfree(failure_errmsgs); return TRUE; } diff --git a/device-src/s3-device.c b/device-src/s3-device.c index 1f0b601..7a98750 100644 --- a/device-src/s3-device.c +++ b/device-src/s3-device.c @@ -95,10 +95,15 @@ struct _S3Device { char *access_key; char *user_token; + /* The Openstack swift information. */ + char *swift_account_id; + char *swift_access_key; + char *bucket_location; char *storage_class; char *host; char *service_path; + char *server_side_encryption; char *ca_info; @@ -115,6 +120,7 @@ struct _S3Device { /* Use SSL? */ gboolean use_ssl; + gboolean openstack_swift_api; /* Throttling */ guint64 max_send_speed; @@ -129,11 +135,13 @@ struct _S3Device { int nb_threads; int nb_threads_backup; int nb_threads_recovery; + GThreadPool *thread_pool_delete; GThreadPool *thread_pool_write; GThreadPool *thread_pool_read; GCond *thread_idle_cond; GMutex *thread_idle_mutex; int next_block_to_read; + GSList *keys; }; /* @@ -157,7 +165,7 @@ struct _S3DeviceClass { /* Note: for compatability, min can only be decreased and max increased */ #define S3_DEVICE_MIN_BLOCK_SIZE 1024 -#define S3_DEVICE_MAX_BLOCK_SIZE (100*1024*1024) +#define S3_DEVICE_MAX_BLOCK_SIZE (3*1024*1024*1024ULL) #define S3_DEVICE_DEFAULT_BLOCK_SIZE (10*1024*1024) #define EOM_EARLY_WARNING_ZONE_BLOCKS 4 @@ -177,6 +185,12 @@ static DevicePropertyBase device_property_s3_secret_key; #define PROPERTY_S3_SECRET_KEY (device_property_s3_secret_key.ID) #define PROPERTY_S3_ACCESS_KEY (device_property_s3_access_key.ID) +/* Authentication information for Openstack Swift. Both of these are strings. */ +static DevicePropertyBase device_property_swift_account_id; +static DevicePropertyBase device_property_swift_access_key; +#define PROPERTY_SWIFT_ACCOUNT_ID (device_property_swift_account_id.ID) +#define PROPERTY_SWIFT_ACCESS_KEY (device_property_swift_access_key.ID) + /* Host and path */ static DevicePropertyBase device_property_s3_host; static DevicePropertyBase device_property_s3_service_path; @@ -195,10 +209,18 @@ static DevicePropertyBase device_property_s3_bucket_location; static DevicePropertyBase device_property_s3_storage_class; #define PROPERTY_S3_STORAGE_CLASS (device_property_s3_storage_class.ID) +/* Storage class */ +static DevicePropertyBase device_property_s3_server_side_encryption; +#define PROPERTY_S3_SERVER_SIDE_ENCRYPTION (device_property_s3_server_side_encryption.ID) + /* Path to certificate authority certificate */ static DevicePropertyBase device_property_ssl_ca_info; #define PROPERTY_SSL_CA_INFO (device_property_ssl_ca_info.ID) +/* Whether to use openstack protocol. */ +static DevicePropertyBase device_property_openstack_swift_api; +#define PROPERTY_OPENSTACK_SWIFT_API (device_property_openstack_swift_api.ID) + /* Whether to use SSL with Amazon S3. */ static DevicePropertyBase device_property_s3_ssl; #define PROPERTY_S3_SSL (device_property_s3_ssl.ID) @@ -306,6 +328,9 @@ delete_all_files(S3Device *self); static gboolean setup_handle(S3Device * self); +static void +s3_wait_thread_delete(S3Device *self); + /* * class mechanics */ @@ -332,6 +357,14 @@ static gboolean s3_device_set_secret_key_fn(Device *self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source); +static gboolean s3_device_set_swift_account_id_fn(Device *self, + DevicePropertyBase *base, GValue *val, + PropertySurety surety, PropertySource source); + +static gboolean s3_device_set_swift_access_key_fn(Device *self, + DevicePropertyBase *base, GValue *val, + PropertySurety surety, PropertySource source); + static gboolean s3_device_set_user_token_fn(Device *self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source); @@ -344,6 +377,10 @@ static gboolean s3_device_set_storage_class_fn(Device *self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source); +static gboolean s3_device_set_server_side_encryption_fn(Device *self, + DevicePropertyBase *base, GValue *val, + PropertySurety surety, PropertySource source); + static gboolean s3_device_set_ca_info_fn(Device *self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source); @@ -352,6 +389,10 @@ static gboolean s3_device_set_verbose_fn(Device *self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source); +static gboolean s3_device_set_openstack_swift_api_fn(Device *self, + DevicePropertyBase *base, GValue *val, + PropertySurety surety, PropertySource source); + static gboolean s3_device_set_ssl_fn(Device *self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source); @@ -400,6 +441,8 @@ static void s3_thread_read_block(gpointer thread_data, gpointer data); static void s3_thread_write_block(gpointer thread_data, gpointer data); +static gboolean make_bucket(Device * pself); + /* Wait that all threads are done */ static void reset_thread(S3Device *self); @@ -545,7 +588,7 @@ write_amanda_header(S3Device *self, d_self->volume_header = dumpinfo; self->volume_bytes += header_size; } - + d_self->header_block_size = header_size; return result; } @@ -682,11 +725,18 @@ static gboolean delete_file(S3Device *self, int file) { + int thread = -1; + gboolean result; GSList *keys; guint64 total_size = 0; - char *my_prefix = g_strdup_printf("%sf%08x-", self->prefix, file); Device *d_self = DEVICE(self); + char *my_prefix; + if (file == -1) { + my_prefix = g_strdup_printf("%sf", self->prefix); + } else { + my_prefix = g_strdup_printf("%sf%08x-", self->prefix, file); + } result = s3_list_keys(self->s3t[0].s3, self->bucket, my_prefix, NULL, &keys, &total_size); @@ -697,59 +747,114 @@ delete_file(S3Device *self, return FALSE; } - /* this will likely be a *lot* of keys */ - for (; keys; keys = g_slist_remove(keys, keys->data)) { - if (self->verbose) g_debug(_("Deleting %s"), (char*)keys->data); - if (!s3_delete(self->s3t[0].s3, self->bucket, keys->data)) { - device_set_error(d_self, - vstrallocf(_("While deleting key '%s': %s"), - (char*)keys->data, s3_strerror(self->s3t[0].s3)), - DEVICE_STATUS_DEVICE_ERROR); - g_slist_free(keys); - return FALSE; - } + g_mutex_lock(self->thread_idle_mutex); + if (!self->keys) { + self->keys = keys; + } else { + self->keys = g_slist_concat(self->keys, keys); + } + + // start the threads + for (thread = 0; thread < self->nb_threads; thread++) { + if (self->s3t[thread].idle == 1) { + /* Check if the thread is in error */ + if (self->s3t[thread].errflags != DEVICE_STATUS_SUCCESS) { + device_set_error(d_self, + (char *)self->s3t[thread].errmsg, + self->s3t[thread].errflags); + self->s3t[thread].errflags = DEVICE_STATUS_SUCCESS; + self->s3t[thread].errmsg = NULL; + g_mutex_unlock(self->thread_idle_mutex); + s3_wait_thread_delete(self); + return FALSE; + } + self->s3t[thread].idle = 0; + self->s3t[thread].done = 0; + g_thread_pool_push(self->thread_pool_delete, &self->s3t[thread], + NULL); + } } + g_cond_wait(self->thread_idle_cond, self->thread_idle_mutex); + g_mutex_unlock(self->thread_idle_mutex); + self->volume_bytes = total_size; + s3_wait_thread_delete(self); + return TRUE; } -static gboolean -delete_all_files(S3Device *self) +static void +s3_thread_delete_block( + gpointer thread_data, + gpointer data) { - int file, last_file; - - /* - * Note: this has to be allowed to retry for a while because the bucket - * may have been created and not yet appeared - */ - last_file = find_last_file(self); - if (last_file < 0) { - guint response_code; - s3_error_code_t s3_error_code; - s3_error(self->s3t[0].s3, NULL, &response_code, &s3_error_code, NULL, NULL, NULL); + static int count = 0; + S3_by_thread *s3t = (S3_by_thread *)thread_data; + Device *pself = (Device *)data; + S3Device *self = S3_DEVICE(pself); + gboolean result = 1; + char *filename; - /* - * if the bucket doesn't exist, it doesn't conatin any files, - * so the operation is a success - */ - if ((response_code == 404 && s3_error_code == S3_ERROR_NoSuchBucket)) { - /* find_last_file set an error; clear it */ - device_set_error(DEVICE(self), NULL, DEVICE_STATUS_SUCCESS); - return TRUE; - } else { - /* find_last_file already set the error */ - return FALSE; - } + g_mutex_lock(self->thread_idle_mutex); + while (result && self->keys) { + filename = self->keys->data; + self->keys = g_slist_remove(self->keys, self->keys->data); + count++; + if (count >= 1000) { + g_debug("Deleting %s ...", filename); + count = 0; + } + g_mutex_unlock(self->thread_idle_mutex); + result = s3_delete(s3t->s3, (const char *)self->bucket, (const char *)filename); + if (!result) { + s3t->errflags = DEVICE_STATUS_DEVICE_ERROR | DEVICE_STATUS_VOLUME_ERROR; + s3t->errmsg = g_strdup_printf(_("While deleting key '%s': %s"), + filename, s3_strerror(s3t->s3)); + } + g_free(filename); + g_mutex_lock(self->thread_idle_mutex); } + s3t->idle = 1; + s3t->done = 1; + g_cond_broadcast(self->thread_idle_cond); + g_mutex_unlock(self->thread_idle_mutex); +} - for (file = 1; file <= last_file; file++) { - if (!delete_file(self, file)) - /* delete_file already set our error message */ - return FALSE; +static void +s3_wait_thread_delete(S3Device *self) +{ + Device *d_self = (Device *)self; + int idle_thread = 0; + int thread; + + g_mutex_lock(self->thread_idle_mutex); + while (idle_thread != self->nb_threads) { + idle_thread = 0; + for (thread = 0; thread < self->nb_threads; thread++) { + if (self->s3t[thread].idle == 1) { + idle_thread++; + } + /* Check if the thread is in error */ + if (self->s3t[thread].errflags != DEVICE_STATUS_SUCCESS) { + device_set_error(d_self, (char *)self->s3t[thread].errmsg, + self->s3t[thread].errflags); + self->s3t[thread].errflags = DEVICE_STATUS_SUCCESS; + self->s3t[thread].errmsg = NULL; + } + } + if (idle_thread != self->nb_threads) { + g_cond_wait(self->thread_idle_cond, self->thread_idle_mutex); + } } + g_mutex_unlock(self->thread_idle_mutex); +} - return TRUE; + +static gboolean +delete_all_files(S3Device *self) +{ + return delete_file(self, -1); } /* @@ -769,6 +874,12 @@ s3_device_register(void) device_property_fill_and_register(&device_property_s3_access_key, G_TYPE_STRING, "s3_access_key", "Access key ID to authenticate with Amazon S3"); + device_property_fill_and_register(&device_property_swift_account_id, + G_TYPE_STRING, "swift_account_id", + "Account ID to authenticate with openstack swift"); + device_property_fill_and_register(&device_property_swift_access_key, + G_TYPE_STRING, "swift_access_key", + "Access key to authenticate with openstack swift"); device_property_fill_and_register(&device_property_s3_host, G_TYPE_STRING, "s3_host", "hostname:port of the server"); @@ -784,9 +895,15 @@ s3_device_register(void) device_property_fill_and_register(&device_property_s3_storage_class, G_TYPE_STRING, "s3_storage_class", "Storage class as specified by Amazon (STANDARD or REDUCED_REDUNDANCY)"); + device_property_fill_and_register(&device_property_s3_server_side_encryption, + G_TYPE_STRING, "s3_server_side_encryption", + "Serve side encryption as specified by Amazon (AES256)"); device_property_fill_and_register(&device_property_ssl_ca_info, G_TYPE_STRING, "ssl_ca_info", "Path to certificate authority certificate"); + device_property_fill_and_register(&device_property_openstack_swift_api, + G_TYPE_BOOLEAN, "openstack_swift_api", + "Whether to use openstack protocol"); device_property_fill_and_register(&device_property_s3_ssl, G_TYPE_BOOLEAN, "s3_ssl", "Whether to use SSL with Amazon S3"); @@ -850,6 +967,7 @@ s3_device_init(S3Device * self) self->nb_threads = 1; self->nb_threads_backup = 1; self->nb_threads_recovery = 1; + self->thread_pool_delete = NULL; self->thread_pool_write = NULL; self->thread_pool_read = NULL; self->thread_idle_cond = NULL; @@ -958,6 +1076,16 @@ s3_device_class_init(S3DeviceClass * c G_GNUC_UNUSED) device_simple_property_get_fn, s3_device_set_secret_key_fn); + device_class_register_property(device_class, PROPERTY_SWIFT_ACCOUNT_ID, + PROPERTY_ACCESS_GET_MASK | PROPERTY_ACCESS_SET_BEFORE_START, + device_simple_property_get_fn, + s3_device_set_swift_account_id_fn); + + device_class_register_property(device_class, PROPERTY_SWIFT_ACCESS_KEY, + PROPERTY_ACCESS_GET_MASK | PROPERTY_ACCESS_SET_BEFORE_START, + device_simple_property_get_fn, + s3_device_set_swift_access_key_fn); + device_class_register_property(device_class, PROPERTY_S3_HOST, PROPERTY_ACCESS_GET_MASK | PROPERTY_ACCESS_SET_BEFORE_START, device_simple_property_get_fn, @@ -983,6 +1111,11 @@ s3_device_class_init(S3DeviceClass * c G_GNUC_UNUSED) device_simple_property_get_fn, s3_device_set_storage_class_fn); + device_class_register_property(device_class, PROPERTY_S3_SERVER_SIDE_ENCRYPTION, + PROPERTY_ACCESS_GET_MASK | PROPERTY_ACCESS_SET_BEFORE_START, + device_simple_property_get_fn, + s3_device_set_server_side_encryption_fn); + device_class_register_property(device_class, PROPERTY_SSL_CA_INFO, PROPERTY_ACCESS_GET_MASK | PROPERTY_ACCESS_SET_BEFORE_START, device_simple_property_get_fn, @@ -993,6 +1126,11 @@ s3_device_class_init(S3DeviceClass * c G_GNUC_UNUSED) device_simple_property_get_fn, s3_device_set_verbose_fn); + device_class_register_property(device_class, PROPERTY_OPENSTACK_SWIFT_API, + PROPERTY_ACCESS_GET_MASK | PROPERTY_ACCESS_SET_BEFORE_START, + device_simple_property_get_fn, + s3_device_set_openstack_swift_api_fn); + device_class_register_property(device_class, PROPERTY_S3_SSL, PROPERTY_ACCESS_GET_MASK | PROPERTY_ACCESS_SET_BEFORE_START, device_simple_property_get_fn, @@ -1073,6 +1211,32 @@ s3_device_set_secret_key_fn(Device *p_self, DevicePropertyBase *base, return device_simple_property_set_fn(p_self, base, val, surety, source); } +static gboolean +s3_device_set_swift_account_id_fn(Device *p_self, DevicePropertyBase *base, + GValue *val, PropertySurety surety, PropertySource source) +{ + S3Device *self = S3_DEVICE(p_self); + + amfree(self->swift_account_id); + self->swift_account_id = g_value_dup_string(val); + device_clear_volume_details(p_self); + + return device_simple_property_set_fn(p_self, base, val, surety, source); +} + +static gboolean +s3_device_set_swift_access_key_fn(Device *p_self, DevicePropertyBase *base, + GValue *val, PropertySurety surety, PropertySource source) +{ + S3Device *self = S3_DEVICE(p_self); + + amfree(self->swift_access_key); + self->swift_access_key = g_value_dup_string(val); + device_clear_volume_details(p_self); + + return device_simple_property_set_fn(p_self, base, val, surety, source); +} + static gboolean s3_device_set_host_fn(Device *p_self, DevicePropertyBase *base, GValue *val, @@ -1162,6 +1326,20 @@ s3_device_set_storage_class_fn(Device *p_self, DevicePropertyBase *base, return device_simple_property_set_fn(p_self, base, val, surety, source); } +static gboolean +s3_device_set_server_side_encryption_fn(Device *p_self, DevicePropertyBase *base, + GValue *val, PropertySurety surety, PropertySource source) +{ + S3Device *self = S3_DEVICE(p_self); + char *str_val = g_value_dup_string(val); + + amfree(self->server_side_encryption); + self->server_side_encryption = str_val; + device_clear_volume_details(p_self); + + return device_simple_property_set_fn(p_self, base, val, surety, source); +} + static gboolean s3_device_set_ca_info_fn(Device *p_self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source) @@ -1195,6 +1373,17 @@ s3_device_set_verbose_fn(Device *p_self, DevicePropertyBase *base, return device_simple_property_set_fn(p_self, base, val, surety, source); } +static gboolean +s3_device_set_openstack_swift_api_fn(Device *p_self, DevicePropertyBase *base, + GValue *val, PropertySurety surety, PropertySource source) +{ + S3Device *self = S3_DEVICE(p_self); + + self->openstack_swift_api = g_value_get_boolean(val); + + return device_simple_property_set_fn(p_self, base, val, surety, source); +} + static gboolean s3_device_set_ssl_fn(Device *p_self, DevicePropertyBase *base, GValue *val, PropertySurety surety, PropertySource source) @@ -1360,10 +1549,8 @@ static Device* s3_device_factory(char * device_name, char * device_type, char * device_node) { Device *rval; - S3Device * s3_rval; g_assert(0 == strcmp(device_type, S3_DEVICE_NAME)); rval = DEVICE(g_object_new(TYPE_S3_DEVICE, NULL)); - s3_rval = (S3Device*)rval; device_open_device(rval, device_name, device_type, device_node); return rval; @@ -1409,6 +1596,7 @@ s3_device_open_device(Device *pself, char *device_name, /* default values */ self->verbose = FALSE; + self->openstack_swift_api = FALSE; /* use SSL if available */ self->use_ssl = s3_curl_supports_ssl(); @@ -1430,6 +1618,10 @@ static void s3_device_finalize(GObject * obj_self) { if(G_OBJECT_CLASS(parent_class)->finalize) (* G_OBJECT_CLASS(parent_class)->finalize)(obj_self); + if (self->thread_pool_delete) { + g_thread_pool_free(self->thread_pool_delete, 1, 1); + self->thread_pool_delete = NULL; + } if (self->thread_pool_write) { g_thread_pool_free(self->thread_pool_write, 1, 1); self->thread_pool_write = NULL; @@ -1456,17 +1648,23 @@ static void s3_device_finalize(GObject * obj_self) { if(self->prefix) g_free(self->prefix); if(self->access_key) g_free(self->access_key); if(self->secret_key) g_free(self->secret_key); + if(self->swift_account_id) g_free(self->swift_account_id); + if(self->swift_access_key) g_free(self->swift_access_key); if(self->host) g_free(self->host); if(self->service_path) g_free(self->service_path); if(self->user_token) g_free(self->user_token); if(self->bucket_location) g_free(self->bucket_location); if(self->storage_class) g_free(self->storage_class); + if(self->server_side_encryption) g_free(self->server_side_encryption); if(self->ca_info) g_free(self->ca_info); } static gboolean setup_handle(S3Device * self) { Device *d_self = DEVICE(self); int thread; + guint response_code; + s3_error_code_t s3_error_code; + CURLcode curl_code; if (self->s3t == NULL) { self->s3t = g_new(S3_by_thread, self->nb_threads); @@ -1476,24 +1674,45 @@ static gboolean setup_handle(S3Device * self) { DEVICE_STATUS_DEVICE_ERROR); return FALSE; } - if (self->access_key == NULL || self->access_key[0] == '\0') { - device_set_error(d_self, - stralloc(_("No Amazon access key specified")), - DEVICE_STATUS_DEVICE_ERROR); - return FALSE; - } - if (self->secret_key == NULL || self->secret_key[0] == '\0') { - device_set_error(d_self, - stralloc(_("No Amazon secret key specified")), - DEVICE_STATUS_DEVICE_ERROR); - return FALSE; + if (!self->openstack_swift_api) { + if (self->access_key == NULL || self->access_key[0] == '\0') { + device_set_error(d_self, + g_strdup(_("No Amazon access key specified")), + DEVICE_STATUS_DEVICE_ERROR); + return FALSE; + } + + if (self->secret_key == NULL || self->secret_key[0] == '\0') { + device_set_error(d_self, + g_strdup(_("No Amazon secret key specified")), + DEVICE_STATUS_DEVICE_ERROR); + return FALSE; + } + } else { + if (self->swift_account_id == NULL || + self->swift_account_id[0] == '\0') { + device_set_error(d_self, + g_strdup(_("No Swift account id specified")), + DEVICE_STATUS_DEVICE_ERROR); + return FALSE; + } + if (self->swift_access_key == NULL || + self->swift_access_key[0] == '\0') { + device_set_error(d_self, + g_strdup(_("No Swift access key specified")), + DEVICE_STATUS_DEVICE_ERROR); + return FALSE; + } } if (!self->use_ssl && self->ca_info) { amfree(self->ca_info); } + self->thread_idle_cond = g_cond_new(); + self->thread_idle_mutex = g_mutex_new(); + for (thread = 0; thread < self->nb_threads; thread++) { self->s3t[thread].idle = 1; self->s3t[thread].done = 1; @@ -1504,25 +1723,42 @@ static gboolean setup_handle(S3Device * self) { self->s3t[thread].curl_buffer.buffer = NULL; self->s3t[thread].curl_buffer.buffer_len = 0; self->s3t[thread].s3 = s3_open(self->access_key, self->secret_key, + self->swift_account_id, + self->swift_access_key, self->host, self->service_path, self->use_subdomain, self->user_token, self->bucket_location, - self->storage_class, self->ca_info); + self->storage_class, self->ca_info, + self->server_side_encryption, + self->openstack_swift_api); if (self->s3t[thread].s3 == NULL) { device_set_error(d_self, stralloc(_("Internal error creating S3 handle")), DEVICE_STATUS_DEVICE_ERROR); + self->nb_threads = thread+1; return FALSE; - } + } else if (self->openstack_swift_api) { + s3_error(self->s3t[0].s3, NULL, &response_code, + &s3_error_code, NULL, &curl_code, NULL); + if (response_code != 200) { + device_set_error(d_self, + g_strdup_printf(_("Internal error creating S3 handle: %s"), + s3_strerror(self->s3t[0].s3)), + DEVICE_STATUS_DEVICE_ERROR); + self->nb_threads = thread+1; + return FALSE; + } + } } g_debug("Create %d threads", self->nb_threads); + self->thread_pool_delete = g_thread_pool_new(s3_thread_delete_block, + self, self->nb_threads, 0, + NULL); self->thread_pool_write = g_thread_pool_new(s3_thread_write_block, self, self->nb_threads, 0, NULL); self->thread_pool_read = g_thread_pool_new(s3_thread_read_block, self, self->nb_threads, 0, NULL); - self->thread_idle_cond = g_cond_new(); - self->thread_idle_mutex = g_mutex_new(); } for (thread = 0; thread < self->nb_threads; thread++) { @@ -1556,6 +1792,48 @@ static gboolean setup_handle(S3Device * self) { return TRUE; } +static gboolean +make_bucket( + Device * pself) +{ + S3Device *self = S3_DEVICE(pself); + guint response_code; + s3_error_code_t s3_error_code; + CURLcode curl_code; + + if (s3_is_bucket_exists(self->s3t[0].s3, self->bucket)) { + return TRUE; + } + + s3_error(self->s3t[0].s3, NULL, &response_code, &s3_error_code, NULL, &curl_code, NULL); + + if (response_code == 0 && s3_error_code == 0 && + (curl_code == CURLE_COULDNT_CONNECT || + curl_code == CURLE_COULDNT_RESOLVE_HOST)) { + device_set_error(pself, + g_strdup_printf(_("While connecting to S3 bucket: %s"), + s3_strerror(self->s3t[0].s3)), + DEVICE_STATUS_DEVICE_ERROR); + return FALSE; + } + + if (!s3_make_bucket(self->s3t[0].s3, self->bucket)) { + s3_error(self->s3t[0].s3, NULL, &response_code, &s3_error_code, NULL, NULL, NULL); + + /* if it isn't an expected error (bucket already exists), + * return FALSE */ + if (response_code != 409 || + (s3_error_code != S3_ERROR_BucketAlreadyExists && + s3_error_code != S3_ERROR_BucketAlreadyOwnedByYou)) { + device_set_error(pself, + g_strdup_printf(_("While creating new S3 bucket: %s"), s3_strerror(self->s3t[0].s3)), + DEVICE_STATUS_DEVICE_ERROR); + return FALSE; + } + } + return TRUE; +} + static DeviceStatusFlags s3_device_read_label(Device *pself) { S3Device *self = S3_DEVICE(pself); @@ -1579,6 +1857,11 @@ s3_device_read_label(Device *pself) { reset_thread(self); key = special_file_to_key(self, "tapestart", -1); + + if (!make_bucket(pself)) { + return pself->status; + } + if (!s3_read(self->s3t[0].s3, self->bucket, key, S3_BUFFER_WRITE_FUNCS, &buf, NULL, NULL)) { guint response_code; s3_error_code_t s3_error_code; @@ -1586,7 +1869,9 @@ s3_device_read_label(Device *pself) { /* if it's an expected error (not found), just return FALSE */ if (response_code == 404 && - (s3_error_code == S3_ERROR_NoSuchKey || + (s3_error_code == S3_ERROR_None || + s3_error_code == S3_ERROR_Unknown || + s3_error_code == S3_ERROR_NoSuchKey || s3_error_code == S3_ERROR_NoSuchEntity || s3_error_code == S3_ERROR_NoSuchBucket)) { g_debug(_("Amanda header not found while reading tapestart header (this is expected for empty tapes)")); @@ -1611,6 +1896,7 @@ s3_device_read_label(Device *pself) { return pself->status; } + pself->header_block_size = buf.buffer_len; g_assert(buf.buffer != NULL); amanda_header = g_new(dumpfile_t, 1); parse_file_header(buf.buffer, amanda_header, buf.buffer_pos); @@ -1653,21 +1939,8 @@ s3_device_start (Device * pself, DeviceAccessMode mode, pself->in_file = FALSE; /* try creating the bucket, in case it doesn't exist */ - if (mode != ACCESS_READ && !s3_make_bucket(self->s3t[0].s3, self->bucket)) { - guint response_code; - s3_error_code_t s3_error_code; - s3_error(self->s3t[0].s3, NULL, &response_code, &s3_error_code, NULL, NULL, NULL); - - /* if it isn't an expected error (bucket already exists), - * return FALSE */ - if (response_code != 409 || - (s3_error_code != S3_ERROR_BucketAlreadyExists && - s3_error_code != S3_ERROR_BucketAlreadyOwnedByYou)) { - device_set_error(pself, - vstrallocf(_("While creating new S3 bucket: %s"), s3_strerror(self->s3t[0].s3)), - DEVICE_STATUS_DEVICE_ERROR); - return FALSE; - } + if (!make_bucket(pself)) { + return FALSE; } /* take care of any dirty work for this mode */ @@ -1835,8 +2108,6 @@ s3_device_write_block (Device * pself, guint size, gpointer data) { for (thread = 0; thread < self->nb_threads_backup; thread++) { if (self->s3t[thread].idle == 1) { idle_thread++; - if (first_idle == -1) - first_idle = thread; /* Check if the thread is in error */ if (self->s3t[thread].errflags != DEVICE_STATUS_SUCCESS) { device_set_error(pself, (char *)self->s3t[thread].errmsg, @@ -1846,6 +2117,10 @@ s3_device_write_block (Device * pself, guint size, gpointer data) { g_mutex_unlock(self->thread_idle_mutex); return FALSE; } + if (first_idle == -1) { + first_idle = thread; + break; + } } } if (!idle_thread) { @@ -1950,7 +2225,9 @@ s3_device_recycle_file(Device *pself, guint file) { if (device_in_error(self)) return FALSE; reset_thread(self); - return delete_file(self, file); + delete_file(self, file); + s3_wait_thread_delete(self); + return !device_in_error(self); /* delete_file already set our error message if necessary */ } @@ -1978,9 +2255,15 @@ s3_device_erase(Device *pself) { } g_free(key); + dumpfile_free(pself->volume_header); + pself->volume_header = NULL; + if (!delete_all_files(self)) return FALSE; + device_set_error(pself, g_strdup("Unlabeled volume"), + DEVICE_STATUS_VOLUME_UNLABELED); + if (!s3_delete_bucket(self->s3t[0].s3, self->bucket)) { s3_error(self->s3t[0].s3, NULL, &response_code, &s3_error_code, NULL, NULL, NULL); @@ -2037,7 +2320,8 @@ s3_device_seek_file(Device *pself, guint file) { /* if it's an expected error (not found), check what to do. */ if (response_code == 404 && - (s3_error_code == S3_ERROR_NoSuchKey || + (s3_error_code == S3_ERROR_None || + s3_error_code == S3_ERROR_NoSuchKey || s3_error_code == S3_ERROR_NoSuchEntity)) { int next_file; next_file = find_next_file(self, pself->file); @@ -2245,10 +2529,11 @@ s3_thread_read_block( guint response_code; s3_error_code_t s3_error_code; s3_error(s3t->s3, NULL, &response_code, &s3_error_code, NULL, NULL, NULL); - /* if it's an expected error (not found), just return -1 */ if (response_code == 404 && - (s3_error_code == S3_ERROR_NoSuchKey || + (s3_error_code == S3_ERROR_None || + s3_error_code == S3_ERROR_Unknown || + s3_error_code == S3_ERROR_NoSuchKey || s3_error_code == S3_ERROR_NoSuchEntity)) { s3t->eof = TRUE; } else { diff --git a/device-src/s3.c b/device-src/s3.c index cd234c3..1c61291 100644 --- a/device-src/s3.c +++ b/device-src/s3.c @@ -88,12 +88,14 @@ #define AMAZON_SECURITY_HEADER "x-amz-security-token" #define AMAZON_BUCKET_CONF_TEMPLATE "\ - \n\ + \n\ %s\n\ " #define AMAZON_STORAGE_CLASS_HEADER "x-amz-storage-class" +#define AMAZON_SERVER_SIDE_ENCRYPTION_HEADER "x-amz-server-side-encryption" + #define AMAZON_WILDCARD_LOCATION "*" /* parameters for exponential backoff in the face of retriable errors */ @@ -120,6 +122,7 @@ { 0, 0, CURLE_COULDNT_RESOLVE_HOST, S3_RESULT_RETRY }, \ { 0, 0, CURLE_PARTIAL_FILE, S3_RESULT_RETRY }, \ { 0, 0, CURLE_OPERATION_TIMEOUTED, S3_RESULT_RETRY }, \ + { 0, 0, CURLE_SSL_CONNECT_ERROR, S3_RESULT_RETRY }, \ { 0, 0, CURLE_SEND_ERROR, S3_RESULT_RETRY }, \ { 0, 0, CURLE_RECV_ERROR, S3_RESULT_RETRY }, \ { 0, 0, CURLE_GOT_NOTHING, S3_RESULT_RETRY } @@ -134,14 +137,20 @@ struct S3Handle { char *access_key; char *secret_key; char *user_token; + char *swift_account_id; + char *swift_access_key; /* attributes for new objects */ char *bucket_location; char *storage_class; + char *server_side_encryption; char *host; char *service_path; gboolean use_subdomain; + gboolean openstack_swift_api; char *ca_info; + char *x_auth_token; + char *x_storage_url; CURL *curl; @@ -266,7 +275,8 @@ lookup_result(const result_handling_t *result_handling, /* * Precompiled regular expressions */ static regex_t etag_regex, error_name_regex, message_regex, subdomain_regex, - location_con_regex, date_sync_regex; + location_con_regex, date_sync_regex, x_auth_token_regex, + x_storage_url_regex; /* @@ -285,14 +295,11 @@ static gboolean is_non_empty_string(const char *str); * A new string is allocated and returned; it is the responsiblity of the caller. * * @param hdl: the S3Handle object - * @param verb: capitalized verb for this request ('PUT', 'GET', etc.) - * @param host: the host name to connect to, 's3.amazonaws.com' * @param service_path: A path to add in the URL, or NULL for none. * @param bucket: the bucket being accessed, or NULL for none * @param key: the key being accessed, or NULL for none * @param subresource: the sub-resource being accessed (e.g. "acl"), or NULL for none - * @param use_subdomain: if TRUE, a subdomain of 'host' will be used - * @param use_ssl: if TRUE, use 'https' + * @param query: the query being accessed (e.g. "acl"), or NULL for none * * !use_subdomain: http://host/service_path/bucket/key * use_subdomain : http://bucket.host/service_path/key @@ -300,14 +307,11 @@ static gboolean is_non_empty_string(const char *str); */ static char * build_url( - const char *host, - const char *service_path, + S3Handle *hdl, const char *bucket, const char *key, const char *subresource, - const char *query, - gboolean use_subdomain, - gboolean use_ssl); + const char *query); /* Create proper authorization headers for an Amazon S3 REST * request to C{headers}. @@ -524,50 +528,76 @@ is_non_empty_string(const char *str) static char * build_url( - const char *host, - const char *service_path, + S3Handle *hdl, const char *bucket, const char *key, const char *subresource, - const char *query, - gboolean use_subdomain, - gboolean use_ssl) + const char *query) { GString *url = NULL; char *esc_bucket = NULL, *esc_key = NULL; - /* scheme */ - url = g_string_new("http"); - if (use_ssl) - g_string_append(url, "s"); + if (hdl->openstack_swift_api && hdl->x_storage_url) { + url = g_string_new(hdl->x_storage_url); + g_string_append(url, "/"); + } else { + /* scheme */ + url = g_string_new("http"); + if (hdl->use_ssl) + g_string_append(url, "s"); - g_string_append(url, "://"); + g_string_append(url, "://"); - /* domain */ - if (use_subdomain && bucket) - g_string_append_printf(url, "%s.%s", bucket, host); - else - g_string_append_printf(url, "%s", host); + /* domain */ + if (hdl->use_subdomain && bucket) + g_string_append_printf(url, "%s.%s", bucket, hdl->host); + else + g_string_append_printf(url, "%s", hdl->host); - if (service_path) { - g_string_append_printf(url, "%s/", service_path); - } else { - g_string_append(url, "/"); + if (hdl->service_path) { + g_string_append_printf(url, "%s/", hdl->service_path); + } else { + g_string_append(url, "/"); + } } /* path */ - if (!use_subdomain && bucket) { - esc_bucket = curl_escape(bucket, 0); + if (!hdl->use_subdomain && bucket) { + /* curl_easy_escape addeded in 7.15.4 */ + #if LIBCURL_VERSION_NUM >= 0x070f04 + curl_version_info_data *info; + /* check the runtime version too */ + info = curl_version_info(CURLVERSION_NOW); + if (info->version_num >= 0x070f04) + esc_bucket = curl_easy_escape(hdl->curl, bucket, 0); + else + esc_bucket = curl_escape(bucket, 0); + #else + esc_bucket = curl_escape(bucket, 0); + #endif if (!esc_bucket) goto cleanup; g_string_append_printf(url, "%s", esc_bucket); if (key) g_string_append(url, "/"); + curl_free(esc_bucket); } if (key) { - esc_key = curl_escape(key, 0); + /* curl_easy_escape addeded in 7.15.4 */ + #if LIBCURL_VERSION_NUM >= 0x070f04 + curl_version_info_data *info; + /* check the runtime version too */ + info = curl_version_info(CURLVERSION_NOW); + if (info->version_num >= 0x070f04) + esc_key = curl_easy_escape(hdl->curl, key, 0); + else + esc_key = curl_escape(key, 0); + #else + esc_key = curl_escape(key, 0); + #endif if (!esc_key) goto cleanup; g_string_append_printf(url, "%s", esc_key); + curl_free(esc_key); } /* query string */ @@ -584,8 +614,6 @@ build_url( g_string_append(url, query); cleanup: - if (esc_bucket) curl_free(esc_bucket); - if (esc_key) curl_free(esc_key); return g_string_free(url, FALSE); } @@ -615,24 +643,6 @@ authenticate_request(S3Handle *hdl, "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"}; - - /* Build the string to sign, per the S3 spec. - * See: "Authenticating REST Requests" - API Version 2006-03-01 pg 58 - */ - - /* verb */ - auth_string = g_string_new(verb); - g_string_append(auth_string, "\n"); - - /* Content-MD5 header */ - if (md5_hash) - g_string_append(auth_string, md5_hash); - g_string_append(auth_string, "\n"); - - /* Content-Type is empty*/ - g_string_append(auth_string, "\n"); - - /* calculate the date */ t = time(NULL); @@ -650,86 +660,137 @@ authenticate_request(S3Handle *hdl, wkday[tmp.tm_wday], tmp.tm_mday, month[tmp.tm_mon], 1900+tmp.tm_year, tmp.tm_hour, tmp.tm_min, tmp.tm_sec); - g_string_append(auth_string, date); - g_string_append(auth_string, "\n"); - - /* CanonicalizedAmzHeaders, sorted lexicographically */ - if (is_non_empty_string(hdl->user_token)) { - g_string_append(auth_string, AMAZON_SECURITY_HEADER); - g_string_append(auth_string, ":"); - g_string_append(auth_string, hdl->user_token); - g_string_append(auth_string, ","); - g_string_append(auth_string, STS_PRODUCT_TOKEN); - g_string_append(auth_string, "\n"); - } + if (hdl->openstack_swift_api) { + if (!bucket) { + buf = g_strdup_printf("X-Auth-User: %s", hdl->swift_account_id); + headers = curl_slist_append(headers, buf); + g_free(buf); + buf = g_strdup_printf("X-Auth-Key: %s", hdl->swift_access_key); + headers = curl_slist_append(headers, buf); + g_free(buf); + } else { + buf = g_strdup_printf("X-Auth-Token: %s", hdl->x_auth_token); + headers = curl_slist_append(headers, buf); + g_free(buf); + } + } else { + /* Build the string to sign, per the S3 spec. + * See: "Authenticating REST Requests" - API Version 2006-03-01 pg 58 + */ + + /* verb */ + auth_string = g_string_new(verb); + g_string_append(auth_string, "\n"); + + /* Content-MD5 header */ + if (md5_hash) + g_string_append(auth_string, md5_hash); + g_string_append(auth_string, "\n"); + + /* Content-Type is empty*/ + g_string_append(auth_string, "\n"); + + /* Date */ + g_string_append(auth_string, date); + g_string_append(auth_string, "\n"); + + /* CanonicalizedAmzHeaders, sorted lexicographically */ + if (is_non_empty_string(hdl->user_token)) { + g_string_append(auth_string, AMAZON_SECURITY_HEADER); + g_string_append(auth_string, ":"); + g_string_append(auth_string, hdl->user_token); + g_string_append(auth_string, ","); + g_string_append(auth_string, STS_PRODUCT_TOKEN); + g_string_append(auth_string, "\n"); + } - if (is_non_empty_string(hdl->storage_class)) { - g_string_append(auth_string, AMAZON_STORAGE_CLASS_HEADER); - g_string_append(auth_string, ":"); - g_string_append(auth_string, hdl->storage_class); - g_string_append(auth_string, "\n"); - } + if (g_str_equal(verb,"PUT") && + is_non_empty_string(hdl->server_side_encryption)) { + g_string_append(auth_string, AMAZON_SERVER_SIDE_ENCRYPTION_HEADER); + g_string_append(auth_string, ":"); + g_string_append(auth_string, hdl->server_side_encryption); + g_string_append(auth_string, "\n"); + } - /* CanonicalizedResource */ - if (hdl->service_path) { - g_string_append(auth_string, hdl->service_path); - } - g_string_append(auth_string, "/"); - if (bucket) { - if (hdl->use_subdomain) - g_string_append(auth_string, bucket); - else { - esc_bucket = curl_escape(bucket, 0); - if (!esc_bucket) goto cleanup; - g_string_append(auth_string, esc_bucket); - } - } + if (is_non_empty_string(hdl->storage_class)) { + g_string_append(auth_string, AMAZON_STORAGE_CLASS_HEADER); + g_string_append(auth_string, ":"); + g_string_append(auth_string, hdl->storage_class); + g_string_append(auth_string, "\n"); + } - if (bucket && (hdl->use_subdomain || key)) - g_string_append(auth_string, "/"); + /* CanonicalizedResource */ + if (hdl->service_path) { + g_string_append(auth_string, hdl->service_path); + } + g_string_append(auth_string, "/"); + if (bucket) { + if (hdl->use_subdomain) + g_string_append(auth_string, bucket); + else { + esc_bucket = curl_escape(bucket, 0); + if (!esc_bucket) goto cleanup; + g_string_append(auth_string, esc_bucket); + } + } - if (key) { - esc_key = curl_escape(key, 0); - if (!esc_key) goto cleanup; - g_string_append(auth_string, esc_key); - } + if (bucket && (hdl->use_subdomain || key)) + g_string_append(auth_string, "/"); - if (subresource) { - g_string_append(auth_string, "?"); - g_string_append(auth_string, subresource); - } + if (key) { + esc_key = curl_escape(key, 0); + if (!esc_key) goto cleanup; + g_string_append(auth_string, esc_key); + } - /* run HMAC-SHA1 on the canonicalized string */ - md = g_byte_array_sized_new(EVP_MAX_MD_SIZE+1); - HMAC_CTX_init(&ctx); - HMAC_Init_ex(&ctx, hdl->secret_key, (int) strlen(hdl->secret_key), EVP_sha1(), NULL); - HMAC_Update(&ctx, (unsigned char*) auth_string->str, auth_string->len); - HMAC_Final(&ctx, md->data, &md->len); - HMAC_CTX_cleanup(&ctx); - auth_base64 = s3_base64_encode(md); - /* append the new headers */ - if (is_non_empty_string(hdl->user_token)) { - /* Devpay headers are included in hash. */ - buf = g_strdup_printf(AMAZON_SECURITY_HEADER ": %s", hdl->user_token); - headers = curl_slist_append(headers, buf); - g_free(buf); + if (subresource) { + g_string_append(auth_string, "?"); + g_string_append(auth_string, subresource); + } - buf = g_strdup_printf(AMAZON_SECURITY_HEADER ": %s", STS_PRODUCT_TOKEN); - headers = curl_slist_append(headers, buf); - g_free(buf); - } + /* run HMAC-SHA1 on the canonicalized string */ + md = g_byte_array_sized_new(EVP_MAX_MD_SIZE+1); + HMAC_CTX_init(&ctx); + HMAC_Init_ex(&ctx, hdl->secret_key, (int) strlen(hdl->secret_key), + EVP_sha1(), NULL); + HMAC_Update(&ctx, (unsigned char*) auth_string->str, auth_string->len); + HMAC_Final(&ctx, md->data, &md->len); + HMAC_CTX_cleanup(&ctx); + auth_base64 = s3_base64_encode(md); + /* append the new headers */ + if (is_non_empty_string(hdl->user_token)) { + /* Devpay headers are included in hash. */ + buf = g_strdup_printf(AMAZON_SECURITY_HEADER ": %s", + hdl->user_token); + headers = curl_slist_append(headers, buf); + g_free(buf); + + buf = g_strdup_printf(AMAZON_SECURITY_HEADER ": %s", + STS_PRODUCT_TOKEN); + headers = curl_slist_append(headers, buf); + g_free(buf); + } - if (is_non_empty_string(hdl->storage_class)) { - buf = g_strdup_printf(AMAZON_STORAGE_CLASS_HEADER ": %s", hdl->storage_class); - headers = curl_slist_append(headers, buf); - g_free(buf); - } + if (g_str_equal(verb,"PUT") && + is_non_empty_string(hdl->server_side_encryption)) { + buf = g_strdup_printf(AMAZON_SERVER_SIDE_ENCRYPTION_HEADER ": %s", + hdl->server_side_encryption); + headers = curl_slist_append(headers, buf); + g_free(buf); + } + if (is_non_empty_string(hdl->storage_class)) { + buf = g_strdup_printf(AMAZON_STORAGE_CLASS_HEADER ": %s", + hdl->storage_class); + headers = curl_slist_append(headers, buf); + g_free(buf); + } - buf = g_strdup_printf("Authorization: AWS %s:%s", + buf = g_strdup_printf("Authorization: AWS %s:%s", hdl->access_key, auth_base64); - headers = curl_slist_append(headers, buf); - g_free(buf); + headers = curl_slist_append(headers, buf); + g_free(buf); + } if (md5_hash && '\0' != md5_hash[0]) { buf = g_strdup_printf("Content-MD5: %s", md5_hash); @@ -740,17 +801,128 @@ authenticate_request(S3Handle *hdl, buf = g_strdup_printf("Date: %s", date); headers = curl_slist_append(headers, buf); g_free(buf); + cleanup: g_free(date); g_free(esc_bucket); g_free(esc_key); - g_byte_array_free(md, TRUE); + if (md) g_byte_array_free(md, TRUE); g_free(auth_base64); - g_string_free(auth_string, TRUE); + if (auth_string) g_string_free(auth_string, TRUE); return headers; } +/* Functions for a SAX parser to parse the XML failure from Amazon */ + +/* Private structure for our "thunk", which tracks where the user is in the list + * * of keys. */ +struct failure_thunk { + gboolean want_text; + + gboolean in_title; + gboolean in_body; + gboolean in_code; + gboolean in_message; + gint in_others; + + gchar *text; + gsize text_len; + + gchar *message; + gchar *error_name; +}; + +static void +failure_start_element(GMarkupParseContext *context G_GNUC_UNUSED, + const gchar *element_name, + const gchar **attribute_names G_GNUC_UNUSED, + const gchar **attribute_values G_GNUC_UNUSED, + gpointer user_data, + GError **error G_GNUC_UNUSED) +{ + struct failure_thunk *thunk = (struct failure_thunk *)user_data; + + if (g_ascii_strcasecmp(element_name, "title") == 0) { + thunk->in_title = 1; + thunk->in_others = 0; + thunk->want_text = 1; + } else if (g_ascii_strcasecmp(element_name, "body") == 0) { + thunk->in_body = 1; + thunk->in_others = 0; + thunk->want_text = 1; + } else if (g_ascii_strcasecmp(element_name, "code") == 0) { + thunk->in_code = 1; + thunk->in_others = 0; + thunk->want_text = 1; + } else if (g_ascii_strcasecmp(element_name, "message") == 0) { + thunk->in_message = 1; + thunk->in_others = 0; + thunk->want_text = 1; + } else { + thunk->in_others++; + } +} + +static void +failure_end_element(GMarkupParseContext *context G_GNUC_UNUSED, + const gchar *element_name, + gpointer user_data, + GError **error G_GNUC_UNUSED) +{ + struct failure_thunk *thunk = (struct failure_thunk *)user_data; + + if (g_ascii_strcasecmp(element_name, "title") == 0) { + char *p = strchr(thunk->text, ' '); + if (p) { + p++; + if (*p) { + thunk->error_name = g_strdup(p); + } + } + g_free(thunk->text); + thunk->text = NULL; + thunk->in_title = 0; + } else if (g_ascii_strcasecmp(element_name, "body") == 0) { + thunk->message = thunk->text; + g_strstrip(thunk->message); + thunk->text = NULL; + thunk->in_body = 0; + } else if (g_ascii_strcasecmp(element_name, "code") == 0) { + thunk->error_name = thunk->text; + thunk->text = NULL; + thunk->in_code = 0; + } else if (g_ascii_strcasecmp(element_name, "message") == 0) { + thunk->message = thunk->text; + thunk->text = NULL; + thunk->in_message = 0; + } else { + thunk->in_others--; + } +} + +static void +failure_text(GMarkupParseContext *context G_GNUC_UNUSED, + const gchar *text, + gsize text_len, + gpointer user_data, + GError **error G_GNUC_UNUSED) +{ + struct failure_thunk *thunk = (struct failure_thunk *)user_data; + + if (thunk->want_text && thunk->in_others == 0) { + char *new_text; + + new_text = g_strndup(text, text_len); + if (thunk->text) { + strappend(thunk->text, new_text); + g_free(new_text); + } else { + thunk->text = new_text; + } + } +} + static gboolean interpret_response(S3Handle *hdl, CURLcode curl_code, @@ -761,10 +933,11 @@ interpret_response(S3Handle *hdl, const char *content_md5) { long response_code = 0; - regmatch_t pmatch[2]; - char *error_name = NULL, *message = NULL; - char *body_copy = NULL; gboolean ret = TRUE; + struct failure_thunk thunk; + GMarkupParseContext *ctxt = NULL; + static GMarkupParser parser = { failure_start_element, failure_end_element, failure_text, NULL, NULL }; + GError *err = NULL; if (!hdl) return FALSE; @@ -790,15 +963,13 @@ interpret_response(S3Handle *hdl, ret = FALSE; return ret; } - if (200 <= response_code && response_code < 400) { /* 2xx and 3xx codes won't have a response body we care about */ hdl->last_s3_error_code = S3_ERROR_None; return FALSE; } - /* Now look at the body to try to get the actual Amazon error message. Rather - * than parse out the XML, just use some regexes. */ + /* Now look at the body to try to get the actual Amazon error message. */ /* impose a reasonable limit on body size */ if (body_len > MAX_ERROR_RESPONSE_LEN) { @@ -809,30 +980,81 @@ interpret_response(S3Handle *hdl, return TRUE; /* perhaps a network error; retry the request */ } - /* use strndup to get a zero-terminated string */ - body_copy = g_strndup(body, body_len); - if (!body_copy) goto cleanup; + thunk.in_title = FALSE; + thunk.in_body = FALSE; + thunk.in_code = FALSE; + thunk.in_message = FALSE; + thunk.in_others = 0; + thunk.text = NULL; + thunk.want_text = FALSE; + thunk.text_len = 0; + thunk.message = NULL; + thunk.error_name = NULL; + + if (hdl->openstack_swift_api && + !g_strstr_len(body, body_len, "xml version") && + !g_strstr_len(body, body_len, "")) { + char *body_copy = g_strndup(body, body_len); + char *b = body_copy; + char *p = strchr(b, '\n'); + char *p1; + if (p) { /* first line: error code */ + *p = '\0'; + p++; + p1 = strchr(b, ' '); + if (p1) { + p1++; + if (*p1) { + thunk.error_name = g_strdup(p1); + } + } + b = p; + } + p = strchr(b, '\n'); + if (p) { /* second line: error message */ + *p = '\0'; + p++; + thunk.message = g_strdup(p); + g_strstrip(thunk.message); + b = p; + } + goto parsing_done; + } + + /* run the parser over it */ + ctxt = g_markup_parse_context_new(&parser, 0, (gpointer)&thunk, NULL); + if (!g_markup_parse_context_parse(ctxt, body, body_len, &err)) { + if (hdl->last_message) g_free(hdl->last_message); + hdl->last_message = g_strdup(err->message); + goto cleanup; + } - if (!s3_regexec_wrap(&error_name_regex, body_copy, 2, pmatch, 0)) - error_name = find_regex_substring(body_copy, pmatch[1]); + if (!g_markup_parse_context_end_parse(ctxt, &err)) { + if (hdl->last_message) g_free(hdl->last_message); + hdl->last_message = g_strdup(err->message); + goto cleanup; + } - if (!s3_regexec_wrap(&message_regex, body_copy, 2, pmatch, 0)) - message = find_regex_substring(body_copy, pmatch[1]); + g_markup_parse_context_free(ctxt); + ctxt = NULL; - if (error_name) { - hdl->last_s3_error_code = s3_error_code_from_name(error_name); +parsing_done: + if (thunk.error_name) { + hdl->last_s3_error_code = s3_error_code_from_name(thunk.error_name); + g_free(thunk.error_name); + thunk.error_name = NULL; } - if (message) { - hdl->last_message = message; - message = NULL; /* steal the reference to the string */ + if (thunk.message) { + g_free(hdl->last_message); + hdl->last_message = thunk.message; + thunk.message = NULL; /* steal the reference to the string */ } cleanup: - g_free(body_copy); - g_free(message); - g_free(error_name); - + g_free(thunk.text); + g_free(thunk.message); + g_free(thunk.error_name); return FALSE; } @@ -1042,7 +1264,17 @@ curl_debug_message(CURL *curl G_GNUC_UNUSED, case CURLINFO_HEADER_OUT: lineprefix="Hdr Out: "; break; +/* + case CURLINFO_DATA_IN: + if (len > 1000) return 0; + lineprefix="Data In: "; + break; + case CURLINFO_DATA_OUT: + if (len > 1000) return 0; + lineprefix="Data Out: "; + break; +*/ default: /* ignore data in/out -- nobody wants to see that in the * debug logs! */ @@ -1105,8 +1337,7 @@ perform_request(S3Handle *hdl, s3_reset(hdl); - url = build_url(hdl->host, hdl->service_path, bucket, key, subresource, - query, hdl->use_subdomain, hdl->use_ssl); + url = build_url(hdl, bucket, key, subresource, query); if (!url) goto cleanup; /* libcurl may behave strangely if these are not set correctly */ @@ -1221,7 +1452,7 @@ perform_request(S3Handle *hdl, goto curl_error; if (hdl->max_recv_speed) - if ((curl_code = curl_easy_setopt(hdl->curl, CURLOPT_MAX_SEND_SPEED_LARGE, (curl_off_t)hdl->max_recv_speed))) + if ((curl_code = curl_easy_setopt(hdl->curl, CURLOPT_MAX_RECV_SPEED_LARGE, (curl_off_t)hdl->max_recv_speed))) goto curl_error; } #endif @@ -1360,10 +1591,24 @@ s3_internal_header_func(void *ptr, size_t size, size_t nmemb, void * stream) header = g_strndup((gchar *) ptr, (gsize) size*nmemb); + if (header[strlen(header)-1] == '\n') + header[strlen(header)-1] = '\0'; + if (header[strlen(header)-1] == '\r') + header[strlen(header)-1] = '\0'; if (!s3_regexec_wrap(&etag_regex, header, 2, pmatch, 0)) data->etag = find_regex_substring(header, pmatch[1]); - if (!strcmp(final_header, header)) + if (!s3_regexec_wrap(&x_auth_token_regex, header, 2, pmatch, 0)) + data->hdl->x_auth_token = find_regex_substring(header, pmatch[1]); + + if (!s3_regexec_wrap(&x_storage_url_regex, header, 2, pmatch, 0)) + data->hdl->x_storage_url = find_regex_substring(header, pmatch[1]); + + if (strlen(header) == 0) + data->headers_done = TRUE; + if (g_str_equal(final_header, header)) data->headers_done = TRUE; + if (g_str_equal("\n", header)) + data->headers_done = TRUE; /* If date header is found */ if (!s3_regexec_wrap(&date_sync_regex, header, 2, pmatch, 0)){ @@ -1399,6 +1644,8 @@ compile_regexes(void) struct {const char * str; int flags; regex_t *regex;} regexes[] = { {"[[:space:]]*([^<]*)[[:space:]]*", REG_EXTENDED | REG_ICASE, &error_name_regex}, {"^ETag:[[:space:]]*\"([^\"]+)\"[[:space:]]*$", REG_EXTENDED | REG_ICASE | REG_NEWLINE, &etag_regex}, + {"^X-Auth-Token:[[:space:]]*([^ ]+)[[:space:]]*$", REG_EXTENDED | REG_ICASE | REG_NEWLINE, &x_auth_token_regex}, + {"^X-Storage-Url:[[:space:]]*([^ ]+)[[:space:]]*$", REG_EXTENDED | REG_ICASE | REG_NEWLINE, &x_storage_url_regex}, {"[[:space:]]*([^<]*)[[:space:]]*", REG_EXTENDED | REG_ICASE, &message_regex}, {"^[a-z0-9](-*[a-z0-9]){2,62}$", REG_EXTENDED | REG_NOSUB, &subdomain_regex}, {"(/>)|(>([^<]*))", REG_EXTENDED | REG_ICASE, &location_con_regex}, @@ -1406,13 +1653,13 @@ compile_regexes(void) {NULL, 0, NULL} }; char regmessage[1024]; - int size, i; + int i; int reg_result; for (i = 0; regexes[i].str; i++) { reg_result = regcomp(regexes[i].regex, regexes[i].str, regexes[i].flags); if (reg_result != 0) { - size = regerror(reg_result, regexes[i].regex, regmessage, sizeof(regmessage)); + regerror(reg_result, regexes[i].regex, regmessage, sizeof(regmessage)); g_error(_("Regex error: %s"), regmessage); return FALSE; } @@ -1490,17 +1737,40 @@ s3_bucket_location_compat(const char *bucket) return !s3_regexec_wrap(&subdomain_regex, bucket, 0, NULL, 0); } +static gboolean +get_openstack_swift_api_setting( + S3Handle *hdl) +{ + s3_result_t result = S3_RESULT_FAIL; + static result_handling_t result_handling[] = { + { 200, 0, 0, S3_RESULT_OK }, + RESULT_HANDLING_ALWAYS_RETRY, + { 0, 0, 0, /* default: */ S3_RESULT_FAIL } + }; + + s3_verbose(hdl, 1); + result = perform_request(hdl, "GET", NULL, NULL, NULL, NULL, + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, NULL, result_handling); + + return result == S3_RESULT_OK; + +} + S3Handle * s3_open(const char *access_key, const char *secret_key, + const char *swift_account_id, + const char *swift_access_key, const char *host, const char *service_path, const gboolean use_subdomain, const char *user_token, const char *bucket_location, const char *storage_class, - const char *ca_info - ) + const char *ca_info, + const char *server_side_encryption, + const gboolean openstack_swift_api) { S3Handle *hdl; @@ -1510,10 +1780,18 @@ s3_open(const char *access_key, hdl->verbose = FALSE; hdl->use_ssl = s3_curl_supports_ssl(); - g_assert(access_key); - hdl->access_key = g_strdup(access_key); - g_assert(secret_key); - hdl->secret_key = g_strdup(secret_key); + if (!openstack_swift_api) { + g_assert(access_key); + hdl->access_key = g_strdup(access_key); + g_assert(secret_key); + hdl->secret_key = g_strdup(secret_key); + } else { + g_assert(swift_account_id); + hdl->swift_account_id = g_strdup(swift_account_id); + g_assert(swift_access_key); + hdl->swift_access_key = g_strdup(swift_access_key); + } + /* NULL is okay */ hdl->user_token = g_strdup(user_token); @@ -1523,20 +1801,34 @@ s3_open(const char *access_key, /* NULL is ok */ hdl->storage_class = g_strdup(storage_class); + /* NULL is ok */ + hdl->server_side_encryption = g_strdup(server_side_encryption); + /* NULL is okay */ hdl->ca_info = g_strdup(ca_info); if (!is_non_empty_string(host)) host = "s3.amazonaws.com"; - hdl->host = g_strdup(host); + hdl->host = g_ascii_strdown(host, -1); hdl->use_subdomain = use_subdomain || - (strcmp(host, "s3.amazonaws.com") == 0 && + (strcmp(hdl->host, "s3.amazonaws.com") == 0 && is_non_empty_string(hdl->bucket_location)); + hdl->openstack_swift_api = openstack_swift_api; if (service_path) { - if (service_path[0] != '/') + if (strlen(service_path) == 0 || + (strlen(service_path) == 1 && service_path[0] == '/')) { + hdl->service_path = NULL; + } else if (service_path[0] != '/') { hdl->service_path = g_strdup_printf("/%s", service_path); - else + } else { hdl->service_path = g_strdup(service_path); + } + if (hdl->service_path) { + /* remove trailling / */ + size_t len = strlen(hdl->service_path) - 1; + if (hdl->service_path[len] == '/') + hdl->service_path[len] = '\0'; + } } else { hdl->service_path = NULL; } @@ -1544,6 +1836,9 @@ s3_open(const char *access_key, hdl->curl = curl_easy_init(); if (!hdl->curl) goto error; + if (openstack_swift_api) { /* get the X-Storage-Url and X-Auth-Token */ + get_openstack_swift_api_setting(hdl); + } return hdl; error: @@ -1559,9 +1854,12 @@ s3_free(S3Handle *hdl) if (hdl) { g_free(hdl->access_key); g_free(hdl->secret_key); + g_free(hdl->swift_account_id); + g_free(hdl->swift_access_key); if (hdl->user_token) g_free(hdl->user_token); if (hdl->bucket_location) g_free(hdl->bucket_location); if (hdl->storage_class) g_free(hdl->storage_class); + if (hdl->server_side_encryption) g_free(hdl->server_side_encryption); if (hdl->host) g_free(hdl->host); if (hdl->service_path) g_free(hdl->service_path); if (hdl->curl) curl_easy_cleanup(hdl->curl); @@ -1718,6 +2016,7 @@ s3_upload(S3Handle *hdl, s3_result_t result = S3_RESULT_FAIL; static result_handling_t result_handling[] = { { 200, 0, 0, S3_RESULT_OK }, + { 201, 0, 0, S3_RESULT_OK }, RESULT_HANDLING_ALWAYS_RETRY, { 0, 0, 0, /* default: */ S3_RESULT_FAIL } }; @@ -1764,15 +2063,20 @@ list_start_element(GMarkupParseContext *context G_GNUC_UNUSED, struct list_keys_thunk *thunk = (struct list_keys_thunk *)user_data; thunk->want_text = 0; - if (g_ascii_strcasecmp(element_name, "contents") == 0) { + if (g_ascii_strcasecmp(element_name, "contents") == 0 || + g_ascii_strcasecmp(element_name, "object") == 0) { thunk->in_contents = 1; } else if (g_ascii_strcasecmp(element_name, "commonprefixes") == 0) { thunk->in_common_prefixes = 1; } else if (g_ascii_strcasecmp(element_name, "prefix") == 0 && thunk->in_common_prefixes) { thunk->want_text = 1; - } else if (g_ascii_strcasecmp(element_name, "key") == 0 && thunk->in_contents) { + } else if ((g_ascii_strcasecmp(element_name, "key") == 0 || + g_ascii_strcasecmp(element_name, "name") == 0) && + thunk->in_contents) { thunk->want_text = 1; - } else if (g_ascii_strcasecmp(element_name, "size") == 0 && thunk->in_contents) { + } else if ((g_ascii_strcasecmp(element_name, "size") == 0 || + g_ascii_strcasecmp(element_name, "bytes") == 0) && + thunk->in_contents) { thunk->want_text = 1; } else if (g_ascii_strcasecmp(element_name, "istruncated")) { thunk->want_text = 1; @@ -1793,10 +2097,18 @@ list_end_element(GMarkupParseContext *context G_GNUC_UNUSED, thunk->in_contents = 0; } else if (g_ascii_strcasecmp(element_name, "commonprefixes") == 0) { thunk->in_common_prefixes = 0; - } else if (g_ascii_strcasecmp(element_name, "key") == 0 && thunk->in_contents) { + } else if ((g_ascii_strcasecmp(element_name, "key") == 0 || + g_ascii_strcasecmp(element_name, "name") == 0) && + thunk->in_contents) { thunk->filename_list = g_slist_prepend(thunk->filename_list, thunk->text); + if (thunk->is_truncated) { + if (thunk->next_marker) g_free(thunk->next_marker); + thunk->next_marker = g_strdup(thunk->text); + } thunk->text = NULL; - } else if (g_ascii_strcasecmp(element_name, "size") == 0 && thunk->in_contents) { + } else if ((g_ascii_strcasecmp(element_name, "size") == 0 || + g_ascii_strcasecmp(element_name, "bytes") == 0) && + thunk->in_contents) { thunk->size += g_ascii_strtoull (thunk->text, NULL, 10); thunk->text = NULL; } else if (g_ascii_strcasecmp(element_name, "prefix") == 0 && thunk->in_common_prefixes) { @@ -1841,6 +2153,7 @@ list_fetch(S3Handle *hdl, s3_result_t result = S3_RESULT_FAIL; static result_handling_t result_handling[] = { { 200, 0, 0, S3_RESULT_OK }, + { 204, 0, 0, S3_RESULT_OK }, RESULT_HANDLING_ALWAYS_RETRY, { 0, 0, 0, /* default: */ S3_RESULT_FAIL } }; @@ -1859,15 +2172,25 @@ list_fetch(S3Handle *hdl, /* loop over possible parts to build query string */ query = g_string_new(""); for (i = 0; pos_parts[i][0]; i++) { - if (pos_parts[i][1]) { - if (have_prev_part) - g_string_append(query, "&"); - else - have_prev_part = TRUE; - esc_value = curl_escape(pos_parts[i][1], 0); - g_string_append_printf(query, "%s=%s", pos_parts[i][0], esc_value); - curl_free(esc_value); - } + if (pos_parts[i][1]) { + const char *keyword; + if (have_prev_part) + g_string_append(query, "&"); + else + have_prev_part = TRUE; + esc_value = curl_escape(pos_parts[i][1], 0); + keyword = pos_parts[i][0]; + if (hdl->openstack_swift_api && strcmp(keyword, "max-keys") == 0) { + keyword = "limit"; + } + g_string_append_printf(query, "%s=%s", keyword, esc_value); + curl_free(esc_value); + } + } + if (hdl->openstack_swift_api) { + if (have_prev_part) + g_string_append(query, "&"); + g_string_append(query, "format=xml"); } /* and perform the request on that URI */ @@ -1922,11 +2245,14 @@ s3_list_keys(S3Handle *hdl, /* get some data from S3 */ result = list_fetch(hdl, bucket, prefix, delimiter, thunk.next_marker, MAX_KEYS, &buf); if (result != S3_RESULT_OK) goto cleanup; + if (buf.buffer_pos == 0) goto cleanup; /* no body */ /* run the parser over it */ thunk.in_contents = FALSE; thunk.in_common_prefixes = FALSE; thunk.is_truncated = FALSE; + if (thunk.next_marker) g_free(thunk.next_marker); + thunk.next_marker = NULL; thunk.want_text = FALSE; ctxt = g_markup_parse_context_new(&parser, 0, (gpointer)&thunk, NULL); @@ -1987,7 +2313,6 @@ s3_read(S3Handle *hdl, g_assert(hdl != NULL); g_assert(write_func != NULL); - result = perform_request(hdl, "GET", bucket, key, NULL, NULL, NULL, NULL, NULL, NULL, NULL, write_func, reset_func, write_data, progress_func, progress_data, result_handling); @@ -2003,8 +2328,10 @@ s3_delete(S3Handle *hdl, s3_result_t result = S3_RESULT_FAIL; static result_handling_t result_handling[] = { { 204, 0, 0, S3_RESULT_OK }, + { 404, 0, 0, S3_RESULT_OK }, { 404, S3_ERROR_NoSuchBucket, 0, S3_RESULT_OK }, RESULT_HANDLING_ALWAYS_RETRY, + { 409, 0, 0, S3_RESULT_OK }, { 0, 0, 0, /* default: */ S3_RESULT_FAIL } }; @@ -2025,6 +2352,9 @@ s3_make_bucket(S3Handle *hdl, s3_result_t result = S3_RESULT_FAIL; static result_handling_t result_handling[] = { { 200, 0, 0, S3_RESULT_OK }, + { 201, 0, 0, S3_RESULT_OK }, + { 202, 0, 0, S3_RESULT_OK }, + { 204, 0, 0, S3_RESULT_OK }, { 404, S3_ERROR_NoSuchBucket, 0, S3_RESULT_RETRY }, RESULT_HANDLING_ALWAYS_RETRY, { 0, 0, 0, /* default: */ S3_RESULT_FAIL } @@ -2043,7 +2373,11 @@ s3_make_bucket(S3Handle *hdl, 0 != strcmp(AMAZON_WILDCARD_LOCATION, hdl->bucket_location)) { if (s3_bucket_location_compat(bucket)) { ptr = &buf; - buf.buffer = g_strdup_printf(AMAZON_BUCKET_CONF_TEMPLATE, hdl->bucket_location); + buf.buffer = g_strdup_printf(AMAZON_BUCKET_CONF_TEMPLATE, + g_str_equal(hdl->host, "gss.iijgio.com")? + " xmlns=\"http://acs.iijgio.com/doc/2006-03-01/\"": + "", + hdl->bucket_location); buf.buffer_len = (guint) strlen(buf.buffer); buf.buffer_pos = 0; buf.max_buffer_size = buf.buffer_len; @@ -2125,6 +2459,26 @@ cleanup: } +gboolean +s3_is_bucket_exists(S3Handle *hdl, + const char *bucket) +{ + s3_result_t result = S3_RESULT_FAIL; + static result_handling_t result_handling[] = { + { 200, 0, 0, S3_RESULT_OK }, + { 204, 0, 0, S3_RESULT_OK }, + RESULT_HANDLING_ALWAYS_RETRY, + { 0, 0, 0, /* default: */ S3_RESULT_FAIL } + }; + + result = perform_request(hdl, "GET", bucket, NULL, NULL, + hdl->openstack_swift_api?"limit=1":"max-keys=1", + NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, + NULL, NULL, result_handling); + + return result == S3_RESULT_OK; +} + gboolean s3_delete_bucket(S3Handle *hdl, const char *bucket) diff --git a/device-src/s3.h b/device-src/s3.h index c5ec607..24ad960 100644 --- a/device-src/s3.h +++ b/device-src/s3.h @@ -115,7 +115,7 @@ typedef curl_progress_callback s3_progress_func; /* This preprocessor magic will enumerate constants named S3_ERROR_XxxYyy for * each of the errors in parentheses. * - * see http://docs.amazonwebservices.com/AmazonS3/2006-03-01/ErrorCodeList.html + * see http://docs.amazonwebservices.com/AmazonS3/latest/API/ErrorResponses.html * for Amazon's breakdown of error responses. */ #define S3_ERROR_LIST \ @@ -166,6 +166,11 @@ typedef curl_progress_callback s3_progress_func; S3_ERROR(UnexpectedContent), \ S3_ERROR(UnresolvableGrantByEmailAddress), \ S3_ERROR(Unknown), \ + S3_ERROR(Unauthorized), \ + S3_ERROR(Created), \ + S3_ERROR(Accepted), \ + S3_ERROR(Forbidden), \ + S3_ERROR(Conflict), \ S3_ERROR(END) typedef enum { @@ -233,10 +238,14 @@ s3_init(void); * @returns: the new S3Handle */ S3Handle * -s3_open(const char * access_key, const char *secret_key, const char *host, +s3_open(const char * access_key, const char *secret_key, + const char *swift_account_id, const char *swift_access_key, + const char *host, const char *service_path, gboolean use_subdomain, const char * user_token, - const char * bucket_location, const char * storage_class, const char * ca_info); + const char * bucket_location, const char * storage_class, + const char * ca_info, const char * server_side_encryption, + const gboolean openstack_swift_api); /* Deallocate an S3Handle * @@ -424,6 +433,16 @@ gboolean s3_make_bucket(S3Handle *hdl, const char *bucket); +/* Check if a bucket exists. + * + * @param hdl: the S3Handle object + * @param bucket: the bucket to create + * @returns: FALSE if an error occur + */ +gboolean +s3_is_bucket_exists(S3Handle *hdl, + const char *bucket); + /* Delete a bucket * * @note A bucket can not be deleted if it still contains keys diff --git a/device-src/tape-device.c b/device-src/tape-device.c index c6b88ce..5e4b449 100644 --- a/device-src/tape-device.c +++ b/device-src/tape-device.c @@ -578,6 +578,9 @@ tape_device_set_compression_fn(Device *p_self, DevicePropertyBase *base, /* looks good .. let's start the device over, though */ device_clear_volume_details(p_self); } else { + device_set_error(p_self, + g_strdup("Error setting COMPRESION property"), + DEVICE_STATUS_DEVICE_ERROR); return FALSE; } @@ -603,6 +606,9 @@ tape_device_set_read_block_size_fn(Device *p_self, DevicePropertyBase *base G_GN if (read_block_size != 0 && ((gsize)read_block_size < p_self->block_size || (gsize)read_block_size > p_self->max_block_size)) + device_set_error(p_self, + g_strdup_printf("Error setting READ-BLOCk-SIZE property to '%u', it must be between %zu and %zu", read_block_size, p_self->block_size, p_self->max_block_size), + DEVICE_STATUS_DEVICE_ERROR); return FALSE; self->private->read_block_size = read_block_size; @@ -919,6 +925,7 @@ static DeviceStatusFlags tape_device_read_label(Device * dself) { return dself->status; } + dself->header_block_size = buffer_len; header = dself->volume_header = g_new(dumpfile_t, 1); fh_init(header); @@ -1111,6 +1118,7 @@ static gboolean write_tapestart_header(TapeDevice * self, char * label, return FALSE; } + d_self->header_block_size = d_self->block_size; amfree(header_buf); if (!tape_weof(self->fd, 1)) { diff --git a/device-src/vfs-device.c b/device-src/vfs-device.c index 4906c29..122a6ef 100644 --- a/device-src/vfs-device.c +++ b/device-src/vfs-device.c @@ -585,11 +585,9 @@ vfs_device_open_device (Device * pself, char * device_name, char * device_type, static gboolean delete_vfs_files_functor(const char * filename, gpointer user_data) { VfsDevice * self; - Device * d_self; char * path_name; self = VFS_DEVICE(user_data); - d_self = DEVICE(self); /* Skip the volume lock. */ if (strcmp(filename, VOLUME_LOCKFILE_NAME) == 0) @@ -691,6 +689,7 @@ static gboolean clear_and_prepare_label(VfsDevice * self, char * label, return FALSE; } dumpfile_free(d_self->volume_header); + d_self->header_block_size = VFS_DEVICE_LABEL_SIZE; d_self->volume_header = label_header; self->volume_bytes = VFS_DEVICE_LABEL_SIZE; return TRUE; @@ -1230,6 +1229,9 @@ vfs_device_seek_file (Device * dself, guint requested_file) { } /* update our state */ + if (requested_file == 0) { + dself->header_block_size = header_buffer_size; + } dself->in_file = TRUE; dself->file = file; @@ -1404,6 +1406,11 @@ vfs_device_erase (Device * dself) { release_file(self); + dumpfile_free(dself->volume_header); + dself->volume_header = NULL; + device_set_error(dself, g_strdup("Unlabeled volume"), + DEVICE_STATUS_VOLUME_UNLABELED); + return TRUE; } diff --git a/device-src/xfer-dest-taper-cacher.c b/device-src/xfer-dest-taper-cacher.c index 12bf923..7564304 100644 --- a/device-src/xfer-dest-taper-cacher.c +++ b/device-src/xfer-dest-taper-cacher.c @@ -270,7 +270,7 @@ _xdt_dbg(const char *fmt, ...) arglist_start(argp, fmt); g_vsnprintf(msg, sizeof(msg), fmt, argp); arglist_end(argp); - g_debug("XDT thd-%p: %s", g_thread_self(), msg); + g_debug("XDT: %s", msg); } /* diff --git a/device-src/xfer-dest-taper-directtcp.c b/device-src/xfer-dest-taper-directtcp.c index 5bc492c..6d9d12d 100644 --- a/device-src/xfer-dest-taper-directtcp.c +++ b/device-src/xfer-dest-taper-directtcp.c @@ -95,7 +95,7 @@ _xdt_dbg(const char *fmt, ...) arglist_start(argp, fmt); g_vsnprintf(msg, sizeof(msg), fmt, argp); arglist_end(argp); - g_debug("XDT thd-%p: %s", g_thread_self(), msg); + g_debug("XDT: %s", msg); } /* * Worker Thread diff --git a/device-src/xfer-dest-taper-splitter.c b/device-src/xfer-dest-taper-splitter.c index 561f04d..ccd7fde 100644 --- a/device-src/xfer-dest-taper-splitter.c +++ b/device-src/xfer-dest-taper-splitter.c @@ -181,7 +181,7 @@ _xdt_dbg(const char *fmt, ...) arglist_start(argp, fmt); g_vsnprintf(msg, sizeof(msg), fmt, argp); arglist_end(argp); - g_debug("XDT thd-%p: %s", g_thread_self(), msg); + g_debug("XDT: %s", msg); } /* "Fast forward" the slice list by the given length. This will free any @@ -551,11 +551,6 @@ part_done: } } - if (elt->cancelled) { - g_timer_destroy(timer); - return NULL; - } - g_timer_stop(timer); msg = xmsg_new(XFER_ELEMENT(self), XMSG_PART_DONE, 0); @@ -564,7 +559,7 @@ part_done: msg->partnum = self->partnum; msg->fileno = fileno; msg->successful = self->last_part_successful = part_status != PART_FAILED; - msg->eom = self->last_part_eom = (part_status == PART_LEOM || !msg->successful); + msg->eom = self->last_part_eom = part_status == PART_LEOM || self->device->is_eom; msg->eof = self->last_part_eof = part_status == PART_EOF; /* time runs backward on some test boxes, so make sure this is positive */ diff --git a/device-src/xfer-source-recovery.c b/device-src/xfer-source-recovery.c index 4f736a2..16673e0 100644 --- a/device-src/xfer-source-recovery.c +++ b/device-src/xfer-source-recovery.c @@ -115,7 +115,7 @@ _xsr_dbg(const char *fmt, ...) arglist_start(argp, fmt); g_vsnprintf(msg, sizeof(msg), fmt, argp); arglist_end(argp); - g_debug("XSR thd-%p: %s", g_thread_self(), msg); + g_debug("XSR: %s", msg); } /* @@ -407,8 +407,9 @@ pull_buffer_impl( _("error reading from %s: %s"), self->device->device_name, device_error_or_status(self->device)); + g_mutex_unlock(self->start_part_mutex); wait_until_xfer_cancelled(elt->xfer); - goto error; + goto error_unlocked; } /* the device has signalled EOF (really end-of-part), so clean up instance @@ -463,6 +464,7 @@ pull_buffer_impl( return buf; error: g_mutex_unlock(self->start_part_mutex); +error_unlocked: *size = 0; return NULL; } diff --git a/example/Makefile.in b/example/Makefile.in index ed48f58..a4b63bd 100644 --- a/example/Makefile.in +++ b/example/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -361,6 +361,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -793,6 +794,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -842,6 +844,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -850,6 +853,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -857,6 +861,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1001,6 +1007,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1034,6 +1041,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1076,7 +1084,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/example/template.d/amanda-S3.conf.in b/example/template.d/amanda-S3.conf.in index 73e07de..8c0d43b 100644 --- a/example/template.d/amanda-S3.conf.in +++ b/example/template.d/amanda-S3.conf.in @@ -10,8 +10,14 @@ tapecycle 10 tapes # the number of tapes in rotation # backups performed at the beginning of the previous # cycle runtapes 1 # number of tapes to be used in a single run of amdump -tpchanger "chg-multi" # the tape-changer glue script -changerfile "@CONFIG_DIR@/@DEFAULT_CONFIG@/changer.conf" + +define changer my_s3 { + tpchanger "chg-multi:" + device-property "S3_ACCESS_KEY" "" + device-property "S3_SECRET_KEY" "" + device-property "NB_THREADS_BACKUP" "3" +} +tpchanger "my_s3" tapetype S3 # what kind of tape it is (see tapetypes below) holdingdisk hd2 { diff --git a/example/template.d/amanda-harddisk.conf.in b/example/template.d/amanda-harddisk.conf.in index 9ed969e..3abbc16 100644 --- a/example/template.d/amanda-harddisk.conf.in +++ b/example/template.d/amanda-harddisk.conf.in @@ -10,10 +10,13 @@ tapecycle 10 tapes # the number of tapes in rotation # backups performed at the beginning of the previous # cycle runtapes 1 # number of tapes to be used in a single run of amdump -tpchanger "chg-disk" # the tape-changer glue script -tapedev "file://var/lib/amanda/vtapes/@DEFAULT_CONFIG@" # the no-rewind tape device to be used -changerfile "@CONFIG_DIR@/@DEFAULT_CONFIG@/changer.conf" -changerdev "/dev/null" + +define changer my_vtapes { + tpchanger "chg-disk:/@prefix@/var/lib/amanda/vtapes/@DEFAULT_CONFIG@" + property "num-slot" "10" + property "auto-create-slot" "yes" +} +tpchanger "my_vtapes" tapetype HARDDISK # what kind of tape it is labelstr "^@DEFAULT_CONFIG@-[0-9][0-9]*$" # label constraint regex: all tapes must match dtimeout 1800 # number of idle seconds before a dump is aborted. diff --git a/example/template.d/amanda-single-tape.conf.in b/example/template.d/amanda-single-tape.conf.in index 7a26942..c4fde14 100644 --- a/example/template.d/amanda-single-tape.conf.in +++ b/example/template.d/amanda-single-tape.conf.in @@ -11,9 +11,11 @@ tapecycle 10 tapes # the number of tapes in rotation # cycle runtapes 1 # number of tapes to be used in a single run of amdump -tapedev "tape:/dev/nst0" # the no-rewind tape device to be used -changerfile "@CONFIG_DIR@/@DEFAULT_CONFIG@/chg-manual.conf" -changerdev "/dev/null" + +define changer my_single { + tpchanger "chg-single:tape:/dev/nst0" +} +tpchanger "my_single" tapetype HP-DAT # what kind of tape it is (see tapetypes below) holdingdisk hd2 { directory "/var/lib/amanda/holdings/@DEFAULT_CONFIG@" diff --git a/example/template.d/amanda-tape-changer.conf.in b/example/template.d/amanda-tape-changer.conf.in index d2922a2..d4a9831 100644 --- a/example/template.d/amanda-tape-changer.conf.in +++ b/example/template.d/amanda-tape-changer.conf.in @@ -10,10 +10,12 @@ tapecycle 10 tapes # the number of tapes in rotation # backups performed at the beginning of the previous # cycle runtapes 1 # number of tapes to be used in a single run of amdump -tpchanger "chg-zd-mtx" # the tape-changer glue script -tapedev "tape:/dev/nst0" # the no-rewind tape device to be used -changerfile "@CONFIG_DIR@/@DEFAULT_CONFIG@/changer.conf" -changerdev "/dev/sg1" + +define changer my_robot { + tpchanger "chg-robot:/dev/sg1" + property "tape-device" "0=tape:/dev/nst0" +} +tpchanger "my_robot" tapetype HP-DAT # what kind of tape it is (see tapetypes below) holdingdisk hd2 { diff --git a/gnulib/Makefile.in b/gnulib/Makefile.in index 6a99cca..6c669fd 100644 --- a/gnulib/Makefile.in +++ b/gnulib/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -337,6 +337,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -769,6 +770,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -818,6 +820,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -826,6 +829,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -833,6 +837,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -977,6 +983,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1010,6 +1017,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1052,7 +1060,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -1303,7 +1310,7 @@ clean-libtool: # (which will cause the Makefiles to be regenerated when you run `make'); # (2) otherwise, pass the desired values on the `make' command line. $(RECURSIVE_TARGETS): - @failcom='exit 1'; \ + @fail= failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ @@ -1328,7 +1335,7 @@ $(RECURSIVE_TARGETS): fi; test -z "$$fail" $(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ + @fail= failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ diff --git a/installcheck/Amanda_Changer_multi.pl b/installcheck/Amanda_Changer_multi.pl index 0ca9ea1..ae3466d 100644 --- a/installcheck/Amanda_Changer_multi.pl +++ b/installcheck/Amanda_Changer_multi.pl @@ -378,22 +378,27 @@ Amanda::MainLoop::run(); is_deeply($inv, [ { slot => 1, state => Amanda::Changer::SLOT_FULL, device_status => $DEVICE_STATUS_DEVICE_ERROR, + device_error => "Error checking directory $taperoot/slot0/data/: No such file or directory", f_type => undef, label => undef, reserved => 0 }, { slot => 2, state => Amanda::Changer::SLOT_FULL, device_status => $DEVICE_STATUS_VOLUME_UNLABELED, + device_error => "File 0 not found", f_type => $Amanda::Header::F_EMPTY, label => undef, reserved => 0 }, { slot => 3, state => Amanda::Changer::SLOT_FULL, device_status => $DEVICE_STATUS_VOLUME_UNLABELED, + device_error => "File 0 not found", f_type => $Amanda::Header::F_EMPTY, label => undef, reserved => 0 }, { slot => 4, state => Amanda::Changer::SLOT_FULL, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => "FOO?BAR", reserved => 0, current => 1 }, { slot => 5, state => Amanda::Changer::SLOT_FULL, device_status => $DEVICE_STATUS_VOLUME_UNLABELED, + device_error => "File 0 not found", f_type => $Amanda::Header::F_EMPTY, label => undef, reserved => 0 }, ], "inventory finds the labeled tape"); diff --git a/installcheck/Amanda_Changer_ndmp.pl b/installcheck/Amanda_Changer_ndmp.pl index 2219a2c..209a60e 100644 --- a/installcheck/Amanda_Changer_ndmp.pl +++ b/installcheck/Amanda_Changer_ndmp.pl @@ -359,19 +359,24 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'load_slot_1'}, [ { slot => 1, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG00XX', current => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG01XX', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG02XX', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory is correct on start-up"); }; @@ -450,20 +455,27 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'load_slot_3'}, [ { slot => 1, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG00XX', reserved => 1, loaded_in => 0, current => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => $DEVICE_STATUS_VOLUME_UNLABELED, + device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG01XX', reserved => 1, loaded_in => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => $DEVICE_STATUS_VOLUME_UNLABELED, + device_error => undef, + f_type => undef, label => undef }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG02XX', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory is updated when slots are loaded"); }; @@ -552,22 +564,25 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'check_state_after_release1'}, [ { slot => 1, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG00XX', reserved => 1, loaded_in => 0, current => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG01XX', loaded_in => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-2' }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG02XX', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory is still up to date"); }; @@ -650,22 +665,24 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'release2'}, [ { slot => 1, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, import_export => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG00XX', reserved => 1, loaded_in => 0, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG01XX', - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-2' }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => 'PTAG02XX', reserved => 1, loaded_in => 1, current => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, ], "$pfx: inventory is up to date after more labelings"); }; diff --git a/installcheck/Amanda_Changer_robot.pl b/installcheck/Amanda_Changer_robot.pl index bed28ba..7eadaa2 100644 --- a/installcheck/Amanda_Changer_robot.pl +++ b/installcheck/Amanda_Changer_robot.pl @@ -466,18 +466,23 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'load_slot_1'}, [ { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', current => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 2, state => Amanda::Changer::SLOT_FULL, barcode => '22222', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '44444', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 5, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory is correct on start-up"); }; @@ -556,18 +561,25 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'load_slot_3'}, [ { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', reserved => 1, loaded_in => 0, current => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => $DEVICE_STATUS_VOLUME_UNLABELED, + device_error => undef, + f_type => undef, label => undef }, { slot => 2, state => Amanda::Changer::SLOT_FULL, barcode => '22222', reserved => 1, loaded_in => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => $DEVICE_STATUS_VOLUME_UNLABELED, + device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '44444', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 5, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory is updated when slots are loaded"); }; @@ -656,20 +668,23 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'check_state_after_release1'}, [ { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', reserved => 1, loaded_in => 0, current => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 2, state => Amanda::Changer::SLOT_FULL, barcode => '22222', loaded_in => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-2' }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '44444', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 5, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory is still up to date"); }; @@ -752,22 +767,24 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'release2'}, [ { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1', reserved => 1, loaded_in => 0 }, { slot => 2, state => Amanda::Changer::SLOT_FULL, barcode => '22222', - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-2' }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '44444', reserved => 1, loaded_in => 1, current => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, { slot => 5, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory is up to date after more labelings"); }; @@ -993,21 +1010,23 @@ sub test_changer { check_inventory($chg, $mtx_config->{'barcodes'} > 0, $steps->{'try_update'}, [ { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', loaded_in => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 2, state => Amanda::Changer::SLOT_FULL, barcode => '22222', loaded_in => 0, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-2' }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '44444', current => 1, - device_status => $DEVICE_STATUS_SUCCESS, + device_status => $DEVICE_STATUS_SUCCESS, device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, { slot => 5, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory still accurate"); }; @@ -1107,20 +1126,26 @@ sub test_changer { { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 2, state => Amanda::Changer::SLOT_FULL, barcode => '22222', device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'SURPRISE!' }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', loaded_in => 1, - device_status => undef, f_type => undef, label => 'TAPE-3' }, + device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, + f_type => undef, label => 'TAPE-3' }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '44444', loaded_in => 0, current => 1, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, { slot => 5, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, ], "$pfx: inventory reflects updates"); }; @@ -1207,19 +1232,25 @@ sub test_changer { { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', loaded_in => 1, - device_status => undef, f_type => undef, label => 'TAPE-3' }, + device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, + f_type => undef, label => 'TAPE-3' }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '22222', current => 1, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'SURPRISE!' }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => '44444', device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, ], "$pfx: inventory reflects the move"); }; @@ -1268,19 +1299,25 @@ sub test_changer { { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', loaded_in => 1, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', loaded_in => 0, - device_status => undef, f_type => undef, label => 'TAPE-3' }, + device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, + f_type => undef, label => 'TAPE-3' }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '22222', current => 1, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-2' }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => '44444', device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, ], "$pfx: inventory before updates with unknown state"); }; @@ -1298,19 +1335,25 @@ sub test_changer { { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', loaded_in => 1, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', loaded_in => 0, - device_status => undef, f_type => undef, label => 'TAPE-3' }, + device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, + f_type => undef, label => 'TAPE-3' }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '22222', current => 1, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-2' }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => '44444', device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, ], "$pfx: inventory reflects updates with unknown state with barcodes"); } else { @@ -1318,18 +1361,23 @@ sub test_changer { { slot => 1, state => Amanda::Changer::SLOT_FULL, barcode => '11111', loaded_in => 1, device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-1' }, { slot => 2, state => Amanda::Changer::SLOT_EMPTY, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 3, state => Amanda::Changer::SLOT_FULL, barcode => '33333', loaded_in => 0, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 4, state => Amanda::Changer::SLOT_FULL, barcode => '22222', current => 1, - device_status => undef, f_type => undef, label => undef }, + device_status => undef, device_error => undef, + f_type => undef, label => undef }, { slot => 5, state => Amanda::Changer::SLOT_FULL, barcode => '44444', device_status => $DEVICE_STATUS_SUCCESS, + device_error => undef, f_type => $Amanda::Header::F_TAPESTART, label => 'TAPE-4' }, ], "$pfx: inventory reflects updates with unknown state without barcodes"); } diff --git a/installcheck/Amanda_Device.pl b/installcheck/Amanda_Device.pl index 363a17e..7fdccef 100644 --- a/installcheck/Amanda_Device.pl +++ b/installcheck/Amanda_Device.pl @@ -16,7 +16,7 @@ # Contact information: Zmanda Inc, 465 S. Mathilda Ave., Suite 300 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com -use Test::More tests => 582; +use Test::More tests => 593; use File::Path qw( mkpath rmtree ); use Sys::Hostname; use Carp; @@ -250,6 +250,9 @@ ok($dev->property_set("comment", "32k"), ok($dev->property_set("block_size", 32768), "set an integer property to an integer"); +ok(!($dev->property_set("invalid-property-name", 32768)), + "set an invalid-property-name"); + $dev->read_label(); ok($dev->status() & $DEVICE_STATUS_VOLUME_UNLABELED, "initially unlabeled") @@ -732,7 +735,7 @@ my $base_name; SKIP: { skip "define \$INSTALLCHECK_S3_{SECRET,ACCESS}_KEY to run S3 tests", - 91 + + 101 + 1 * $verify_file_count + 7 * $write_file_count + 13 * $s3_make_device_count @@ -1121,6 +1124,22 @@ SKIP: { ok(!$dev->property_set('S3_BUCKET_LOCATION', 'EU'), "should not be able to set S3 bucket location with an incompatible name") or diag($dev->error_or_status()); + + $dev_name = lc("s3:$base_name-s3-eu"); + $dev = s3_make_device($dev_name, "s3"); + ok($dev->property_set('S3_BUCKET_LOCATION', 'XYZ'), + "should be able to set S3 bucket location with a compatible name") + or diag($dev->error_or_status()); + $dev->read_label(); + $status = $dev->status(); + ok(($status == $DEVICE_STATUS_DEVICE_ERROR), + "status is DEVICE_STATUS_DEVICE_ERROR") + or diag($dev->error_or_status()); + my $error_msg = $dev->error_or_status(); + ok(($dev->error_or_status() == "While creating new S3 bucket: The specified location-constraint is not valid (Unknown) (HTTP 400)"), + "invalid location-constraint") + or diag("bad error: " . $dev->error_or_status()); + } SKIP: { diff --git a/installcheck/Amanda_Tapelist.pl b/installcheck/Amanda_Tapelist.pl index 02e6fb4..1509ed9 100644 --- a/installcheck/Amanda_Tapelist.pl +++ b/installcheck/Amanda_Tapelist.pl @@ -64,8 +64,8 @@ sub readtapelist { @lines = ( "20071111010002 TESTCONF004 reuse META:META1\n", - "20071110010002 TESTCONF003 reuse BARCODE:BAR-003\n", - "20071109010002 TESTCONF002 reuse BARCODE:BAR-002 META:META2 #comment 2\n", + "20071110010002 TESTCONF003 reuse BARCODE:BAR-003 BLOCKSIZE:32\n", + "20071109010002 TESTCONF002 reuse BARCODE:BAR-002 META:META2 BLOCKSIZE:64 #comment 2\n", "20071108010001 TESTCONF001 no-reuse #comment 1\n", ); mktapelist($tapelist, @lines); @@ -76,16 +76,16 @@ $tl_ok = is_deeply($tl, { lockname => $tapelist . ".lock", tles => [ { 'datestamp' => '20071111010002', 'label' => 'TESTCONF004', - 'reuse' => 1, 'position' => 1, + 'reuse' => 1, 'position' => 1, 'blocksize' => undef, 'barcode' => undef, 'meta' => 'META1', 'comment' => undef }, { 'datestamp' => '20071110010002', 'label' => 'TESTCONF003', - 'reuse' => 1, 'position' => 2, + 'reuse' => 1, 'position' => 2, 'blocksize' => '32', 'barcode' => 'BAR-003', 'meta' => undef, 'comment' => undef }, { 'datestamp' => '20071109010002', 'label' => 'TESTCONF002', - 'reuse' => 1, 'position' => 3, + 'reuse' => 1, 'position' => 3, 'blocksize' => '64', 'barcode' => 'BAR-002', 'meta' => 'META2', 'comment' => 'comment 2' }, { 'datestamp' => '20071108010001', 'label' => 'TESTCONF001', - 'reuse' => '', 'position' => 4, + 'reuse' => '', 'position' => 4, 'blocksize' => undef, 'barcode' => undef, 'meta' => undef, 'comment' => 'comment 1' }, ] }, "A simple tapelist is parsed correctly"); @@ -100,7 +100,7 @@ SKIP: { is_deeply($tl->lookup_tapelabel('TESTCONF002'), { 'datestamp' => '20071109010002', 'label' => 'TESTCONF002', - 'reuse' => 1, 'position' => 3, + 'reuse' => 1, 'position' => 3, 'blocksize' => '64', 'barcode' => 'BAR-002', 'meta' => 'META2', 'comment' => 'comment 2' }, "lookup_tapelabel works"); @@ -109,7 +109,7 @@ SKIP: { is_deeply($tl->lookup_tapepos(4), { 'datestamp' => '20071108010001', 'label' => 'TESTCONF001', - 'reuse' => '', 'position' => 4, + 'reuse' => '', 'position' => 4, 'blocksize' => undef, 'barcode' => undef, 'meta' => undef, 'comment' => 'comment 1' }, "lookup_tapepos works"); @@ -118,7 +118,7 @@ SKIP: { is_deeply($tl->lookup_tapedate('20071110010002'), { 'datestamp' => '20071110010002', 'label' => 'TESTCONF003', - 'reuse' => 1, 'position' => 2, + 'reuse' => 1, 'position' => 2, 'blocksize' => '32', 'barcode' => 'BAR-003', 'meta' => undef, 'comment' => undef }, "lookup_tapedate works"); @@ -131,29 +131,29 @@ SKIP: { is_deeply($tl->lookup_tapepos(1), { 'datestamp' => '20080112010203', 'label' => 'TESTCONF007', - 'reuse' => 1, 'position' => 1, + 'reuse' => 1, 'position' => 1, 'blocksize' => undef, 'barcode' => 'BAR-007', 'meta' => 'META3', 'comment' => 'seven' }, ".. lookup_tapepos finds it at the beginning"); is_deeply($tl->lookup_tapelabel("TESTCONF007"), { 'datestamp' => '20080112010203', 'label' => 'TESTCONF007', - 'reuse' => 1, 'position' => 1, + 'reuse' => 1, 'position' => 1, 'blocksize' => undef, 'barcode' => 'BAR-007', 'meta' => 'META3' , 'comment' => 'seven' }, ".. lookup_tapelabel finds it"); is_deeply($tl->lookup_tapedate("20080112010203"), { 'datestamp' => '20080112010203', 'label' => 'TESTCONF007', - 'reuse' => 1, 'position' => 1, + 'reuse' => 1, 'position' => 1, 'blocksize' => undef, 'barcode' => 'BAR-007', 'meta' => 'META3', 'comment' => 'seven' }, ".. lookup_tapedate finds it"); # try some edits - $tl->add_tapelabel("20080112010204", "TESTCONF008", "eight", 0); + $tl->add_tapelabel("20080112010204", "TESTCONF008", "eight", 0, undef, undef, 128); is(scalar @{$tl->{'tles'}}, 6, "add_tapelabel adds a new element to the tapelist no-reuse"); is_deeply($tl->lookup_tapelabel("TESTCONF008"), { 'datestamp' => '20080112010204', 'label' => 'TESTCONF008', - 'reuse' => 0, 'position' => 1, + 'reuse' => 0, 'position' => 1, 'blocksize' => '128', 'barcode' => undef, 'meta' => undef, 'comment' => 'eight' }, ".. lookup_tapelabel finds it no-reuse"); @@ -165,7 +165,7 @@ SKIP: { is_deeply($tl->lookup_tapepos(4), # used to be in position 5 { 'datestamp' => '20071108010001', 'label' => 'TESTCONF001', - 'reuse' => '', 'position' => 4, + 'reuse' => '', 'position' => 4, 'blocksize' => undef, 'barcode' => undef, 'meta' => undef, 'comment' => 'comment 1' }, ".. tape positions are adjusted correctly"); @@ -180,13 +180,13 @@ SKIP: { is_deeply($tl->lookup_tapepos(4), { 'datestamp' => '20071109010204', 'label' => 'TESTCONF009', - 'reuse' => '1', 'position' => 4, + 'reuse' => '1', 'position' => 4, 'blocksize' => undef, 'barcode' => undef, 'meta' => undef, 'comment' => 'nine' }, ".. tape positions are adjusted correctly"); is_deeply($tl->lookup_tapelabel('TESTCONF009'), { 'datestamp' => '20071109010204', 'label' => 'TESTCONF009', - 'reuse' => '1', 'position' => 4, + 'reuse' => '1', 'position' => 4, 'blocksize' => undef, 'barcode' => undef, 'meta' => undef, 'comment' => 'nine' }, ".. tape positions are adjusted correctly"); @@ -222,7 +222,7 @@ is_deeply($tl, { lockname => $tapelist . ".lock", tles => [ { 'datestamp' => '2006123456', 'label' => 'FOO', - 'reuse' => 1, 'position' => 1, + 'reuse' => 1, 'position' => 1, 'blocksize' => undef, 'barcode' => undef, 'meta' => undef, 'comment' => undef }, ] }, "Invalid lines are ignored"); @@ -238,7 +238,7 @@ is_deeply($tl, { lockname => $tapelist . ".lock", tles => [ { 'datestamp' => '2006123456', 'label' => 'FOO', - 'reuse' => 1, 'position' => 1, + 'reuse' => 1, 'position' => 1, 'blocksize' => undef, 'barcode' => undef, 'meta' => undef, 'comment' => undef }, ] }, "reload works"); diff --git a/installcheck/Installcheck/Changer.pm b/installcheck/Installcheck/Changer.pm index 00104f0..3864868 100644 --- a/installcheck/Installcheck/Changer.pm +++ b/installcheck/Installcheck/Changer.pm @@ -71,7 +71,7 @@ sub chg_err_like { like($err->{'message'}, $expected, $msg); } else { my $ok = 1; - for my $key qw( type reason message ) { + for my $key (qw( type reason message )) { if (exists $expected->{$key}) { if (!exists $err->{$key}) { fail($msg) if ($ok); diff --git a/installcheck/Makefile.in b/installcheck/Makefile.in index 072d47e..73b4c83 100644 --- a/installcheck/Makefile.in +++ b/installcheck/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -374,6 +374,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -806,6 +807,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -855,6 +857,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -863,6 +866,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -870,6 +874,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1014,6 +1020,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1047,6 +1054,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1089,7 +1097,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/installcheck/amcheck-device.pl b/installcheck/amcheck-device.pl index 552790d..02f1acb 100644 --- a/installcheck/amcheck-device.pl +++ b/installcheck/amcheck-device.pl @@ -16,12 +16,12 @@ # Contact information: Zmanda Inc, 465 S. Mathilda Ave., Suite 300 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com -use Test::More tests => 3; +use Test::More tests => 4; use strict; use warnings; use lib "@amperldir@"; -use Installcheck::Run qw(run run_get); +use Installcheck::Run qw(run run_get run_err); use Amanda::Config qw( :init :getconf ); use Amanda::Paths; use Amanda::Debug; @@ -45,3 +45,12 @@ ok(!run("$amlibexecdir/amcheck-device", "TESTCONF", "-o", "autolabel="), like(run_get("$amlibexecdir/amcheck-device", "TESTCONF", "-w"), qr/Volume 'TESTCONF01' is writeable/, "tests for writeability with -w"); + +$testconf = Installcheck::Run::setup(); +$testconf->add_param("autolabel", "\"TESTCONF-\$4s\" empty volume_error"); +$testconf->write(); + +like(run_err("$amlibexecdir/amcheck-device", "TESTCONF"), + qr/ERROR: Newly-generated label 'TESTCONF-0001' does not match labelstr 'TESTCONF\[0-9\]\[0-9\]'/m, + "a run with incompatible autolabel and labelstr"); + diff --git a/installcheck/amgetconf.pl b/installcheck/amgetconf.pl index 3d7f8d8..5ae66d9 100644 --- a/installcheck/amgetconf.pl +++ b/installcheck/amgetconf.pl @@ -16,7 +16,7 @@ # Contact information: Zmanda Inc, 465 S. Mathilda Ave., Suite 300 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com -use Test::More tests => 82; +use Test::More tests => 86; use strict; use warnings; @@ -335,5 +335,20 @@ is_deeply([sort(+split(qr/\n/, run_get('amgetconf', 'TESTCONF', 'dumptype:testdu is_deeply([sort(+split(qr/\n/, run_get('amgetconf', 'TESTCONF', 'dumptype:testdump:include')))], [sort('FILE OPTIONAL "ifo"', 'LIST OPTIONAL "ilo"')], - "a final 'OPTIONAL' makes the whole include/exclude optional") + "a final 'OPTIONAL' makes the whole include/exclude optional"); + +$testconf = Installcheck::Config->new(); +$testconf->add_param("property", '"prop1" "value1"'); +$testconf->add_param("property", '"prop2" "value2"'); +$testconf->add_param("property", '"prop3" "value3"'); +$testconf->write(); + +is(run_get('amgetconf', 'TESTCONF', "property:prop1"), "value1", + "correctly returns property prop1 from the file"); +is(run_get('amgetconf', 'TESTCONF', "property:prop2"), "value2", + "correctly returns property prop2 from the file"); +is(run_get('amgetconf', 'TESTCONF', "property:prop3"), "value3", + "correctly returns property prop3 from the file"); +is(run_get('amgetconf', 'TESTCONF', "property"), "\"prop1\" \"value1\"\n\"prop2\" \"value2\"\n\"prop3\" \"value3\"", + "correctly returns all propertiss from the file"); diff --git a/installcheck/amlabel.pl b/installcheck/amlabel.pl index 791f232..5326f0b 100644 --- a/installcheck/amlabel.pl +++ b/installcheck/amlabel.pl @@ -82,6 +82,7 @@ is_deeply($tl->{'tles'}->[0], { 'reuse' => 1, 'barcode' => undef, 'meta' => undef, + 'blocksize' => '32', 'comment' => undef, 'position' => 1, 'label' => 'TESTCONF92', @@ -145,6 +146,7 @@ is_deeply($tl->{'tles'}->[0], { 'reuse' => 1, 'barcode' => 'bar-01', 'meta' => 'meta-01', + 'blocksize' => undef, 'comment' => undef, 'position' => 1, 'label' => 'TESTCONF88', @@ -167,6 +169,7 @@ is_deeply($tl->{'tles'}->[0], { 'reuse' => 1, 'barcode' => undef, 'meta' => 'meta-01', + 'blocksize' => '32', 'comment' => undef, 'position' => 1, 'label' => 'TESTCONF01', diff --git a/installcheck/amreport.pl b/installcheck/amreport.pl index 00faff3..3b48861 100644 --- a/installcheck/amreport.pl +++ b/installcheck/amreport.pl @@ -16,10 +16,11 @@ # Contact information: Zmanda Inc, 465 S. Mathilda Ave., Suite 300 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com -use Test::More tests => 166; +use Test::More tests => 167; use strict; use warnings; +use Errno; use Cwd qw(abs_path); use lib "@amperldir@"; @@ -521,6 +522,11 @@ ok(run($amreport, 'TESTCONF', '--from-amdump'), or diag($Installcheck::Run::stderr); ok(!-f $mail_output, "..produces no mail output"); is($Installcheck::Run::stdout, "", "..produces no stdout output"); +$! = &Errno::ENOENT; +my $enoent = $!; +like($Installcheck::Run::stderr, + qr/^error: the mailer '.*' is not an executable program\.$/, + "..produces correct stderr output"); results_match( $printer_output, $cat->get_text('postscript'), diff --git a/installcheck/amtape.pl b/installcheck/amtape.pl index cc7efd6..3220e70 100644 --- a/installcheck/amtape.pl +++ b/installcheck/amtape.pl @@ -16,7 +16,7 @@ # Contact information: Zmanda Inc, 465 S. Mathilda Ave., Suite 300 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com -use Test::More tests => 42; +use Test::More tests => 46; use strict; use warnings; @@ -148,13 +148,26 @@ ok(run('amtape', 'TESTCONF', 'show'), "'amtape TESTCONF show'"); like($Installcheck::Run::stderr, qr/slot +2:.*label MyTape\nslot +3/, - "..result correct"); + "'amtape TESTCONF show' ..result correct"); + +ok(run('amtape', 'TESTCONF', 'show', '2'), + "'amtape TESTCONF show'"); +like($Installcheck::Run::stderr, + qr/^slot +2:.*label MyTape$/, + "'amtape TESTCONF show 2' ..result correct"); + +ok(run('amtape', 'TESTCONF', 'show', '1,3'), + "'amtape TESTCONF show'"); +like($Installcheck::Run::stderr, + qr/^slot +1: unlabeled volume\nslot +3: date \d{14} label TESTCONF13$/, +# qr/slot +1: unlabeled volume\nslot +3: date 20111121133419 label TESTCONF13/, + "'amtape TESTCONF show 1,3' ..result correct"); ok(run('amtape', 'TESTCONF', 'taper'), "'amtape TESTCONF taper'"); like($Installcheck::Run::stderr, - qr/Will write to volume TESTCONF13 in slot 3/, - "..result correct"); + qr/Will write to volume 'TESTCONF13' in slot 3/, + "'amtape TESTCONF taper' ..result correct"); ### ## shift to using the new Amanda::Changer::disk @@ -221,7 +234,7 @@ like($Installcheck::Run::stdout, ok(run('amtape', 'TESTCONF', 'taper'), "'amtape TESTCONF taper'"); like($Installcheck::Run::stderr, - qr/Will write to volume TESTCONF13 in slot 3/, - "..result correct"); + qr/Will write to volume 'TESTCONF13' in slot 3/, + "'amtape TESTCONF taper' ..result correct"); Installcheck::Run::cleanup(); diff --git a/installcheck/catalogs/longstrange.cat b/installcheck/catalogs/longstrange.cat index 73e5ca3..70f0f4b 100644 --- a/installcheck/catalogs/longstrange.cat +++ b/installcheck/catalogs/longstrange.cat @@ -1165,6 +1165,11 @@ sendbackup: info end | x | x | x +| x +| x +| x +| x +| x \\-------- 913 lines follow, see the corresponding log.* file for the complete list \\-------- diff --git a/installcheck/gnutar.pl b/installcheck/gnutar.pl index 886fd08..4136780 100644 --- a/installcheck/gnutar.pl +++ b/installcheck/gnutar.pl @@ -76,6 +76,21 @@ my ($v, $numeric_version); $numeric_version += $maj * 10000 if $maj; $numeric_version += $min * 100 if $min; $numeric_version += $mic if $mic; + +} + +my ($fc14, $fc15); +{ + my $uname = `uname -a`; + if ($uname =~ /\.fc14\./) { + $fc14 = 1; + } + if ($uname =~ /\.fc15\./) { + $fc15 = 1; + } + if ($uname =~ /\.fc16\./) { #like fc15 + $fc15 = 1; + } } # see if the default for --wildcards during inclusion has been changed @@ -99,8 +114,10 @@ my %version_classes = ( '>=1.23' => $numeric_version >= 12300, '*' => 1, '1.23' => ($numeric_version >= 12290 and $numeric_version <= 12300), + '1.23fc14' => ($numeric_version == 12300 and $fc14), '!1.23' => ($numeric_version < 12290 || ($numeric_version > 12300 && $numeric_version < 12500)), - '>=1.25' => $numeric_version >= 12500. + '>=1.25' => $numeric_version >= 12500, + 'fc15' => ($numeric_version >= 12500 and $fc15), ); # include and exclude all use the same set of patterns and filenames @@ -135,28 +152,29 @@ my $named_expectations = [ 'epsilon', 'zeta', 'eta', - 'empty', ], - # al be ga de ep ze et empty - [ 1, 1, 1, 1, 1, 1, 1, 1, ], # './A*A' => 'A*A', - [ 1, 1, 1, 1, 0, 1, 1, 0, ], # './A*A' => 'AxA', - [ 1, 1, 1, 1, 1, 1, 1, 1, ], # './B?B' => 'B?B', - [ 1, 1, 1, 1, 0, 1, 1, 0, ], # './B?B' => 'BxB', - [ 0, 0, 0, 0, 1, 1, 1, 1, ], # './C[C' => 'C[C', - [ 1, 1, 1, 1, 1, 1, 1, 1, ], # './D]D' => 'D]D', - [ 1, 0, 0, 1, 1, 0, 0, 1, ], # './E\\E' => 'E\\E', - [ 1, 1, 1, 1, 1, 1, 1, 1, ], # './F\'F' => 'F\'F', - [ 1, 1, 1, 1, 1, 1, 1, 1, ], # './G"G' => 'G"G', - [ 1, 1, 1, 1, 1, 1, 1, 1, ], # './H H' => 'H H', - [ 1, 1, 1, 0, 0, 1, 1, 0, ], # './A\\*A' => 'A*A', - [ 0, 0, 0, 0, 0, 0, 0, 0, ], # './A\\*A' => 'AxA', - [ 0, 0, 1, 0, 0, 0, 1, 0, ], # './B\\?B' => 'B?B', - [ 0, 0, 0, 0, 0, 0, 0, 0, ], # './B\\?B' => 'BxB', - [ 1, 1, 1, 0, 0, 1, 1, 0, ], # './C\\[C' => 'C[C', - [ 0, 1, 1, 0, 0, 1, 1, 0, ], # './D\\]D' => 'D]D', - [ 1, 0, 1, 0, 1, 0, 1, 0, ], # './E\\\\E' => 'E\\E', - [ 0, 1, 1, 0, 0, 1, 1, 0, ], # './F\\\'F' => 'F\'F', - [ 0, 1, 1, 0, 0, 1, 1, 0, ], # './G\\"G' => 'G"G', - [ 0, 1, 1, 0, 0, 1, 1, 0, ], # './H\\ H' => 'H H', + 'iota', + 'empty', ], + # al be ga de ep ze et io empty + [ 1, 1, 1, 1, 1, 1, 1, 1, 1, ], # './A*A' => 'A*A', + [ 1, 1, 1, 1, 0, 1, 1, 1, 0, ], # './A*A' => 'AxA', + [ 1, 1, 1, 1, 1, 1, 1, 1, 1, ], # './B?B' => 'B?B', + [ 1, 1, 1, 1, 0, 1, 1, 1, 0, ], # './B?B' => 'BxB', + [ 0, 0, 0, 0, 1, 1, 1, 1, 1, ], # './C[C' => 'C[C', + [ 1, 1, 1, 1, 1, 1, 1, 1, 1, ], # './D]D' => 'D]D', + [ 1, 0, 0, 1, 1, 0, 0, 1, 1, ], # './E\\E' => 'E\\E', + [ 1, 1, 1, 1, 1, 1, 1, 1, 1, ], # './F\'F' => 'F\'F', + [ 1, 1, 1, 1, 1, 1, 1, 1, 1, ], # './G"G' => 'G"G', + [ 1, 1, 1, 1, 1, 1, 1, 1, 1, ], # './H H' => 'H H', + [ 1, 1, 1, 0, 0, 1, 1, 0, 0, ], # './A\\*A' => 'A*A', + [ 0, 0, 0, 0, 0, 0, 0, 0, 0, ], # './A\\*A' => 'AxA', + [ 0, 0, 1, 0, 0, 0, 1, 0, 0, ], # './B\\?B' => 'B?B', + [ 0, 0, 0, 0, 0, 0, 0, 0, 0, ], # './B\\?B' => 'BxB', + [ 1, 1, 1, 0, 0, 1, 1, 0, 0, ], # './C\\[C' => 'C[C', + [ 0, 1, 1, 0, 0, 1, 1, 0, 0, ], # './D\\]D' => 'D]D', + [ 1, 0, 1, 0, 1, 0, 1, 0, 0, ], # './E\\\\E' => 'E\\E', + [ 0, 1, 1, 0, 0, 1, 1, 0, 0, ], # './F\\\'F' => 'F\'F', + [ 0, 1, 1, 0, 0, 1, 1, 0, 0, ], # './G\\"G' => 'G"G', + [ 0, 1, 1, 0, 0, 1, 1, 0, 0, ], # './H\\ H' => 'H H', ]; sub get_expectation { @@ -187,9 +205,11 @@ sub get_matching_type { my ($expectations) = @_; # find the type for the first matching version - for (keys %$expectations) { - if ($version_classes{$_}) { - return $expectations->{$_}; + foreach my $exp (@$expectations) { + foreach (keys %$exp) { + if ($version_classes{$_}) { + return $exp->{$_}; + } } } return undef; @@ -313,54 +333,60 @@ sub test_gnutar_inclusion { test_gnutar_inclusion( extra_args => [], - expectations => { - '<1.16' => 'alpha', - '>=1.16-no-wc' => 'epsilon', - '>=1.16-wc' => 'beta', # acts like --wildcards - }, + expectations => [ + {'<1.16' => 'alpha'}, + {'1.23fc14' => 'zeta'}, + {'fc15' => 'zeta'}, + {'>=1.16-no-wc' => 'epsilon'}, + {'>=1.16-wc' => 'beta'}, # acts like --wildcards + ], ); test_gnutar_inclusion( extra_args => [ '--no-wildcards' ], - expectations => { - '<1.16' => 'alpha', - '>=1.16' => 'epsilon', - }, + expectations => [ + {'<1.16' => 'alpha'}, + {'>=1.16' => 'epsilon'}, + ], ); test_gnutar_inclusion( extra_args => [ '--no-unquote' ], - expectations => { - '<1.16' => undef, - '>=1.16-no-wc' => 'empty', - '>=1.16-wc' => 'gamma', # acts like --wildcards --no-unquote - }, + expectations => [ + {'<1.16' => undef}, + {'1.23fc14' => 'eta'}, + {'fc15' => 'eta'}, + {'>=1.16-no-wc' => 'empty'}, + {'>=1.16-wc' => 'gamma'}, # acts like --wildcards --no-unquote + ], ); test_gnutar_inclusion( extra_args => [ '--no-wildcards', '--no-unquote' ], - expectations => { - '<1.16' => undef, - '>=1.16' => 'empty', - }, + expectations => [ + {'<1.16' => undef}, + {'>=1.16' => 'empty'}, + ], ); test_gnutar_inclusion( extra_args => [ '--wildcards' ], - expectations => { - '<1.16' => 'alpha', - '1.16..<1.25' => 'beta', - '>=1.25' => 'zeta', - }, + expectations => [ + {'<1.16' => 'alpha'}, + {'1.23fc14' => 'zeta'}, + {'1.16..<1.25' => 'beta'}, + {'>=1.25' => 'zeta'}, + ], ); test_gnutar_inclusion( extra_args => [ '--wildcards', '--no-unquote' ], - expectations => { - '<1.16' => undef, - '1.16..<1.25' => 'gamma', - '>=1.25' => 'eta', - }, + expectations => [ + {'<1.16' => undef}, + {'1.23fc14' => 'eta'}, + {'1.16..<1.25' => 'gamma'}, + {'>=1.25' => 'eta'}, + ], ); ## exclusion tests (using -t and filenames on the command line) @@ -467,19 +493,20 @@ sub test_gnutar_exclusion { # --wildcards test_gnutar_exclusion( extra_args => [], - expectations => { - '!1.23' => 'gamma', - '1.23' => 'delta', - '>=1.25' => 'eta', - }, + expectations => [ + {'!1.23' => 'gamma'}, + {'1.23fc14' => 'iota'}, + {'1.23' => 'delta'}, + {'>=1.25' => 'eta'}, + ], ); # --no-wildcards test_gnutar_exclusion( extra_args => [ '--no-wildcards' ], - expectations => { - '*' => 'empty', - }, + expectations => [ + {'*' => 'empty'}, + ], ); ## list (-t) diff --git a/installcheck/mock/mtx.pl b/installcheck/mock/mtx.pl index b8dce83..e2bedf9 100644 --- a/installcheck/mock/mtx.pl +++ b/installcheck/mock/mtx.pl @@ -81,7 +81,7 @@ sub load_statefile { } # make sure some things are zero if they're not defined - for my $k qw(num_drives num_slots num_ie first_drive first_slot first_ie) { + for my $k (qw(num_drives num_slots num_ie first_drive first_slot first_ie)) { $CONFIG->{$k} = 0 unless defined $CONFIG->{$k}; } } diff --git a/man/Makefile.am b/man/Makefile.am index 9e428d5..79106bd 100644 --- a/man/Makefile.am +++ b/man/Makefile.am @@ -42,6 +42,7 @@ SERVER_MAN_PAGES = \ amcheckdb.8 \ amcheckdump.8 \ amcleanup.8 \ + amcleanupdisk.8 \ amcrypt-ossl-asym.8 \ amcrypt-ossl.8 \ amcrypt.8 \ diff --git a/man/Makefile.in b/man/Makefile.in index bfae62e..d396ddd 100644 --- a/man/Makefile.in +++ b/man/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -293,6 +293,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -725,6 +726,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -774,6 +776,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -782,6 +785,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -789,6 +793,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -933,6 +939,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -966,6 +973,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1008,7 +1016,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -1061,6 +1068,7 @@ SERVER_MAN_PAGES = \ amcheckdb.8 \ amcheckdump.8 \ amcleanup.8 \ + amcleanupdisk.8 \ amcrypt-ossl-asym.8 \ amcrypt-ossl.8 \ amcrypt.8 \ diff --git a/man/amaddclient.8 b/man/amaddclient.8 index 0e2fd99..9272624 100644 --- a/man/amaddclient.8 +++ b/man/amaddclient.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amaddclient .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMADDCLIENT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMADDCLIENT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -54,7 +63,7 @@ must be run by user amandabackup\&. .PP .RS 4 -Options may be abbreviated, as long as the abbreviation is not ambiguous\&. Option argument can either separated by \'=\' or a space\&. +Options may be abbreviated, as long as the abbreviation is not ambiguous\&. Option argument can either separated by \*(Aq=\*(Aq or a space\&. Example: \-\-conf=v253, \-\-client client8\&.zmanda\&.com .RE .PP diff --git a/man/amadmin.8 b/man/amadmin.8 index c31b2ac..85513f0 100644 --- a/man/amadmin.8 +++ b/man/amadmin.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amadmin .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMADMIN" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMADMIN" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -189,11 +198,11 @@ Delete holding files matching the given specification\&. At least a hostname mus .RS 4 List holding files matching the given dump specification, or all holding files if no specification is provided\&. See \fBamanda-match\fR(7) -for more information on dump specifications\&. With \'\-l\', additional information (size, level, and whether the dump is outdated) is provided\&. With \'\-d\', only outdated dumps are shown\&. +for more information on dump specifications\&. With \*(Aq\-l\*(Aq, additional information (size, level, and whether the dump is outdated) is provided\&. With \*(Aq\-d\*(Aq, only outdated dumps are shown\&. .sp An outdated holding file is one which is not required for a restore of the \fImost recent\fR -dump\&. Note that outdated dumps may still be required for restores at earlier dates\&. For example, assume that a DLE had a level 0 on Monday, level 1\'s Tuesday through Thursday, and a level 2 on Friday\&. Then the files required for a restore of Fridays (the most recent) dump are those from Monday (level 0), Thursday (level 1), and Friday (level 2)\&. Tuesday and Wednesday\'s files are outdated\&. +dump\&. Note that outdated dumps may still be required for restores at earlier dates\&. For example, assume that a DLE had a level 0 on Monday, level 1\*(Aqs Tuesday through Thursday, and a level 2 on Friday\&. Then the files required for a restore of Fridays (the most recent) dump are those from Monday (level 0), Thursday (level 1), and Friday (level 2)\&. Tuesday and Wednesday\*(Aqs files are outdated\&. .RE .PP \fBdelete\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+ @@ -355,7 +364,7 @@ file, Amanda will treat it as a new disk during the next run\&. .nf $ amadmin daily delete machine\-d /workspace amadmin: machine\-d:/workspace deleted from database\&. -amadmin: NOTE: you\'ll have to remove these from the \fBdisklist\fR(5) yourself\&. +amadmin: NOTE: you\*(Aqll have to remove these from the \fBdisklist\fR(5) yourself\&. .fi .PP Find the next tape Amanda will use (in this case, @@ -377,7 +386,7 @@ show the estimated total size of the backups before and after any compression, r .PP The \fIbalance\fR -column shows how far off that night\'s backups are from the average size (shown at the bottom of the balance column)\&. Amanda tries to keep the backups within +/\- 5%, but since the amount of data on each filesystem is always changing, and Amanda will never delay backups just to rebalance the schedule, it is common for the schedule to fluctuate by larger percentages\&. In particular, in the case of a tape or backup failure, a bump will occur the following night, which will not be smoothed out until the next pass through the schedule\&. +column shows how far off that night\*(Aqs backups are from the average size (shown at the bottom of the balance column)\&. Amanda tries to keep the backups within +/\- 5%, but since the amount of data on each filesystem is always changing, and Amanda will never delay backups just to rebalance the schedule, it is common for the schedule to fluctuate by larger percentages\&. In particular, in the case of a tape or backup failure, a bump will occur the following night, which will not be smoothed out until the next pass through the schedule\&. .PP The last line also shows an estimate of how many Amanda runs will be made between full backups for a file system\&. In the example, a file system will probably have a full backup done every eight times Amanda is run (e\&.g\&. every eight days)\&. .nf diff --git a/man/amaespipe.8 b/man/amaespipe.8 index 8f3cb02..c01a2d4 100644 --- a/man/amaespipe.8 +++ b/man/amaespipe.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amaespipe .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMAESPIPE" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMAESPIPE" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -47,7 +56,7 @@ for Amanda data encryption\&. .PP \fBamaespipe\fR -is based on aespipe\'s bzaespipe program\&. It calls aespipe to encrypt data using AES256 as the encryption and SHA256 as the hash function\&. GPG key should be stored in $AMANDA_HOME/\&.gnupg/am_key\&.gpg\&. +is based on aespipe\*(Aqs bzaespipe program\&. It calls aespipe to encrypt data using AES256 as the encryption and SHA256 as the hash function\&. GPG key should be stored in $AMANDA_HOME/\&.gnupg/am_key\&.gpg\&. \fBamaespipe\fR reads passphrase from file descriptor 3\&. During decryption, \fBamaespipe\fR diff --git a/man/amanda-applications.7 b/man/amanda-applications.7 index 8500a83..a43f7f8 100644 --- a/man/amanda-applications.7 +++ b/man/amanda-applications.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-applications .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-APPLICATIONS" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-APPLICATIONS" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -48,7 +57,7 @@ This section lists the applications included with Amanda\&. See the individual m .IP \(bu 2.3 .\} \fBampgsql\fR(8), -\- use PostgreSQL\'s continuous WAL archiving\&. +\- use PostgreSQL\*(Aqs continuous WAL archiving\&. .RE .sp .RS 4 @@ -108,7 +117,7 @@ This section lists the applications included with Amanda\&. See the individual m .IP \(bu 2.3 .\} \fBamzfs-sendrecv\fR(8), -\- use zfs to create a snapshot and use \'zfs send\' to generate the backup\&. +\- use zfs to create a snapshot and use \*(Aqzfs send\*(Aq to generate the backup\&. .RE .sp .RS 4 diff --git a/man/amanda-archive-format.5 b/man/amanda-archive-format.5 index 3656ce2..e673887 100644 --- a/man/amanda-archive-format.5 +++ b/man/amanda-archive-format.5 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-archive-format .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: File formats and conventions -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-ARCHIVE\-FOR" "5" "06/02/2011" "Amanda 3\&.3\&.0" "File formats and conventions" +.TH "AMANDA\-ARCHIVE\-FOR" "5" "02/21/2012" "Amanda 3\&.3\&.1" "File formats and conventions" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -38,7 +47,7 @@ A header record has a fixed size of 28 bytes, as follows: .nf 28 bytes: magic string .fi -The magic string is the ASCII text "AMANDA ARCHIVE FORMAT " followed by a decimal representation of the format version number (currently \'1\'), padded to 28 bytes with NUL bytes\&. +The magic string is the ASCII text "AMANDA ARCHIVE FORMAT " followed by a decimal representation of the format version number (currently \*(Aq1\*(Aq), padded to 28 bytes with NUL bytes\&. .PP A data record has a variable size, as follows: .sp diff --git a/man/amanda-auth.7 b/man/amanda-auth.7 index 098d5d8..b9d3933 100644 --- a/man/amanda-auth.7 +++ b/man/amanda-auth.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-auth .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-AUTH" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-AUTH" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -106,7 +115,7 @@ There are additional configure options for Kerberos if you so desire\&. All but \-\-with\-krb5\-security=DIR where libkrb\&.a lives [see below] .fi .PP -If configuring with \-\-with\-krb5\-security, the configure script will search under /usr/kerberos/lib, /usr/cygnus/lib, /usr/lib, and /opt/kerberos/lib for the kerberos bits, libkrb\&.a, in this order\&. Kerberos support will not be added if it does not find them\&. If the kerberos bits are found under some other hierarchy, you can specify this via \-\-with\-krb5\-security=DIR where DIR is where the kerberos bits live\&. The configure script will then look in the \'lib\' directory under this hierarchy for libkrb\&.a\&. +If configuring with \-\-with\-krb5\-security, the configure script will search under /usr/kerberos/lib, /usr/cygnus/lib, /usr/lib, and /opt/kerberos/lib for the kerberos bits, libkrb\&.a, in this order\&. Kerberos support will not be added if it does not find them\&. If the kerberos bits are found under some other hierarchy, you can specify this via \-\-with\-krb5\-security=DIR where DIR is where the kerberos bits live\&. The configure script will then look in the \*(Aqlib\*(Aq directory under this hierarchy for libkrb\&.a\&. .PP The \fBauth\fR @@ -115,10 +124,10 @@ parameter selects a communication/authentication method to use between the clien .PP When Amanda is built, a username is specified with the \fB\-\-with\-user\fR -option\&. Most Amanda processes run under this user\'s identity, to minimize security risks\&. In binary distributions, this username is usually one of \'amanda\', \'amandabackup\', or \'backup\'\&. The examples below use \'amandabackup\' since it is unambiguous\&. You may need to adjust accordingly for your system\&. +option\&. Most Amanda processes run under this user\*(Aqs identity, to minimize security risks\&. In binary distributions, this username is usually one of \*(Aqamanda\*(Aq, \*(Aqamandabackup\*(Aq, or \*(Aqbackup\*(Aq\&. The examples below use \*(Aqamandabackup\*(Aq since it is unambiguous\&. You may need to adjust accordingly for your system\&. .SS "Authenticated Peer Hostnames" .PP -Amanda\'s authentication mechanisms provide an authenticated hostname of the system on the other end of the connection, which is used to restrict access to only particular hosts\&. The degree of "authentication" performed on this hostname varies with the authentication mechanism, and is discussed below\&. +Amanda\*(Aqs authentication mechanisms provide an authenticated hostname of the system on the other end of the connection, which is used to restrict access to only particular hosts\&. The degree of "authentication" performed on this hostname varies with the authentication mechanism, and is discussed below\&. .SH "BSD, BSDUDP, AND BSDTCP COMMUNICATION AND AUTHENTICATION" .PP For additional information including example configurations, see http://wiki\&.zmanda\&.com/index\&.php/Configuring_bsd/bsdudp/bsdtcp_authentication\&. @@ -137,7 +146,7 @@ above), the authentication method that the client is configured to receive is sp \fBauth\fR parameter in the network service configuration for Amanda\&. The authentication method used by an Amanda client to reach the server during recovery is the authentication method specified by the \fIauth\fR -parameter in the client\'s Amanda network service configuration or in its amanda\-client\&.conf file (see amanda\-client\&.conf(5))\&. +parameter in the client\*(Aqs Amanda network service configuration or in its amanda\-client\&.conf file (see amanda\-client\&.conf(5))\&. .PP By default, Amanda use the "amanda" service name and associated port set in /etc/services\&. It can be changed by setting the dumptype \fIclient\-port\fR @@ -146,7 +155,7 @@ option to a different port number or a different service name\&. All examples ar .PP Servers and clients using the bsd, bsdudp, and bsdtcp authentication methods refer to the \&.amandahosts file to control access\&. Amanda should be compiled for this access control if one of these methods will be used and is the default compilation option for Amanda 2\&.6 (use \-\-with\-amandahosts when compiling pre\-2\&.6 versions of Amanda)\&. .PP -Amanda looks for the \&.amandahosts file in the Amanda user\'s home directory, commonly /var/lib/amanda\&. +Amanda looks for the \&.amandahosts file in the Amanda user\*(Aqs home directory, commonly /var/lib/amanda\&. .PP Each authorization is on its own line in the following format .PP @@ -183,7 +192,7 @@ If service is omitted, it defaults to (which is equivalent to \fBamdump\fR)\&. .PP -Example of the \&.amandahosts file on an Amanda client, where \'amandabackup\' is the Amanda dumpuser\&. +Example of the \&.amandahosts file on an Amanda client, where \*(Aqamandabackup\*(Aq is the Amanda dumpuser\&. .sp .nf \fBamandaserver\&.example\&.com amandabackup amdump\fR @@ -196,13 +205,13 @@ Example of the \&.amandahosts file on an Amanda server .fi .SS "bsd communication and authentication" .PP -The authentication is done using \&.amandahosts file in the Amanda user\'s home directory\&. The protocol between Amanda server and client is UDP\&. The number of disk list entries (DLEs)\-\-number of Amanda clients\-\-is limited by the UDP packet size\&. This authentication protocol will use a different port for each data stream (see PORT USAGE below) +The authentication is done using \&.amandahosts file in the Amanda user\*(Aqs home directory\&. The protocol between Amanda server and client is UDP\&. The number of disk list entries (DLEs)\-\-number of Amanda clients\-\-is limited by the UDP packet size\&. This authentication protocol will use a different port for each data stream (see PORT USAGE below) .SS "bsdudp communication and authentication" .PP -The authentication is done using \&.amandahosts files in the Amanda user\'s home directory\&. It uses UDP protocol between Amanda server and client for data and hence the number of DLEs is limited by the UDP packet size\&. It uses one TCP port to establish the connection and multiplexes all data streams using one port on the server (see PORT USAGE below)\&. +The authentication is done using \&.amandahosts files in the Amanda user\*(Aqs home directory\&. It uses UDP protocol between Amanda server and client for data and hence the number of DLEs is limited by the UDP packet size\&. It uses one TCP port to establish the connection and multiplexes all data streams using one port on the server (see PORT USAGE below)\&. .SS "bsdtcp communication and authentication" .PP -The authentication is done using \&.amandahosts files in the backup user\'s (for example: amandabackup) home directory\&. It uses TCP protocol between Amanda server and client\&. On the client, two reserved ports are used\&. On the server, all data streams are multiplexed to one port (see PORT USAGE below)\&. +The authentication is done using \&.amandahosts files in the backup user\*(Aqs (for example: amandabackup) home directory\&. It uses TCP protocol between Amanda server and client\&. On the client, two reserved ports are used\&. On the server, all data streams are multiplexed to one port (see PORT USAGE below)\&. .SS "USING INETD SERVER" .PP Template for Amanda client inetd service entry @@ -440,7 +449,7 @@ and \fBamanda-client.conf\fR(5))\&. .SS "Authenticated Peer Hostnames with BSD Authentications" .PP -The BSD authentication mechanisms only verify that the remote host\'s DNS is configured correctly and that the remote user has access to reserved ports\&. As such, the peer hostname should only be trusted to the extent that the local DNS service is trusted\&. +The BSD authentication mechanisms only verify that the remote host\*(Aqs DNS is configured correctly and that the remote user has access to reserved ports\&. As such, the peer hostname should only be trusted to the extent that the local DNS service is trusted\&. .SH "KERBEROS COMMUNICATION AND AUTHENTICATION" For more detail, see http://wiki\&.zmanda\&.com/index\&.php/Kerberos_authentication\&. @@ -481,7 +490,7 @@ And the /etc/inetd\&.conf line is: k5amanda stream tcp nowait root /usr/local/libexec/amanda/amandad amandad \-auth=krb5 .fi .PP -Note that you\'re running this as root, rather than as your dump user\&. AMANDA will set its UID down to the dump user at times it doesn\'t need to read the keytab file, and give up root permissions entirely before it goes off and runs dump\&. Alternately you can change your keytab files to be readable by user amanda\&. You should understand the security implications of this before changing the permissions on the keytab\&. +Note that you\*(Aqre running this as root, rather than as your dump user\&. AMANDA will set its UID down to the dump user at times it doesn\*(Aqt need to read the keytab file, and give up root permissions entirely before it goes off and runs dump\&. Alternately you can change your keytab files to be readable by user amanda\&. You should understand the security implications of this before changing the permissions on the keytab\&. .PP The following dumptype options apply to \fBkrb5\fR: @@ -505,7 +514,7 @@ For example: krb5principal "amanda/saidin\&.omniscient\&.com" .fi .PP -The principal in the second option must be contained in the first\&. The keytab should be readable by the amanda user (and definitely not world readable!) and is (obviously) on the server\&. In MIT\'s kadmin, the following: +The principal in the second option must be contained in the first\&. The keytab should be readable by the amanda user (and definitely not world readable!) and is (obviously) on the server\&. In MIT\*(Aqs kadmin, the following: .sp .nf addprinc \-randkey amanda/saidin\&.omniscient\&.com @@ -518,7 +527,7 @@ You must also configure each client to allow the amanda principal in for dumps\& .PP There are several ways to go about authorizing a server to connect to a client\&. .PP -The normal way is via a \&.k5amandausers file or a \&.k5login file in the client user\'s home directory\&. The determination of which file to use is based on the way you ran configure on AMANDA\&. By default, AMANDA will use \&.k5amandahosts, but if you configured with \-\-without\-amandahosts, AMANDA will use \&.k5login\&. (similar to the default for \&.rhosts/\&.amandahosts\-style security)\&. The \&.k5login file syntax is a superset of the default +The normal way is via a \&.k5amandausers file or a \&.k5login file in the client user\*(Aqs home directory\&. The determination of which file to use is based on the way you ran configure on AMANDA\&. By default, AMANDA will use \&.k5amandahosts, but if you configured with \-\-without\-amandahosts, AMANDA will use \&.k5login\&. (similar to the default for \&.rhosts/\&.amandahosts\-style security)\&. The \&.k5login file syntax is a superset of the default \fBkrb5\fR \&.k5login\&. The routines to check it are implemented in amanda rather than using krb5_kuserok because the connections are actually gssapi based\&. .PP @@ -535,12 +544,12 @@ Here are examples of valid entries in the \&.k5amandahosts: dumpmaster\&.test\&.com service/amanda@TEST\&.COM .fi .PP -Rather than using a \&.k5amandahosts or \&.k5login file, the easiest way is to use a principal named after the destination user, (such as amanda@TEST\&.COM in our example) and not have either a \&.k5amandahosts or \&.k5login file in the destination user\'s home directory\&. +Rather than using a \&.k5amandahosts or \&.k5login file, the easiest way is to use a principal named after the destination user, (such as amanda@TEST\&.COM in our example) and not have either a \&.k5amandahosts or \&.k5login file in the destination user\*(Aqs home directory\&. .PP There is no attempt to verify the realm in this case (only a concern if you have cross\-realm authentication setup)\&. .SS "Authenticated Peer Hostnames with Kerberos Authentication" .PP -When accepting a new incoming connection, the Kerberos authentication mechanism performs a similar check to that done by the BSD authentications: the forward and reverse DNS entries for the remote host must match\&. As such, while Kerberos authentication can cryptographically ensure that the remote system is recognized (since it has a ticket), its assurances about the remote host\'s identity are weaker and depend on the integrity of the DNS\&. +When accepting a new incoming connection, the Kerberos authentication mechanism performs a similar check to that done by the BSD authentications: the forward and reverse DNS entries for the remote host must match\&. As such, while Kerberos authentication can cryptographically ensure that the remote system is recognized (since it has a ticket), its assurances about the remote host\*(Aqs identity are weaker and depend on the integrity of the DNS\&. .SH "LOCAL COMMUNICATION" .PP The Amanda server communicates with the client internally versus over the network, ie\&. the client is also the server\&. @@ -617,7 +626,7 @@ If your server \fBamandad\fR path and client \fBamandad\fR path are different, amandad\-path "/client/amandad/path" .PP -For a marginal increase in security, prepend the keys used for AMANDA in the clients\' authorized_keys file with the following: +For a marginal increase in security, prepend the keys used for AMANDA in the clients\*(Aq authorized_keys file with the following: .sp .nf from="amanda_server\&.your\&.domain\&.com",no\-port\-forwarding,no\-X11\-forwarding,no\-agent\-forwarding,command="/absolute/path/to/amandad \-auth=ssh amdump" @@ -626,7 +635,7 @@ For a marginal increase in security, prepend the keys used for AMANDA in the cli This will limit that key to connect only from Amanda server and only be able to execute \fBamandad\fR(8)\&. .PP -In the same way, prepend the key used for AMANDA in the server\'s authorized_keys file with: +In the same way, prepend the key used for AMANDA in the server\*(Aqs authorized_keys file with: .sp .nf from="amanda_client\&.your\&.domain\&.com",no\-port\-forwarding,no\-X11\-forwarding,no\-agent\-forwarding,command="/absolute/path/to/amandad \-auth=ssh amindexd amidxtaped" @@ -649,7 +658,7 @@ Besides user keys, SSH uses host keys to uniquely identify each host, to prevent .sp .nf $ ssh client1\&.zmanda\&.com - The authenticity of host \'client1\&.zmanda\&.com (192\&.168\&.10\&.1)\' can\'t be established\&. + The authenticity of host \*(Aqclient1\&.zmanda\&.com (192\&.168\&.10\&.1)\*(Aq can\*(Aqt be established\&. RSA key fingerprint is 26:4e:df:a2:be:c8:cb:20:1c:68:8b:cc:c0:3b:8e:9d\&. Are you sure you want to continue connecting (yes/no)?yes .fi @@ -657,7 +666,7 @@ Besides user keys, SSH uses host keys to uniquely identify each host, to prevent As Amanda will not answer this question itself, you must manually make every connection (server to client and client to server) that you expect Amanda to make\&. Note that you must use the same username that Amanda will use (that is, ssh client and ssh client\&.domain\&.com are distinct)\&. .SS "Authenticated Peer Hostnames with SSH Authentication" .PP -When accepting an incoming conneciton, the SSH daemon gives Amanda information about the remote system in the $SSH_CONNECTION environment variable\&. Amanda parses this information to determine the remote address, and then performs a similar check to that done by the BSD authentications: the forward and reverse DNS entries for the remote host must match\&. As such, while SSH authentication can cryptographically ensure that the remote system is recognized (since it had a recognized secret key), its assurances about the remote host\'s identity are weaker and depend on the integrity of the DNS\&. +When accepting an incoming conneciton, the SSH daemon gives Amanda information about the remote system in the $SSH_CONNECTION environment variable\&. Amanda parses this information to determine the remote address, and then performs a similar check to that done by the BSD authentications: the forward and reverse DNS entries for the remote host must match\&. As such, while SSH authentication can cryptographically ensure that the remote system is recognized (since it had a recognized secret key), its assurances about the remote host\*(Aqs identity are weaker and depend on the integrity of the DNS\&. .SH "SEE ALSO" .PP \fBamanda\fR(8), diff --git a/man/amanda-changers.7 b/man/amanda-changers.7 index 0e4da92..230657f 100644 --- a/man/amanda-changers.7 +++ b/man/amanda-changers.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-changers .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-CHANGERS" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-CHANGERS" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -30,7 +39,7 @@ overview of the API, and does not address details that are only of concern to de The Amanda Changer API is in transition from version 1\&.0 \- driven by shell scripts invoked for each changer operation \- to version 2\&.0, composed of perl objects that can manage parallel access to multiple devices and other complexity\&. At this point, all Amanda programs use the new Changer API directly, although 1\&.0 changer scripts are still fully supported via chg\-compat\&. .PP -The Changer API strives to treat all changers identically, so that Amanda\'s behavior is independent of the changer in use\&. However, some parts of Amanda operate differently depending on whether a changer can efficiently search for a volume with a given label\&. This distinction is really only apparent with tape libraries: those with barcode readers can quickly find a desired tape, while those without may fall back to an inefficient scan of each volume\&. The capability to perform quick searches is called "fast\-search", and each changer is annotated below to indicate its support\&. +The Changer API strives to treat all changers identically, so that Amanda\*(Aqs behavior is independent of the changer in use\&. However, some parts of Amanda operate differently depending on whether a changer can efficiently search for a volume with a given label\&. This distinction is really only apparent with tape libraries: those with barcode readers can quickly find a desired tape, while those without may fall back to an inefficient scan of each volume\&. The capability to perform quick searches is called "fast\-search", and each changer is annotated below to indicate its support\&. .SH "SPECIFYING CHANGERS" .PP Changer specifications are strings like @@ -293,15 +302,15 @@ The configuration file has simple lines with a parameter and its value separated .PP multieject .RS 4 -If this is 1, use an \'mt -offline\' command to change to the next tape, or multiple such commands for +If this is 1, use an \*(Aqmt +offline\*(Aq command to change to the next tape, or multiple such commands for skipping several tapes at a time\&. .RE .PP needeject .RS 4 This option is incompatible with -\'multieject\'\&. This should be 1 for changers accessed through several virtual +\*(Aqmultieject\*(Aq\&. This should be 1 for changers accessed through several virtual tape devices, when the changer needs the current tape to be ejected before changing to another device\&. .RE @@ -310,14 +319,14 @@ gravity .RS 4 Set this to 1 if the changer/stacker is unable to loop back to the first tape after unloading the -last one, or if you don\'t want amanda to go through the tape stack looking for +last one, or if you don\*(Aqt want amanda to go through the tape stack looking for the exact tape it wants instead of using the first acceptable one\&. .RE .PP slot X .RS 4 The configuration file should list -as many \'slot X\' statements as the number of slots supported by the changer or +as many \*(Aqslot X\*(Aq statements as the number of slots supported by the changer or the number of separate tape drives used\&. .RE .PP @@ -335,7 +344,7 @@ resend_mail=900 # resend mail every __ seconds timeout_mail=604800 # time out after this many seconds (default 7 days) request="[type]" # How to request a new tape (default "tty_email") request="tty" # Use the tty to ask the user to change tape\&. - # Can\'t be use by cron + # Can\*(Aqt be use by cron request="email" # Send an email to ask the user to change tape\&. request="tty_email" # Use the tty if it exist or send an email\&. .fi @@ -344,12 +353,12 @@ This changer is not fast\-search capable\&. .SS "chg\-zd\-mtx (old)" .nf tpchanger "chg\-zd\-mtx" -changerdev "/dev/sg0" # used with \'mtx \-f\' +changerdev "/dev/sg0" # used with \*(Aqmtx \-f\*(Aq changerfile "chg\-zd\-mtx\&.conf" tapedev "tape:/dev/nst0" .fi .PP -This script interfaces with a tape drive using the Zubkoff/Dandelion version of mtx\&. That\'s the version that takes a device specifier with the +This script interfaces with a tape drive using the Zubkoff/Dandelion version of mtx\&. That\*(Aqs the version that takes a device specifier with the \fB\-f\fR option and has subcommands like \fBstatus\fR\&. The configuration file parameters are (as listed in the script itself): @@ -360,12 +369,12 @@ lastslot=? #### Last storage slot (element) cleanslot=\-1 #### Slot with cleaner tape \-\- default is "\-1" #### Set negative to indicate no cleaner available driveslot=0 #### Drive slot number\&. Defaults to 0 - #### Use the \'Data Transfer Element\' you want -autoclean=0 #### Set to \'1\' or greater to enable + #### Use the \*(AqData Transfer Element\*(Aq you want +autoclean=0 #### Set to \*(Aq1\*(Aq or greater to enable autocleancount=99 #### Number of access before a clean\&. havereader=0 #### If you have a barcode reader, set to 1\&. offline_before_unload=0 #### Does your robot require an - #### \'mt offline\' before mtx unload? + #### \*(Aqmt offline\*(Aq before mtx unload? poll_drive_ready=NN #### Time (seconds) between tests to see if #### the tape drive has gone ready (default: 3)\&. max_drive_wait=NN #### Maximum time (seconds) to wait for the @@ -382,7 +391,7 @@ is true\&. .SS "chg\-rait:{CHILD1,CHILD2,\&.\&.}" .nf define changer vtape { - tpcanger "chg\-disk:/path/to/vtape" + tpchanger "chg\-disk:/path/to/vtape" } define changer robot { tpchanger "chg\-robot:/dev/sg0" @@ -437,7 +446,7 @@ define changer robot { tpchanger "robot" .fi .PP -This changer drives a robotic tape library using the operating system\'s +This changer drives a robotic tape library using the operating system\*(Aqs \fBmtx\fR command\&. It replaces the ancient \fBchg\-zd\-mtx\fR @@ -453,7 +462,7 @@ parameter can be used to specify a filename at which it should store its state\& .PP With a barcode reader present, it is possible for \fBchg\-robot\fR -to track the state of the library reliably, even recognizing tapes that are removed and later re\-inserted (by remembering their barcodes)\&. Without barcodes, the changer can still remember the slot in which it last saw the tape with a particular label, although this information can become stale if the tapes are rearranged by an operator\&. In any case, the changer will never "hunt" for a tape by repeatedly loading slots and checking labels\&. If the changer\'s state is inaccurate, use the +to track the state of the library reliably, even recognizing tapes that are removed and later re\-inserted (by remembering their barcodes)\&. Without barcodes, the changer can still remember the slot in which it last saw the tape with a particular label, although this information can become stale if the tapes are rearranged by an operator\&. In any case, the changer will never "hunt" for a tape by repeatedly loading slots and checking labels\&. If the changer\*(Aqs state is inaccurate, use the \fBamtape\fR(8) subcommand \fBupdate\fR\&. @@ -464,7 +473,7 @@ the changer when tapes are added to or removed from the library\&. .PP There is a shell script in the contrib/ -directory of Amanda\'s source distribution which can help you convert a +directory of Amanda\*(Aqs source distribution which can help you convert a \fBchg\-zd\-mtx\fR configuration into a \fBchg\-robot\fR @@ -563,7 +572,7 @@ returns incorrect barcodes, for example due to a malfunction in the barcode read .PP LOAD\-POLL .RS 4 -This property specifies the timing of Amanda\'s polling for the tape drive to be ready after loading a new tape\&. See "Timing", below\&. +This property specifies the timing of Amanda\*(Aqs polling for the tape drive to be ready after loading a new tape\&. See "Timing", below\&. .sp The script "polls" by trying to open the tape device repeatedly until no error is encountered\&. The property specifies the time to wait before the first poll (D), the frequency at which to poll and retry on errors (P); and the time after which it should give up (U)\&. The format is .sp @@ -592,7 +601,7 @@ The default value is MTX .RS 4 -The path to the \'mtx\' binary\&. The default value is defined at compile time\&. +The path to the \*(Aqmtx\*(Aq binary\&. The default value is defined at compile time\&. .RE .PP STATUS\-INTERVAL @@ -706,8 +715,18 @@ The username for the NDMP server\&. VERBOSE .RS 4 -If true, enables the NDMJOB library\'s verbose (packet\-level) debugging\&. +If true, enables the NDMJOB library\*(Aqs verbose (packet\-level) debugging\&. .RE +.SS "chg\-single:DEVICE" +.nf +tpchanger "chg\-single:tape:/dev/nst0" +.fi +.PP +This changer is for use with standalone drive, it can work with any device\&. The device (\fBtape:/dev/nst0\fR) must be set in the tpchanger definition\&. +.PP +The +\fBchg\-single\fR +changer has no property\&. .SS "Unmaintained Changers" .PP Amanda has many other changer scripts and programs beyond those described here (see the diff --git a/man/amanda-client.conf.5 b/man/amanda-client.conf.5 index 1359016..c907c19 100644 --- a/man/amanda-client.conf.5 +++ b/man/amanda-client.conf.5 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-client.conf .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: File formats and conventions -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-CLIENT\&.CON" "5" "06/02/2011" "Amanda 3\&.3\&.0" "File formats and conventions" +.TH "AMANDA\-CLIENT\&.CON" "5" "02/21/2012" "Amanda 3\&.3\&.1" "File formats and conventions" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -61,6 +70,12 @@ Default: \fBamanda.conf\fR(5), this specifies the port to connect on the server\&. It can be a service name or a numeric port number\&. .RE .PP +\fBamdump\-server\fR \fIstring\fR +.RS 4 +No default: +\fISet by configure\fR\&. The amanda server to connect with the amdump_client program\&. +.RE +.PP \fBindex\-server\fR \fIstring\fR .RS 4 Default: @@ -93,7 +108,7 @@ Default: \fB"krb5"\fR to use Kerberos\-V authorization\&. .sp -\fB"local"\fR, if the client is the server, it doesn\'t require authencation setup\&. +\fB"local"\fR, if the client is the server, it doesn\*(Aqt require authencation setup\&. .sp \fB"rsh"\fR to use rsh authorization\&. @@ -116,7 +131,7 @@ Default from configure .PP \fBmailer\fR \fIstring\fR .RS 4 -Default found by configure\&. A mail program that can send mail with \'\fIMAILER \-s "subject" user < message_file\fR\'\&. +Default found by configure\&. A mail program that can send mail with \*(Aq\fIMAILER \-s "subject" user < message_file\fR\*(Aq\&. .RE .PP \fBamandates\fR \fIstring\fR @@ -134,7 +149,7 @@ Default: \fBrep\-tries\fR \fIint\fR .RS 4 Default: -\fI5\fR\&. How many times amandad will resend a REP packet if it doesn\'t get the ACK packet\&. +\fI5\fR\&. How many times amandad will resend a REP packet if it doesn\*(Aqt get the ACK packet\&. .RE .PP \fBdebug\-days\fR \fIint\fR @@ -344,7 +359,7 @@ directory on the client\&. If set, it must be the same as the dle \fBexecute\-where\fR \fBclient\fR .RS 4 Default: -\fBclient\fR\&. Value can\'t be changed\&. +\fBclient\fR\&. Value can\*(Aqt be changed\&. .RE .PP \fBexecute\-on\fR \fIexecute_on\fR[,\fIexecute_on\fR]* diff --git a/man/amanda-compatibility.7 b/man/amanda-compatibility.7 index a9b8b98..44850b0 100644 --- a/man/amanda-compatibility.7 +++ b/man/amanda-compatibility.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-compatibility .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-COMPATIBILIT" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-COMPATIBILIT" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -32,7 +41,7 @@ Amanda 2\&.5\&.0 uses the same protocol as 2\&.4\&. One can use a 2\&.5\&.0 serv .PP Kerberos4 authentication in 2\&.5 is compatible with 2\&.4\&. In 2\&.5, kerberos4 encryption is broken, at least for the server\&. .PP -Amanda 2\&.5\&.1 introduced a new recover protocol\&. Backup communication works with any combination of versions, but 2\&.5\&.1\'s amrecover cannot communicate with an older server\&. Use oldamrecover on 2\&.5\&.1 and higher clients when communicating with an older server\&. +Amanda 2\&.5\&.1 introduced a new recover protocol\&. Backup communication works with any combination of versions, but 2\&.5\&.1\*(Aqs amrecover cannot communicate with an older server\&. Use oldamrecover on 2\&.5\&.1 and higher clients when communicating with an older server\&. .PP Amanda 2\&.6\&.0 and later are completely compatible with 2\&.5\&.1\&. .PP @@ -109,7 +118,6 @@ to the previous value of \fBfallback\-splitsize\fR\&. Be sure to remove all of the old keywords from your configuration\&. .RE .sp -.RE .SS "Amanda 3\&.1" .PP Although it is a significant rewrite, there are no incompatible changes in this release\&. @@ -136,7 +144,6 @@ label_new_tapes autolabel .RE .sp -.RE .SS "Amanda 2\&.6\&.1" .PP There are no incompatible changes in this release, but consider switching to some of the new applications instead of the old GNUTAR and DUMP programs\&. @@ -183,7 +190,6 @@ file\-pad \- this is no longer optional, and all files are padded .RE .sp -.RE .SS "Amanda 2\&.6\&.0" .PP amverify diff --git a/man/amanda-devices.7 b/man/amanda-devices.7 index ef52fcb..732fce5 100644 --- a/man/amanda-devices.7 +++ b/man/amanda-devices.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-devices .\" Author: Ian Turner -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-DEVICES" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-DEVICES" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -107,7 +116,7 @@ There is no way to reset a device property to its default value\&. .PP Device drivers use \fIproperties\fR -as a generic means to interact with other parts of Amanda\&. Some properties are set by the device driver and used by Amanda to determine how its devices should be used\&. Other properties can be set by Amanda or by the user to influence the driver\'s behavior\&. Properties are set for a particular device, so that if you have two tape devices, they will not share property values\&. +as a generic means to interact with other parts of Amanda\&. Some properties are set by the device driver and used by Amanda to determine how its devices should be used\&. Other properties can be set by Amanda or by the user to influence the driver\*(Aqs behavior\&. Properties are set for a particular device, so that if you have two tape devices, they will not share property values\&. .PP Properties are specified in \fIamanda\&.conf\fR @@ -181,7 +190,7 @@ CANONICAL_NAME COMMENT .RS 4 - (read\-write) This string property is entirely for the user\'s convenience\&. It is supported by all devices, but no device interprets its value in any way\&. + (read\-write) This string property is entirely for the user\*(Aqs convenience\&. It is supported by all devices, but no device interprets its value in any way\&. .RE .PP COMPRESSION @@ -274,7 +283,7 @@ Amanda writes device data in blocks\&. On most devices the block boundaries are .PP Amanda has historically supported a single, fixed block size \-\- usually 32k\&. The Device API adds the ability to specify a block size at runtime, using the BLOCK_SIZE property\&. Devices provide MIN_BLOCK_SIZE and MAX_BLOCK_SIZE as a guide to the range of acceptable block sizes\&. Note that this does not imply that all sizes in the range MIN_BLOCK_SIZE \- MAX_BLOCK_SIZE are available \-\- the device may require that block sizes are even multiples of some power of two, for example\&. Consult the documentation for your hardware and operating system for more information\&. .PP -Most devices are flexible enough to read a volume using a different block size than that with which it was written\&. This can be useful when handling old volumes written with a smaller blocksize, or volumes of unknown blocksize\&. Unfortunately, some tape devices do not detect oversized blocks correctly, and may lose data if the configured block size is smaller than the volume\'s block size\&. The tape device driver has a READ_BLOCK_SIZE property which specifies the minimum buffer size that will be allocated for reads from tape\&. If the hardware supports it, setting this property allows Amanda to correctly read from tapes written with any blocksize less than or equal to READ_BLOCK_SIZE\&. +Most devices are flexible enough to read a volume using a different block size than that with which it was written\&. This can be useful when handling old volumes written with a smaller blocksize, or volumes of unknown blocksize\&. Unfortunately, some tape devices do not detect oversized blocks correctly, and may lose data if the configured block size is smaller than the volume\*(Aqs block size\&. The tape device driver has a READ_BLOCK_SIZE property which specifies the minimum buffer size that will be allocated for reads from tape\&. If the hardware supports it, setting this property allows Amanda to correctly read from tapes written with any blocksize less than or equal to READ_BLOCK_SIZE\&. .if n \{\ .sp .\} @@ -352,7 +361,7 @@ The access and secret keys used to authenticate to Amazon S3 are provided as pro .PP The S3 device driver stores each block in a distinct S3 object\&. Due to high HTTP overhead for each request, use of larger than normal block sizes (> 1 megabyte) is recommended with the S3 device\&. .PP -Amanda automatically creates a bucket when writing, if the bucket doesn\'t already exist\&. At that time, it specifies where Amazon should store the data based on the S3_BUCKET_LOCATION property\&. If this property is not set, Amazon\'s default value (equivalent to "*") is used\&. The bucket location has both billing and legal concerns, so you are encouraged to consult Amazon\'s documentation for details\&. +Amanda automatically creates a bucket when writing, if the bucket doesn\*(Aqt already exist\&. At that time, it specifies where Amazon should store the data based on the S3_BUCKET_LOCATION property\&. If this property is not set, Amazon\*(Aqs default value (equivalent to "*") is used\&. The bucket location has both billing and legal concerns, so you are encouraged to consult Amazon\*(Aqs documentation for details\&. .PP Amazon does not permit changes to bucket locations, so this is a permanent specification\&. If the bucket already exists and the property is set, then Amanda checks the property against the location of the bucket, and produces an error if they do not match\&. .if n \{\ @@ -372,7 +381,7 @@ If a location constraint is set, the bucket name must consist only of lower\-cas .sp .5v .RE .PP -This driver supports the VERBOSE property, but use it carefully \-\- it produces a great deal of output, and may cause spurious failures by filling your debug log partition\&. Its logging is generally only useful for developers chasing down a problem in communications with Amazon\'s servers\&. +This driver supports the VERBOSE property, but use it carefully \-\- it produces a great deal of output, and may cause spurious failures by filling your debug log partition\&. Its logging is generally only useful for developers chasing down a problem in communications with Amazon\*(Aqs servers\&. .PP Since Amazon storage is unlimited, the device never encounteres EOM, so LEOM detection is trivially enabled for this device\&. .PP @@ -416,6 +425,12 @@ NB_THREADS_RECOVERY (read\-write) The number of thread that read data from the s3 device, higher value can provide more throutput\&. .RE .PP +OPENSTACK_SWIFT_API +.RS 4 + + (read\-write) Set to yes if it is an openstack storage device\&. +.RE +.PP S3_ACCESS_KEY .RS 4 @@ -428,7 +443,7 @@ S3_BUCKET_LOCATION (read\-write) Location constraint for buckets on Amazon S3\&. As of this writing, it can be set to "*" (US Standard, i\&.e\&. lowest\-latency choice of US East or West), "us\-west\-1" (US West, Northern California), "EU" -(European Union), or "ap\-southeast\-1" (Asia Pacific)\&. See : http://docs.amazonwebservices.com/AmazonS3/latest/index.html?LocationSelection.html for the most up\-to\-date list\&. +(European Union), or "ap\-southeast\-1" (Asia Pacific)\&. See : http://docs.amazonwebservices.com/general/latest/gr/index.html?rande.html for the most up\-to\-date list\&. .RE .PP SSL_CA_INFO @@ -454,6 +469,16 @@ S3_SECRET_KEY (read\-write) This property gives the Amazon S3 secret key used to access the service\&. .RE .PP +S3_SERVER_SIDE_ENCRYPTION +.RS 4 + +(read\-write) Set to the server side encryption algorithm to use\&. +There is actually only one algorithm, it is "AES256"\&. The encryption is done +by Amazon on their server\&. See +: http://docs.amazonwebservices.com/AmazonS3/latest/API/index.html?RESTObjectPUT.html +for the most up\-to\-date list\&. +.RE +.PP S3_SERVICE_PATH .RS 4 @@ -503,9 +528,9 @@ VERBOSE tapedev "tape:/dev/nst0" .fi .PP -The tape device driver interacts with a tape drive\&. The device uses the operating system\'s built\-in tape support, which is generally similar to that available via the command\-line utilities dd(1) and mt(1)\&. +The tape device driver interacts with a tape drive\&. The device uses the operating system\*(Aqs built\-in tape support, which is generally similar to that available via the command\-line utilities dd(1) and mt(1)\&. .PP -The tape device name should specify a path to the operating system\'s device file\&. +The tape device name should specify a path to the operating system\*(Aqs device file\&. .PP There is no simple way to determine whether a particular system (operating system and tape hardware) supports LEOM, so as a safe default the tape device has LEOM detection disabled\&. However, on modern hardware and common operating systems (Linux, *BSD, and Solaris, at least), LEOM support is functional\&. On these systems, enable LEOM by setting the LEOM property to "true" at the appropriate place in the Amanda configuration\&. .SS "Device-Specific Properties" @@ -515,7 +540,7 @@ Most of these properties are automatically detected, but can be overridden in th BROKEN_GMT_ONLINE .RS 4 - (read\-write) Set this boolean property if the system\'s GMT_ONLINE macro gives incorrect results\&. This is currently true for the Linux IDE\-TAPE driver\&. + (read\-write) Set this boolean property if the system\*(Aqs GMT_ONLINE macro gives incorrect results\&. This is currently true for the Linux IDE\-TAPE driver\&. .RE .PP BSF @@ -574,7 +599,7 @@ FSR NONBLOCKING_OPEN .RS 4 - (read\-write) Set this boolean property to "true" if O_NONBLOCK must be used on the open call\&. Default to "true" on Linux and "false" on all others machines\&. Witout it, Linux wait for a few seconds if no tape are loaded\&. Solaris have strange error it is set to "yes"\&. + (read\-write) Set this boolean property to "true" if O_NONBLOCK must be used on the open call\&. Default to "true" on Linux and "false" on all others machines\&. Without it, Linux wait for a few seconds if no tape are loaded\&. Solaris have strange error it is set to "yes"\&. .RE .PP READ_BLOCK_SIZE @@ -645,7 +670,7 @@ MONITOR_FREE_SPACE .RS 4 (read\-write) This property controls whether the device will monitor - the filesystem\'s free space to detect a full filesystem before an + the filesystem\*(Aqs free space to detect a full filesystem before an error occurs, and defaults to true\&. The monitoring operation works on most filesystems, but if it causes problems, use this property to disable it\&. diff --git a/man/amanda-interactivity.7 b/man/amanda-interactivity.7 index d0fb89a..682da04 100644 --- a/man/amanda-interactivity.7 +++ b/man/amanda-interactivity.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-interactivity .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-INTERACTIVIT" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-INTERACTIVIT" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -26,7 +35,7 @@ Amanda uses interactivity to ask user to load specific volumes when they are nee .PP This is a \fIuser\-level\fR -description of the API, and does not address details that are only of concern to developers of new interactivity plugins\&. For that purpose, consult the Amanda source code, perldoc \'Amanda::Interactivity\' and http://wiki\&.zmanda\&.com\&. +description of the API, and does not address details that are only of concern to developers of new interactivity plugins\&. For that purpose, consult the Amanda source code, perldoc \*(AqAmanda::Interactivity\*(Aq and http://wiki\&.zmanda\&.com\&. .SH "DEFINING INTERACTIVITY" .PP Interactivity is specified in @@ -67,7 +76,7 @@ The \fItty\fR interactivity module uses the tty to communicate with the user, it works only if a terminal is available, which is the case if amanda is executed from a command line\&. .PP -When promted for a volume, the user must put the requested volume in the changer and type \&. User can type the name of another changer if the volume is available in that changer\&. Typing \'abort\' will abort the operation\&. +When promted for a volume, the user must put the requested volume in the changer and type \&. User can type the name of another changer if the volume is available in that changer\&. Typing \*(Aqabort\*(Aq will abort the operation\&. .SS "EMAIL" .PP The @@ -84,7 +93,7 @@ check\-file If set, amanda will check this file for user input\&. The user can touch the file to tell amanda that the requested volume was inserted in the changer\&. If the user writes the name of a changer into the file, Amanda will use that changer\&. If the user -writes the word \'abort\' into the file, the scan will be aborted\&. +writes the word \*(Aqabort\*(Aq into the file, the scan will be aborted\&. .RE .PP check\-file\-delay diff --git a/man/amanda-match.7 b/man/amanda-match.7 index 7ed4236..8a5a7dc 100644 --- a/man/amanda-match.7 +++ b/man/amanda-match.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-match .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-MATCH" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-MATCH" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -27,9 +36,9 @@ Several Amanda commands allow the user to specify dumps using "match expressions In some places, only certain match expressions are allowed\&. However, several commands take a dump specification ("dumpspec") consisting of a sequence of several expressions intended to match particular dumps in the catalog\&. Other applications take a DLE specification which indicates a set of DLEs to be operated on\&. These formats are described below\&. .SH "HOST & DISK EXPRESSIONS" .PP -The hosts and disks match by word\&. Each word is a glob expression, and words are separated by the character \'\&.\' for host expressions and \'/\' for disk expressions\&. You can anchor the expression on the left with a \'^\' or on the right with a \'$\'\&. The matcher is case insensitive for hosts but case sensitive for disks\&. A match succeeds if all words in the expression match contiguous words in the host or disk\&. +The hosts and disks match by word\&. Each word is a glob expression, and words are separated by the character \*(Aq\&.\*(Aq for host expressions and \*(Aq/\*(Aq for disk expressions\&. You can anchor the expression on the left with a \*(Aq^\*(Aq or on the right with a \*(Aq$\*(Aq\&. The matcher is case insensitive for hosts but case sensitive for disks\&. A match succeeds if all words in the expression match contiguous words in the host or disk\&. .PP -If the disk is a UNC ("\e\ewindows\eshare") then all \'\e\' are converted to \'/\' before the match\&. Using \'\e\' is complicated because of the extra quoting required by the shell and amanda\&. It\'s easier to use \'/\' because it requires less quoting ("//windows/share") +If the disk is a UNC ("\e\ewindows\eshare") then all \*(Aq\e\*(Aq are converted to \*(Aq/\*(Aq before the match\&. Using \*(Aq\e\*(Aq is complicated because of the extra quoting required by the shell and amanda\&. It\*(Aqs easier to use \*(Aq/\*(Aq because it requires less quoting ("//windows/share") .PP The special characters follow\&. Note that the shell interprets some of these characters, so when used on the command line, they must be escaped appropriately for the shell\&. .PP @@ -207,7 +216,7 @@ Will match the disk .RE .SH "DATESTAMP EXPRESSIONS" .PP -A datestamp expression is either a prefix of the datestamp, or a range expression (separated by \'\-\') matching several prefixes\&. A leading ^ is removed, while arailing $ will force an exact match\&. +A datestamp expression is either a prefix of the datestamp, or a range expression (separated by \*(Aq\-\*(Aq) matching several prefixes\&. A leading ^ is removed, while arailing $ will force an exact match\&. .SS "Examples" .PP 20001212\-14 @@ -257,14 +266,14 @@ amtool MyConfig ^vpdesktop$ all dumps of host "vpdesktop" .RE .PP -amtool MyConfig \'*\' /var/stage +amtool MyConfig \*(Aq*\*(Aq /var/stage .RS 4 All dumps of /var/stage on any host .RE .PP -amtool MyConfig www1 /var/www \'*\' www2 /var/www \'*\' +amtool MyConfig www1 /var/www \*(Aq*\*(Aq www2 /var/www \*(Aq*\*(Aq .RS 4 All dumps of /var/www on www1 and www2 (assuming amtool does not require a level argument) .RE @@ -280,7 +289,7 @@ amtool MyConfig vpdesktop /home/anderson on host vpdesktop .RE .PP -amtool MyConfig \'*\' ^/etc \'*\' ^/var +amtool MyConfig \*(Aq*\*(Aq ^/etc \*(Aq*\*(Aq ^/var .RS 4 All DLEs matching ^/var diff --git a/man/amanda-scripts.7 b/man/amanda-scripts.7 index eeef59f..762698d 100644 --- a/man/amanda-scripts.7 +++ b/man/amanda-scripts.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-scripts .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-SCRIPTS" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-SCRIPTS" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/amanda-taperscan.7 b/man/amanda-taperscan.7 index 90d66b5..e380148 100644 --- a/man/amanda-taperscan.7 +++ b/man/amanda-taperscan.7 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda-taperscan .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: Miscellanea -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\-TAPERSCAN" "7" "06/02/2011" "Amanda 3\&.3\&.0" "Miscellanea" +.TH "AMANDA\-TAPERSCAN" "7" "02/21/2012" "Amanda 3\&.3\&.1" "Miscellanea" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -79,7 +88,7 @@ but never used) are considered reusable\&. Many of these algorithms look for the oldest reusable volume\&. In most cases, this is the best volume to overwrite, as the data it contains is older than that on any other volume\&. If there are no reusable volumes, then there is no oldest reusable volume\&. .SS "traditional" .PP -This algorithm duplicates Amanda\'s historical behavior, and it operates in two stages\&. +This algorithm duplicates Amanda\*(Aqs historical behavior, and it operates in two stages\&. .PP First, if there is an oldest reusable volume and if the changer supports "fast" searches, then the algorithm uses the changer to search for that volume\&. Newly labeled volumes are not considered when calculating the oldest reusable volume\&. Consequently, this taperscan algorithm prefers volumes which have been used before to newly\-labeled volumes when a fast\-searchable changer is in use\&. .PP @@ -121,7 +130,7 @@ An acceptable volume is a reusable volume, a new labeled volume or an unlabeled .PP Use \fBamtape CONF inventory\fR -to see the changer\'s inventory, and use +to see the changer\*(Aqs inventory, and use \fBamtape CONF update\fR to update it\&. .SS "lexical" @@ -133,9 +142,6 @@ It scans unknown slots only if no usable volume is found in the inventory\&. .PP See \fBoldest\fR, above, for a definition of acceptable volumes\&. - - ->>>>>>> 6a40a39\&.\&.\&. manpage edits .SH "SEE ALSO" .PP \fBamanda\fR(8), diff --git a/man/amanda.8 b/man/amanda.8 index 31c3735..a0fac58 100644 --- a/man/amanda.8 +++ b/man/amanda.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMANDA" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -699,14 +708,14 @@ amdump \-o INTERFACE:local:use="2000 kbps" When overriding device properties, one must carefully quote the command line to simulate the syntax of real configuration files\&. The following example should serve as a guide: .sp .nf -amdump \-o \'device\-property="PROPERTY_MAX_VOLUME_USAGE" "100000"\' +amdump \-o \*(Aqdevice\-property="PROPERTY_MAX_VOLUME_USAGE" "100000"\*(Aq .fi .PP Note that configuration overrides are not effective for tape changers, which supply a tapedev based on their own configuration\&. In order to override \fItapedev\fR, you must also disable any changer: .sp .nf -amdump \-otapedev=/dev/nst1 \-otpchanger=\'\' +amdump \-otapedev=/dev/nst1 \-otpchanger=\*(Aq\*(Aq .fi .SH "AUTHORS" .PP diff --git a/man/amanda.conf.5 b/man/amanda.conf.5 index ea3267d..0fba0e2 100644 --- a/man/amanda.conf.5 +++ b/man/amanda.conf.5 @@ -1,13 +1,22 @@ '\" t .\" Title: amanda.conf .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: File formats and conventions -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMANDA\&.CONF" "5" "06/02/2011" "Amanda 3\&.3\&.0" "File formats and conventions" +.TH "AMANDA\&.CONF" "5" "02/21/2012" "Amanda 3\&.3\&.1" "File formats and conventions" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -42,13 +51,13 @@ Keywords are case insensitive, i\&.e\&. \fBmailto\fR and \fBMailTo\fR -are treated the same\&. Also, the characters \'\fB\-\fR\' and \'\fB_\fR\' are interchangeable in all predefined Amanda keywords: +are treated the same\&. Also, the characters \*(Aq\fB\-\fR\*(Aq and \*(Aq\fB_\fR\*(Aq are interchangeable in all predefined Amanda keywords: \fBdevice_property\fR and \fBdevice\-property\fR have the same meaning\&. This manpage uses the dashed versions, but the underscored versions will be accepted for backward compatibility .PP -Identifiers are names which are defined in the configuration itself, such as dumptypes or interfaces\&. Identifiers are are case\-insensitive, but sensitive to \'\fB\-\fR\' vs\&. \'\fB_\fR\'\&. Identifiers should be quoted in the configuration file, although For historical reasons, the quotes are optional\&. +Identifiers are names which are defined in the configuration itself, such as dumptypes or interfaces\&. Identifiers are are case\-insensitive, but sensitive to \*(Aq\fB\-\fR\*(Aq vs\&. \*(Aq\fB_\fR\*(Aq\&. Identifiers should be quoted in the configuration file, although For historical reasons, the quotes are optional\&. .PP Strings are always quoted with double quotes ("), and any double quotes or backslashes within the string are escaped with a backslash: .sp @@ -191,7 +200,7 @@ Illegally quoted strings are handled on a "best\-effort" basis, which may lead t Examples: .sp .nf -finserver "/data/finance/XYZ Corp\'s \e"real\e" finances" finance\-high eth0 \-1 +finserver "/data/finance/XYZ Corp\*(Aqs \e"real\e" finances" finance\-high eth0 \-1 property "syspath" "C:\e\eWINDOWS\e\eSYSTEM" .fi .SS "SUBSECTIONS AND INHERITANCE" @@ -208,7 +217,7 @@ define dumptype global { } define dumptype nocomp { - global # inherit the parameters in dumptype \'global\' + global # inherit the parameters in dumptype \*(Aqglobal\*(Aq compress none } .fi @@ -233,7 +242,7 @@ define tapetype child { filemark 32k } .fi -In this example, \'child\' will have a filemark of 32k, a speed of 400bps, and a length of 200M\&. +In this example, \*(Aqchild\*(Aq will have a filemark of 32k, a speed of 400bps, and a length of 200M\&. .SH "GLOBAL PARAMETERS" .PP \fBorg\fR \fIstring\fR @@ -244,7 +253,7 @@ Default: .PP \fBmailer\fR \fIstring\fR .RS 4 -Default found by configure\&. A mail program that can send mail with \'\fIMAILER \-s "subject" user < message_file\fR\'\&. +Default found by configure\&. A mail program that can send mail with \*(Aq\fIMAILER \-s "subject" user < message_file\fR\*(Aq\&. .RE .PP \fBmailto\fR \fIstring\fR @@ -278,6 +287,12 @@ Never send an email\&. .RE .RE .PP +\fBmax\-dle\-by\-volume\fR \fIint\fR +.RS 4 +Default: +\fI1000000000\fR\&. The maximum number of dle written to a single volume\&. +.RE +.PP \fBdumpcycle\fR \fIint\fR .RS 4 Default: @@ -322,8 +337,8 @@ days / \fBtapecycle\fR \fIint\fR .RS 4 Default: -\fI15 tapes\fR\&. Specifies the number of "active" volumes \- volumes that Amanda will not overwrite\&. While Amanda is always willing to write to a new volume, it refuses to overwrite a volume unless at least \'\fBtapecycle\fR -\-1\' volumes have been written since\&. +\fI15 tapes\fR\&. Specifies the number of "active" volumes \- volumes that Amanda will not overwrite\&. While Amanda is always willing to write to a new volume, it refuses to overwrite a volume unless at least \*(Aq\fBtapecycle\fR +\-1\*(Aq volumes have been written since\&. .sp It is considered good administrative practice to set the \fBtapecycle\fR @@ -352,7 +367,7 @@ is set to two or four times the tapes per dumpcycle\&. \fBusetimestamps\fR \fIbool\fR .RS 4 Default: -\fBYes\fR\&. This option allows Amanda to track multiple runs per calendar day\&. The only reason one might disable it is that Amanda versions before 2\&.5\&.1 can\'t read logfiles written when this option was enabled\&. +\fBYes\fR\&. This option allows Amanda to track multiple runs per calendar day\&. The only reason one might disable it is that Amanda versions before 2\&.5\&.1 can\*(Aqt read logfiles written when this option was enabled\&. .RE .PP \fBlabel\-new\-tapes\fR \fIstring\fR @@ -376,22 +391,30 @@ When using this directive, specify the template for new tape labels\&. The templ $c : config name $o : org configuration $b : barcode of the volume + $s : slot number, can specify a minimun number of digit: + $3s to get \*(Aq001\*(Aq $m : meta label .fi .sp -The template should contain some number of contiguous \'%\' characters, which will be replaced with a generated number\&. Be sure to specify enough \'%\' characters that you do not run out of tape labels\&. Example: +The template can contain some number of contiguous \*(Aq%\*(Aq characters, which will be replaced with a generated number\&. Be sure to specify enough \*(Aq%\*(Aq characters that you do not run out of tape labels\&. Example: \fB"DailySet1\-%%%"\fR, \fB"$c\-%%%"\fR, \fB"$m\-%%%"\fR, \fB"$m\-$b"\fR .sp +The generared label can be used only if it match the +\fBlabelstr\fR +setting\&. The volume will not be used if the generated label doesn\*(Aqt match the +\fBlabelstr\fR +setting\&. +.sp Note that many devices cannot distinguish an empty tape from an error condition, so it may is often necessary to include \fBvolume\-error\fR as an autolabel condition\&. .PP \fBany\fR .RS 4 -equivalent to \'\fBother\-config non\-amanda volume\-error empty\fR\' +equivalent to \*(Aq\fBother\-config non\-amanda volume\-error empty\fR\*(Aq .RE .PP \fBother\-config\fR @@ -433,7 +456,7 @@ When using this directive, specify the template for new meta labels\&. The templ $o : org configuration .fi .sp -The template should contain some number of contiguous \'%\' characters, which will be replaced with a generated number\&. Be sure to specify enough \'%\' characters that you do not run out of meta labels\&. Example: +The template should contain some number of contiguous \*(Aq%\*(Aq characters, which will be replaced with a generated number\&. Be sure to specify enough \*(Aq%\*(Aq characters that you do not run out of meta labels\&. Example: \fB"DailySet1\-%%%"\fR, \fB"$o\-%%%"\fR, .RE @@ -579,16 +602,23 @@ Last in, first out\&. .PP \fBtaper\-parallel\-write\fR \fIint\fR .RS 4 -.PP Default: \fI1\fR\&. Amanda can write simultaneously up to that number of volume at any given time\&. The changer must have as many drives\&. .RE .PP +\fBeject\-volume\fR \fIint\fR +.RS 4 +Default: +\fIno\fR\&. Set to +\fByes\fR +if you want the volume to be ejected after Amanda wrote data to it\&. It works only with some changer and device\&. +.RE +.PP \fBlabelstr\fR \fIstring\fR .RS 4 Default: \fI"\&.*"\fR\&. The tape label constraint regular expression\&. All tape labels generated (see -\fBamlabel\fR(8)) and used by this configuration must match the regular expression\&. If multiple configurations are run from the same tape server host, it is helpful to set their labels to different strings (for example, "DAILY[0\-9][0\-9]*" vs\&. "ARCHIVE[0\-9][0\-9]*") to avoid overwriting each other\'s tapes\&. +\fBamlabel\fR(8)) and used by this configuration must match the regular expression\&. If multiple configurations are run from the same tape server host, it is helpful to set their labels to different strings (for example, "DAILY[0\-9][0\-9]*" vs\&. "ARCHIVE[0\-9][0\-9]*") to avoid overwriting each other\*(Aqs tapes\&. .RE .PP \fBtapetype\fR \fIstring\fR @@ -631,7 +661,7 @@ Default: \fBplanner\fR step of \fBamdump\fR -will wait to get the dump size estimates (note: Amanda runs up to 3 estimates for each DLE)\&. For instance, with the default of 300 seconds and four DLE\'s, each estimating level 0 and level 1 on client A, +will wait to get the dump size estimates (note: Amanda runs up to 3 estimates for each DLE)\&. For instance, with the default of 300 seconds and four DLE\*(Aqs, each estimating level 0 and level 1 on client A, \fBplanner\fR will wait up to 40 minutes for that machine\&. A negative value will be interpreted as a total amount of time to wait per client instead of per disk\&. .RE @@ -645,13 +675,13 @@ Default: \fBreq\-tries\fR \fIint\fR .RS 4 Default: -\fI3\fR\&. How many times the server will resend a REQ packet if it doesn\'t get the ACK packet\&. +\fI3\fR\&. How many times the server will resend a REQ packet if it doesn\*(Aqt get the ACK packet\&. .RE .PP \fBnetusage\fR \fIint\fR .RS 4 Default: -\fI8000 Kbps\fR\&. The maximum network bandwidth allocated to Amanda, in Kbytes per second\&. See also the +\fI80000 Kbps\fR\&. The maximum network bandwidth allocated to Amanda, in Kbytes per second\&. See also the \fBinterface\fR section\&. .RE @@ -659,7 +689,7 @@ section\&. \fBinparallel\fR \fIint\fR .RS 4 Default: -\fI10\fR\&. The maximum number of backups that Amanda will attempt to run in parallel\&. Amanda will stay within the constraints of network bandwidth and holding disk space available, so it doesn\'t hurt to set this number a bit high\&. Some contention can occur with larger numbers of backups, but this effect is relatively small on most systems\&. +\fI10\fR\&. The maximum number of backups that Amanda will attempt to run in parallel\&. Amanda will stay within the constraints of network bandwidth and holding disk space available, so it doesn\*(Aqt hurt to set this number a bit high\&. Some contention can occur with larger numbers of backups, but this effect is relatively small on most systems\&. .RE .PP \fBdisplayunit\fR "k|m|g|t" @@ -850,7 +880,7 @@ Default: .PP \fBamrecover\-changer\fR \fIstring\fR .RS 4 -Default: not set\&. Amrecover will use the changer if you use \'settape \' and that string is the same as the +Default: not set\&. Amrecover will use the changer if you use \*(Aqsettape \*(Aq and that string is the same as the \fBamrecover\-changer\fR setting\&. .RE @@ -863,7 +893,7 @@ Defines the width of columns \fBamreport\fR should use\&. \fIString\fR -is a comma (\',\') separated list of triples\&. Each triple consists of three parts which are separated by a equal sign (\'=\') and a colon (\':\') (see the example)\&. These four parts specify: +is a comma (\*(Aq,\*(Aq) separated list of triples\&. Each triple consists of three parts which are separated by a equal sign (\*(Aq=\*(Aq) and a colon (\*(Aq:\*(Aq) (see the example)\&. These four parts specify: .sp .RS 4 .ie n \{\ @@ -1056,7 +1086,7 @@ The value of this parameter may not exceed that of the \fBflush\-threshold\-scheduled\fR parameter\&.; \fBautoflush\fR -must be set to \'yes\' if +must be set to \*(Aqyes\*(Aq if \fBtaperflush\fR is greater than 0\&. .RE @@ -1436,7 +1466,7 @@ Use a faster program to do estimates, but the result is less accurate\&. .PP server .RS 4 -Use only statistics from the previous few runs to give an estimate\&. This very quick, but the result is not accurate if your disk usage changes from day to day\&. If this method is specified, but the server does not have enough data to make an estimate, then the option is internally moved to the end of the list, thereby preferring \'client\' or \'calcsize\' in this case\&. +Use only statistics from the previous few runs to give an estimate\&. This very quick, but the result is not accurate if your disk usage changes from day to day\&. If this method is specified, but the server does not have enough data to make an estimate, then the option is internally moved to the end of the list, thereby preferring \*(Aqclient\*(Aq or \*(Aqcalcsize\*(Aq in this case\&. .RE .RE .PP @@ -1464,7 +1494,7 @@ is an exclude expression\&. With \fIstring\fR is a file name on the client containing \fBGNU\-tar\fR -exclude expressions\&. The path to the specified exclude list file, if present (see description of \'optional\' below), must be readable by the Amanda user\&. +exclude expressions\&. The path to the specified exclude list file, if present (see description of \*(Aqoptional\*(Aq below), must be readable by the Amanda user\&. .sp All exclude expressions are concatenated in one file and passed to the application as an \fB\-\-exclude\-from\fR @@ -1485,7 +1515,7 @@ If \fBoptional\fR is specified for \fBexclude\fR -\fBlist\fR, then amcheck will not complain if the file doesn\'t exist or is not readable\&. +\fBlist\fR, then amcheck will not complain if the file doesn\*(Aqt exist or is not readable\&. .sp For \fBexclude\fR @@ -1518,12 +1548,12 @@ Never use a holdingdisk, the dump will always go directly to tape\&. There will .PP \fBauto\fR|yes|true|on .RS 4 -Use the holding disk, unless there is a problem with the holding disk, the dump won\'t fit there or the medium doesn\'t require spooling (e\&.g\&., VFS device) +Use the holding disk, unless there is a problem with the holding disk, the dump won\*(Aqt fit there or the medium doesn\*(Aqt require spooling (e\&.g\&., VFS device) .RE .PP \fBrequired\fR .RS 4 -Always dump to holdingdisk, never directly to tape\&. There will be no dump if it doesn\'t fit on holdingdisk +Always dump to holdingdisk, never directly to tape\&. There will be no dump if it doesn\*(Aqt fit on holdingdisk .RE .RE .PP @@ -1586,7 +1616,7 @@ overwrites the list\&. If \fBoptional\fR is specified for -\fBinclude list\fR, then amcheck will not complain if the file doesn\'t exist or is not readable\&. +\fBinclude list\fR, then amcheck will not complain if the file doesn\*(Aqt exist or is not readable\&. .sp For \fBinclude list\fR, If the file name is relative, the disk name being backed up is prepended\&. @@ -1617,7 +1647,7 @@ Default: \fBmaxpromoteday\fR \fIint\fR .RS 4 Default: -\fI10000\fR\&. The maximum number of day for a promotion, set it 0 if you don\'t want promotion, set it to 1 or 2 if your disks get overpromoted\&. +\fI10000\fR\&. The maximum number of day for a promotion, set it 0 if you don\*(Aqt want promotion, set it to 1 or 2 if your disks get overpromoted\&. .RE .PP \fBpriority\fR [ \fBlow\fR | \fBmedium\fR | \fBhigh\fR ] @@ -1732,7 +1762,7 @@ Never do incremental backups, only full dumps\&. .PP \fBskip\fR .RS 4 -Treat this DLE as if it doesn\'t exist (useful to disable DLEs when sharing the +Treat this DLE as if it doesn\*(Aqt exist (useful to disable DLEs when sharing the \fIdisklist\fR file between multiple configurations)\&. Skipped DLEs will not be checked or dumped, and will not be matched by disklist expressions\&. .RE @@ -1919,7 +1949,7 @@ device property, but if the blocksize is not a multiple of 1024 bytes, then this .RS 4 Default: \fI32 kytes\fR -How much data will be read in each tape record\&. This can be used to override a device\'s block size for reads only\&. This may be useful, for example, in reading a tape written with a 256k block size when Amanda is configured to use 128k blocks\&. This unusual feature is not supported by all operating systems and tape devices\&. +How much data will be read in each tape record\&. This can be used to override a device\*(Aqs block size for reads only\&. This may be useful, for example, in reading a tape written with a 256k block size when Amanda is configured to use 128k blocks\&. This unusual feature is not supported by all operating systems and tape devices\&. .sp The default unit is Kbytes if it is not specified\&. .RE @@ -2017,7 +2047,7 @@ Default: not set\&. A comment string describing this set of network information\ \fBuse\fR \fIint\fR .RS 4 Default: -\fI8000 Kbps\fR\&. The speed of the interface in Kbytes per second\&. +\fI80000 Kbps\fR\&. The speed of the interface in Kbytes per second\&. .RE .PP In addition to options, another @@ -2056,7 +2086,7 @@ is set then it is an error if that application is not defined on the client\&. .sp If \fBclient\-name\fR -is not set then the merge is done with the application that have the name equal to the plugin\&. eg\&. if the plugin is \'amgtar\', then the setting from the application \'amgtar\' is used if it is defined\&. +is not set then the merge is done with the application that have the name equal to the plugin\&. eg\&. if the plugin is \*(Aqamgtar\*(Aq, then the setting from the application \*(Aqamgtar\*(Aq is used if it is defined\&. .RE .PP \fBcomment\fR \fIstring\fR @@ -2109,7 +2139,7 @@ is set then it is an error if that script is not defined on the client\&. .sp If \fBclient\-name\fR -is not set then the merge is done with the script that have the name equal to the plugin\&. eg\&. if the plugin is \'amlog\-script\', then the setting from the script \'amlog\-script\' is used\&. +is not set then the merge is done with the script that have the name equal to the plugin\&. eg\&. if the plugin is \*(Aqamlog\-script\*(Aq, then the setting from the script \*(Aqamlog\-script\*(Aq is used\&. .RE .PP \fBcomment\fR \fIstring\fR @@ -2219,7 +2249,7 @@ Execute before the backup command for the dle\&. .PP \fBpre\-host\-backup\fR .RS 4 -Execute before the backup command for all dle for the client\&. It can\'t be run on client, it must be run on server +Execute before the backup command for all dle for the client\&. It can\*(Aqt be run on client, it must be run on server .RE .PP \fBpost\-backup\fR @@ -2234,7 +2264,7 @@ Execute after the backup command for the dle\&. .PP \fBpost\-host\-backup\fR .RS 4 -Execute after the backup command for all dle for the client\&. It can\'t be run on client, it must be run on server +Execute after the backup command for all dle for the client\&. It can\*(Aqt be run on client, it must be run on server .RE .PP \fBpre\-recover\fR @@ -2308,7 +2338,7 @@ parameter\&. The specifies the device name to use; see \fBamanda-devices\fR(7)\&. As with most sections, the \fIcomment\fR -parmeter is optional and only for the user\'s convenience\&. +parmeter is optional and only for the user\*(Aqs convenience\&. .PP An arbitrary number of \fIdevice\-property\fR diff --git a/man/amarchiver.8 b/man/amarchiver.8 index c2cf0e5..18e802b 100644 --- a/man/amarchiver.8 +++ b/man/amarchiver.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amarchiver .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMARCHIVER" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMARCHIVER" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -26,7 +35,7 @@ amarchiver \- Create, extract or list amanda archive .SH "DESCRIPTION" .PP \fBAmarchiver\fR -manipulates amanda archive file\&. On creation, amarchiver doesn\'t recurse into directories\&. If a filename specifies a directory, it will be ignored\&. If it specifies a character device, amarchiver reads the device and archives the data\&. If a filename specifies a named pipe, amarchiver reads the named pipe and archives the data\&. +manipulates amanda archive file\&. On creation, amarchiver doesn\*(Aqt recurse into directories\&. If a filename specifies a directory, it will be ignored\&. If it specifies a character device, amarchiver reads the device and archives the data\&. If a filename specifies a named pipe, amarchiver reads the named pipe and archives the data\&. .PP Note that this tool is more limited than the Amanda archive library, and may not be appropriate for some archive files \-\- particularly those which use non\-strings in their filenames\&. .SH "OPTIONS" @@ -49,7 +58,7 @@ List the filenames in an amanda archive\&. No additional filenames are allowed o .PP \fB\-\-extract\fR .RS 4 -Extract an amanda archive\&. If filenames are supplied, only those files are extracted\&. Files are created in the current directory, suffixed with a dot (\'\&.\') and the attribute ID\&. +Extract an amanda archive\&. If filenames are supplied, only those files are extracted\&. Files are created in the current directory, suffixed with a dot (\*(Aq\&.\*(Aq) and the attribute ID\&. .RE .PP \fB\-\-verbose\fR diff --git a/man/amcheck.8 b/man/amcheck.8 index 2ac9b74..a8d414c 100644 --- a/man/amcheck.8 +++ b/man/amcheck.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcheck .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCHECK" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCHECK" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -22,7 +31,7 @@ amcheck \- run Amanda self\-checks .SH "SYNOPSIS" .HP \w'\fBamcheck\fR\ 'u -\fBamcheck\fR [\-am] [\-w] [\-sclt] [\-M\ \fIaddress\fR] [\fB\-o\fR\ \fIconfigoption\fR...] \fIconfig\fR [\fIhost\fR\ [\fIdisk\fR...]...] +\fBamcheck\fR [\-am] [\-w] [\-sclt] [\-M\ \fIaddress\fR] [\-\-client\-verbose] [\fB\-o\fR\ \fIconfigoption\fR...] \fIconfig\fR [\fIhost\fR\ [\fIdisk\fR...]...] .SH "DESCRIPTION" .PP \fBAmcheck\fR @@ -105,6 +114,11 @@ value from \fB\-m\fR\&. .RE .PP +\fB\-\-client\-verbose\fR +.RS 4 +Print all client messages\&. +.RE +.PP \fIhost\fR [\fIdisk\fR]* .RS 4 Specify the host and disk on which the command will work\&. @@ -125,7 +139,7 @@ In this example, both the tape server and client tests are run\&. The results ar % amcheck daily Amanda Tape Server Host Check \-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\- -/amanda2/amanda/work: 911475 KB disk space available, that\'s plenty\&. +/amanda2/amanda/work: 911475 KB disk space available, that\*(Aqs plenty\&. NOTE: skipping tape\-writable test\&. Tape VOL10 label ok\&. Server check took 34\&.966 seconds\&. @@ -469,7 +483,7 @@ to exit with a non\-zero status\&. .RE .RE .PP -Holding disk \fIdisk\fR: \fIN\fR KB disk space available, that\'s plenty\&. +Holding disk \fIdisk\fR: \fIN\fR KB disk space available, that\*(Aqs plenty\&. .RS 4 (info) There was sufficient free space on holding disk \fIdisk\fR\&. @@ -524,7 +538,7 @@ ERROR: cannot overwrite active tape \fIlabel\fR\&. is still active and cannot be used\&. .RE .PP -ERROR: label \fIlabel\fR doesn\'t match labelstr \fIpattern\fR \&. +ERROR: label \fIlabel\fR doesn\*(Aqt match labelstr \fIpattern\fR \&. .RS 4 (error) The label on tape \fIlabel\fR diff --git a/man/amcheckdb.8 b/man/amcheckdb.8 index 0bece92..1fda719 100644 --- a/man/amcheckdb.8 +++ b/man/amcheckdb.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcheckdb .\" Author: Adrian T. Filipi-Martin -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCHECKDB" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCHECKDB" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/amcheckdump.8 b/man/amcheckdump.8 index ec4b4c8..7a73f7d 100644 --- a/man/amcheckdump.8 +++ b/man/amcheckdump.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcheckdump .\" Author: Ian Turner -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCHECKDUMP" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCHECKDUMP" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -45,7 +54,7 @@ option\&. # check the most recent dump amcheckdump MYCONFIG -# check a specific dump from back in \'78 +# check a specific dump from back in \*(Aq78 amcheckdump MYCONFIG \-\-timestamp 19780615 .fi .SH "SEE ALSO" diff --git a/man/amcleanup.8 b/man/amcleanup.8 index 6906d80..600e272 100644 --- a/man/amcleanup.8 +++ b/man/amcleanup.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcleanup .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCLEANUP" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCLEANUP" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -22,7 +31,7 @@ amcleanup \- run the Amanda cleanup process after a failure .SH "SYNOPSIS" .HP \w'\fBamcleanup\fR\ 'u -\fBamcleanup\fR [\fB\-k\fR] [\fB\-p\fR] [\fB\-v\fR] \fIconfig\fR +\fBamcleanup\fR [\fB\-k\fR] [\fB\-p\fR] [\fB\-r\fR] [\fB\-v\fR] \fIconfig\fR .SH "DESCRIPTION" .PP \fBAmcleanup\fR @@ -36,6 +45,14 @@ cannot complete for some reason (usually because of a tape server host crash), \fBamcleanup\fR must be run some time later (usually during system boot)\&. .PP +The +\fBamcleanupdisk\fR +program is run with the same +[\fB\-r\fR] +and +[\fB\-v\fR] +options\&. +.PP See the \fBamanda\fR(8) man page for more details about Amanda\&. @@ -51,9 +68,14 @@ Kill all process listed in the log file are their child\&. if there is no log fi Do the cleanup only if all process listed in the log file are already terminated\&. .RE .PP +\fB\-r\fR +.RS 4 +Remove bad file in holding disk\&. This options is passed to amcleanupdisk\&. +.RE +.PP \fB\-v\fR .RS 4 -Generate verbose output\&. +Generate verbose output\&. This options is passed to amcleanupdisk\&. .RE .SH "EXAMPLES" .PP diff --git a/man/amcleanupdisk.8 b/man/amcleanupdisk.8 new file mode 100644 index 0000000..e7409b6 --- /dev/null +++ b/man/amcleanupdisk.8 @@ -0,0 +1,75 @@ +'\" t +.\" Title: amcleanupdisk +.\" Author: James da Silva +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 +.\" Manual: System Administration Commands +.\" Source: Amanda 3.3.1 +.\" Language: English +.\" +.TH "AMCLEANUPDISK" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' +.\" ----------------------------------------------------------------- +.\" * set default formatting +.\" ----------------------------------------------------------------- +.\" disable hyphenation +.nh +.\" disable justification (adjust text to left margin only) +.ad l +.\" ----------------------------------------------------------------- +.\" * MAIN CONTENT STARTS HERE * +.\" ----------------------------------------------------------------- +.SH "NAME" +amcleanupdisk \- cleanup holding disk directory +.SH "SYNOPSIS" +.HP \w'\fBamcleanupdisk\fR\ 'u +\fBamcleanupdisk\fR [\fB\-r\fR] [\fB\-v\fR] \fIconfig\fR +.SH "DESCRIPTION" +.PP +\fBAmcleanupdisk\fR +list and/or remove invalid file from the holding disk directories\&. +.PP +This program is run by +\fBamcleanup\fR\&. +.PP +See the +\fBamanda\fR(8) +man page for more details about Amanda\&. +.SH "OPTIONS" +.PP +\fB\-r\fR +.RS 4 +Remove invalid file from holding disk\&. +.RE +.PP +\fB\-v\fR +.RS 4 +Generate verbose output\&. +.RE +.SH "EXAMPLES" +.PP +This example runs the Amanda holding disk cleanup process\&. +.nf +% amcleanupdisk daily \-v \-r +.fi +.SH "SEE ALSO" +.PP +\fBamanda\fR(8), +\fBamcleanup\fR(8), +\fBamdump\fR(8) +.PP +The Amanda Wiki: +: http://wiki.zmanda.com/ +.SH "AUTHORS" +.PP +\fBJames da Silva\fR <\&jds@amanda\&.org\&> +.PP +\fBStefan G\&. Weichinger\fR <\&sgw@amanda\&.org\&> diff --git a/man/amcrypt-ossl-asym.8 b/man/amcrypt-ossl-asym.8 index 34d2c95..e2c19b9 100644 --- a/man/amcrypt-ossl-asym.8 +++ b/man/amcrypt-ossl-asym.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcrypt-ossl-asym .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCRYPT\-OSSL\-ASYM" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCRYPT\-OSSL\-ASYM" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -72,7 +81,7 @@ is used to decrypt data, and must be protected\&. Encrypted backup data cannot b .PP While the public key must be online at all times to perorm backups, the private key and optional passphrase are only needed to restore data\&. It is recommended that the latter be stored offline all other times\&. For example, you could keep the private key on removable media, and copy it into place for a restore; or you could keep the private key online, encrypted with a passphrase that is present only for a restore\&. .PP -OpenSSL\'s key derivation routines use a salt to guard against dictionary attacks on the pass phrase; still it is important to pick a pass phrase that is hard to guess\&. The Diceware method (see +OpenSSL\*(Aqs key derivation routines use a salt to guard against dictionary attacks on the pass phrase; still it is important to pick a pass phrase that is hard to guess\&. The Diceware method (see www\&.diceware\&.com) can be used to create passphrases that are difficult to guess and easy to remember\&. .SH "FILES" .PP diff --git a/man/amcrypt-ossl.8 b/man/amcrypt-ossl.8 index a0ef05e..4f23318 100644 --- a/man/amcrypt-ossl.8 +++ b/man/amcrypt-ossl.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcrypt-ossl .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCRYPT\-OSSL" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCRYPT\-OSSL" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -45,7 +54,7 @@ uses the same pass phrase to encrypt and decrypt data\&. It is very important to \fBonly\fR be recovered with the correct passphrase\&. .PP -OpenSSL\'s key derivation routines use a salt to guard against dictionary attacks on the pass phrase; still it is important to pick a pass phrase that is hard to guess\&. The Diceware method (see +OpenSSL\*(Aqs key derivation routines use a salt to guard against dictionary attacks on the pass phrase; still it is important to pick a pass phrase that is hard to guess\&. The Diceware method (see www\&.diceware\&.com) can be used to create passphrases that are difficult to guess and easy to remember\&. .SH "FILES" .PP diff --git a/man/amcrypt.8 b/man/amcrypt.8 index ac2ce1b..a8cadc1 100644 --- a/man/amcrypt.8 +++ b/man/amcrypt.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcrypt .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCRYPT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCRYPT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -48,7 +57,7 @@ and pass the through file descriptor 3\&. The passphrase should be stored in ~amanda/\&.am_passphrase\&. .SH "HOW TO CREATE ENCRYPTION KEYS FOR AMCRYPT" .PP -1\&. Create 65 random encryption keys and encrypt those keys using gpg\&. Reading from /dev/random may take indefinitely long if kernel\'s random entropy pool is empty\&. If that happens, do some other work on some other console (use keyboard, mouse and disks)\&. +1\&. Create 65 random encryption keys and encrypt those keys using gpg\&. Reading from /dev/random may take indefinitely long if kernel\*(Aqs random entropy pool is empty\&. If that happens, do some other work on some other console (use keyboard, mouse and disks)\&. .PP head \-c 2925 /dev/random | uuencode \-m \- | head \-n 66 | tail \-n 65 \e | gpg \-\-symmetric \-a > ~amanda/\&.gnupg/am_key\&.gpg .PP diff --git a/man/amcryptsimple.8 b/man/amcryptsimple.8 index 41465d5..282ac80 100644 --- a/man/amcryptsimple.8 +++ b/man/amcryptsimple.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amcryptsimple .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMCRYPTSIMPLE" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMCRYPTSIMPLE" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/amdevcheck.8 b/man/amdevcheck.8 index 0298382..7dce8a9 100644 --- a/man/amdevcheck.8 +++ b/man/amdevcheck.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amdevcheck .\" Author: Ian Turner -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMDEVCHECK" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMDEVCHECK" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -27,7 +36,7 @@ amdevcheck \- Validate an Amanda device and volume\&. .PP \fBAmdevcheck\fR -provides a way to check that a particular Amanda device is accessible, whether or not it contains a volume, and whether or not that volume is labeled\&. Some devices can\'t distinguish between all of these cases; a missing volume and an unlabeled volume might generate the same error code, for example\&. In those cases, this tool reports all possible causes of the error\&. Optionally this tools lists the properties for the device\&. +provides a way to check that a particular Amanda device is accessible, whether or not it contains a volume, and whether or not that volume is labeled\&. Some devices can\*(Aqt distinguish between all of these cases; a missing volume and an unlabeled volume might generate the same error code, for example\&. In those cases, this tool reports all possible causes of the error\&. Optionally this tools lists the properties for the device\&. .PP See the \fBamanda\fR(8) @@ -50,12 +59,12 @@ Amanda device to use\&. This option overrides any tapedev configuration specifie .PP \fI\-\-label\fR .RS 4 -Get the device\'s label\&. If this option is given, the usual check output is omitted, and the label of the loaded volume is printed to stdout\&. Returns with error if the label is not found\&. +Get the device\*(Aqs label\&. If this option is given, the usual check output is omitted, and the label of the loaded volume is printed to stdout\&. Returns with error if the label is not found\&. .RE .PP \fI\-\-properties [list]\fR .RS 4 -List device properties\&. If this option is given, the usual check output is omitted, and property values are printed to stdout, one per line, as a property name, followed by \'=\', followed by the property value\&. Returns with error if properties are not available\&. +List device properties\&. If this option is given, the usual check output is omitted, and property values are printed to stdout, one per line, as a property name, followed by \*(Aq=\*(Aq, followed by the property value\&. Returns with error if properties are not available\&. .sp If \fIlist\fR diff --git a/man/amdump.8 b/man/amdump.8 index c1e5427..59d1e9c 100644 --- a/man/amdump.8 +++ b/man/amdump.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amdump .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMDUMP" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMDUMP" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -110,7 +119,7 @@ The exit code of \fBamdump\fR is the ORed value of: 1 = error 2 = a dle give strange message 4 = a dle failed - 8 = Don\'t know the status of a dle (RESULT_MISSING in the report) + 8 = Don\*(Aqt know the status of a dle (RESULT_MISSING in the report) 16 = tape error or no more tape .fi .SH "SEE ALSO" diff --git a/man/amdump_client.8 b/man/amdump_client.8 index 454dfa4..8408481 100644 --- a/man/amdump_client.8 +++ b/man/amdump_client.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amdump_client .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMDUMP_CLIENT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMDUMP_CLIENT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -26,7 +35,7 @@ amdump_client \- back up all disks in an Amanda configuration .SH "DESCRIPTION" .PP \fBAmdump_client\fR -initiate backup on the client\&. There are two commands (CMD): +initiate backup on the client\&. There are three commands (CMD): .PP \fBlist\fR .RS 4 diff --git a/man/amfetchdump.8 b/man/amfetchdump.8 index b9ad3ca..63e155a 100644 --- a/man/amfetchdump.8 +++ b/man/amfetchdump.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amfetchdump .\" Author: John Stange -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMFETCHDUMP" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMFETCHDUMP" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -22,7 +31,7 @@ amfetchdump \- extract backup images from multiple Amanda tapes\&. .SH "SYNOPSIS" .HP \w'\fBamfetchdump\fR\ 'u -\fBamfetchdump\fR [\-phcClawns] [\-d\ \fIdevice\fR] [\-O\ \fIdirectory\fR] [\-b\ \fIblocksize\fR] [\-\-header\-fd\ \fIfd\fR] [\-\-header\-file\ \fIfilename\fR] [\fB\-o\fR\ \fIconfigoption\fR...] \fIconfig\fR \fIhostname\fR [\fIdisk\fR\ [\ \fIdate\fR\ [\ \fIlevel\fR\ [\ \fIhostname\fR\ [\&.\&.\&.]\ ]\ ]\ ]] +\fBamfetchdump\fR [\-c|\-C|\-L] [\-p|\-n] [\-a] [\-O\ \fIdirectory\fR] [\-d\ \fIdevice\fR] [\-h] [\-\-header\-file\ \fIfilename\fR] [\-\-header\-fd\ \fIfd\fR] [\fB\-o\fR\ \fIconfigoption\fR...] \fIconfig\fR \fIhostname\fR [\fIdisk\fR\ [\ \fIdate\fR\ [\ \fIlevel\fR\ [\ \fIhostname\fR\ [\&.\&.\&.]\ ]\ ]\ ]] .SH "DESCRIPTION" .PP \fBAmfetchdump\fR @@ -123,12 +132,12 @@ See the "\fBCONFIGURATION OVERRIDE\fR" section in All the examples here assume your configuration is called \fISetA\fR\&. .PP -Here\'s a simple case, restoring all known dumps of the host vanya to the current working directory\&. +Here\*(Aqs a simple case, restoring all known dumps of the host vanya to the current working directory\&. .nf $ amfetchdump SetA vanya .fi .PP -A more likely scenario involves restoring a particular dump from a particular date\&. We\'ll pipe this one to +A more likely scenario involves restoring a particular dump from a particular date\&. We\*(Aqll pipe this one to \fBGNU\-tar\fR as well, to automatically extract the dump\&. .nf @@ -137,7 +146,7 @@ $ amfetchdump \-p SetA vanya /home 20051020 | gtar \-xvpf \- .SH "CAVEATS" .PP \fBAmfetchdump\fR -is dependent on accessing your server\'s config, tape changer, and (normally) dump logs\&. As such, it\'s not necessarily the most useful tool when those have all been wiped out and you desperately need to pull things from your tape\&. Pains have been taken to make it as capable as possible, but for seriously minimialist restores, look to +is dependent on accessing your server\*(Aqs config, tape changer, and (normally) dump logs\&. As such, it\*(Aqs not necessarily the most useful tool when those have all been wiped out and you desperately need to pull things from your tape\&. Pains have been taken to make it as capable as possible, but for seriously minimialist restores, look to \fBamrestore\fR(8) or \fBdd\fR(8) diff --git a/man/amflush.8 b/man/amflush.8 index 38f8615..a36d55b 100644 --- a/man/amflush.8 +++ b/man/amflush.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amflush .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMFLUSH" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMFLUSH" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -130,12 +139,12 @@ to tape drive /dev/rmt/0mn\&. Expecting tape DMP014 or a new tape\&. (The last dumps were to tape DMP013) Are you sure you want to do this? yes Running in background, you can log off now\&. -You\'ll get mail when amflush is finished\&. +You\*(Aqll get mail when amflush is finished\&. .fi .PP -The following example causes amflush to flush everything to tape, then ejects tape, using \'at\' to run the task in the background\&. +The following example causes amflush to flush everything to tape, then ejects tape, using \*(Aqat\*(Aq to run the task in the background\&. .nf -% echo \'amflush \-b \-f MyConfig && mt offline\' | at now +% echo \*(Aqamflush \-b \-f MyConfig && mt offline\*(Aq | at now .fi .SH "EXIT CODE" @@ -144,7 +153,7 @@ The exit code of \fBamflush\fR is the ORed value of: 0 = success 1 = error 4 = a dle failed - 8 = Don\'t know the status of a dle (RESULT_MISSING in the report) + 8 = Don\*(Aqt know the status of a dle (RESULT_MISSING in the report) 16 = tape error or no more tape .fi .SH "SEE ALSO" diff --git a/man/amgetconf.8 b/man/amgetconf.8 index 20121ad..adcc61d 100644 --- a/man/amgetconf.8 +++ b/man/amgetconf.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amgetconf .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMGETCONF" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMGETCONF" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -37,7 +46,7 @@ assumes it is being run from the configuration directory and that \fIamanda\&.conf\fR is present\&. The order of options and arguments does not matter\&. \fIparameter\fR -is always case\-insensitive, and \'\-\' and \'_\' are treated as identical, just as in +is always case\-insensitive, and \*(Aq\-\*(Aq and \*(Aq_\*(Aq are treated as identical, just as in \fBamanda.conf\fR(5)\&. .PP See the "\fBCONFIGURATION OVERRIDE\fR" section in @@ -236,7 +245,7 @@ Find out the current tape type: DLT4000\-IV .fi .PP -Find out that tape type\'s length: +Find out that tape type\*(Aqs length: .nf % amgetconf daily tapetype:DLT4000\-IV:length 1024000 diff --git a/man/amgpgcrypt.8 b/man/amgpgcrypt.8 index 5c75837..fc8e3e4 100644 --- a/man/amgpgcrypt.8 +++ b/man/amgpgcrypt.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amgpgcrypt .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMGPGCRYPT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMGPGCRYPT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -126,12 +135,12 @@ encrypt data with this public key along with the cipher algorithm\&. .PP \fB$AMANDA_HOME/\&.gnupg/secring\&.gpg\fR .RS 4 -The private/secret key\&. It\'s only needed during amrecover/amrestore\&. Store and protect it properly during other time\&. +The private/secret key\&. It\*(Aqs only needed during amrecover/amrestore\&. Store and protect it properly during other time\&. .RE .PP \fB$AMANDA_HOME/\&.am_passphrase\fR .RS 4 -The passphrase\&. It\'s only needed during amrecover/amrestore\&. Store and protect it properly during other time\&. +The passphrase\&. It\*(Aqs only needed during amrecover/amrestore\&. Store and protect it properly during other time\&. .RE .SH "BUGS" .PP diff --git a/man/amgtar.8 b/man/amgtar.8 index 5af9bcb..e6d1f8e 100644 --- a/man/amgtar.8 +++ b/man/amgtar.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amgtar .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMGTAR" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMGTAR" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -23,9 +32,13 @@ amgtar \- Amanda Application to interface with GNU Tar .SH "DESCRIPTION" .PP Amgtar is an Amanda Application API script\&. It should not be run by users directly\&. It uses GNU Tar to backup and restore data\&. +.PP +The +\fBdiskdevice\fR +in the disklist (DLE) must be the directory to backup\&. .SH "PROPERTIES" .PP -This section lists the properties that control amgtar\'s functionality\&. See +This section lists the properties that control amgtar\*(Aqs functionality\&. See \fBamanda-applications\fR(7) for information on application properties and how they are configured\&. .PP @@ -38,7 +51,7 @@ If "YES" (the default), amgtar use the \fI\-\-atime\-preserve=system\fR option o CHECK\-DEVICE .RS 4 -If "YES" (the default), amgtar checks that the device number doesn\'t change for each file\&. If "NO", changes in device number are ignored\&. To ignore device numbers, tar must support the \fI\-\-no\-check\-device\fR option (gnutar 1\&.19\&.90 and newer)\&. This option is needed for some filesystems and devices on which device numbers change frequently, such as LVM or FiberChannel\&. +If "YES" (the default), amgtar checks that the device number doesn\*(Aqt change for each file\&. If "NO", changes in device number are ignored\&. To ignore device numbers, tar must support the \fI\-\-no\-check\-device\fR option (gnutar 1\&.19\&.90 and newer)\&. This option is needed for some filesystems and devices on which device numbers change frequently, such as LVM or FiberChannel\&. .RE .PP COMMAND\-OPTIONS @@ -107,7 +120,7 @@ If "YES" (the default), gnutar will store sparse files efficiently\&. If "NO", t NO\-UNQUOTE .RS 4 -If "NO" (the default), gnutar doesn\'t get the \fI\-\-no\-unquote\fR option and the diskname can\'t have some characters, eg\&. \'\e\'\&. If "YES", then the \fI\-\-no\-unquote\fR option is given to gnutar and the diskname can have any characters\&. This option is available only if you are using tar\-1\&.16 or newer\&. +If "NO" (the default), gnutar doesn\*(Aqt get the \fI\-\-no\-unquote\fR option and the diskname can\*(Aqt have some characters, eg\&. \*(Aq\e\*(Aq\&. If "YES", then the \fI\-\-no\-unquote\fR option is given to gnutar and the diskname can have any characters\&. This option is available only if you are using tar\-1\&.16 or newer\&. .RE .PP ACLS @@ -164,7 +177,7 @@ To treat one of these default patterns differently, specify it explicitly in a d STRANGE .RS 4 -List all regex (POSIX Extended Regular Expression syntax) that are strange output from gtar\&. All gtar output that doesn\'t match a normal or ignore regex are strange by default\&. The result of the dump is STRANGE if gtar produce a strange output\&. These output are in the "FAILED DUMP DETAILS" section of the email report\&. +List all regex (POSIX Extended Regular Expression syntax) that are strange output from gtar\&. All gtar output that doesn\*(Aqt match a normal or ignore regex are strange by default\&. The result of the dump is STRANGE if gtar produce a strange output\&. These output are in the "FAILED DUMP DETAILS" section of the email report\&. .RE .PP VERBOSE @@ -196,7 +209,7 @@ to match a single character\&. Character classes are represented with .fi .PP Similarly, include expressions are supplied to -\fBGNU\-tar\fR\'s +\fBGNU\-tar\fR\*(Aqs \fB\-\-files\-from\fR option\&. This option ordinarily does not accept any sort of wildcards, but amgtar "manually" applies glob pattern matching to include expressions with only one slash\&. The expressions must still begin with "\&./", so this effectively only allows expressions like "\&./[abc]*" or "\&./*\&.txt"\&. .SH "EXAMPLE" diff --git a/man/amlabel.8 b/man/amlabel.8 index 3327b5c..66c1862 100644 --- a/man/amlabel.8 +++ b/man/amlabel.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amlabel .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMLABEL" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMLABEL" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -114,26 +123,26 @@ Label the tape in slot 3 of the changer with the label "DMP003": .fi .SH "MESSAGES" .PP -Label \'\fIlabel\fR\' doesn\'t match labelstr \'\fIlabelstr\fR\' +Label \*(Aq\fIlabel\fR\*(Aq doesn\*(Aqt match labelstr \*(Aq\fIlabelstr\fR\*(Aq .RS 4 The given label does not match the configured labelstr\&. Even with \fB\-f\fR, this is an error\&. .RE .PP -Label \'\fIlabel\fR\' already on a volume +Label \*(Aq\fIlabel\fR\*(Aq already on a volume .RS 4 The given label is already on another volume in the tapelist, and Amanda will not write it to this volume unless forced\&. .RE .PP -Found label \'\fIlabel\fR\', but it is not from configuration \fIconfig\fR\&. +Found label \*(Aq\fIlabel\fR\*(Aq, but it is not from configuration \fIconfig\fR\&. .RS 4 The label \fBamlabel\fR -found on the volume does not match this configuration\'s +found on the volume does not match this configuration\*(Aqs \fBlabelstr\fR, so it is probably part of a different Amanda configuration\&. Amanda will not overwrite the label unless it is forced\&. .RE .PP -Volume with label \'\fIlabel\fR\' contains data from this configuration\&. +Volume with label \*(Aq\fIlabel\fR\*(Aq contains data from this configuration\&. .RS 4 The label \fBamlabel\fR diff --git a/man/amoverview.8 b/man/amoverview.8 index 854a941..8041bb8 100644 --- a/man/amoverview.8 +++ b/man/amoverview.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amoverview .\" Author: Stefan G. Weichinger -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMOVERVIEW" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMOVERVIEW" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/ampgsql.8 b/man/ampgsql.8 index 9252f49..2ef913a 100644 --- a/man/ampgsql.8 +++ b/man/ampgsql.8 @@ -1,13 +1,22 @@ '\" t .\" Title: ampgsql .\" Author: Nikolas Coukouma -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMPGSQL" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMPGSQL" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -128,7 +137,6 @@ back up the required WAL files optionally delete WAL files that are no longer necessary .RE .sp -.RE The two dumps are made with GNU Tar, to data_dir\&.tar and @@ -139,49 +147,88 @@ A level N backup creates a single tar file containing all WAL files since the pr .PP This section lists the \fBamanda.conf\fR(5) -properties that control ampsql\'s functionality\&. See +properties that control ampsql\*(Aqs functionality\&. See \fBamanda-applications\fR(7) for information on application properties and how they are configured\&. .PP +ARCHIVEDIR +.RS 4 +Directory that WAL segment files are archived to, as specified by the archive_command in PosgreSQL\*(Aqs postgresql\&.conf\&. The amanda user on the client must have at least read and execute permission on this directory, and preferably write\&. Without write permission, Amanda cannot clean up expired WAL and backup files\&. +.RE +.PP +CLEANUPWAL +.RS 4 +Whether or not to remove old WAL segment files during base backups\&. Defaults to yes\&. +.RE +.PP +DB +.RS 4 +Database to connect to\&. Defaults to "template1" (which exists by default)\&. +.RE +.PP DIRECTORY .RS 4 - For restore command only, the data is recoved in that directory\&. Must be a unix path\&. .RE .PP GNUTAR\-PATH .RS 4 - -Path to the GNU tar executable\&. This option only has an effect during restore\&. -The default is set when Amanda is built by the \-\-with\-gnutar configure option\&. +Path to the GNU tar executable\&. This option only has an effect during restore\&. The default is set when Amanda is built by the \-\-with\-gnutar configure option\&. +.RE +.PP +HOST +.RS 4 +Host to connect to\&. If it starts with "/" it will be interepreted as a directory that holds the socket file\&. PostgreSQL defaults to /tmp\&. +.RE +.PP +MAX\-WAL\-WAIT +.RS 4 +The maximum amount of time to wait for PG_STOP_BACKUP to archive a WAL file\&. In versions of PostgreSQL before 8\&.2, PG_STOP_BACKUP does not automatically archive the latest WAL file, so a quiet database may wait a very long time before archiving the WAL file\&. Default: 60 seconds\&. Set to 0 to wait forever\&. +.RE +.PP +PASSFILE +.RS 4 +Connect using the creditials in this file\&. Each line should have the format "hostname:port:database:username:password"\&. The permissions must permit it to be read only by the user, or the file will not be used\&. Only usable with Postgres 8\&.1 and up\&. +.RE +.PP +PORT +.RS 4 +The TCP port to connect to, or the suffix of the socket file\&. PostgreSQL defaults to 5432\&. +.RE +.PP +PSQL\-PATH +.RS 4 +Path to the psql binary\&. If not specified, the PATH environment variable will be searched\&. .RE .PP STATEDIR .RS 4 - -Directory for saving state about backups already made\&. The default is set -when Amanda is built by the \-\-with\-gnutar\-listdir configure option\&. +Directory for saving state about backups already made\&. The default is set when Amanda is built by the \-\-with\-gnutar\-listdir configure option\&. .RE .PP TMPDIR .RS 4 - -Directory to use for temporary files during the backup process\&. It should -have enough space to store a complete copy of the database\&. The default is set -when Amanda is built by the \-\-with\-tmpdir configure option\&. +Directory to use for temporary files during the backup process\&. It should have enough space to store a complete copy of the database\&. The default is set when Amanda is built by the \-\-with\-tmpdir configure option\&. +.RE +.PP +USER +.RS 4 +User to connect as\&. It must be a superuser\&. .RE .SH "CLIENT PROPERTIES" .PP +Client properties are deprecated\&. All properties should be set in the dumptype\&. +.PP This section lists the \fBamanda-client.conf\fR(5) -properties that control ampsql\'s functionality\&. If a property is prefixed with the diskname and an underscore, then it will be used when that diskname is being backed up\&. For example, if the properties PG\-DATADIR and foo\-PG\-DATADIR are set, the value of PG\-DATADIR will be used when bar and baz are being backed up, but foo\-PG\-DATADIR will be used when foo is being backed up\&. Disknames are specified in the +properties that control ampsql\*(Aqs functionality\&. If a property is prefixed with the diskname and an underscore, then it will be used when that diskname is being backed up\&. For example, if the properties PG\-DATADIR and foo\-PG\-DATADIR are set, the value of PG\-DATADIR will be used when bar and baz are being backed up, but foo\-PG\-DATADIR will be used when foo is being backed up\&. Disknames are specified in the \fBdisklist\fR(5)\&. .PP PG\-ARCHIVEDIR .RS 4 Directory that WAL segment files are archived to, as specified by the archive_command -in PosgreSQL\'s postgresql\&.conf\&. The amanda user on the client must have at least read +in PosgreSQL\*(Aqs postgresql\&.conf\&. The amanda user on the client must have at least read and execute permission on this directory, and preferably write\&. Without write permission, Amanda cannot clean up expired WAL and backup files\&. .RE @@ -263,7 +310,7 @@ in the data directory, owned by the proper user and with proper permissions\&. A \fBrestore_command\fR to it, e\&.g\&., .nf -restore_command = \'cp /path/to/archive_dir/%f "%p"\' +restore_command = \*(Aqcp /path/to/archive_dir/%f "%p"\*(Aq .fi .PP Start the database server, and examine the logs to track the process of the recovery\&. When the recovery is complete, the server will transition into a running state, and will move the diff --git a/man/amplot.8 b/man/amplot.8 index 4aed6a1..a26efa0 100644 --- a/man/amplot.8 +++ b/man/amplot.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amplot .\" Author: Olafur Gudmundsson -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMPLOT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMPLOT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/amraw.8 b/man/amraw.8 index c672104..66133d0 100644 --- a/man/amraw.8 +++ b/man/amraw.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amraw .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMRAW" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMRAW" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -26,12 +35,16 @@ Amraw is an Amanda Application API script\&. It should not be run by users direc .PP Amraw can backup only one directory entry, it can be a single file, a raw device, anything that amanda can open and read\&. .PP -Restore is done in place, an open is done and the data is written to it\&. A file owned by root and permission 0600 is create if the directory entry doesn\'t exist before the restore\&. +The +\fBdiskdevice\fR +in the disklist (DLE) must be the filename amraw open and read\&. +.PP +Restore is done in place, an open is done and the data is written to it\&. A file owned by root and permission 0600 is create if the directory entry doesn\*(Aqt exist before the restore\&. .PP Only full backup is allowed .SH "PROPERTIES" .PP -This section lists the properties that control amgtar\'s functionality\&. See +This section lists the properties that control amgtar\*(Aqs functionality\&. See \fBamanda-applications\fR(7) for information on application properties and how they are configured\&. .PP diff --git a/man/amrecover.8 b/man/amrecover.8 index 4784997..6c6dd4d 100644 --- a/man/amrecover.8 +++ b/man/amrecover.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amrecover .\" Author: Alan M. McIvor -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMRECOVER" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMRECOVER" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -86,7 +95,7 @@ Tape device to use on the tape server host\&. .PP \fB\-h hostname\fR .RS 4 -Hostname to begin restoring; defaults to the system\'s hostname\&. +Hostname to begin restoring; defaults to the system\*(Aqs hostname\&. .RE .PP \fB\-o\fR \fIclientconfigoption\fR @@ -98,9 +107,9 @@ See the "\fBCONFIGURATION OVERRIDE\fR" section in .PP The default \fBauth\fR -is \'BSDTCP\', you can set a different auth in the +is \*(AqBSDTCP\*(Aq, you can set a different auth in the \fBamanda\-client\&.conf\fR -file or by specifying the \'\-oauth=bsd\' command line argument\&. +file or by specifying the \*(Aq\-oauth=bsd\*(Aq command line argument\&. .SH "COMMANDS" .PP \fBAmrecover\fR @@ -248,6 +257,13 @@ is \fBtar\fR, they are extracted on the local machine the same way tar volumes are extracted\&. .RE .PP +\fBsettranslate\fR [\fBon\fR|\fBoff\fR] +.RS 4 +Default: on\&. Translate escaped octal value (\*(Aq\e000\*(Aq) in the index file to their corespondig characters, it improve the interface if amrecover is run in the same charset as the filename\&. Set it to +\fBoff\fR +if the charset of some filename is not compatible with the amrecover charset\&. +.RE +.PP \fBmode\fR .RS 4 Displays the extracting mode for Samba shares\&. @@ -372,7 +388,7 @@ Setting restore date to today (1997\-12\-09) 200 Working date set to 1997\-12\-09\&. 200 Config set to MyConfig\&. 200 Dump host set to this\-host\&.some\&.org\&. -$CWD \'/var/log\' is on disk \'/var\' mounted at \'/var\'\&. +$CWD \*(Aq/var/log\*(Aq is on disk \*(Aq/var\*(Aq mounted at \*(Aq/var\*(Aq\&. 200 Disk set to /var\&. /var/log WARNING: not on root of selected filesystem, check man\-page! @@ -406,7 +422,7 @@ Continue? [Y/n]: y Load tape DMP014 now Continue? [Y/n/t]: y -set owner/mode for \'\&.\'? [yn] n +set owner/mode for \*(Aq\&.\*(Aq? [yn] n amrecover> quit 200 Good bye\&. # ls \-l syslog\&.7 diff --git a/man/amreport.8 b/man/amreport.8 index 691227d..95b8a7f 100644 --- a/man/amreport.8 +++ b/man/amreport.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amreport .\" Author: Stefan G. Weichinger -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMREPORT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMREPORT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -101,7 +110,7 @@ from the Amanda configuration\&. .PP \fB\-i\fR .RS 4 -Don\'t email the report\&. +Don\*(Aqt email the report\&. .RE .PP \fB\-M\fR \fIaddress\fR @@ -151,9 +160,9 @@ Force script mode\&. Has no other effect\&. .RE .SH "TEXT REPORT FORMAT" .PP -Amanda\'s text report format is divided into several sections\&. Some of these sections only appear if they are not empty\&. +Amanda\*(Aqs text report format is divided into several sections\&. Some of these sections only appear if they are not empty\&. .PP -Although newer versions of Amanda try to use the term "volume" to refer to a unit of storage, amreport still uses the term "tape", even if backups are done to non\-tape devices, to allow scripts which parse amreport\'s output to continue to function\&. +Although newer versions of Amanda try to use the term "volume" to refer to a unit of storage, amreport still uses the term "tape", even if backups are done to non\-tape devices, to allow scripts which parse amreport\*(Aqs output to continue to function\&. .SS "Summary" .nf Hostname: bkserver @@ -271,7 +280,7 @@ Number of split parts writtten to storage\&. If this number is very large, then .PP Avg Tp Write Rate .RS 4 -Taper speed, based on the tape time and tape size, above\&. Note that, because the tape time includes time spent on tasks other than writing to tape, this does not necessary reflect the device\'s real write speed\&. However, the value is useful for capacity planning, as it reflects a realistic estimate of how quickly Amanda can write data to storage\&. +Taper speed, based on the tape time and tape size, above\&. Note that, because the tape time includes time spent on tasks other than writing to tape, this does not necessary reflect the device\*(Aqs real write speed\&. However, the value is useful for capacity planning, as it reflects a realistic estimate of how quickly Amanda can write data to storage\&. .RE .SS "Usage by Tape" .nf @@ -348,7 +357,7 @@ The information printed varies slightly between label templates due to size cons .PP Add the \fIlbl\-templ\fR -parameter to the tapetype definition in amanda\&.conf to enable labels\&. If you don\'t add this line to your tapetype definition, +parameter to the tapetype definition in amanda\&.conf to enable labels\&. If you don\*(Aqt add this line to your tapetype definition, \fBamreport\fR will not print tape labels\&. .PP @@ -381,7 +390,7 @@ The exit code of \fBamreport\fR is the ORed value of: 1 = error 2 = a dle give strange message 4 = a dle failed - 8 = Don\'t know the status of a dle (RESULT_MISSING in the report) + 8 = Don\*(Aqt know the status of a dle (RESULT_MISSING in the report) 16 = tape error or no more tape .fi .SH "SEE ALSO" diff --git a/man/amrestore.8 b/man/amrestore.8 index 24fdfb8..a6bb8e9 100644 --- a/man/amrestore.8 +++ b/man/amrestore.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amrestore .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMRESTORE" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMRESTORE" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/amrmtape.8 b/man/amrmtape.8 index 118d4dd..66699bf 100644 --- a/man/amrmtape.8 +++ b/man/amrmtape.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amrmtape .\" Author: Adrian T. Filipi-Martin -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMRMTAPE" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMRMTAPE" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -42,7 +51,7 @@ Specify which changer to use when erasing \fB\-\-cleanup\fR .RS 4 Remove logs and indexes associated with -\fIlabel\fR\&. Otherwise, they\'ll remain until the next run of amdump\&. +\fIlabel\fR\&. Otherwise, they\*(Aqll remain until the next run of amdump\&. .RE .PP \fB\-\-dryrun\fR, \fB\-n\fR diff --git a/man/amsamba.8 b/man/amsamba.8 index 95be24d..291e71f 100644 --- a/man/amsamba.8 +++ b/man/amsamba.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amsamba .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMSAMBA" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMSAMBA" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -24,7 +33,9 @@ amsamba \- Amanda Application to interface with smbclient .PP Amsamba is an Amanda Application API script\&. It should not be run by users directly\&. It uses smbclient to backup and restore data\&. .PP -The device name in the disklist must have the form \'//CIFSHOST/SHARE/SUBDIR\' where CIFSHOST is the CIFS host containing the data to be backed up, SHARE is the share to connect, and subdir is the subdirectory to backup\&. \'/subdir\' can be ommited, in which case the complete share is archived\&. +The +\fBdiskdevice\fR +in the disklist (DLE) must have the form \*(Aq//CIFSHOST/SHARE/SUBDIR\*(Aq where CIFSHOST is the CIFS host containing the data to be backed up, SHARE is the share to connect, and subdir is the subdirectory to backup\&. \*(Aq/subdir\*(Aq can be ommited, in which case the complete share is archived\&. .PP Unlike most applications, amsamba backs up and restores data located on a different system from that where amsamba itself runs\&. The host containing the data is the CIFS host\&. In practice, amsamba is usually run on the same system as the Amanda server, with a DLE like .sp @@ -32,10 +43,10 @@ Unlike most applications, amsamba backs up and restores data located on a differ localhost "//CIFSHOST/SHARENAME" amsamba\-dumptype .fi .PP -Include or exclude can be used, but not both\&. The path for \'exclude list\' or \'include list\' must be absolute path on the CIFS host\&. The estimate calculates the complete size of the share, without regard for include or exclude directives\&. It will be larger than the actual dump if you use include or exclude\&. Using \'estimate server\' in the dumptype could give better estimate\&. +Include or exclude can be used, but not both\&. The path for \*(Aqexclude list\*(Aq or \*(Aqinclude list\*(Aq must be absolute path on the CIFS host\&. The estimate calculates the complete size of the share, without regard for include or exclude directives\&. It will be larger than the actual dump if you use include or exclude\&. Using \*(Aqestimate server\*(Aq in the dumptype could give better estimate\&. .SH "PROPERTIES" .PP -This section lists the properties that control amsamba\'s functionality\&. See +This section lists the properties that control amsamba\*(Aqs functionality\&. See \fBamanda-applications\fR(7) for information on application properties and how they are configured\&. .PP @@ -65,14 +76,14 @@ The format of the file is as follow: Sharename User%Password Domain .fi -Sharename is \'//HOST/SHARE\' without the SUBDIR\&. +Sharename is \*(Aq//HOST/SHARE\*(Aq without the SUBDIR\&. Sharename can be quoted, -it can be \'*\' to match all share, -it can be \'//pc\-host/*\' to match all share on pc\-host\&. +it can be \*(Aq*\*(Aq to match all share, +it can be \*(Aq//pc\-host/*\*(Aq to match all share on pc\-host\&. User is the username use to connect to the share\&. Password is the password use to connect to the share\&. -\'%Password\' is optional if the user can connect to the share without password\&. -\'User%Password\' is optional, the user \'guest\' without password is use to connect to the share\&. +\*(Aq%Password\*(Aq is optional if the user can connect to the share without password\&. +\*(AqUser%Password\*(Aq is optional, the user \*(Aqguest\*(Aq without password is use to connect to the share\&. Domain is optional\&. Example: .nf //another\-pc/share otheruser%otherpw domain diff --git a/man/amserverconfig.8 b/man/amserverconfig.8 index d6082a3..a038d9a 100644 --- a/man/amserverconfig.8 +++ b/man/amserverconfig.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amserverconfig .\" Author: Kevin Till -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMSERVERCONFIG" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMSERVERCONFIG" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -34,7 +43,7 @@ does not change existing Amanda configurations\&. must be run by user amandabackup\&. .SH "OPTIONS" .PP -Options may be abbreviated, as long as the abbreviation is not ambiguous\&. Option argument can either separated by \'=\' or a space\&. Example: \-\-templ=harddisk \-\-tapedev /dev/nst0 +Options may be abbreviated, as long as the abbreviation is not ambiguous\&. Option argument can either separated by \*(Aq=\*(Aq or a space\&. Example: \-\-templ=harddisk \-\-tapedev /dev/nst0 .PP \fBamserverconfig\fR @@ -52,7 +61,7 @@ are the valid inputs for this option\&. Pre\-configured template files can be fo .sp If tape\-changer is chosen for this option, program mtx is required\&. \fBamserverconfig\fR -will search for mtx in the following directory: "/usr/sbin", "/usr/local/sbin", "/usr/local/bin", "/usr/bin", "/bin" and amandabackup\'s PATH\&. +will search for mtx in the following directory: "/usr/sbin", "/usr/local/sbin", "/usr/local/bin", "/usr/bin", "/bin" and amandabackup\*(Aqs PATH\&. .sp If harddisk is chosen and \-\-no\-vtape is not specified, \fBamserverconfig\fR diff --git a/man/amservice.8 b/man/amservice.8 index 35b751e..1cd2768 100644 --- a/man/amservice.8 +++ b/man/amservice.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amservice .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMSERVICE" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMSERVICE" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -83,7 +92,7 @@ The exit code of \fBamservice\fR is one of: .PP As \fBamservice\fR -doesn\'t parse the REP packet, it can only detect failures in executing amandad on the client\&. +doesn\*(Aqt parse the REP packet, it can only detect failures in executing amandad on the client\&. \fBamservice\fR can exit with value 0 even if the user is not authorized to execute the service\&. An error message will be printed\&. .SH "SEE ALSO" diff --git a/man/amstar.8 b/man/amstar.8 index 9b1d9ce..1434d7e 100644 --- a/man/amstar.8 +++ b/man/amstar.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amstar .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMSTAR" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMSTAR" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -23,14 +32,18 @@ amstar \- Amanda Application to interface with star .SH "DESCRIPTION" .PP Amstar is an Amanda Application API script\&. It should not be run by users directly\&. It uses star to backup and restore data\&. +.PP +The +\fBdiskdevice\fR +in the disklist (DLE) must be the directory to backup\&. .SH "INCLUDE - EXCLUDE" .PP -amstar doesn\'t support include\&. Both \'exclude list\' and \'exclude file\' are supported\&. There is a maximum of 100 patterns (limit of star)\&. +amstar doesn\*(Aqt support include\&. Both \*(Aqexclude list\*(Aq and \*(Aqexclude file\*(Aq are supported\&. There is a maximum of 100 patterns (limit of star)\&. .PP Moving directories into and out of directories on the exclude list causes incremental backups to not contain the files in the moved directories until the next full backup unless the moved files are modified after the move\&. .SH "PROPERTIES" .PP -This section lists the properties that control amstar\'s functionality\&. See +This section lists the properties that control amstar\*(Aqs functionality\&. See \fBamanda-applications\fR(7) for information on application properties and how they are configured\&. .PP @@ -64,7 +77,7 @@ If set, gnutar will backup from that directory instead of the \fIdiskdevice\fR s ONE\-FILE\-SYSTEM .RS 4 -The default is "YES"\&. This property is deprecated and the default value can\'t be changed\&. star requires it when it works in dump mode\&. This corresponds to the \fI\-xdev\fR option of star\&. +The default is "YES"\&. This property is deprecated and the default value can\*(Aqt be changed\&. star requires it when it works in dump mode\&. This corresponds to the \fI\-xdev\fR option of star\&. .RE .PP SPARSE @@ -122,7 +135,7 @@ List all regex (POSIX Extended Regular Expression syntax) that amanda ignore\&. STRANGE .RS 4 -List all regex (POSIX Extended Regular Expression syntax) that are strange output from star\&. All star output that doesn\'t match a normal or ignore regex are strange by default\&. The result of the dump is STRANGE if star produce a strange output\&. These output are in the "FAILED DUMP DETAILS" section of the email report\&. +List all regex (POSIX Extended Regular Expression syntax) that are strange output from star\&. All star output that doesn\*(Aqt match a normal or ignore regex are strange by default\&. The result of the dump is STRANGE if star produce a strange output\&. These output are in the "FAILED DUMP DETAILS" section of the email report\&. .nf "^Perform a level 0 dump first\&.*$" .fi diff --git a/man/amstatus.8 b/man/amstatus.8 index fbe1871..3c7663e 100644 --- a/man/amstatus.8 +++ b/man/amstatus.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amstatus .\" Author: Stefan G. Weichinger -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMSTATUS" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMSTATUS" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -108,7 +117,7 @@ Display statistics about active\-time of taper and dumpers\&. .PP \fB\-\-locale\-independent\-date\-format\fR .RS 4 -Output the date in a locale independent format\&. The format is the same executing: date +\'%Y\-%m\-%d %H:%M:%S %Z\' +Output the date in a locale independent format\&. The format is the same executing: date +\*(Aq%Y\-%m\-%d %H:%M:%S %Z\*(Aq .RE .SH "EXIT CODE" @@ -117,7 +126,7 @@ The exit code of \fBamstatus\fR is the ORed value of: 0 = success 1 = error 4 = a dle failed - 8 = Don\'t know the status of a dle (RESULT_MISSING in the report) + 8 = Don\*(Aqt know the status of a dle (RESULT_MISSING in the report) 16 = tape error or no more tape .fi .SH "SEE ALSO" diff --git a/man/amsuntar.8 b/man/amsuntar.8 index a7479ca..cb6d161 100644 --- a/man/amsuntar.8 +++ b/man/amsuntar.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amsuntar .\" Author: Satya Ganga -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMSUNTAR" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMSUNTAR" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -24,10 +33,14 @@ amsuntar \- Amanda Application to interface with native tar utility available on .PP Amsuntar is an Amanda Application API script\&. It should not be run by users directly\&. It uses Solaris bundled tar utility to backup and restore data\&. Currenty ACLs from ZFS file system can only be backed up using the solaris supplied tar utility\&. .PP -Solaris 10 supports Role Based Access Control(RBAC) which is enabled by default\&. To run backup operations using sun tar utility by under privileged user like amandabackup, amandabackup user need to have proper roles and profiles, specially "Media Backup" profile/role\&. This can be done using \'usermod \-P "Media Backup" amandabackup\' command\&. +The +\fBdiskdevice\fR +in the disklist (DLE) must be the directory to backup\&. +.PP +Solaris 10 supports Role Based Access Control(RBAC) which is enabled by default\&. To run backup operations using sun tar utility by under privileged user like amandabackup, amandabackup user need to have proper roles and profiles, specially "Media Backup" profile/role\&. This can be done using \*(Aqusermod \-P "Media Backup" amandabackup\*(Aq command\&. .SH "PROPERTIES" .PP -This section lists the properties that control amsuntar\'s functionality\&. See +This section lists the properties that control amsuntar\*(Aqs functionality\&. See \fBamanda-applications\fR(7) for information on application properties and how they are configured\&. .PP @@ -100,7 +113,7 @@ To treat one of these default patterns differently, specify it explicitly in a d .PP ERROR .RS 4 -List all regex (perl Regular Expression syntax) that are error output from sun tar\&. All sun tar output that doesn\'t match a normal, ignore or strange regex are error by default\&. The result of the dump is FAILED if sun tar produce an error output\&. These output are in the "FAILED DUMP DETAILS" section of the email report\&. Default values: +List all regex (perl Regular Expression syntax) that are error output from sun tar\&. All sun tar output that doesn\*(Aqt match a normal, ignore or strange regex are error by default\&. The result of the dump is FAILED if sun tar produce an error output\&. These output are in the "FAILED DUMP DETAILS" section of the email report\&. Default values: .sp .nf : Permission denied\e$ diff --git a/man/amtape.8 b/man/amtape.8 index 28caa8c..ce9be5c 100644 --- a/man/amtape.8 +++ b/man/amtape.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amtape .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMTAPE" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMTAPE" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -26,7 +35,7 @@ amtape \- Control Amanda changers .SH "DESCRIPTION" .PP \fBAmtape\fR -is the command\-line interface to Amanda\'s tape changers (\fBamanda-changers\fR(7)) and to the taperscan algorithm (\fBamanda-taperscan\fR(7))\&. +is the command\-line interface to Amanda\*(Aqs tape changers (\fBamanda-changers\fR(7)) and to the taperscan algorithm (\fBamanda-taperscan\fR(7))\&. .PP Tape changers maintain a notion of the \fIcurrent\fR @@ -61,12 +70,12 @@ current\&. .PP \fBinventory\fR .RS 4 -Show the contents of all slots, based on the changer\'s cached metadata\&. This is a quick operation as it does not load or unload any volumes, but is not supported by all changers\&. +Show the contents of all slots, based on the changer\*(Aqs cached metadata\&. This is a quick operation as it does not load or unload any volumes, but is not supported by all changers\&. .RE .PP -\fBshow\fR +\fBshow\fR [slots] .RS 4 -Show the contents of all slots by loading each slot and reading its label\&. This can be very slow\&. +Show the contents of all slots (or listed slots) by loading each slot and reading its label\&. This can be very slow\&. The slots arguments is of the form 1,3\-5,7\&. .RE .PP \fBreset\fR diff --git a/man/amtapetype.8 b/man/amtapetype.8 index 1a4eba7..a3f8c4e 100644 --- a/man/amtapetype.8 +++ b/man/amtapetype.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amtapetype .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMTAPETYPE" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMTAPETYPE" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- diff --git a/man/amtoc.8 b/man/amtoc.8 index c80948b..baf93a4 100644 --- a/man/amtoc.8 +++ b/man/amtoc.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amtoc .\" Author: Nicolas Mayencourt -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMTOC" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMTOC" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -26,7 +35,7 @@ amtoc \- generate TOC (Table Of Contents) for an Amanda run .SH "DESCRIPTION" .PP \fIAmtoc\fR -generates a table of contents for an Amanda run\&. It\'s a perl script (if you don\'t have perl, install it first!)\&. +generates a table of contents for an Amanda run\&. It\*(Aqs a perl script (if you don\*(Aqt have perl, install it first!)\&. .SH "OPTIONS" .PP \fB\-a\fR @@ -49,7 +58,7 @@ Generate the output in tabular form\&. .PP \fB\-f file\fR .RS 4 -Write the output to a file (\'\-\' for stdout)\&. +Write the output to a file (\*(Aq\-\*(Aq for stdout)\&. .RE .PP \fB\-s subs\fR @@ -60,7 +69,7 @@ Evaluate the output file name from \fB\-a\fR option is equivalent to \fB\-s\fR -\fI\'s/$_/\&.toc/\'\fR\&. +\fI\*(Aqs/$_/\&.toc/\*(Aq\fR\&. .RE .PP \fB\-w\fR @@ -76,7 +85,7 @@ Marks the last option so the next parameter is the .PP \fBlogfile\fR .RS 4 -(use \'\-\' for stdin) +(use \*(Aq\-\*(Aq for stdin) .RE .SH "OUTPUT FORMAT" .PP diff --git a/man/amvault.8 b/man/amvault.8 index 2a97c40..8fbc661 100644 --- a/man/amvault.8 +++ b/man/amvault.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amvault .\" Author: Dustin J. Mitchell -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMVAULT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMVAULT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -22,7 +31,7 @@ amvault \- Copy Amanda dumps from one volume to another .SH "SYNOPSIS" .HP \w'\fBamvault\fR\ 'u -\fBamvault\fR [\fB\-o\fR\ \fIconfigoption\fR...] [\-q] [\-\-quiet] [\-n] [\-\-dry\-run] [\-\-fulls\-only] [\-\-export] [\fB\-\-src\-timestamp\fR\ \fIsrc\-timestamp\fR] +\fBamvault\fR [\fB\-o\fR\ \fIconfigoption\fR...] [\-\-dry\-run | \-n] [\-\-quiet | \-q] [\-\-fulls\-only] [\-\-export] [\fB\-\-src\-timestamp\fR\ \fIsrc\-timestamp\fR] .br \fB\-\-label\-template\fR\ \fIlabel\-template\fR \fB\-\-dst\-changer\fR\ \fIdst\-changer\fR [\fB\-\-autolabel\fR\ \fIautolabel\-arg\fR...] .br @@ -43,17 +52,7 @@ Copies data from the run with timestamp \fBsrc\-timestamp\fR onto volumes using the changer \fBdst\-changer\fR, and labeling new volumes with -\fBlabel\-template\fR\&. If -\fBsrc\-timestamp\fR -is "latest", then the most recent amdump or amflush run will be used\&. If -\fB\-\-fulls\-only\fR -is given, then only full (level\-0) dumps are copied\&. -.PP -The -\fB\-\-quiet\fR -(\fB\-q\fR) option will eliminate non\-error messages, and is useful when running amvault from cron\&. The -\fB\-\-dry\-run\fR -(\fB\-n\fR) option will cause amvault to print the dumps it would vault, but not actually perform any vaulting operations\&. +\fBlabel\-template\fR\&. .SS "Secondary Media" .PP The dumps to be read from secondary media can be specified by any combination of dump specifications, @@ -72,28 +71,7 @@ timestamp \- the run in which the dump was written to secondary media\&. The lat .PP The \fB\-\-dst\-changer\fR -must be specified, and names the changer in which tertiary media are stored\&. In general, this should be different from the secondary changer, to eliminate the possibility of overwriting secondary media with tertiary data\&. -.PP -The changer parameter should specify the name of a changer defined in -\fBamanda.conf\fR(5)\&. For example: -.sp -.nf -define changer vaulting_tape { - tapedev "/dev/rmt/1n" - tpchanger "chg\-zd\-mtx" - changerdev "/dev/sg0" - changerfile "vaulting\-changer\&.conf" -} -.fi -.PP -The -\fB\-\-label\-template\fR -option is required, and specifies a label template which is used to generate new labels for tertiary volumes\&. The -\fB\-\-autolabel\fR -option works just like the -\fBautolabel\fR -parameter in -\fBamanda.conf\fR(5), and can be specified multiple times if necessary\&. The default is \'empty\'\&. +must be specified, and names the changer in which tertiary media are stored\&. .PP If \fBamanda.conf\fR(5) @@ -109,10 +87,86 @@ and other appropriate parameters there\&. Then reference that tapetype in the am .nf amvault \-otapetype=TERTIARY \&.\&.\&. .fi +.SH "OPTIONS" .PP +\fB\-\-autolabel\fR [any] [other\-config] [non\-amanda] [volume\-error] [empty] +.RS 4 +Works just like the +\fBautolabel\fR +parameter in +\fBamanda.conf\fR(5), and can be specified multiple times if necessary\&. The default is \*(Aqempty\*(Aq\&. +.RE +.PP +\fB\-\-dst\-changer\fR \fIdst\-changer\fR +.RS 4 +Specifies the changer in which tertiary media are stored\&. In general, this should be different from the secondary changer, to eliminate the possibility of overwriting secondary media with tertiary data\&. +.sp The +\fBdst\-changer\fR +parameter should specify the name of a changer defined in +\fBamanda.conf\fR(5)\&. For example: +.sp +.nf +define changer vaulting_tape { + tapedev "/dev/rmt/1n" + tpchanger "chg\-zd\-mtx" + changerdev "/dev/sg0" + changerfile "vaulting\-changer\&.conf" +} +.fi +.RE +.PP +\fB\-\-dry\-run\fR, \fB\-n\fR +.RS 4 +Cause amvault to print the dumps it would vault, but not actually perform any vaulting operations\&. +.RE +.PP \fB\-\-export\fR -option will cause amvault to attempt to move completed tertiary volumes to import/export slots, where they can be more easily removed by an operator\&. +.RS 4 +Cause amvault to attempt to move completed tertiary volumes to import/export slots, where they can be more easily removed by an operator\&. +.RE +.PP +\fB\-\-\-fulls\-only\fR +.RS 4 +Only full (level\-0) dumps are copied\&. +.RE +.PP +\fB\-\-label\-template\fR \fIlabel\-template\fR +.RS 4 +Specifies a label template which is used to generate new labels for tertiary volumes\&. +.RE +.PP +\fB\-\-quiet\fR, \fB\-q\fR +.RS 4 +Eliminate non\-error messages, and is useful when running amvault from cron\&. +.RE +.PP +\fB\-\-src\-timestamps\fR \fIsrc\-timestamps\fR +.RS 4 +Specifies the timestamps in the format \*(AqYYYYMMDDHHMMSS\*(Aq of the run to vault, can be "latest", then the most recent amdump or amflush run will be used\&. +.RE +.PP +\fB\-o\fR \fIconfigoption\fR +.RS 4 +See the "\fBCONFIGURATION OVERRIDE\fR" section in +\fBamanda\fR(8)\&. +.RE +.SH "EXAMPLES" +.PP +Vault all dump written to tape in the latest amdump or amflush run: +.nf +$ amvault \-\-src\-timestamps latest \-\-label\-template "CONF\-%%%" \-\-dst\-changer vault\-changer CONF +.fi +.PP +Vault all dump written on the run of December 7 2011 12:13:14 : +.nf +$ amvault \-\-src\-timestamps 20111207121314 \-\-label\-template "CONF\-%%%" \-\-dst\-changer vault\-changer CONF +.fi +.PP +Vault all dump dumped on any run of December 7 2011: +.nf +$ amvault \-\-label\-template "CONF\-%%%" \-\-dst\-changer vault\-changer CONF \e* \e* 20111207 +.fi .SH "SEE ALSO" .PP \fBamanda\fR(8), diff --git a/man/amzfs-sendrecv.8 b/man/amzfs-sendrecv.8 index 61c6ba2..bdaacba 100644 --- a/man/amzfs-sendrecv.8 +++ b/man/amzfs-sendrecv.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amzfs-sendrecv .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMZFS\-SENDRECV" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMZFS\-SENDRECV" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -22,7 +31,7 @@ amzfs-sendrecv \- Amanda script to create zfs sendrecv .SH "DESCRIPTION" .PP -amzfs\-sendrecv is an Amanda application implementing the Application API\&. It should not be run by users directly\&. It create a zfs snapshot of the filesystem and backup the snapshot with \'zfs send\'\&. Snapshot are kept after the backup is done, this increase the disk space use on the client but it is neccesary to be able do to incremental backup\&. If you want only full backup, you can disable this feature by setting the KEEP\-SNAPSHOT property to \'NO\'\&. Only the restoration of the complete backup is allowed, it is impossible to restore a single file\&. +amzfs\-sendrecv is an Amanda application implementing the Application API\&. It should not be run by users directly\&. It create a zfs snapshot of the filesystem and backup the snapshot with \*(Aqzfs send\*(Aq\&. Snapshot are kept after the backup is done, this increase the disk space use on the client but it is neccesary to be able do to incremental backup\&. If you want only full backup, you can disable this feature by setting the KEEP\-SNAPSHOT property to \*(AqNO\*(Aq\&. Only the restoration of the complete backup is allowed, it is impossible to restore a single file\&. .PP The application is run as the amanda user, it must have many zfs priviledge: .sp @@ -30,14 +39,16 @@ The application is run as the amanda user, it must have many zfs priviledge: zfs allow \-ldu AMANDA_USER mount,create,rename,snapshot,destroy,send,receive FILESYSTEM .fi .PP -Some system doesn\'t have "zfs allow", but you can give the Amanda backup user the rights to manipulate ZFS filesystems by using the following command: +Some system doesn\*(Aqt have "zfs allow", but you can give the Amanda backup user the rights to manipulate ZFS filesystems by using the following command: .sp .nf usermod \-P "ZFS File System Management,ZFS Storage Management" AMANDA_USER .fi This will require that your run zfs under pfexec, set the PFEXEC property to YES\&. .PP -The format of the DLE must be one of: +The format of the +\fBdiskdevice\fR +in the disklist (DLE) must be one of: .sp .nf Desciption Example @@ -48,17 +59,17 @@ ZFS filesystem datapool/database ZFS logical volume datapool/dbvol .fi .PP -The filesystem doesn\'t need to be mounted\&. +The filesystem doesn\*(Aqt need to be mounted\&. .SH "PROPERTIES" .PP -This section lists the properties that control amzfs\-sendrecv\'s functionality\&. See +This section lists the properties that control amzfs\-sendrecv\*(Aqs functionality\&. See \fBamanda-applications\fR(7) for information on the Application API, application configuration\&. .PP DF\-PATH .RS 4 -Path to the \'df\' binary, search in $PATH by default\&. +Path to the \*(Aqdf\*(Aq binary, search in $PATH by default\&. .RE .PP KEEP\-SNAPSHOT @@ -70,13 +81,13 @@ If "YES" (the default), snapshot are kept after the backup, if set to "NO" then ZFS\-PATH .RS 4 -Path to the \'zfs\' binary, search in $PATH by default\&. +Path to the \*(Aqzfs\*(Aq binary, search in $PATH by default\&. .RE .PP PFEXEC\-PATH .RS 4 -Path to the \'pfexec\' binary, search in $PATH by default\&. +Path to the \*(Aqpfexec\*(Aq binary, search in $PATH by default\&. .RE .PP PFEXEC diff --git a/man/amzfs-snapshot.8 b/man/amzfs-snapshot.8 index 11e9e98..e32a9ab 100644 --- a/man/amzfs-snapshot.8 +++ b/man/amzfs-snapshot.8 @@ -1,13 +1,22 @@ '\" t .\" Title: amzfs-snapshot .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "AMZFS\-SNAPSHOT" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "AMZFS\-SNAPSHOT" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -39,7 +48,7 @@ The script is run as the amanda user, it must have the priviledge to create and zfs allow \-ldu AMANDA_USER mount,snapshot,destroy FILESYSTEM .fi .PP -Some system doesn\'t have "zfs allow", but you can give the Amanda backup user the rights to manipulate ZFS filesystems by using the following command: +Some system doesn\*(Aqt have "zfs allow", but you can give the Amanda backup user the rights to manipulate ZFS filesystems by using the following command: .sp .nf usermod \-P "ZFS File System Management,ZFS Storage Management" AMANDA_USER @@ -61,26 +70,26 @@ ZFS logical volume datapool/dbvol The filesystem must be mounted\&. .SH "PROPERTIES" .PP -This section lists the properties that control amzfs\-snapshot\'s functionality\&. See +This section lists the properties that control amzfs\-snapshot\*(Aqs functionality\&. See \fBamanda-scripts\fR(7) for information on the Script API, script configuration\&. .PP DF\-PATH .RS 4 -Path to the \'df\' binary, search in $PATH by default\&. +Path to the \*(Aqdf\*(Aq binary, search in $PATH by default\&. .RE .PP ZFS\-PATH .RS 4 -Path to the \'zfs\' binary, search in $PATH by default\&. +Path to the \*(Aqzfs\*(Aq binary, search in $PATH by default\&. .RE .PP PFEXEC\-PATH .RS 4 -Path to the \'pfexec\' binary, search in $PATH by default\&. +Path to the \*(Aqpfexec\*(Aq binary, search in $PATH by default\&. .RE .PP PFEXEC diff --git a/man/disklist.5 b/man/disklist.5 index 0f28f3c..84bd2d4 100644 --- a/man/disklist.5 +++ b/man/disklist.5 @@ -1,13 +1,22 @@ '\" t .\" Title: disklist .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: File formats and conventions -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "DISKLIST" "5" "06/02/2011" "Amanda 3\&.3\&.0" "File formats and conventions" +.TH "DISKLIST" "5" "02/21/2012" "Amanda 3\&.3\&.1" "File formats and conventions" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -50,12 +59,12 @@ The name of the disk (a label)\&. In most case, you set your \fBdiskname\fR to the \fBdiskdevice\fR -and you don\'t set the +and you don\*(Aqt set the \fBdiskdevice\&.\fR If you want multiple entries with the same \fBdiskdevice\fR, you must set a different \fBdiskname\fR -for each entry\&. It\'s the +for each entry\&. It\*(Aqs the \fBdiskname\fR that you use on the commandline for any Amanda command\&. Look at the example/disklist file for example\&. .RE @@ -89,7 +98,7 @@ defined in the \fBamanda\&.conf\fR file\&. \fIDumptype\fRs specify backup related parameters, such as whether to compress the backups, whether to record backup results in -/etc/dumpdates, the disk\'s relative priority, etc\&. +/etc/dumpdates, the disk\*(Aqs relative priority, etc\&. .RE .PP \fIspindle\fR diff --git a/man/script-email.8 b/man/script-email.8 index cf2a1c4..bd636da 100644 --- a/man/script-email.8 +++ b/man/script-email.8 @@ -1,13 +1,22 @@ '\" t .\" Title: script-email .\" Author: Jean-Louis Martineau -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: System Administration Commands -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "SCRIPT\-EMAIL" "8" "06/02/2011" "Amanda 3\&.3\&.0" "System Administration Commands" +.TH "SCRIPT\-EMAIL" "8" "02/21/2012" "Amanda 3\&.3\&.1" "System Administration Commands" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -25,7 +34,7 @@ script-email \- Amanda script to send email notifications script\-email is an Amanda script implementing the Script API\&. It should not be run by users directly\&. It sends a notification email to the addresses specified in the MAILTO property\&. .SH "PROPERTIES" .PP -This section lists the properties that control script\-email\'s functionality\&. See +This section lists the properties that control script\-email\*(Aqs functionality\&. See \fBamanda-scripts\fR(7) for information on the Script API, script configuration\&. .PP diff --git a/man/tapelist.5 b/man/tapelist.5 index e1d082a..83fce3e 100644 --- a/man/tapelist.5 +++ b/man/tapelist.5 @@ -1,13 +1,22 @@ '\" t .\" Title: tapelist .\" Author: James da Silva -.\" Generator: DocBook XSL Stylesheets vsnapshot_8273 -.\" Date: 06/02/2011 +.\" Generator: DocBook XSL Stylesheets v1.76.1 +.\" Date: 02/21/2012 .\" Manual: File formats and conventions -.\" Source: Amanda 3.3.0 +.\" Source: Amanda 3.3.1 .\" Language: English .\" -.TH "TAPELIST" "5" "06/02/2011" "Amanda 3\&.3\&.0" "File formats and conventions" +.TH "TAPELIST" "5" "02/21/2012" "Amanda 3\&.3\&.1" "File formats and conventions" +.\" ----------------------------------------------------------------- +.\" * Define some portability stuff +.\" ----------------------------------------------------------------- +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.\" http://bugs.debian.org/507673 +.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html +.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +.ie \n(.g .ds Aq \(aq +.el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- @@ -43,7 +52,7 @@ is one of "reuse" or "no\-reuse" and tells Amanda whether the tape may be reused dumps\&. See the \fBreuse\fR options of -\fBamadmin\fR(8)\&. The optional barcode is prefixed with \'BARCODE\' if the volume have a barcode\&. The optional meta label is prefixed with \'META\' if the volume is on a meta volume\&. The optional comment is prefixed with a \'#\' and continues to the end of the line\&. Amanda will maintain this comment until the tape is overwritten\&. Note that comments are not allowed on blank lines\&. +\fBamadmin\fR(8)\&. The optional barcode is prefixed with \*(AqBARCODE\*(Aq if the volume have a barcode\&. The optional meta label is prefixed with \*(AqMETA\*(Aq if the volume is on a meta volume\&. The optional comment is prefixed with a \*(Aq#\*(Aq and continues to the end of the line\&. Amanda will maintain this comment until the tape is overwritten\&. Note that comments are not allowed on blank lines\&. .PP The file is sorted such that the most\-recently used tape appears on the first line, and the oldest tape appears on the last line\&. .PP diff --git a/man/xml-source/amanda-changers.7.xml b/man/xml-source/amanda-changers.7.xml index 1520f27..0a69b1a 100644 --- a/man/xml-source/amanda-changers.7.xml +++ b/man/xml-source/amanda-changers.7.xml @@ -430,7 +430,7 @@ slotinfofile=FILENAME #### record slot information to this file, in chg-rait:{CHILD1,CHILD2,..} define changer vtape { - tpcanger "chg-disk:/path/to/vtape" + tpchanger "chg-disk:/path/to/vtape" } define changer robot { tpchanger "chg-robot:/dev/sg0" @@ -759,6 +759,17 @@ If true, enables the NDMJOB library's verbose (packet-level) debugging. +chg-single:DEVICE + +tpchanger "chg-single:tape:/dev/nst0" + + +This changer is for use with standalone drive, it can work with any +device. The device (tape:/dev/nst0) must be set in the tpchanger definition. +The chg-single changer has no property. + + + Unmaintained Changers Amanda has many other changer scripts and programs beyond those described diff --git a/man/xml-source/amanda-client.conf.5.xml b/man/xml-source/amanda-client.conf.5.xml index 2a1dcdd..9380657 100644 --- a/man/xml-source/amanda-client.conf.5.xml +++ b/man/xml-source/amanda-client.conf.5.xml @@ -72,6 +72,15 @@ Similar to the parameter of the same name in &amconf;, this specifies the port t + + amdump-server string + +No default: +Set by configure. +The amanda server to connect with the amdump_client program. + + + index-server string diff --git a/man/xml-source/amanda-devices.7.xml b/man/xml-source/amanda-devices.7.xml index 170b901..575b065 100644 --- a/man/xml-source/amanda-devices.7.xml +++ b/man/xml-source/amanda-devices.7.xml @@ -442,6 +442,10 @@ writing long enough to bring the average below this value. NB_THREADS_RECOVERY (read-write) The number of thread that read data from the s3 device, higher value can provide more throutput. + + + OPENSTACK_SWIFT_API + (read-write) Set to yes if it is an openstack storage device. S3_ACCESS_KEY @@ -453,7 +457,7 @@ writing long enough to bring the average below this value. As of this writing, it can be set to "*" (US Standard, i.e. lowest-latency choice of US East or West), "us-west-1" (US West, Northern California), "EU" (European Union), or "ap-southeast-1" (Asia Pacific). See for the most up-to-date list. @@ -472,6 +476,14 @@ The value is passed to curl_easy_setopt(3) as CURLOPT_CAINFO. S3_SECRET_KEY (read-write) This property gives the Amazon S3 secret key used to access the service. + + + S3_SERVER_SIDE_ENCRYPTION +(read-write) Set to the server side encryption algorithm to use. +There is actually only one algorithm, it is "AES256". The encryption is done +by Amazon on their server. See + +for the most up-to-date list. S3_SERVICE_PATH @@ -585,7 +597,7 @@ operations can be emulated with the MTREW and read data operations. NONBLOCKING_OPEN - (read-write) Set this boolean property to "true" if O_NONBLOCK must be used on the open call. Default to "true" on Linux and "false" on all others machines. Witout it, Linux wait for a few seconds if no tape are loaded. Solaris have strange error it is set to "yes". + (read-write) Set this boolean property to "true" if O_NONBLOCK must be used on the open call. Default to "true" on Linux and "false" on all others machines. Without it, Linux wait for a few seconds if no tape are loaded. Solaris have strange error it is set to "yes". READ_BLOCK_SIZE diff --git a/man/xml-source/amanda-taperscan.7.xml b/man/xml-source/amanda-taperscan.7.xml index 6c53d4e..6882c38 100644 --- a/man/xml-source/amanda-taperscan.7.xml +++ b/man/xml-source/amanda-taperscan.7.xml @@ -152,7 +152,6 @@ is found in the inventory. See oldest, above, for a definition of acceptable volumes. ->>>>>>> 6a40a39... manpage edits diff --git a/man/xml-source/amanda.conf.5.xml b/man/xml-source/amanda.conf.5.xml index 7c63bcc..33353eb 100644 --- a/man/xml-source/amanda.conf.5.xml +++ b/man/xml-source/amanda.conf.5.xml @@ -348,6 +348,16 @@ Specify which types of messages will trigger an email from amreport. amreport is + + + max-dle-by-volume int + +Default: +1000000000. +The maximum number of dle written to a single volume. + + + dumpcycle int @@ -387,6 +397,7 @@ days / runtapes. + tapecycle int @@ -466,9 +477,11 @@ values: $c : config name $o : org configuration $b : barcode of the volume + $s : slot number, can specify a minimun number of digit: + $3s to get '001' $m : meta label -The template should contain some number of contiguous '%' +The template can contain some number of contiguous '%' characters, which will be replaced with a generated number. Be sure to specify enough '%' characters that you do not run out of tape labels. Example: @@ -477,6 +490,10 @@ Example: "$m-%%%", "$m-$b" +The generared label can be used only if it match the +labelstr setting. The volume will not be used if the +generated label doesn't match the labelstr setting. + Note that many devices cannot distinguish an empty tape from an error condition, so it may is often necessary to include volume-error as an autolabel condition. @@ -729,13 +746,23 @@ The algorithm used to choose which dump image to send to the taper. -taper-parallel-write int - - -Default: 1. + taper-parallel-write int + + Default: 1. Amanda can write simultaneously up to that number of volume at any given time. The changer must have as many drives. - + + + + + eject-volume int + + Default: no. +Set to yes if you want the volume to be ejected +after Amanda wrote data to it. It works only with some changer and device. + + + labelstr string @@ -833,7 +860,7 @@ How many times the server will resend a REQ packet if it doesn't get the ACK pac netusage int Default: -8000 Kbps. +80000 Kbps. The maximum network bandwidth allocated to Amanda, in Kbytes per second. See also the interface @@ -2600,7 +2627,7 @@ A comment string describing this set of network information. use int Default: -8000 Kbps. +80000 Kbps. The speed of the interface in Kbytes per second. diff --git a/man/xml-source/amcheck.8.xml b/man/xml-source/amcheck.8.xml index be04e9b..ac8dc45 100644 --- a/man/xml-source/amcheck.8.xml +++ b/man/xml-source/amcheck.8.xml @@ -33,6 +33,7 @@ -w -sclt -M address + --client-verbose &configoverride.synopsis; config @@ -149,6 +150,13 @@ Implies + + + +Print all client messages. + + + host [disk]* diff --git a/man/xml-source/amcleanup.8.xml b/man/xml-source/amcleanup.8.xml index dfc11f1..1caaed6 100644 --- a/man/xml-source/amcleanup.8.xml +++ b/man/xml-source/amcleanup.8.xml @@ -28,9 +28,10 @@ - amcleanup + amcleanup + config @@ -50,6 +51,10 @@ cannot complete for some reason (usually because of a tape server host crash), amcleanup must be run some time later (usually during system boot). +The amcleanupdisk program is run with +the same and + options. + See the man page for more details about Amanda. @@ -70,9 +75,15 @@ man page for more details about Amanda. + + + Remove bad file in holding disk. This options is passed to amcleanupdisk. + + + - Generate verbose output. + Generate verbose output. This options is passed to amcleanupdisk. diff --git a/man/xml-source/amcleanupdisk.8.xml b/man/xml-source/amcleanupdisk.8.xml new file mode 100644 index 0000000..f3da7c5 --- /dev/null +++ b/man/xml-source/amcleanupdisk.8.xml @@ -0,0 +1,81 @@ + + + + %global_entities; +]> + + + + + +amcleanupdisk +8 +&rmi.source; +&rmi.version; +&rmi.manual.8; + + +amcleanupdisk +cleanup holding disk directory + + +&author.jds; +&author.sgw.xml; + + + + + amcleanupdisk + + + config + + + + +DESCRIPTION +Amcleanupdisk +list and/or remove invalid file from the holding disk directories. + +This program is run by amcleanup. + +See the + +man page for more details about Amanda. + + +OPTIONS + + + + + Remove invalid file from holding disk. + + + + + + Generate verbose output. + + + + + +EXAMPLES +This example runs the Amanda holding disk cleanup process. + + +% amcleanupdisk daily -v -r + + + + + + + + + + diff --git a/man/xml-source/amdump_client.8.xml b/man/xml-source/amdump_client.8.xml index 6827b5b..0bc6da8 100644 --- a/man/xml-source/amdump_client.8.xml +++ b/man/xml-source/amdump_client.8.xml @@ -37,7 +37,7 @@ DESCRIPTION -Amdump_client initiate backup on the client. There are two commands (CMD): +Amdump_client initiate backup on the client. There are three commands (CMD): list diff --git a/man/xml-source/amfetchdump.8.xml b/man/xml-source/amfetchdump.8.xml index 863b893..89ee3c7 100644 --- a/man/xml-source/amfetchdump.8.xml +++ b/man/xml-source/amfetchdump.8.xml @@ -28,12 +28,14 @@ amfetchdump - -phcClawns - -d device + -c|-C|-L + -p|-n + -a -O directory - -b blocksize - --header-fd fd + -d device + -h --header-file filename + --header-fd fd &configoverride.synopsis; config hostname diff --git a/man/xml-source/amgtar.8.xml b/man/xml-source/amgtar.8.xml index ed546cd..852b31e 100644 --- a/man/xml-source/amgtar.8.xml +++ b/man/xml-source/amgtar.8.xml @@ -31,6 +31,9 @@ Amgtar is an Amanda Application API script. It should not be run by users directly. It uses GNU Tar to backup and restore data. +The diskdevice in the disklist (DLE) +must be the directory to backup. + PROPERTIES diff --git a/man/xml-source/ampgsql.8.xml b/man/xml-source/ampgsql.8.xml index 21fc0b7..5fe8844 100644 --- a/man/xml-source/ampgsql.8.xml +++ b/man/xml-source/ampgsql.8.xml @@ -73,26 +73,79 @@ for information on application properties and how they are configured. + + ARCHIVEDIR +Directory that WAL segment files are archived to, as specified by the +archive_command in PosgreSQL's postgresql.conf. The amanda user on the +client must have at least read and execute permission on this directory, +and preferably write. Without write permission, Amanda cannot clean up +expired WAL and backup files. + + + CLEANUPWAL +Whether or not to remove old WAL segment files during base backups. +Defaults to yes. + + + DB +Database to connect to. Defaults to "template1" (which exists by +default). + DIRECTORY -For restore command only, the data is recoved in that directory. Must be a unix path. +For restore command only, the data is recoved in that directory. +Must be a unix path. - GNUTAR-PATH -Path to the GNU tar executable. This option only has an effect during restore. -The default is set when Amanda is built by the --with-gnutar configure option. +Path to the GNU tar executable. This option only has an effect +during restore. The default is set when Amanda is built by the +--with-gnutar configure option. + + + HOST +Host to connect to. If it starts with "/" it will be interepreted as a +directory that holds the socket file. PostgreSQL defaults to /tmp. + + + MAX-WAL-WAIT +The maximum amount of time to wait for PG_STOP_BACKUP to archive a WAL +file. In versions of PostgreSQL before 8.2, PG_STOP_BACKUP does not +automatically archive the latest WAL file, so a quiet database may +wait a very long time before archiving the WAL file. Default: 60 +seconds. Set to 0 to wait forever. + + + PASSFILE +Connect using the creditials in this file. Each line should have the +format "hostname:port:database:username:password". The permissions must +permit it to be read only by the user, or the file will not be used. +Only usable with Postgres 8.1 and up. + + + PORT +The TCP port to connect to, or the suffix of the socket file. PostgreSQL +defaults to 5432. + + + PSQL-PATH +Path to the psql binary. If not specified, the PATH environment variable +will be searched. STATEDIR -Directory for saving state about backups already made. The default is set -when Amanda is built by the --with-gnutar-listdir configure option. +Directory for saving state about backups already made. The default is set +when Amanda is built by the --with-gnutar-listdir configure option. TMPDIR -Directory to use for temporary files during the backup process. It should +Directory to use for temporary files during the backup process. It should have enough space to store a complete copy of the database. The default is set -when Amanda is built by the --with-tmpdir configure option. +when Amanda is built by the --with-tmpdir configure option. + + + USER +User to connect as. It must be a superuser. @@ -101,6 +154,9 @@ when Amanda is built by the --with-tmpdir configure option. CLIENT PROPERTIES +Client properties are deprecated. All properties should be set in +the dumptype. + This section lists the properties that control ampsql's functionality. If a property is prefixed with the diskname and an underscore, then it will be used when that diskname is being backed up. diff --git a/man/xml-source/amraw.8.xml b/man/xml-source/amraw.8.xml index 4816e49..768af71 100644 --- a/man/xml-source/amraw.8.xml +++ b/man/xml-source/amraw.8.xml @@ -32,6 +32,9 @@ by users directly. It uses dd to backup and restore data. Amraw can backup only one directory entry, it can be a single file, a raw device, anything that amanda can open and read. +The diskdevice in the disklist (DLE) +must be the filename amraw open and read. + Restore is done in place, an open is done and the data is written to it. A file owned by root and permission 0600 is create if the directory entry doesn't exist before the restore. Only full backup is allowed diff --git a/man/xml-source/amrecover.8.xml b/man/xml-source/amrecover.8.xml index bc760e0..469b363 100644 --- a/man/xml-source/amrecover.8.xml +++ b/man/xml-source/amrecover.8.xml @@ -282,6 +282,15 @@ If is tar, they are extracted on the local machine the same way tar volumes are extracted. + + + + settranslate [on|off] + +Default: on. Translate escaped octal value ('\000') in +the index file to their corespondig characters, it improve the interface +if amrecover is run in the same charset as the filename. Set it to +off if the charset of some filename is not compatible with the amrecover charset. diff --git a/man/xml-source/amsamba.8.xml b/man/xml-source/amsamba.8.xml index 13cb4bf..c5b31ce 100644 --- a/man/xml-source/amsamba.8.xml +++ b/man/xml-source/amsamba.8.xml @@ -30,7 +30,8 @@ Amsamba is an Amanda Application API script. It should not be run by users directly. It uses smbclient to backup and restore data. - The device name in the disklist must have the form + The diskdevice in the disklist (DLE) +must have the form '//CIFSHOST/SHARE/SUBDIR' where CIFSHOST is the CIFS host containing the data to be backed up, SHARE is the share to connect, and subdir is the subdirectory to backup. '/subdir' can be ommited, in which case the complete share is diff --git a/man/xml-source/amstar.8.xml b/man/xml-source/amstar.8.xml index 4e5d44e..5fcaba9 100644 --- a/man/xml-source/amstar.8.xml +++ b/man/xml-source/amstar.8.xml @@ -31,6 +31,9 @@ Amstar is an Amanda Application API script. It should not be run by users directly. It uses star to backup and restore data. +The diskdevice in the disklist (DLE) +must be the directory to backup. + INCLUDE - EXCLUDE diff --git a/man/xml-source/amsuntar.8.xml b/man/xml-source/amsuntar.8.xml index cff7b3d..47ff3d5 100644 --- a/man/xml-source/amsuntar.8.xml +++ b/man/xml-source/amsuntar.8.xml @@ -34,6 +34,9 @@ by users directly. It uses Solaris bundled tar utility to backup and restore data. Currenty ACLs from ZFS file system can only be backed up using the solaris supplied tar utility. +The diskdevice in the disklist (DLE) +must be the directory to backup. + Solaris 10 supports Role Based Access Control(RBAC) which is enabled by default. To run backup operations using sun tar utility by under privileged user like amandabackup, amandabackup user need to have proper diff --git a/man/xml-source/amtape.8.xml b/man/xml-source/amtape.8.xml index 656e011..47d6033 100644 --- a/man/xml-source/amtape.8.xml +++ b/man/xml-source/amtape.8.xml @@ -97,11 +97,11 @@ supported by all changers. -show +show slots -Show the contents of all slots by loading each slot and reading its -label. This can be very slow. +Show the contents of all slots (or listed slots) by loading each slot +and reading its label. This can be very slow. The slots arguments is of the form 1,3-5,7. diff --git a/man/xml-source/amvault.8.xml b/man/xml-source/amvault.8.xml index eed3375..a2e1414 100644 --- a/man/xml-source/amvault.8.xml +++ b/man/xml-source/amvault.8.xml @@ -27,8 +27,8 @@ amvault &configoverride.synopsis; - -q --quiet - -n --dry-run + --dry-run-n + --quiet-q --fulls-only --export @@ -83,16 +83,7 @@ specified dumps from secondary media and re-writes them on tertiary media.Amvault Copies data from the run with timestamp onto volumes using the changer , and labeling new volumes with -. If is -"latest", then the most recent amdump or amflush run will be used. If - is given, then only full (level-0) dumps are -copied. - -The () option will -eliminate non-error messages, and is useful when running amvault from -cron. The () option will -cause amvault to print the dumps it would vault, but not actually perform -any vaulting operations. +. Secondary Media @@ -115,12 +106,51 @@ might have been flushed from holding disk. Tertiary Media -The must be specified, and names the changer +The must be specified, and names the +changer in which tertiary media are stored. + +If &amconf; contains the new part-size +splitting parameters, then amvault will use them without any additional configuration. +However, if the configuration still uses the old splitting parameters +(tape_splitsize, +split_diskbuffer, and +fallback_splitsize), then amvault will need some +additional configuration in order to properly split dumps to tertiary +media. To do so, specify a new tapetype in &amconf;, say "TERTIARY", +and set the part-size and other appropriate +parameters there. Then reference that tapetype in the amvault invocation: + + amvault -otapetype=TERTIARY ... + + + + + + +OPTIONS + + + any + other-config + non-amanda + volume-error + empty + +Works just like the +autolabel parameter in &amconf;, and can be +specified multiple times if necessary. The default is 'empty'. + + + + + dst-changer + +Specifies the changer in which tertiary media are stored. In general, this should be different from the secondary changer, to eliminate the possibility of overwriting secondary media with tertiary data. -The changer parameter should specify the name of a changer defined in +The dst-changer parameter should specify the name of a changer defined in &amconf;. For example: define changer vaulting_tape { @@ -130,32 +160,87 @@ define changer vaulting_tape { changerfile "vaulting-changer.conf" } + + + + + + +Cause amvault to print the dumps it would vault, but not actually +perform any vaulting operations. + + + + + + +Cause amvault to attempt to move completed tertiary volumes to +import/export slots, where they can be more easily removed by an operator. + + + + + + + +Only full (level-0) dumps are copied. + + + + + label-template + +Specifies a label template which is used to generate new labels for +tertiary volumes. + + + + + + +Eliminate non-error messages, and is useful when running amvault from +cron. + + + + + src-timestamps + +Specifies the timestamps in the format 'YYYYMMDDHHMMSS' of the run to +vault, can be "latest", then the most recent amdump or amflush run will be +used. + + + + + configoption + +See the "CONFIGURATION OVERRIDE" + section in . + + + + -The option is required, and specifies a -label template which is used to generate new labels for tertiary volumes. -The option works just like the -autolabel parameter in &amconf;, and can be -specified multiple times if necessary. The default is 'empty'. -If &amconf; contains the new part-size -splitting parameters, then amvault will use them without any additional configuration. -However, if the configuration still uses the old splitting parameters -(tape_splitsize, -split_diskbuffer, and -fallback_splitsize), then amvault will need some -additional configuration in order to properly split dumps to tertiary -media. To do so, specify a new tapetype in &amconf;, say "TERTIARY", -and set the part-size and other appropriate -parameters there. Then reference that tapetype in the amvault invocation: + + +EXAMPLES + +Vault all dump written to tape in the latest amdump or amflush run: - amvault -otapetype=TERTIARY ... - +$ amvault --src-timestamps latest --label-template "CONF-%%%" --dst-changer vault-changer CONF + -The option will cause amvault to attempt to move -completed tertiary volumes to import/export slots, where they can be -more easily removed by an operator. +Vault all dump written on the run of December 7 2011 12:13:14 : + +$ amvault --src-timestamps 20111207121314 --label-template "CONF-%%%" --dst-changer vault-changer CONF + - +Vault all dump dumped on any run of December 7 2011: + +$ amvault --label-template "CONF-%%%" --dst-changer vault-changer CONF \* \* 20111207 + diff --git a/man/xml-source/amzfs-sendrecv.8.xml b/man/xml-source/amzfs-sendrecv.8.xml index c7219c4..5fbfbcc 100644 --- a/man/xml-source/amzfs-sendrecv.8.xml +++ b/man/xml-source/amzfs-sendrecv.8.xml @@ -45,7 +45,8 @@ usermod -P "ZFS File System Management,ZFS Storage Management" AMANDA_USER This will require that your run zfs under pfexec, set the PFEXEC property to YES. -The format of the DLE must be one of: +The format of the diskdevice in the +disklist (DLE) must be one of: Desciption Example ---------- ------- diff --git a/ndmp-src/Makefile.in b/ndmp-src/Makefile.in index dccd1f1..0d5dbd5 100644 --- a/ndmp-src/Makefile.in +++ b/ndmp-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -496,6 +496,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -928,6 +929,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -977,6 +979,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -985,6 +988,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -992,6 +996,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1136,6 +1142,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1169,6 +1176,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1211,7 +1219,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/ndmp-src/amndmjob_main.c b/ndmp-src/amndmjob_main.c index d68025a..b554519 100644 --- a/ndmp-src/amndmjob_main.c +++ b/ndmp-src/amndmjob_main.c @@ -47,6 +47,11 @@ main (int ac, char *av[]) { int rc; + if (ac > 1 && av && av[1] && g_str_equal(av[1], "--version")) { + printf("amndmjob-%s\n", VERSION); + return (0); + } + set_pname("amndmjob"); dbopen(DBG_SUBDIR_CLIENT); config_init(0, NULL); diff --git a/oldrecover-src/Makefile.in b/oldrecover-src/Makefile.in index fe14d12..48d3930 100644 --- a/oldrecover-src/Makefile.in +++ b/oldrecover-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -377,6 +377,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -809,6 +810,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -858,6 +860,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -866,6 +869,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -873,6 +877,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1017,6 +1023,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1050,6 +1057,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1092,7 +1100,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/oldrecover-src/extract_list.c b/oldrecover-src/extract_list.c index 970b88d..4c36eb2 100644 --- a/oldrecover-src/extract_list.c +++ b/oldrecover-src/extract_list.c @@ -585,7 +585,7 @@ void add_file( char *err = NULL; int i; ssize_t j; - char *dir, *dir_undo, dir_undo_ch = '\0'; + char *dir_undo, dir_undo_ch = '\0'; char *ditem_path = NULL; char *l = NULL; int added; @@ -757,7 +757,6 @@ void add_file( err = _("bad reply: missing directory field"); continue; } - dir = s - 1; skip_quoted_string(s, ch); dir_undo = s - 1; dir_undo_ch = *dir_undo; @@ -902,7 +901,6 @@ delete_file( char *tape, *tape_undo, tape_undo_ch = '\0'; char *dir_undo, dir_undo_ch = '\0'; int level = 0; - off_t fileno; char *ditem_path = NULL; char *l = NULL; int deleted; @@ -1064,7 +1062,6 @@ delete_file( err = _("bad reply: cannot parse fileno field"); continue; } - fileno = (off_t)fileno_; skip_integer(s, ch); } diff --git a/oldrecover-src/uparse.c b/oldrecover-src/uparse.c index 0de18c5..9db3d70 100644 --- a/oldrecover-src/uparse.c +++ b/oldrecover-src/uparse.c @@ -1,24 +1,21 @@ -/* A Bison parser, made by GNU Bison 2.3. */ +/* A Bison parser, made by GNU Bison 2.5. */ -/* Skeleton implementation for Bison's Yacc-like parsers in C - - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify +/* Bison implementation for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2011 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. - + the Free Software Foundation, either version 3 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. */ + along with this program. If not, see . */ /* As a special exception, you may create a larger work that contains part or all of the Bison parser skeleton and distribute that work @@ -29,7 +26,7 @@ special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. - + This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ @@ -47,7 +44,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.3" +#define YYBISON_VERSION "2.5" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -55,11 +52,53 @@ /* Pure parsers. */ #define YYPURE 0 +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + /* Using locations. */ #define YYLSP_NEEDED 0 +/* Copy the first part of user declarations. */ + +/* Line 268 of yacc.c */ +#line 31 "uparse.y" + +#include "amanda.h" +#include "amrecover.h" + +void yyerror(char *s); +extern int yylex(void); +extern char * yytext; + + + +/* Line 268 of yacc.c */ +#line 82 "uparse.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + /* Tokens. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE @@ -129,60 +168,34 @@ -/* Copy the first part of user declarations. */ -#line 31 "uparse.y" - -#include "amanda.h" -#include "amrecover.h" - -void yyerror(char *s); -extern int yylex(void); -extern char * yytext; - - - -/* Enabling traces. */ -#ifndef YYDEBUG -# define YYDEBUG 0 -#endif - -/* Enabling verbose error messages. */ -#ifdef YYERROR_VERBOSE -# undef YYERROR_VERBOSE -# define YYERROR_VERBOSE 1 -#else -# define YYERROR_VERBOSE 0 -#endif - -/* Enabling the token table. */ -#ifndef YYTOKEN_TABLE -# define YYTOKEN_TABLE 0 -#endif - #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef union YYSTYPE -#line 42 "uparse.y" { + +/* Line 293 of yacc.c */ +#line 42 "uparse.y" + int intval; double floatval; char * strval; int subtok; -} -/* Line 187 of yacc.c. */ -#line 173 "uparse.c" - YYSTYPE; + + + +/* Line 293 of yacc.c */ +#line 187 "uparse.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 -# define YYSTYPE_IS_TRIVIAL 1 #endif - /* Copy the second part of user declarations. */ -/* Line 216 of yacc.c. */ -#line 186 "uparse.c" +/* Line 343 of yacc.c */ +#line 199 "uparse.c" #ifdef short # undef short @@ -232,7 +245,7 @@ typedef short int yytype_int16; #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) #ifndef YY_ -# if YYENABLE_NLS +# if defined YYENABLE_NLS && YYENABLE_NLS # if ENABLE_NLS # include /* INFRINGES ON USER NAME SPACE */ # define YY_(msgid) dgettext ("bison-runtime", msgid) @@ -257,14 +270,14 @@ typedef short int yytype_int16; #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static int -YYID (int i) +YYID (int yyi) #else static int -YYID (i) - int i; +YYID (yyi) + int yyi; #endif { - return i; + return yyi; } #endif @@ -285,11 +298,11 @@ YYID (i) # define alloca _alloca # else # define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # endif @@ -312,24 +325,24 @@ YYID (i) # ifndef YYSTACK_ALLOC_MAXIMUM # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM # endif -# if (defined __cplusplus && ! defined _STDLIB_H \ +# if (defined __cplusplus && ! defined EXIT_SUCCESS \ && ! ((defined YYMALLOC || defined malloc) \ && (defined YYFREE || defined free))) # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # ifndef YYMALLOC # define YYMALLOC malloc -# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free -# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif @@ -345,9 +358,9 @@ void free (void *); /* INFRINGES ON USER NAME SPACE */ /* A type that is properly aligned for any stack member. */ union yyalloc { - yytype_int16 yyss; - YYSTYPE yyvs; - }; + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; /* The size of the maximum gap between one aligned stack and the next. */ # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) @@ -358,6 +371,27 @@ union yyalloc ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM) +# define YYCOPY_NEEDED 1 + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +#if defined YYCOPY_NEEDED && YYCOPY_NEEDED /* Copy COUNT objects from FROM to TO. The source and destination do not overlap. */ # ifndef YYCOPY @@ -375,24 +409,7 @@ union yyalloc while (YYID (0)) # endif # endif - -/* Relocate STACK from its old location to the new one. The - local variables YYSIZE and YYSTACKSIZE give the old and new number of - elements in the stack, and YYPTR gives the new location of the - stack. Advance YYPTR to a properly aligned location for the next - stack. */ -# define YYSTACK_RELOCATE(Stack) \ - do \ - { \ - YYSIZE_T yynewbytes; \ - YYCOPY (&yyptr->Stack, Stack, yysize); \ - Stack = &yyptr->Stack; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / sizeof (*yyptr); \ - } \ - while (YYID (0)) - -#endif +#endif /* !YYCOPY_NEEDED */ /* YYFINAL -- State number of the termination state. */ #define YYFINAL 55 @@ -537,8 +554,8 @@ static const yytype_uint8 yyr2[] = 2, 2, 1, 2, 2, 1, 1, 2, 1, 1 }; -/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state - STATE-NUM when YYTABLE doesn't specify something else to do. Zero +/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. + Performed when YYTABLE doesn't specify something else to do. Zero means the default is an error. */ static const yytype_uint8 yydefact[] = { @@ -581,8 +598,7 @@ static const yytype_int8 yypgoto[] = /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which - number is the opposite. If zero, do what YYDEFACT says. - If YYTABLE_NINF, syntax error. */ + number is the opposite. If YYTABLE_NINF, syntax error. */ #define YYTABLE_NINF -1 static const yytype_uint8 yytable[] = { @@ -593,6 +609,12 @@ static const yytype_uint8 yytable[] = 54, 56, 57, 58, 59, 60 }; +#define yypact_value_is_default(yystate) \ + ((yystate) == (-6)) + +#define yytable_value_is_error(yytable_value) \ + YYID (0) + static const yytype_int8 yycheck[] = { 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, @@ -627,9 +649,18 @@ static const yytype_uint8 yystos[] = /* Like YYERROR except do call yyerror. This remains here temporarily to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. */ + Once GCC version 2 has supplanted version 1, this can go. However, + YYFAIL appears to be in use. Nevertheless, it is formally deprecated + in Bison 2.4.2's NEWS entry, where a plan to phase it out is + discussed. */ #define YYFAIL goto yyerrlab +#if defined YYFAIL + /* This is here to suppress warnings from the GCC cpp's + -Wunused-macros. Normally we don't worry about that warning, but + some users do, and we want to make it easy for users to remove + YYFAIL uses, which will produce warnings from Bison 2.5. */ +#endif #define YYRECOVERING() (!!yyerrstatus) @@ -639,7 +670,6 @@ do \ { \ yychar = (Token); \ yylval = (Value); \ - yytoken = YYTRANSLATE (yychar); \ YYPOPSTACK (1); \ goto yybackup; \ } \ @@ -681,19 +711,10 @@ while (YYID (0)) #endif -/* YY_LOCATION_PRINT -- Print the location on the stream. - This macro was not mandated originally: define only if we know - we won't break user code: when these are the locations we know. */ +/* This macro is provided for backward compatibility. */ #ifndef YY_LOCATION_PRINT -# if YYLTYPE_IS_TRIVIAL -# define YY_LOCATION_PRINT(File, Loc) \ - fprintf (File, "%d.%d-%d.%d", \ - (Loc).first_line, (Loc).first_column, \ - (Loc).last_line, (Loc).last_column) -# else -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -# endif +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) #endif @@ -797,17 +818,20 @@ yy_symbol_print (yyoutput, yytype, yyvaluep) #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void -yy_stack_print (yytype_int16 *bottom, yytype_int16 *top) +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) #else static void -yy_stack_print (bottom, top) - yytype_int16 *bottom; - yytype_int16 *top; +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; #endif { YYFPRINTF (stderr, "Stack now"); - for (; bottom <= top; ++bottom) - YYFPRINTF (stderr, " %d", *bottom); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } YYFPRINTF (stderr, "\n"); } @@ -841,11 +865,11 @@ yy_reduce_print (yyvsp, yyrule) /* The symbols being reduced. */ for (yyi = 0; yyi < yynrhs; yyi++) { - fprintf (stderr, " $%d = ", yyi + 1); + YYFPRINTF (stderr, " $%d = ", yyi + 1); yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], &(yyvsp[(yyi + 1) - (yynrhs)]) ); - fprintf (stderr, "\n"); + YYFPRINTF (stderr, "\n"); } } @@ -882,7 +906,6 @@ int yydebug; # define YYMAXDEPTH 10000 #endif - #if YYERROR_VERBOSE @@ -985,115 +1008,142 @@ yytnamerr (char *yyres, const char *yystr) } # endif -/* Copy into YYRESULT an error message about the unexpected token - YYCHAR while in state YYSTATE. Return the number of bytes copied, - including the terminating null byte. If YYRESULT is null, do not - copy anything; just return the number of bytes that would be - copied. As a special case, return 0 if an ordinary "syntax error" - message will do. Return YYSIZE_MAXIMUM if overflow occurs during - size calculation. */ -static YYSIZE_T -yysyntax_error (char *yyresult, int yystate, int yychar) -{ - int yyn = yypact[yystate]; +/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message + about the unexpected token YYTOKEN for the state stack whose top is + YYSSP. - if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) - return 0; - else + Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is + not large enough to hold the message. In that case, also set + *YYMSG_ALLOC to the required number of bytes. Return 2 if the + required number of bytes is too large to store. */ +static int +yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, + yytype_int16 *yyssp, int yytoken) +{ + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + /* Internationalized format string. */ + const char *yyformat = 0; + /* Arguments of yyformat. */ + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + /* Number of reported tokens (one for the "unexpected", one per + "expected"). */ + int yycount = 0; + + /* There are many possibilities here to consider: + - Assume YYFAIL is not used. It's too flawed to consider. See + + for details. YYERROR is fine as it does not invoke this + function. + - If this state is a consistent state with a default action, then + the only way this function was invoked is if the default action + is an error action. In that case, don't check for expected + tokens because there are none. + - The only way there can be no lookahead present (in yychar) is if + this state is a consistent state with a default action. Thus, + detecting the absence of a lookahead is sufficient to determine + that there is no unexpected or expected token to report. In that + case, just report a simple "syntax error". + - Don't assume there isn't a lookahead just because this state is a + consistent state with a default action. There might have been a + previous inconsistent state, consistent state with a non-default + action, or user semantic action that manipulated yychar. + - Of course, the expected token list depends on states to have + correct lookahead information, and it depends on the parser not + to perform extra reductions after fetching a lookahead from the + scanner and before detecting a syntax error. Thus, state merging + (from LALR or IELR) and default reductions corrupt the expected + token list. However, the list is correct for canonical LR with + one exception: it will still contain any token that will not be + accepted due to an error action in a later state. + */ + if (yytoken != YYEMPTY) { - int yytype = YYTRANSLATE (yychar); - YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); - YYSIZE_T yysize = yysize0; - YYSIZE_T yysize1; - int yysize_overflow = 0; - enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; - char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; - int yyx; - -# if 0 - /* This is so xgettext sees the translatable formats that are - constructed on the fly. */ - YY_("syntax error, unexpected %s"); - YY_("syntax error, unexpected %s, expecting %s"); - YY_("syntax error, unexpected %s, expecting %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); -# endif - char *yyfmt; - char const *yyf; - static char const yyunexpected[] = "syntax error, unexpected %s"; - static char const yyexpecting[] = ", expecting %s"; - static char const yyor[] = " or %s"; - char yyformat[sizeof yyunexpected - + sizeof yyexpecting - 1 - + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) - * (sizeof yyor - 1))]; - char const *yyprefix = yyexpecting; - - /* Start YYX at -YYN if negative to avoid negative indexes in - YYCHECK. */ - int yyxbegin = yyn < 0 ? -yyn : 0; - - /* Stay within bounds of both yycheck and yytname. */ - int yychecklim = YYLAST - yyn + 1; - int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; - int yycount = 1; - - yyarg[0] = yytname[yytype]; - yyfmt = yystpcpy (yyformat, yyunexpected); - - for (yyx = yyxbegin; yyx < yyxend; ++yyx) - if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) - { - if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) - { - yycount = 1; - yysize = yysize0; - yyformat[sizeof yyunexpected - 1] = '\0'; - break; - } - yyarg[yycount++] = yytname[yyx]; - yysize1 = yysize + yytnamerr (0, yytname[yyx]); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - yyfmt = yystpcpy (yyfmt, yyprefix); - yyprefix = yyor; - } + int yyn = yypact[*yyssp]; + yyarg[yycount++] = yytname[yytoken]; + if (!yypact_value_is_default (yyn)) + { + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. In other words, skip the first -YYN actions for + this state because they are default actions. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yyx; + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR + && !yytable_value_is_error (yytable[yyx + yyn])) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + if (! (yysize <= yysize1 + && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + } + } - yyf = YY_(yyformat); - yysize1 = yysize + yystrlen (yyf); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; + switch (yycount) + { +# define YYCASE_(N, S) \ + case N: \ + yyformat = S; \ + break + YYCASE_(0, YY_("syntax error")); + YYCASE_(1, YY_("syntax error, unexpected %s")); + YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); + YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); + YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); + YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); +# undef YYCASE_ + } - if (yysize_overflow) - return YYSIZE_MAXIMUM; + yysize1 = yysize + yystrlen (yyformat); + if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; - if (yyresult) - { - /* Avoid sprintf, as that infringes on the user's name space. - Don't have undefined behavior even if the translation - produced a string with the wrong number of "%s"s. */ - char *yyp = yyresult; - int yyi = 0; - while ((*yyp = *yyf) != '\0') - { - if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) - { - yyp += yytnamerr (yyp, yyarg[yyi++]); - yyf += 2; - } - else - { - yyp++; - yyf++; - } - } - } - return yysize; + if (*yymsg_alloc < yysize) + { + *yymsg_alloc = 2 * yysize; + if (! (yysize <= *yymsg_alloc + && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) + *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; + return 1; } + + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + { + char *yyp = *yymsg; + int yyi = 0; + while ((*yyp = *yyformat) != '\0') + if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyformat += 2; + } + else + { + yyp++; + yyformat++; + } + } + return 0; } #endif /* YYERROR_VERBOSE */ - /*-----------------------------------------------. | Release the memory associated to this symbol. | @@ -1125,10 +1175,9 @@ yydestruct (yymsg, yytype, yyvaluep) break; } } - -/* Prevent warnings from -Wmissing-prototypes. */ +/* Prevent warnings from -Wmissing-prototypes. */ #ifdef YYPARSE_PARAM #if defined __STDC__ || defined __cplusplus int yyparse (void *YYPARSE_PARAM); @@ -1144,18 +1193,16 @@ int yyparse (); #endif /* ! YYPARSE_PARAM */ - -/* The look-ahead symbol. */ +/* The lookahead symbol. */ int yychar; -/* The semantic value of the look-ahead symbol. */ +/* The semantic value of the lookahead symbol. */ YYSTYPE yylval; /* Number of syntax errors so far. */ int yynerrs; - /*----------. | yyparse. | `----------*/ @@ -1182,66 +1229,66 @@ yyparse () #endif #endif { - - int yystate; - int yyn; - int yyresult; - /* Number of tokens to shift before error messages enabled. */ - int yyerrstatus; - /* Look-ahead token as an internal (translated) token number. */ - int yytoken = 0; -#if YYERROR_VERBOSE - /* Buffer for error messages, and its allocated size. */ - char yymsgbuf[128]; - char *yymsg = yymsgbuf; - YYSIZE_T yymsg_alloc = sizeof yymsgbuf; -#endif - - /* Three stacks and their tools: - `yyss': related to states, - `yyvs': related to semantic values, - `yyls': related to locations. - - Refer to the stacks thru separate pointers, to allow yyoverflow - to reallocate them elsewhere. */ - - /* The state stack. */ - yytype_int16 yyssa[YYINITDEPTH]; - yytype_int16 *yyss = yyssa; - yytype_int16 *yyssp; + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; - /* The semantic value stack. */ - YYSTYPE yyvsa[YYINITDEPTH]; - YYSTYPE *yyvs = yyvsa; - YYSTYPE *yyvsp; + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; -#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; - YYSIZE_T yystacksize = YYINITDEPTH; + YYSIZE_T yystacksize; + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; /* The variables used to return semantic value and location from the action routines. */ YYSTYPE yyval; +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) /* The number of symbols on the RHS of the reduced rule. Keep to zero when no symbol should be popped. */ int yylen = 0; + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + YYDPRINTF ((stderr, "Starting parse\n")); yystate = 0; yyerrstatus = 0; yynerrs = 0; - yychar = YYEMPTY; /* Cause a token to be read. */ + yychar = YYEMPTY; /* Cause a token to be read. */ /* Initialize stack pointers. Waste one element of value and location stack so that they stay on the same level as the state stack. The wasted elements are never initialized. */ - yyssp = yyss; yyvsp = yyvs; @@ -1271,7 +1318,6 @@ yyparse () YYSTYPE *yyvs1 = yyvs; yytype_int16 *yyss1 = yyss; - /* Each stack pointer address is followed by the size of the data in use in that stack, in bytes. This used to be a conditional around just the two extra args, but that might @@ -1279,7 +1325,6 @@ yyparse () yyoverflow (YY_("memory exhausted"), &yyss1, yysize * sizeof (*yyssp), &yyvs1, yysize * sizeof (*yyvsp), - &yystacksize); yyss = yyss1; @@ -1302,9 +1347,8 @@ yyparse () (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); if (! yyptr) goto yyexhaustedlab; - YYSTACK_RELOCATE (yyss); - YYSTACK_RELOCATE (yyvs); - + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); # undef YYSTACK_RELOCATE if (yyss1 != yyssa) YYSTACK_FREE (yyss1); @@ -1315,7 +1359,6 @@ yyparse () yyssp = yyss + yysize - 1; yyvsp = yyvs + yysize - 1; - YYDPRINTF ((stderr, "Stack size increased to %lu\n", (unsigned long int) yystacksize)); @@ -1325,6 +1368,9 @@ yyparse () YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + if (yystate == YYFINAL) + YYACCEPT; + goto yybackup; /*-----------. @@ -1333,16 +1379,16 @@ yyparse () yybackup: /* Do appropriate processing given the current state. Read a - look-ahead token if we need one and don't already have one. */ + lookahead token if we need one and don't already have one. */ - /* First try to decide what to do without reference to look-ahead token. */ + /* First try to decide what to do without reference to lookahead token. */ yyn = yypact[yystate]; - if (yyn == YYPACT_NINF) + if (yypact_value_is_default (yyn)) goto yydefault; - /* Not known => get a look-ahead token if don't already have one. */ + /* Not known => get a lookahead token if don't already have one. */ - /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol. */ + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ if (yychar == YYEMPTY) { YYDPRINTF ((stderr, "Reading a token: ")); @@ -1368,26 +1414,22 @@ yybackup: yyn = yytable[yyn]; if (yyn <= 0) { - if (yyn == 0 || yyn == YYTABLE_NINF) - goto yyerrlab; + if (yytable_value_is_error (yyn)) + goto yyerrlab; yyn = -yyn; goto yyreduce; } - if (yyn == YYFINAL) - YYACCEPT; - /* Count tokens shifted since error; after three, turn off error status. */ if (yyerrstatus) yyerrstatus--; - /* Shift the look-ahead token. */ + /* Shift the lookahead token. */ YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); - /* Discard the shifted token unless it is eof. */ - if (yychar != YYEOF) - yychar = YYEMPTY; + /* Discard the shifted token. */ + yychar = YYEMPTY; yystate = yyn; *++yyvsp = yylval; @@ -1427,6 +1469,8 @@ yyreduce: switch (yyn) { case 12: + +/* Line 1806 of yacc.c */ #line 75 "uparse.y" { char * errstr = vstralloc("Invalid command: ", yytext, NULL); @@ -1437,61 +1481,85 @@ yyreduce: break; case 13: + +/* Line 1806 of yacc.c */ #line 84 "uparse.y" { list_host(); } break; case 14: + +/* Line 1806 of yacc.c */ #line 85 "uparse.y" { list_disk((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 15: + +/* Line 1806 of yacc.c */ #line 86 "uparse.y" { list_disk(NULL); } break; case 16: + +/* Line 1806 of yacc.c */ #line 87 "uparse.y" { set_date((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 17: + +/* Line 1806 of yacc.c */ #line 88 "uparse.y" { set_host((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 18: + +/* Line 1806 of yacc.c */ #line 89 "uparse.y" { set_disk((yyvsp[(2) - (3)].strval), (yyvsp[(3) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(3) - (3)].strval)); } break; case 19: + +/* Line 1806 of yacc.c */ #line 90 "uparse.y" { set_disk((yyvsp[(2) - (2)].strval), NULL); amfree((yyvsp[(2) - (2)].strval)); } break; case 20: + +/* Line 1806 of yacc.c */ #line 91 "uparse.y" { set_tape((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 21: + +/* Line 1806 of yacc.c */ #line 92 "uparse.y" { set_tape(""); } break; case 22: + +/* Line 1806 of yacc.c */ #line 93 "uparse.y" { cd_glob((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 23: + +/* Line 1806 of yacc.c */ #line 94 "uparse.y" { cd_regex((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 24: + +/* Line 1806 of yacc.c */ #line 95 "uparse.y" { #ifdef SAMBA_CLIENT @@ -1501,6 +1569,8 @@ yyreduce: break; case 25: + +/* Line 1806 of yacc.c */ #line 100 "uparse.y" { #ifdef SAMBA_CLIENT @@ -1510,91 +1580,127 @@ yyreduce: break; case 26: + +/* Line 1806 of yacc.c */ #line 108 "uparse.y" { list_disk_history(); } break; case 27: + +/* Line 1806 of yacc.c */ #line 109 "uparse.y" { list_directory(); } break; case 28: + +/* Line 1806 of yacc.c */ #line 110 "uparse.y" { display_extract_list((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 29: + +/* Line 1806 of yacc.c */ #line 111 "uparse.y" { display_extract_list(NULL); } break; case 30: + +/* Line 1806 of yacc.c */ #line 112 "uparse.y" { show_directory(); } break; case 31: + +/* Line 1806 of yacc.c */ #line 113 "uparse.y" { clear_extract_list(); } break; case 32: + +/* Line 1806 of yacc.c */ #line 114 "uparse.y" { show_mode (); } break; case 33: + +/* Line 1806 of yacc.c */ #line 118 "uparse.y" { quit(); } break; case 35: + +/* Line 1806 of yacc.c */ #line 126 "uparse.y" { add_glob((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 36: + +/* Line 1806 of yacc.c */ #line 127 "uparse.y" { add_glob((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } break; case 38: + +/* Line 1806 of yacc.c */ #line 135 "uparse.y" { add_regex((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 39: + +/* Line 1806 of yacc.c */ #line 136 "uparse.y" { add_regex((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } break; case 41: + +/* Line 1806 of yacc.c */ #line 144 "uparse.y" { delete_glob((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 42: + +/* Line 1806 of yacc.c */ #line 145 "uparse.y" { delete_glob((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } break; case 44: + +/* Line 1806 of yacc.c */ #line 153 "uparse.y" { delete_regex((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 45: + +/* Line 1806 of yacc.c */ #line 154 "uparse.y" { delete_regex((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } break; case 46: + +/* Line 1806 of yacc.c */ #line 158 "uparse.y" { char buf[STR_SIZE]; puts(getcwd(buf, sizeof(buf))); } break; case 47: + +/* Line 1806 of yacc.c */ #line 159 "uparse.y" { local_cd((yyvsp[(2) - (2)].strval)); @@ -1603,20 +1709,36 @@ yyreduce: break; case 48: + +/* Line 1806 of yacc.c */ #line 166 "uparse.y" { help_list(); } break; case 49: + +/* Line 1806 of yacc.c */ #line 170 "uparse.y" { extract_files(); } break; -/* Line 1267 of yacc.c. */ -#line 1618 "uparse.c" + +/* Line 1806 of yacc.c */ +#line 1729 "uparse.c" default: break; } + /* User semantic actions sometimes alter yychar, and that requires + that yytoken be updated with the new translation. We take the + approach of translating immediately before every use of yytoken. + One alternative is translating here after every semantic action, + but that translation would be missed if the semantic action invokes + YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or + if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an + incorrect destructor might then be invoked immediately. In the + case of YYERROR or YYBACKUP, subsequent parser actions might lead + to an incorrect destructor call or verbose syntax error message + before the lookahead is translated. */ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); YYPOPSTACK (yylen); @@ -1625,7 +1747,6 @@ yyreduce: *++yyvsp = yyval; - /* Now `shift' the result of the reduction. Determine what state that goes to, based on the state we popped back to and the rule number reduced by. */ @@ -1645,6 +1766,10 @@ yyreduce: | yyerrlab -- here on detecting error | `------------------------------------*/ yyerrlab: + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); + /* If not already recovering from an error, report this error. */ if (!yyerrstatus) { @@ -1652,37 +1777,36 @@ yyerrlab: #if ! YYERROR_VERBOSE yyerror (YY_("syntax error")); #else +# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ + yyssp, yytoken) { - YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); - if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) - { - YYSIZE_T yyalloc = 2 * yysize; - if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) - yyalloc = YYSTACK_ALLOC_MAXIMUM; - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); - yymsg = (char *) YYSTACK_ALLOC (yyalloc); - if (yymsg) - yymsg_alloc = yyalloc; - else - { - yymsg = yymsgbuf; - yymsg_alloc = sizeof yymsgbuf; - } - } - - if (0 < yysize && yysize <= yymsg_alloc) - { - (void) yysyntax_error (yymsg, yystate, yychar); - yyerror (yymsg); - } - else - { - yyerror (YY_("syntax error")); - if (yysize != 0) - goto yyexhaustedlab; - } + char const *yymsgp = YY_("syntax error"); + int yysyntax_error_status; + yysyntax_error_status = YYSYNTAX_ERROR; + if (yysyntax_error_status == 0) + yymsgp = yymsg; + else if (yysyntax_error_status == 1) + { + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); + if (!yymsg) + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + yysyntax_error_status = 2; + } + else + { + yysyntax_error_status = YYSYNTAX_ERROR; + yymsgp = yymsg; + } + } + yyerror (yymsgp); + if (yysyntax_error_status == 2) + goto yyexhaustedlab; } +# undef YYSYNTAX_ERROR #endif } @@ -1690,7 +1814,7 @@ yyerrlab: if (yyerrstatus == 3) { - /* If just tried and failed to reuse look-ahead token after an + /* If just tried and failed to reuse lookahead token after an error, discard it. */ if (yychar <= YYEOF) @@ -1707,7 +1831,7 @@ yyerrlab: } } - /* Else will try to reuse look-ahead token after shifting the error + /* Else will try to reuse lookahead token after shifting the error token. */ goto yyerrlab1; @@ -1741,7 +1865,7 @@ yyerrlab1: for (;;) { yyn = yypact[yystate]; - if (yyn != YYPACT_NINF) + if (!yypact_value_is_default (yyn)) { yyn += YYTERROR; if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) @@ -1764,9 +1888,6 @@ yyerrlab1: YY_STACK_PRINT (yyss, yyssp); } - if (yyn == YYFINAL) - YYACCEPT; - *++yyvsp = yylval; @@ -1791,7 +1912,7 @@ yyabortlab: yyresult = 1; goto yyreturn; -#ifndef yyoverflow +#if !defined(yyoverflow) || YYERROR_VERBOSE /*-------------------------------------------------. | yyexhaustedlab -- memory exhaustion comes here. | `-------------------------------------------------*/ @@ -1802,9 +1923,14 @@ yyexhaustedlab: #endif yyreturn: - if (yychar != YYEOF && yychar != YYEMPTY) - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval); + if (yychar != YYEMPTY) + { + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = YYTRANSLATE (yychar); + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + } /* Do not reclaim the symbols of the rule which action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); @@ -1828,6 +1954,8 @@ yyreturn: } + +/* Line 2067 of yacc.c */ #line 174 "uparse.y" diff --git a/oldrecover-src/uparse.h b/oldrecover-src/uparse.h index d813294..6507174 100644 --- a/oldrecover-src/uparse.h +++ b/oldrecover-src/uparse.h @@ -1,24 +1,21 @@ -/* A Bison parser, made by GNU Bison 2.3. */ +/* A Bison parser, made by GNU Bison 2.5. */ -/* Skeleton interface for Bison's Yacc-like parsers in C - - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify +/* Bison interface for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2011 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. - + the Free Software Foundation, either version 3 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. */ + along with this program. If not, see . */ /* As a special exception, you may create a larger work that contains part or all of the Bison parser skeleton and distribute that work @@ -29,10 +26,11 @@ special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. - + This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ + /* Tokens. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE @@ -104,20 +102,26 @@ #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef union YYSTYPE -#line 42 "uparse.y" { + +/* Line 2068 of yacc.c */ +#line 42 "uparse.y" + int intval; double floatval; char * strval; int subtok; -} -/* Line 1489 of yacc.c. */ -#line 116 "uparse.h" - YYSTYPE; + + + +/* Line 2068 of yacc.c */ +#line 119 "uparse.h" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 -# define YYSTYPE_IS_TRIVIAL 1 #endif extern YYSTYPE yylval; + diff --git a/oldrecover-src/uscan.c b/oldrecover-src/uscan.c index 923f357..6e02e62 100644 --- a/oldrecover-src/uscan.c +++ b/oldrecover-src/uscan.c @@ -679,7 +679,7 @@ static int input (void ); /* This used to be an fputs(), but since the string might contain NUL's, * we now use fwrite(). */ -#define ECHO fwrite( yytext, yyleng, 1, yyout ) +#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0) #endif /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, diff --git a/packaging/Makefile.am b/packaging/Makefile.am index c29f4c9..240c7d4 100644 --- a/packaging/Makefile.am +++ b/packaging/Makefile.am @@ -2,8 +2,9 @@ EXTRA_DIST = \ common \ deb \ rpm \ + sun-pkg \ Makefile.am \ - README + README dist-hook: rm -rf `find ${distdir} -name .svn` diff --git a/packaging/Makefile.in b/packaging/Makefile.in index 7a4b834..880e260 100644 --- a/packaging/Makefile.in +++ b/packaging/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -258,6 +258,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -690,6 +691,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -739,6 +741,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -747,6 +750,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -754,6 +758,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -898,6 +904,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -931,6 +938,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -973,7 +981,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -993,8 +1000,9 @@ EXTRA_DIST = \ common \ deb \ rpm \ + sun-pkg \ Makefile.am \ - README + README all: all-am diff --git a/packaging/common/common_functions.sh b/packaging/common/common_functions.sh new file mode 100644 index 0000000..28351d9 --- /dev/null +++ b/packaging/common/common_functions.sh @@ -0,0 +1,262 @@ +#!/bin/sh +# Common Functions + +# Required variables: +# LOGFILE +# SYSCONFDIR +# os + +logger() { + # A non-annoying way to log stuff + # ${@} is all the parameters, also known as the message. Quoting the input + # preserves whitespace. + msg="`date +'%b %e %Y %T'`: ${@}" + echo "${msg}" >> ${LOGFILE} +} + +log_output_of() { + # A non-annoying way to log output of commands + # ${@} is all the parameters supplied to the function. just execute it, + # and capture the output in a variable. then log that. + output=`"${@}" 2>&1` + ret=$? + if [ -n "${output}" ] ; then + logger "${1}: ${output}" + fi + return ${ret} +} + +check_superserver() { + # Check for the superserver $1 for the config $2 + case $1 in + xinetd) check_xinetd $2; return $?;; + inetd) check_inetd $2; return $?;; + launchd) check_launchd $2; return $?;; + smf) check_smf $2; return $?;; + esac +} + +check_xinetd() { + # Checks for an xinetd install and a config name passed as the first + # parameter. + # Returns: + # 0 if the file exists, + # 1 if it does not, + # 2 if xinetd.d/ does not exist or is a file + + if [ -d ${SYSCONFDIR}/xinetd.d ] ; then + if [ -f ${SYSCONFDIR}/xinetd.d/${1} ] ; then + logger "Found existing xinetd config: ${1}" + return 0 + else + return 1 + fi + else + # No xinetd installation. + return 2 + fi +} + +check_inetd() { + case $os in + SunOS) inetd_conf=${BASEDIR}/${SYSCONFDIR}/inet/inetd.conf ;; + *) inetd_conf=${SYSCONFDIR}/inetd.conf ;; + esac + if [ -e ${inetd_conf} ] ; then + if grep "${1}" ${inetd_conf} > /dev/null ; then + logger "Found existing inetd config: ${1}" + return 0 + else + return 1 + fi + else + # No inetd installation. + return 2 + fi +} + +check_launchd() { + # TODO: refactor OS X scripts. + : +} + +check_smf() { + # Only for solaris! This check only notices if an amanda service is active, + # it does not notice server vs client entries. + log_output_of svcs -H "*amanda*" || { \ + logger "No amanda service found."; return 1; } +} + +check_superserver_running() { + # Check for the given superserver, $1, in the output of ps -ef, or on + # mac/bsd ps ax. + # Return codes: + # 0: $1 is running + # 1: $1 is not running + # 2: $1 is not valid for this system + case $1 in + # Linux or Solaris. This works despite sol10 using SMF. + inetd) ps_flags='-e';; + xinetd) ps_flags='-e';; + # Mac OS X + launchd) ps_flags='aux';; + *) echo "Bad superserver."; return 2 ;; + esac + if [ "$1" = "launchd" ] && [ `uname` != 'Darwin' ]; then + echo "Only darwin uses launchd" + return 2 + fi + if [ "$1" = "xinetd" ] && [ "$os" = 'SunOS' ] && \ + [ `uname -r` = "5.10" ]; then + echo "Solaris 10 does not use xinetd." + return 2 + fi + # Search for $1, + PROC=`ps ${ps_flags} | grep -v 'grep'| grep "${1}"` + if [ x"${PROC}" != x ]; then + return 0 + else + return 1 + fi +} + +backup_xinetd() { + log_output_of mv ${SYSCONFDIR}/xinetd.d/${1} ${AMANDAHOMEDIR}/example/xinetd.${1}.orig || \ + { logger "WARNING: Could not back up existing xinetd configuration '${1}'"; + return 1; } + logger "Old xinetd config for '${1}' backed up to '${AMANDAHOMEDIR}/example/xinetd.${1}.orig'" +} + +backup_inetd() { + case $os in + SunOS) inetd_conf=${BASEDIR}/${SYSCONFDIR}/inet/inetd.conf ;; + *) inetd_conf=${SYSCONFDIR}/inetd.conf ;; + esac + # Backs up any amanda configuration it finds + log_output_of sed -n "/^amanda .* amandad/w ${AMANDAHOMEDIR}/example/inetd.orig" ${inetd_conf} || \ + { logger "WARNING: could not write ${AMANDAHOMEDIR}/example/inetd.orig"; + return 1; } + log_output_of sed "/^amanda .* amandad/d" ${inetd_conf} > \ + ${inetd_conf}.tmp || \ + { logger "WARNING: could not write ${inetd_conf}.tmp"; + return 1; } + log_output_of mv ${inetd_conf}.tmp ${inetd_conf} || \ + { logger "WARNING: could not overwrite ${inetd_conf}, old config not removed."; + return 1; } + logger "Old inetd config for amanda backed up to ${AMANDAHOMEDIR}/example/inetd.orig" +} + +backup_smf() { + # Solaris only. I *think* this should be consistent across all smf installs + svccfg -s *amanda* > ${BASEDIR}/${AMANDAHOMEDIR}/example/amanda_smf.xml.orig || {\ + logger "Warning: export of existing amanda service failed."; + return 1; } + + log_output_of inetadm -d *amanda* || { \ + # Not critical, we don't need to return if this fails. + logger "Warning: disabling existing amanda service failed."; } + + log_output_of svccfg delete -f *amanda* || { \ + logger "Error: removing the old amanda service failed."; + return 1; } +} + +install_xinetd() { + log_output_of install -m 0644 ${AMANDAHOMEDIR}/example/xinetd.${1} ${SYSCONFDIR}/xinetd.d/${1} || \ + { logger "WARNING: Could not install xinetd configuration '${1}'" ; return 1; } + logger "Installed xinetd config for ${1}." +} + +install_inetd() { + case $os in + SunOS) inetd_conf=${BASEDIR}/${SYSCONFDIR}/inet/inetd.conf ;; + *) inetd_conf=${SYSCONFDIR}/inetd.conf ;; + esac + # This one is hard to log because we're just appending. + logger "Appending ${AMANDAHOMEDIR}/example/inetd.conf.${1} to ${inetd_conf}" + cat ${AMANDAHOMEDIR}/example/inetd.conf.${1} >> ${inetd_conf} +} + +install_smf() { + # First parameter should be the name of the service to install + # (amandaserver, or amandaclient). + ver=`uname -r` + case $ver in + 5.10) + # Use inetadm and svcadm. + log_output_of ${BASEDIR}/usr/sbin/inetconv -f -i ${AMANDAHOMEDIR}/example/inetd.conf.${1} || { \ + logger "Warning: Failed to create Amanda SMF manifest. Check the system log."; + return 1; } + log_output_of ${BASEDIR}/usr/sbin/inetadm -e svc:/network/amanda/tcp || { \ + logger "Warning: Failed to enable Amanda service. See system log for more information."; + return 1; } + log_output_of ${BASEDIR}/usr/sbin/svcadm restart network/amanda/tcp || { \ + logger "Warning: Failed to restart Amanda service. See system log for details."; + return 1; } + ;; + + 5.8|5.9) + logger "Solaris 8 and 9 use inetd, not SMF tools." + return 1 + ;; + + *) + # I don't know what to do... + logger "ERROR: Unsupported and untested version of Solaris: $ver" + return 1 + ;; + esac +} + +reload_xinetd() { + # Default action is to try reload. + if [ "x$1" = "x" ]; then + action="reload" + elif [ "$1" = "reload" -o "$1" = "restart" ]; then + action="$1" + else + logger "WARNING: bad argument to reload_xinetd: $1" + return 1 + fi + if [ "$action" = "reload" ] ; then + logger "Reloading xinetd configuration..." + log_output_of ${SYSCONFDIR}/init.d/xinetd $action # Don't exit! + if [ $? -ne 0 ] ; then + logger "xinetd reload failed. Attempting restart..." + log_output_of ${SYSCONFDIR}/init.d/xinetd restart || \ + { logger "WARNING: restart failed." ; return 1; } + fi + else + # Must be restart... + logger "Restarting xinetd." + log_output_of ${SYSCONFDIR}/init.d/xinetd $1 || \ + { logger "WARNING: ${1} failed." ; return 1; } + fi +} + +reload_inetd() { + # Default action is to try reload. + if [ "x$1" = "x" ]; then + action="reload" + elif [ "$1" = "reload" -o "$1" = "restart" ]; then + action="$1" + else + logger "WARNING: bad argument to reload_inetd: $1" + return 1 + fi + if [ "$1" = "reload" ] ; then + logger "Reloading inetd configuration..." + log_output_of ${SYSCONFDIR}/init.d/inetd $1 # Don't exit! + if [ $? -ne 0 ] ; then + logger "inetd reload failed. Attempting restart..." + log_output_of ${SYSCONFDIR}/init.d/inetd restart || \ + { logger "WARNING: restart failed." ; return 1; } + fi + else + # Must be restart... + logger "Restarting inetd." + log_output_of ${SYSCONFDIR}/init.d/inetd $1 || \ + { logger "WARNING: ${1} failed." ; return 1; } + fi +} +# End Common functions diff --git a/packaging/common/mock_utils.sh b/packaging/common/mock_utils.sh new file mode 100644 index 0000000..a0989c2 --- /dev/null +++ b/packaging/common/mock_utils.sh @@ -0,0 +1,131 @@ +#!/bin/sh + +## Mock builtin utilities +# These should preempt builtin programs. +# They should print expected output on STDOUT, and write given arguments to +# mock__flags. Be sure to overwrite this file, not append! If they need +# to act differently depending on a condition, use temp files in $MOCKDIR, and +# delete when you're done. (Solaris shell does not re-export environment +# variables correctly). + +MOCKDIR=$TMPDIR/mocks; export MOCKDIR +[ -d $MOCKDIR ] || mkdir $MOCKDIR +PATH=${MOCKDIR}:$PATH; export PATH +mock_flag_files="" + +mk_mock_util() { + if [ ! "$IAmRoot" ]; then + # The repetitive stuff + cat << EOF > "$MOCKDIR/$1" +#!/bin/sh +EOF + /bin/chmod u+x $MOCKDIR/$1 + else + touch $MOCKDIR/$1 + fi + # Dynamic var names are ugly in shell, but useful. + eval mock_$1_flags=\$MOCKDIR/mock_\$1_flags + eval export mock_$1_flags + # Append to the list of flag files + mock_flag_files="$mock_flag_files mock_$1_flags" +} + +############### +# ps replacement +mk_mock_util "ps" +cat << EOF >> "${MOCKDIR}/ps" +echo "ps args: \${@}" > $mock_ps_flags +if [ -f "${MOCKDIR}/running" ]; then + ps_list="inetd xinetd launchd" +else + ps_list="foo bar baz" +fi + +echo "faux process list: \$ps_list" +EOF + +############### +# chown replacement +mk_mock_util "chown" +cat << EOF >> "${MOCKDIR}/chown" +echo "chown args: \${@}" > $mock_chown_flags +EOF + +############### +# chmod replacement +mk_mock_util "chmod" +cat << EOF >> "${MOCKDIR}/chmod" +echo "chmod args: \${@}" > $mock_chmod_flags +EOF + +############### +# id replacemnt + +# Set defaults for deb_uid and amanda_group, if running outside test_sh_libs +deb_uid=${deb_uid:=12345} +amanda_group=${amanda_group:=disk} + +mk_mock_util "id" +cat << EOF >> "${MOCKDIR}/id" +echo "id args: \${1}" > $mock_id_flags +[ -n "\${1}" ] || { echo "Missing a username to id!"; exit 1; } + +# We have to return the most basic form of id to be portable +# group file is used for supplemental groups. +if [ -f "${MOCKDIR}/is_member" ]; then + echo "uid=${deb_uid}(\${1}) gid=6(${amanda_group})" +else + echo "uid=123(\${1}) gid=123(foobar)" +fi +EOF + +############### +# svcs replacement +mk_mock_util "svcs" +cat << EOF >> "${MOCKDIR}/svcs" +echo "svcs args: \${@}" > $mock_svcs_flags +if [ -f "${MOCKDIR}/prexisting_service" ]; then + echo "online Sep_09 svc:/network/amanda/tcp:default" +else + echo "Pattern '\${3}' doesn't match any instances" + exit 1 +fi +EOF + +############### +# xinetd init script replacement +mk_mock_util xinetd +cat << EOF >> "${MOCKDIR}/xinetd" +echo "xinetd args: \${1}" > $mock_xinetd_flags +[ -f ${MOCKDIR}/success ] && exit 0 +echo "xinetd did not \${1}" +exit 1 +EOF + +############### +# inetd init script replacement +mk_mock_util inetd +cat << EOF >> "${MOCKDIR}/inetd" +echo "inetd args: \${1}" > $mock_inetd_flags +[ -f ${MOCKDIR}/success ] && exit 0 +echo "inetd did not \${1}" +exit 1 +EOF + +############### +# install replacement +mk_mock_util install +cat << EOF >> "${MOCKDIR}/install" +echo "install args: \$@" > $mock_install_flags +[ -f ${MOCKDIR}/success ] && exit 0 +echo "Some funky install error, yo!" +exit 1 +EOF + +# TODO: inetconv inetadm, svcadm + +# Touch all the flag files +for file in $mock_flag_files; do + touch $MOCKDIR/$file +done + diff --git a/packaging/common/post_inst_functions.sh b/packaging/common/post_inst_functions.sh new file mode 100644 index 0000000..1b131c4 --- /dev/null +++ b/packaging/common/post_inst_functions.sh @@ -0,0 +1,232 @@ +#!/bin/sh +# ------------- Begin Post Install Functions ----------------- +# These functions are included by various different installers. + +# We assume that the following variables are defined in the main script: +# amanda_user: the amanda account username +# amanda_group: the amanda account's group +# AMANDAHOMEDIR: a directory to use as amanda's home +# dist: used on linux for the distro. +# install_log: a log file we append to +# os: Linux, Mac, Solaris, etc... +# SYSCONFDIR: location of system config files (ie, /etc) +# LOGDIR: logging directory for amanda + +#TODO: gnutar-lists dir for solaris?? + +add_service() { + # Only needed on Solaris! + entry="amanda 10080/tcp # amanda backup services" + # make sure amanda is in /etc/services + if [ -z "`grep 'amanda' /${SYSCONFDIR}/services |grep '10080/tcp'`" ] ; then + logger "Adding amanda entry to /${SYSCONFDIR}/services." + echo "${entry}" >> /${SYSCONFDIR}/services + fi + + # make sure kamanda is in /etc/services + entry_2="amanda 10081/tcp famdc # amanda backup services (kerberos)" + if [ -z "`grep 'kamanda' /etc/services |grep '10081/tcp'`" ] ; then + logger "Adding kamanda entry to /${SYSCONFDIR}/services." + echo "${entry_2}" >> /${SYSCONFDIR}/services + fi +} + +create_amandates() { + logger "Creating ${AMANDATES}." + if [ ! -f ${AMANDATES} ] ; then + touch ${AMANDATES} || { logger "WARNING: Could not create Amandates." ; return 1; } + fi +} + +check_amandates() { + logger "Ensuring correct permissions for '${AMANDATES}'." + log_output_of chown ${amanda_user}:${amanda_group} ${AMANDATES} || \ + { logger "WARNING: Could not chown ${AMANDATES}" ; return 1; } + log_output_of chmod 0640 ${AMANDATES} || \ + { logger "WARNING: Could not fix perms on ${AMANDATES}" ; return 1; } + if [ -x /sbin/restorecon ] ; then + log_output_of /sbin/restorecon ${AMANDATES} || \ + { logger "WARNING: restorecon execution failed." ; return 1; } + fi +} + +create_gnupg() { + # Install .gnupg directory + if [ ! -d ${AMANDAHOMEDIR}/.gnupg ] ; then + logger "Creating '${AMANDAHOMEDIR}/.gnupg'" + log_output_of mkdir ${AMANDAHOMEDIR}/.gnupg || \ + { logger "WARNING: Could not create .gnupg dir" ; return 1; } + fi +} + +check_gnupg() { + logger "Ensuring correct permissions for '${AMANDAHOMEDIR}/.gnupg'." + log_output_of chown ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}/.gnupg || \ + { logger "WARNING: Could not chown .gnupg dir." ; return 1; } + log_output_of chmod 700 ${AMANDAHOMEDIR}/.gnupg || \ + { logger "WARNING: Could not set permissions on .gnupg dir." ; return 1; } +} + +create_amandahosts() { + # Install .amandahosts to server + if [ ! -f ${AMANDAHOMEDIR}/.amandahosts ] ; then + logger "Creating ${AMANDAHOMEDIR}/.amandahosts" + log_output_of touch ${AMANDAHOMEDIR}/.amandahosts || \ + { logger "WARNING: Could not create .amandahosts file." ; return 1; } + fi +} + +check_amandahosts_entry() { + # Entries for client and server differ slightly + # $1 username (root, ${amanda_user}) + # subsequent parameters are a list of programs to check (amindexd + # amidxtaped, or amdump) + logger "Checking '${AMANDAHOMEDIR}/.amandahosts' for '${@}' entries." + # Generate our grep expression + expr="" + for prog in ${@} ; do + expr=${expr}"[[:blank:]]\+${prog}" + done + for host in localhost localhost.localdomain ; do + logger "Searching .amandahosts for ^${host}${expr}" + if `grep "^${host}${expr}" ${AMANDAHOMEDIR}/.amandahosts >> /dev/null` ; then + continue + else + add_amandahosts_entry ${host} ${@} + fi + done +} + +add_amandahosts_entry() { + # Add entries to amandahosts. + # $@ is a fully formatted entry for amandahosts + logger "Appending '${@}' to amandahosts" + echo "${@}" >>${AMANDAHOMEDIR}/.amandahosts || \ + { logger "WARNING: Could not append to .amandahosts" ; return 1; } +} + +check_amandahosts_perms() { + logger "Ensuring correct permissions on .amandahosts" + log_output_of chown ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}/.amandahosts || \ + { logger "WARNING: Could not chown .amandahosts." ; return 1; } + log_output_of chmod 0600 ${AMANDAHOMEDIR}/.amandahosts || \ + { logger "WARNING: Could not fix permissions on .amandahosts" ; return 1; } +} + +create_ssh_key() { + # SSH RSA key generation for amdump and amrecover + # $1 must be "server" or "client" + KEYDIR="${AMANDAHOMEDIR}/.ssh" + if [ $1 = "server" ] ; then + KEYFILE="id_rsa_amdump" + elif [ $1 = "client" ] ; then + KEYFILE="id_rsa_amrecover" + else + logger "Bad parameter to create_ssh_key" ; return 1 + fi + COMMENT="${amanda_user}@$1" + if [ ! -d ${KEYDIR} ] ; then + if [ -f ${KEYDIR} ] ; then + logger "Directory '${KEYDIR}' exists as a file. Renaming to '${KEYDIR}.save'." + log_output_of mv ${KEYDIR} ${KEYDIR}.save || \ + { logger "WARNING: Could not backup old .ssh directory." ; return 1; } + fi + logger "Creating directory '${KEYDIR}'." + log_output_of mkdir ${KEYDIR} || \ + { logger "WARNING: Could not create .ssh dir." ; return 1; } + fi + if [ ! -f ${KEYDIR}/${KEYFILE} ] ; then + logger "Creating ssh RSA key in '${KEYDIR}/${KEYFILE}'" + log_output_of ssh-keygen -q -C $COMMENT -t rsa -f ${KEYDIR}/${KEYFILE} -N '' || \ + { logger "WARNING: Error generating ssh key" ; return 1; } + fi + logger "Setting ownership and permissions for '${KEYDIR}' and '${KEYDIR}/${KEYFILE}*'" + log_output_of chown ${amanda_user}:${amanda_group} ${KEYDIR} ${KEYDIR}/${KEYFILE}* || \ + { logger "WARNING: Could not chown one of ${KEYDIR} or ${KEYFILE}"; return 1; } + log_output_of chmod 0750 ${KEYDIR} || \ + { logger "WARNING: Could not fix permissions on ${KEYDIR}"; return 1; } + log_output_of chmod 0600 ${KEYDIR}/${KEYFILE}* || \ + { logger "WARNING: Could not fix permissions on ${KEYFILE}"; return 1; } +} + +create_profile() { + # environment variables (~${amanda_user}/.profile) + logger "Checking for '${AMANDAHOMEDIR}/.profile'." + if [ ! -f ${AMANDAHOMEDIR}/.profile ] ; then + log_output_of touch ${AMANDAHOMEDIR}/.profile || \ + { logger "WARNING: Could not create .profile" ; return 1; } + fi +} + +check_profile(){ + logger "Checking for ${SBINDIR} in path statement." + if [ -z "`grep PATH.*${SBINDIR} ${AMANDAHOMEDIR}/.profile`" ] ; then + echo "PATH=\"\$PATH:${SBINDIR}\"" >>${AMANDAHOMEDIR}/.profile || \ + { logger "WARNING: Could not append to .profile" ; return 1; } + echo "export PATH" >>${AMANDAHOMEDIR}/.profile + fi + case $os in + SunOS) + sun_paths=/opt/csw/bin:/usr/ucb + if [ -z "`grep PATH ${AMANDAHOMEDIR}/.profile | grep ${sun_paths}`" ] ; then + echo "PATH=\"$PATH:${SBINDIR}:${sun_paths}\"" >>${AMANDAHOMEDIR}/.profile + fi + ;; + esac + logger "Setting ownership and permissions for '${AMANDAHOMEDIR}/.profile'" + log_output_of chown ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}/.profile || \ + { logger "WARNING: Could not chown .profile." ; return 1; } + log_output_of chmod 0640 ${AMANDAHOMEDIR}/.profile || \ + { logger "WARNING: Could not fix permissions on .profile" ; return 1; } +} + +install_client_conf() { + # Install client config + if [ "$os" = "SunOS" ] ; then + install="install -m 0600 -u ${amanda_user} -g ${amanda_group}" + else + install="install -m 0600 -o ${amanda_user} -g ${amanda_group}" + fi + logger "Checking '${SYSCONFDIR}/amanda/amanda-client.conf' file." + if [ ! -f ${SYSCONFDIR}/amanda/amanda-client.conf ] ; then + logger "Installing amanda-client.conf." + log_output_of ${install} ${AMANDAHOMEDIR}/example/amanda-client.conf \ + ${SYSCONFDIR}/amanda/ || \ + { logger "WARNING: Could not install amanda-client.conf" ; return 1; } + else + logger "Note: ${SYSCONFDIR}/amanda/amanda-client.conf exists. Please check ${AMANDAHOMEDIR}/example/amanda-client.conf for updates." + fi +} + +create_ampassphrase() { + # install am_passphrase file to server + logger "Checking '${AMANDAHOMEDIR}/.am_passphrase' file." + if [ ! -f ${AMANDAHOMEDIR}/.am_passphrase ] ; then + logger "Create '${AMANDAHOMEDIR}/.am_passphrase' file." + log_output_of touch ${AMANDAHOMEDIR}/.am_passphrase || \ + { logger "WARNING: Could not create .am_passphrase." ; return 1; } + phrase=`echo $RANDOM | md5sum | awk '{print $1}'` || \ + { logger "WARNING: Error creating pseudo random passphrase." ; return 1; } + echo ${phrase} >>${AMANDAHOMEDIR}/.am_passphrase + + log_output_of chown ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}/.am_passphrase || \ + { logger "WARNING: Could not chown .am_passphrase" ; return 1; } + log_output_of chmod 0600 ${AMANDAHOMEDIR}/.am_passphrase || \ + { logger "WARNING: Could not fix permissions on .am_passphrase" ; return 1; } + fi + +} + +create_amtmp() { + # Check for existence of and permissions on ${AMTMP} + logger "Checking for '${AMTMP}' dir." + if [ ! -d ${AMTMP} ]; then + logger "Create '${AMTMP}' dir." + log_output_of mkdir ${AMTMP} || \ + { logger "WARNING: Could not create ${AMTMP}." ; return 1; } + log_output_of chown ${amanda_user}:${amanda_group} ${AMTMP} || \ + { logger "WARNING: Could not chown ${AMTMP}" ; return 1; } + fi +} + +# ------------- End Post Install Functions ----------------- diff --git a/packaging/common/post_rm_functions.sh b/packaging/common/post_rm_functions.sh new file mode 100644 index 0000000..d0d43a8 --- /dev/null +++ b/packaging/common/post_rm_functions.sh @@ -0,0 +1,34 @@ +#!/bin/sh + +# ------------- Begin Post Removal Functions ----------------- +# Functions used for post removal actions + +rm_xinetd() { + # Remove the xinetd configuration file $1. check_xinetd should be + # executed first. + logger "Removing xinetd configuration $1" + log_output_of rm ${SYSCONFDIR}/xinetd.d/$1 +} + +rm_inetd() { + # Remove amanda entries from inetd.conf + logger "Removing amanda's inetd.conf entries" + log_output_of sed -i "/^amanda .* amandad/d" +} + +remove_smf() { + # Remove the amanda service from solaris style service framework. + ret=0; export ret + logger "Removing amanda's smf entry" + log_output_of svcadm disable $1 || { ret=1; } + log_output_of svccfg delete $1 || { ret=1; } + return $ret +} + +rm_user() { + # Delete the user provided as first parameter ($1) + logger "Deleting user: $1" + log_output_of userdel $1 +} + +# ------------- End Post Removal Functions ----------------- diff --git a/packaging/common/pre_inst_functions.sh b/packaging/common/pre_inst_functions.sh new file mode 100644 index 0000000..878a8af --- /dev/null +++ b/packaging/common/pre_inst_functions.sh @@ -0,0 +1,280 @@ +#!/bin/sh +# These functions are included by various different installers. + +# We assume that the following variables are defined in the main script: +# amanda_user: the amanda account username +# amanda_group: the amanda account's group +# amandahomedir: a directory to use as amanda's home +# deb_uid: sepecific uid amanda_user should get on deb style systems. +# dist: used on linux for the distro. +# LOGFILE: a log file we append to +# os: Linux, Darwin, SunOS, `uname`... +# SYSCONFDIR: location of system config files (ie, /etc) +# LOGDIR: logging directory for amanda + +# These variables are defined, but null to allow checking names +checked_uid= +export checked_uid +# PreInstall Functions + +create_user() { + case $os in + Linux|SunOS) + # Create the amanda user with a specific uid on deb systems + if [ ${dist} = "Debian" -o ${dist} = "Ubuntu" ] ; then + uid_flag="-u ${deb_uid}" + else + uid_flag= + fi + logger "Checking for user: ${amanda_user}" + # we want the output of id, but if the user doesn't exist, + # sterr output just confuses things + ID=`id ${amanda_user} 2> /dev/null | sed 's/uid=\([0-9]*\).*/\1/'` + if [ "${ID}x" = "x" ] ; then + logger "Adding ${amanda_user}." + log_output_of useradd -c "Amanda" \ + -g ${amanda_group} \ + ${uid_flag} \ + -d ${AMANDAHOMEDIR} \ + -s /bin/bash ${amanda_user} || \ + { logger "WARNING: Could not create user ${amanda_user}. Installation will fail." ; return 1 ; } + r=`uname -r` + if [ "$os" = "Linux"] && [ ${dist} != "SuSE" ]; then + # Lock the amanda account until admin sets password + log_output_of passwd -l ${amanda_user} || { \ + logger "${warning_user_passwd}"; } + fi + if [ "$os" = "SunOS" ]; then + case $r in + 5.8|5.9) log_output_of passwd -l ${amanda_user};; + 5.10) # Special login-lock, while allowing execution. + log_ouptut_of passwd -N ${amanda_user} || { \ + logger "${warning_user_passwd}"; } + ;; + esac + fi + + logger "${info_create_user_success}" + else + # The user already existed + logger "${info_user_params}" + fi + ;; + Darwin) : #TODO + ;; + esac +} + +add_group() { + # Try to add the group, detect via return code if it already exists. + # This works on linux and solaris... + log_output_of groupadd ${1} + # return of 0 means group was added; 9 means group existed. + if [ $? = "0" ] || [ $? = "9" ]; then + logger "Adding ${amanda_user} to ${1}" + case $os in + Linux) um_flags="-a -G";; + # Solaris does not have -a flag. + SunOS) um_flags="-G `groups ${amanda_user}`";; + esac + # So far, all linux distros have usermod + log_output_of usermod -a -G ${1} ${amanda_user} || \ + { logger "${error_group_member}" ; return 1 ; } + else + logger "Error: groupadd failed in an unexpected way." + return 1 + fi +} + +check_user() { + # Check parameters of ${amanda_user}'s account. + # $1= user field $2= value to check + # group, shell, homedir, UID are valid for $1. + # group: checks the system group file for ${amanda_user}'s + # membership in the group named $2. + # shell: confirms the passwd file's shell field for + # ${amanda_user} is $2 + # homedir: confirm the passwd file's homedir field for + # ${amanda_user} is $2 + # UID: confirm that ${amanda_user}'s UID is $2. + # + # Extra information about the failed check is written to the log. + # + # Return codes: + # 0 = success + # 1 = error + # 2 = usage error + err=0 + if [ ! $# -eq 2 ]; then + echo "check_user(): Wrong number of parameters" + return 2 + fi + logger "Verify ${amanda_user}'s $1 = $2 " + case $1 in + "group") + # Check if the group exists, disregarding membership. + if `grep "^${2}" ${SYSCONFDIR}/group > /dev/null` ; then + # Assume the user exists, and check the user's primary group. + GROUP=`id ${amanda_user} 2> /dev/null | sed 's/.*gid=[0-9]*(\([^ ()]*\))/\1/'` + if [ ! "x${GROUP}" = "x${2}" ] ; then + logger "${amanda_user} not a member of ${2}" + err=1 + fi + else + logger "User group '${2}' does not exist" + err=1 + fi + ;; + "group-sup*") + # Check if a supplementary group exists. + SUP_MEM=`awk -F: "\$1 ~ ${2} { print \$4; }" 2> /dev/null` + if [ -n "$SUP_MEM" ] ; then + # Check if our user is a member. + if echo "${SUP_MEM}"|grep "${amanda_user}" &> /dev/null ; then + : + else + logger "${amanda_user} is not a member of supplemental group ${2}." + err=1 + fi + else + logger "Supplemental group ${2} does not exist" + err=1 + fi + ;; + "shell") + SHELL=`grep "^${amanda_user}" ${SYSCONFDIR}/passwd | cut -d: -f7` + wanted_shell=$2; export wanted_shell + if [ ! "x${SHELL}" = "x${2}" ] ; then + logger "${warning_user_shell}" + err=1 + fi + ;; + "homedir") + HOMEDIR=`grep "^${amanda_user}" ${SYSCONFDIR}/passwd | cut -d: -f6` + if [ ! "x${HOMEDIR}" = "x${2}" ] ; then + logger "${warning_user_homedir}" + err=1 + fi + ;; + "UID") + # Debian systems must use a specific UID + ID=`id ${amanda_user} 2> /dev/null | sed 's/uid=\([0-9]*\).*/\1/'` + if [ ! "${ID}" -eq "${2}" ] ; then + checked_uid=${2}; export checked_uid + logger "${warning_user_uid_debian}" + err=1 + fi + ;; + *) + echo "check_user(): unknown user parameter." + err=2 + ;; + esac + + return $err +} + +check_homedir() { + # Checks that the homedir has correct permissions and belongs to correct + # user. Uses $amanda_user and $amanda_group. + if [ -d ${AMANDAHOMEDIR} ] ; then + OWNER_GROUP=`ls -dl ${AMANDAHOMEDIR} | awk '{ print $3" "$4; }'` + [ "$OWNER_GROUP" = "${amanda_user} ${amanda_group}" ] || \ + logger "${warning_homedir_owner}" + return $? + else + logger "homedir ${AMANDAHOMEDIR} does not exist." + return 1 + fi +} + +create_homedir() { + # Creates the homedir, if necessary, and fixes ownership. + if [ ! -d ${AMANDAHOMEDIR} ] ; then + logger "Creating ${AMANDAHOMEDIR}" + log_output_of mkdir -p -m 0750 ${AMANDAHOMEDIR} || + { logger "WARNING: Could not create ${AMANDAHOMEDIR}" ; return 1 ; } + fi + log_output_of chown -R ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR} || + { logger "WARNING: Could not chown ${AMANDAHOMEDIR}" ; return 1 ; } +} + +create_logdir() { + if [ -d ${LOGDIR} ] || [ -f ${LOGDIR} ] ; then + logger "Found existing ${LOGDIR}" + log_output_of mv ${LOGDIR} ${LOGDIR}.save || \ + { logger "WARNING: Could not backup existing log directory: ${LOGDIR}" ; return 1 ; } + fi + logger "Creating ${LOGDIR}." + log_output_of mkdir -p -m 0750 ${LOGDIR} || \ + { logger "WARNING: Could not create ${LOGDIR}" ; return 1 ; } + if [ -d ${LOGDIR}.save ] || [ -f ${LOGDIR}.save ] ; then + # Move the saved log into the logdir. + log_output_of mv ${LOGDIR}.save ${LOGDIR} + fi + log_output_of chown -R ${amanda_user}:${amanda_group} ${LOGDIR} || \ + { logger "WARNING: Could not chown ${LOGDIR}" ; return 1 ; } +} + +# Info, Warning, and Error strings used by the installer + +info_create_user_success="The '${amanda_user}' user account has been successfully created. + Furthermore, the account has been automatically locked for you for security + purposes. Once a password for the '${amanda_user}' account has been set, + the user can be unlocked by issuing the following command as root.: + + # passwd -u ${amanda_user} + + If this is not a new installation of Amanda and you have pre-existing Amanda + configurations in ${SYSCONFDIR}/amanda you should ensure that 'dumpuser' + is set to '${amanda_user}' in those configurations. Additionally, you + should ensure that ${AMANDAHOMEDIR}/.amandahosts on your client systems + is properly configured to allow connections for the user '${amanda_user}'." + +warning_user_password="!!! WARNING! WARNING! WARNING! WARNING! WARNING! !!! +!!! !!! +!!! The '${amanda_user}' user account for this system has been !!! +!!! created, however the user has no password set. For !!! +!!! security purposes this account is normally locked after !!! +!!! creation. Unfortunately, when locking this account an !!! +!!! error occurred. To ensure the security of your system, !!! +!!! you should set a password for the user account !!! +!!! '${amanda_user}' immediately! To set such a password, !!! +!!! please issue the following command: !!! +!!! !!! +!!! # passwd ${amanda_user} !!! +!!! !!! +!!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" + +info_user_params="The Amanda backup software is configured to operate as the user + '${amanda_user}'. This user exists on your system and has not been modified. + To ensure that Amanda functions properly, please see that the following + parameters are set for that user: + SHELL: /bin/bash + HOME: ${AMANDAHOMEDIR} + Default group: ${amanda_group}" + +error_group_member="!!! Nonfatal ERROR. Nonfatal ERROR. !!! +!!! user '${amanda_user}' is not part of the '${amanda_group}' group, !!! +!!! Amanda will not run until '${amanda_user}' is a member of '${amanda_group}'. !!! +!!! Nonfatal ERROR. Nonfatal ERROR. Nonfatal Error. !!!" + +warning_user_shell="WARNING: The user '${amanda_user}' has a non-default shell. +the default shell is ${wanted_shell}. Other shells have not been tested." + +warning_user_homedir="!!! WARNING! WARNING! WARNING! WARNING! WARNING! !!! +!!! The user '${amanda_user}' must have its home directory set to !!! +!!! '${AMANDAHOMEDIR}' Please correct before using Amanda !!! +!!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" + +warning_user_uid_debian="!!! WARNING! WARNING! WARNING! WARNING! WARNING! !!! +!!! Debian packages were built assuming that ${amanda_user} !!! +!!! uid = ${checked_uid}. The uid of ${amanda_user} is different !!! +!!! different on this system. Files owned by ${checked_uid} must !!! +!!! be chowned to ${amanda_user}. !!! +!!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" + +warning_homedir_owner="!!! Please ensure that the directory '${AMANDAHOMEDIR}' is owned by !!! +!!! the user '${amanda_user}' and group '${amanda_group}'. !!!" + +# --------------- End included Functions ----------------- diff --git a/packaging/common/shunit2 b/packaging/common/shunit2 new file mode 100644 index 0000000..232633e --- /dev/null +++ b/packaging/common/shunit2 @@ -0,0 +1,1117 @@ +# $Id: shunit2 277 2008-10-29 21:20:22Z kate.ward@forestent.com $ +# vim:et:ft=sh:sts=2:sw=2 +# vim:foldmethod=marker:foldmarker=/**,*/ +# +#/** +# +# +# +# shUnit 2.1.5 +# Shell Unit Test Framework +# +# http://shunit2.googlecode.com/ +# +# written by Kate Ward <kate.ward@forestent.com> +# released under the LGPL +# +# This module implements a xUnit based unit test framework similar to JUnit. +# +#*/ + +SHUNIT_VERSION='2.1.5' + +SHUNIT_TRUE=0 +SHUNIT_FALSE=1 +SHUNIT_ERROR=2 + +_shunit_warn() { echo "shunit2:WARN $@" >&2; } +_shunit_error() { echo "shunit2:ERROR $@" >&2; } +_shunit_fatal() { echo "shunit2:FATAL $@" >&2; } + +# specific shell checks +if [ -n "${ZSH_VERSION:-}" ]; then + setopt |grep "^shwordsplit$" >/dev/null + if [ $? -ne ${SHUNIT_TRUE} ]; then + _shunit_fatal 'zsh shwordsplit option is required for proper operation' + exit ${SHUNIT_ERROR} + fi + if [ -z "${SHUNIT_PARENT:-}" ]; then + _shunit_fatal "zsh does not pass \$0 through properly. please declare \ +\"SHUNIT_PARENT=\$0\" before calling shUnit2" + exit ${SHUNIT_ERROR} + fi +fi + +# +# constants +# + +__SHUNIT_ASSERT_MSG_PREFIX='ASSERT:' +__SHUNIT_PARENT=${SHUNIT_PARENT:-$0} + +# set the constants readonly +shunit_constants_=`set |grep '^__SHUNIT_' |cut -d= -f1` +echo "${shunit_constants_}" |grep '^Binary file' >/dev/null \ + && shunit_constants_=`set |grep -a '^__SHUNIT_' |cut -d= -f1` +for shunit_constant_ in ${shunit_constants_}; do + shunit_ro_opts_='' + case ${ZSH_VERSION:-} in + '') ;; # this isn't zsh + [123].*) ;; # early versions (1.x, 2.x, 3.x) + *) shunit_ro_opts_='-g' ;; # all later versions. declare readonly globally + esac + readonly ${shunit_ro_opts_} ${shunit_constant_} +done +unset shunit_constant_ shunit_constants_ shunit_ro_opts_ + +# variables +__shunit_skip=${SHUNIT_FALSE} +__shunit_suite='' + +# counts of tests +__shunit_testSuccess=${SHUNIT_TRUE} +__shunit_testsTotal=0 +__shunit_testsPassed=0 +__shunit_testsFailed=0 + +# counts of asserts +__shunit_assertsTotal=0 +__shunit_assertsPassed=0 +__shunit_assertsFailed=0 +__shunit_assertsSkipped=0 + +__shunit_lineno='' +__shunit_reportGenerated=${SHUNIT_FALSE} + +# macros +_SHUNIT_LINENO_='eval __shunit_lineno=""; if [ "${1:-}" = "--lineno" ]; then [ -n "$2" ] && __shunit_lineno="[$2] "; shift 2; fi' + +#----------------------------------------------------------------------------- +# assert functions +# + +#/** +# +# +# void +# +# +# +# +# assertEquals +# string [message] +# string expected +# string actual +# +# +# Asserts that expected and +# actual are equal to one another. The message is +# optional. +# +# +#*/ +assertEquals() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 2 -o $# -gt 3 ]; then + _shunit_error "assertEquals() requires two or three arguments; $# given" + _shunit_error "1: ${1:+$1} 2: ${2:+$2} 3: ${3:+$3}" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 3 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + shunit_expected_=$1 + shunit_actual_=$2 + + shunit_return=${SHUNIT_TRUE} + if [ "${shunit_expected_}" = "${shunit_actual_}" ]; then + _shunit_assertPass + else + failNotEquals "${shunit_message_}" "${shunit_expected_}" "${shunit_actual_}" + shunit_return=${SHUNIT_FALSE} + fi + + unset shunit_message_ shunit_expected_ shunit_actual_ + return ${shunit_return} +} +_ASSERT_EQUALS_='eval assertEquals --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# assertNotEquals +# string [message] +# string unexpected +# string actual +# +# +# Asserts that unexpected and +# actual are not +# equal to one another. The message is optional. +# +# +#*/ +assertNotEquals() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 2 -o $# -gt 3 ]; then + _shunit_error "assertNotEquals() requires two or three arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 3 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + shunit_unexpected_=$1 + shunit_actual_=$2 + + shunit_return=${SHUNIT_TRUE} + if [ "${shunit_unexpected_}" != "${shunit_actual_}" ]; then + _shunit_assertPass + else + failSame "${shunit_message_}" "$@" + shunit_return=${SHUNIT_FALSE} + fi + + unset shunit_message_ shunit_unexpected_ shunit_actual_ + return ${shunit_return} +} +_ASSERT_NOT_EQUALS_='eval assertNotEquals --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# assertNull +# string [message] +# string value +# +# +# Asserts that value is null, +# or in shell terms a zero-length string. The message is optional. +# +# +#*/ +assertNull() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 1 -o $# -gt 2 ]; then + _shunit_error "assertNull() requires one or two arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 2 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + assertTrue "${shunit_message_}" "[ -z '$1' ]" + shunit_return=$? + + unset shunit_message_ + return ${shunit_return} +} +_ASSERT_NULL_='eval assertNull --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# assertNotNull +# string [message] +# string value +# +# +# Asserts that value is not null, or in shell terms not +# a zero-length string. The message is optional. +# +# +#*/ +assertNotNull() +{ + ${_SHUNIT_LINENO_} + if [ $# -gt 2 ]; then # allowing 0 arguments as $1 might actually be null + _shunit_error "assertNotNull() requires one or two arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 2 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + assertTrue "${shunit_message_}" "[ -n '${1:-}' ]" + shunit_return=$? + + unset shunit_message_ + return ${shunit_return} +} +_ASSERT_NOT_NULL_='eval assertNotNull --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# assertSame +# string [message] +# string expected +# string actual +# +# +# This function is functionally equivalent to +# assertEquals. +# +# +#*/ +assertSame() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 2 -o $# -gt 3 ]; then + _shunit_error "assertSame() requires two or three arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 3 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + assertEquals "${shunit_message_}" "$1" "$2" + shunit_return=$? + + unset shunit_message_ + return ${shunit_return} +} +_ASSERT_SAME_='eval assertSame --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# assertNotSame +# string [message] +# string unexpected +# string actual +# +# +# Asserts that unexpected and +# actual are not +# equal to one another. The message is optional. +# +# +#*/ +assertNotSame() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 2 -o $# -gt 3 ]; then + _shunit_error "assertNotSame() requires two or three arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 3 ]; then + shunit_message_="${shunit_message_:-}$1" + shift + fi + assertNotEquals "${shunit_message_}" "$1" "$2" + shunit_return=$? + + unset shunit_message_ + return ${shunit_return} +} +_ASSERT_NOT_SAME_='eval assertNotSame --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# assertTrue +# string [message] +# string condition +# +# +# Asserts that a given shell test condition is true. The message is +# optional. +# Testing whether something is true or false is easy enough by using +# the assertEquals/assertNotSame functions. Shell supports much more +# complicated tests though, and a means to support them was needed. As such, +# this function tests that conditions are true or false through evaluation +# rather than just looking for a true or false. +# +# The following test will succeed: assertTrue "[ 34 -gt 23 ]" +# The folloing test will fail with a message: assertTrue "test failed" "[ -r '/non/existant/file' ]" +# +# +# +#*/ +assertTrue() +{ + ${_SHUNIT_LINENO_} + if [ $# -gt 2 ]; then + _shunit_error "assertTrue() takes one two arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 2 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + shunit_condition_=$1 + + # see if condition is an integer, i.e. a return value + shunit_match_=`expr "${shunit_condition_}" : '\([0-9]*\)'` + shunit_return=${SHUNIT_TRUE} + if [ -z "${shunit_condition_}" ]; then + # null condition + shunit_return=${SHUNIT_FALSE} + elif [ "${shunit_condition_}" = "${shunit_match_}" ]; then + # possible return value. treating 0 as true, and non-zero as false. + [ ${shunit_condition_} -ne 0 ] && shunit_return=${SHUNIT_FALSE} + else + # (hopefully) a condition + ( eval ${shunit_condition_} ) >/dev/null 2>&1 + [ $? -ne 0 ] && shunit_return=${SHUNIT_FALSE} + fi + + # record the test + if [ ${shunit_return} -eq ${SHUNIT_TRUE} ]; then + _shunit_assertPass + else + _shunit_assertFail "${shunit_message_}" + fi + + unset shunit_message_ shunit_condition_ shunit_match_ + return ${shunit_return} +} +_ASSERT_TRUE_='eval assertTrue --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# assertFalse +# string [message] +# string condition +# +# +# Asserts that a given shell test condition is false. The message is +# optional. +# Testing whether something is true or false is easy enough by using +# the assertEquals/assertNotSame functions. Shell supports much more +# complicated tests though, and a means to support them was needed. As such, +# this function tests that conditions are true or false through evaluation +# rather than just looking for a true or false. +# +# The following test will succeed: assertFalse "[ 'apples' = 'oranges' ]" +# The folloing test will fail with a message: assertFalse "test failed" "[ 1 -eq 1 -a 2 -eq 2 ]" +# +# +# +#*/ +assertFalse() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 1 -o $# -gt 2 ]; then + _shunit_error "assertFalse() quires one or two arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 2 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + shunit_condition_=$1 + + # see if condition is an integer, i.e. a return value + shunit_match_=`expr "${shunit_condition_}" : '\([0-9]*\)'` + shunit_return=${SHUNIT_TRUE} + if [ -z "${shunit_condition_}" ]; then + # null condition + shunit_return=${SHUNIT_FALSE} + elif [ "${shunit_condition_}" = "${shunit_match_}" ]; then + # possible return value. treating 0 as true, and non-zero as false. + [ ${shunit_condition_} -eq 0 ] && shunit_return=${SHUNIT_FALSE} + else + # (hopefully) a condition + ( eval ${shunit_condition_} ) >/dev/null 2>&1 + [ $? -eq 0 ] && shunit_return=${SHUNIT_FALSE} + fi + + # record the test + if [ ${shunit_return} -eq ${SHUNIT_TRUE} ]; then + _shunit_assertPass + else + _shunit_assertFail "${shunit_message_}" + fi + + unset shunit_message_ shunit_condition_ shunit_match_ + return ${shunit_return} +} +_ASSERT_FALSE_='eval assertFalse --lineno "${LINENO:-}"' + +#----------------------------------------------------------------------------- +# failure functions +# + +#/** +# +# +# void +# +# +# +# +# fail +# string [message] +# +# +# Fails the test immediately, with the optional message. +# +# +#*/ +fail() +{ + ${_SHUNIT_LINENO_} + if [ $# -gt 1 ]; then + _shunit_error "fail() requires one or two arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 1 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + + _shunit_assertFail "${shunit_message_}" + + unset shunit_message_ + return ${SHUNIT_FALSE} +} +_FAIL_='eval fail --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# failNotEquals +# string [message] +# string unexpected +# string actual +# +# +# Fails the test if unexpected and +# actual are not +# equal to one another. The message is optional. +# +# +#*/ +failNotEquals() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 2 -o $# -gt 3 ]; then + _shunit_error "failNotEquals() requires one or two arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 3 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + shunit_unexpected_=$1 + shunit_actual_=$2 + + _shunit_assertFail "${shunit_message_:+${shunit_message_} }expected:<${shunit_unexpected_}> but was:<${shunit_actual_}>" + + unset shunit_message_ shunit_unexpected_ shunit_actual_ + return ${SHUNIT_FALSE} +} +_FAIL_NOT_EQUALS_='eval failNotEquals --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# failSame +# string [message] +# +# +# Indicate test failure because arguments were the same. The message is +# optional. +# +# +#*/ +failSame() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 2 -o $# -gt 3 ]; then + _shunit_error "failSame() requires two or three arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 3 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + + _shunit_assertFail "${shunit_message_:+${shunit_message_} }expected not same" + + unset shunit_message_ + return ${SHUNIT_FALSE} +} +_FAIL_SAME_='eval failSame --lineno "${LINENO:-}"' + +#/** +# +# +# void +# +# +# +# +# failNotSame +# string [message] +# string expected +# string actual +# +# +# Indicate test failure because arguments were not the same. The +# message is optional. +# +# +#*/ +failNotSame() +{ + ${_SHUNIT_LINENO_} + if [ $# -lt 2 -o $# -gt 3 ]; then + _shunit_error "failNotEquals() requires one or two arguments; $# given" + return ${SHUNIT_ERROR} + fi + _shunit_shouldSkip && return ${SHUNIT_TRUE} + + shunit_message_=${__shunit_lineno} + if [ $# -eq 3 ]; then + shunit_message_="${shunit_message_}$1" + shift + fi + failNotEquals "${shunit_message_}" "$1" "$2" + shunit_return=$? + + unset shunit_message_ + return ${shunit_return} +} +_FAIL_NOT_SAME_='eval failNotSame --lineno "${LINENO:-}"' + +#----------------------------------------------------------------------------- +# skipping functions +# + +#/** +# +# +# void +# +# +# +# +# startSkipping +# +# +# +# This function forces the remaining assert and fail functions to be +# "skipped", i.e. they will have no effect. Each function skipped will be +# recorded so that the total of asserts and fails will not be altered. +# +# +#*/ +startSkipping() +{ + __shunit_skip=${SHUNIT_TRUE} +} + +#/** +# +# +# void +# +# +# +# +# endSkipping +# +# +# +# This function returns calls to the assert and fail functions to their +# default behavior, i.e. they will be called. +# +# +#*/ +endSkipping() +{ + __shunit_skip=${SHUNIT_FALSE} +} + +#/** +# +# +# boolean +# +# +# +# +# isSkipping +# +# +# +# This function returns the state of skipping. +# +# +#*/ +isSkipping() +{ + return ${__shunit_skip} +} + +#----------------------------------------------------------------------------- +# suite functions +# + +#/** +# +# +# void +# +# +# +# +# suite +# +# +# +# This function can be optionally overridden by the user in their test +# suite. +# If this function exists, it will be called when +# shunit2 is sourced. If it does not exist, shUnit2 will +# search the parent script for all functions beginning with the word +# test, and they will be added dynamically to the test +# suite. +# +# +#*/ +# Note: see _shunit_mktempFunc() for actual implementation +# suite() { :; } + +#/** +# +# +# void +# +# +# +# +# suite_addTest +# string function +# +# +# This function adds a function name to the list of tests scheduled for +# execution as part of this test suite. This function should only be called +# from within the suite() function. +# +# +#*/ +suite_addTest() +{ + shunit_func_=${1:-} + + __shunit_suite="${__shunit_suite:+${__shunit_suite} }${shunit_func_}" + __shunit_testsTotal=`expr ${__shunit_testsTotal} + 1` + + unset shunit_func_ +} + +#/** +# +# +# void +# +# +# +# +# oneTimeSetUp +# +# +# +# This function can be be optionally overridden by the user in their +# test suite. +# If this function exists, it will be called once before any tests are +# run. It is useful to prepare a common environment for all tests. +# +# +#*/ +# Note: see _shunit_mktempFunc() for actual implementation +# oneTimeSetUp() { :; } + +#/** +# +# +# void +# +# +# +# +# oneTimeTearDown +# +# +# +# This function can be be optionally overridden by the user in their +# test suite. +# If this function exists, it will be called once after all tests are +# completed. It is useful to clean up the environment after all tests. +# +# +#*/ +# Note: see _shunit_mktempFunc() for actual implementation +# oneTimeTearDown() { :; } + +#/** +# +# +# void +# +# +# +# +# setUp +# +# +# +# This function can be be optionally overridden by the user in their +# test suite. +# If this function exists, it will be called before each test is run. +# It is useful to reset the environment before each test. +# +# +#*/ +# Note: see _shunit_mktempFunc() for actual implementation +# setUp() { :; } + +#/** +# +# +# void +# +# +# +# +# tearDown +# +# +# +# This function can be be optionally overridden by the user in their +# test suite. +# If this function exists, it will be called after each test completes. +# It is useful to clean up the environment after each test. +# +# +#*/ +# Note: see _shunit_mktempFunc() for actual implementation +# tearDown() { :; } + +#------------------------------------------------------------------------------ +# internal shUnit2 functions +# + +# this function is a cross-platform temporary directory creation tool. not all +# OSes have the mktemp function, so one is included here. +_shunit_mktempDir() +{ + # try the standard mktemp function + ( exec mktemp -dqt shunit.XXXXXX 2>/dev/null ) && return + + # the standard mktemp didn't work. doing our own. + if [ -r '/dev/urandom' ]; then + _shunit_random_=`od -vAn -N4 -tx4 "${_shunit_file_}" +#! /bin/sh +exit ${SHUNIT_TRUE} +EOF + # If the path is changed, put it back for this command + PATH=/bin:/usr/bin chmod +x "${_shunit_file_}" + done + + unset _shunit_file_ +} + +_shunit_cleanup() +{ + _shunit_name_=$1 + + case ${_shunit_name_} in + EXIT) _shunit_signal_=0 ;; + INT) _shunit_signal_=2 ;; + TERM) _shunit_signal_=15 ;; + *) + _shunit_warn "unrecognized trap value (${_shunit_name_})" + _shunit_signal_=0 + ;; + esac + + # do our work + rm -fr "${__shunit_tmpDir}" + + # exit for all non-EXIT signals + if [ ${_shunit_name_} != 'EXIT' ]; then + _shunit_warn "trapped and now handling the (${_shunit_name_}) signal" + # disable EXIT trap + trap 0 + # add 128 to signal and exit + exit `expr ${_shunit_signal_} + 128` + elif [ ${__shunit_reportGenerated} -eq ${SHUNIT_FALSE} ] ; then + _shunit_assertFail 'Unknown failure encountered running a test' + _shunit_generateReport + exit ${SHUNIT_ERROR} + fi + + unset _shunit_name_ _shunit_signal_ +} + +# The actual running of the tests happens here. +_shunit_execSuite() +{ + for _shunit_test_ in ${__shunit_suite}; do + __shunit_testSuccess=${SHUNIT_TRUE} + + # disable skipping + endSkipping + + # execute the per-test setup function + setUp + + # execute the test + echo "${_shunit_test_}" + eval ${_shunit_test_} + + # execute the per-test tear-down function + tearDown + + # update stats + if [ ${__shunit_testSuccess} -eq ${SHUNIT_TRUE} ]; then + __shunit_testsPassed=`expr ${__shunit_testsPassed} + 1` + else + __shunit_testsFailed=`expr ${__shunit_testsFailed} + 1` + fi + done + + unset _shunit_test_ +} + +# This function exits shUnit2 with the appropriate error code and OK/FAILED +# message. +_shunit_generateReport() +{ + _shunit_ok_=${SHUNIT_TRUE} + + # if no exit code was provided one, determine an appropriate one + [ ${__shunit_testsFailed} -gt 0 \ + -o ${__shunit_testSuccess} -eq ${SHUNIT_FALSE} ] \ + && _shunit_ok_=${SHUNIT_FALSE} + + echo + if [ ${__shunit_testsTotal} -eq 1 ]; then + echo "Ran ${__shunit_testsTotal} test." + else + echo "Ran ${__shunit_testsTotal} tests." + fi + + _shunit_failures_='' + _shunit_skipped_='' + [ ${__shunit_assertsFailed} -gt 0 ] \ + && _shunit_failures_="failures=${__shunit_assertsFailed}" + [ ${__shunit_assertsSkipped} -gt 0 ] \ + && _shunit_skipped_="skipped=${__shunit_assertsSkipped}" + + if [ ${_shunit_ok_} -eq ${SHUNIT_TRUE} ]; then + _shunit_msg_='OK' + [ -n "${_shunit_skipped_}" ] \ + && _shunit_msg_="${_shunit_msg_} (${_shunit_skipped_})" + else + _shunit_msg_="FAILED (${_shunit_failures_}" + [ -n "${_shunit_skipped_}" ] \ + && _shunit_msg_="${_shunit_msg_},${_shunit_skipped_}" + _shunit_msg_="${_shunit_msg_})" + fi + + echo + echo ${_shunit_msg_} + __shunit_reportGenerated=${SHUNIT_TRUE} + + unset _shunit_failures_ _shunit_msg_ _shunit_ok_ _shunit_skipped_ +} + +_shunit_shouldSkip() +{ + [ ${__shunit_skip} -eq ${SHUNIT_FALSE} ] && return ${SHUNIT_FALSE} + _shunit_assertSkip +} + +_shunit_assertPass() +{ + __shunit_assertsPassed=`expr ${__shunit_assertsPassed} + 1` + __shunit_assertsTotal=`expr ${__shunit_assertsTotal} + 1` +} + +_shunit_assertFail() +{ + _shunit_msg_=$1 + + __shunit_testSuccess=${SHUNIT_FALSE} + __shunit_assertsFailed=`expr ${__shunit_assertsFailed} + 1` + __shunit_assertsTotal=`expr ${__shunit_assertsTotal} + 1` + echo "${__SHUNIT_ASSERT_MSG_PREFIX}${_shunit_msg_}" + + unset _shunit_msg_ +} + +_shunit_assertSkip() +{ + __shunit_assertsSkipped=`expr ${__shunit_assertsSkipped} + 1` + __shunit_assertsTotal=`expr ${__shunit_assertsTotal} + 1` +} + +#------------------------------------------------------------------------------ +# main +# + +# create a temporary storage location +__shunit_tmpDir=`_shunit_mktempDir` + +# provide a public temporary directory for unit test scripts +# TODO(kward): document this +shunit_tmpDir="${__shunit_tmpDir}/tmp" +mkdir "${shunit_tmpDir}" + +# setup traps to clean up after ourselves +trap '_shunit_cleanup EXIT' 0 +trap '_shunit_cleanup INT' 2 +trap '_shunit_cleanup TERM' 15 + +# create phantom functions to work around issues with Cygwin +_shunit_mktempFunc +PATH="${__shunit_tmpDir}:${PATH}" + +# execute the oneTimeSetUp function (if it exists) +oneTimeSetUp + +# execute the suite function defined in the parent test script +# deprecated as of 2.1.0 +suite + +# if no suite function was defined, dynamically build a list of functions +if [ -z "${__shunit_suite}" ]; then + shunit_funcs_=`grep "^[ \t]*test[A-Za-z0-9_]* *()" ${__SHUNIT_PARENT} \ + |sed 's/[^A-Za-z0-9_]//g'` + for shunit_func_ in ${shunit_funcs_}; do + suite_addTest ${shunit_func_} + done +fi +unset shunit_func_ shunit_funcs_ + +# execute the tests +_shunit_execSuite + +# execute the oneTimeTearDown function (if it exists) +oneTimeTearDown + +# generate the report +_shunit_generateReport + +# that's it folks +[ ${__shunit_testsFailed} -eq 0 ] +exit $? + +#/** +# +#*/ diff --git a/packaging/common/substitute.pl b/packaging/common/substitute.pl index 8b5e384..680d4ac 100755 --- a/packaging/common/substitute.pl +++ b/packaging/common/substitute.pl @@ -15,92 +15,49 @@ if ( not -e "packaging/common/substitute.pl" ) { die "Error: 'substitute.pl' must be run from the root of a source tree" } -sub get_version { - # Two build cases: from checkout (svn info works), or dist tarball - # (FULL_VERSION will exist). First try FULL_VERSION, then - # try svn info, which takes more time and processing. We assume our url - # is structured something like this: - # http://///[|] - # The re is tested on http urls with full DNS names, but ssh+svn:// or - # file:/// and short DNS names should work too. - - my $VERSION; - my $version_file = "FULL_VERSION"; - my $version_handle; - my $versioned_tree = 'packaging/deb'; - if (-e $version_file) { - # Autogen has been run, search FULL_VERSION file. - if (-e "$version_file") { - open($version_handle, "<", "$version_file") or - die "Could not open FULL_VERSION."; - chomp($VERSION = <$version_handle>); - close($version_file); - - } else { - die "Could not find FULL_VERSION file."; - } - } - if ( ! $VERSION ) { - # Autogen has not been run or VERSION macro was found. Try to - # use svn info. - my $SVN_URL = ""; - my $SVN_ROOT = ""; - my $SVN_REV = ""; - foreach my $info_line (`svn info $versioned_tree`) { - $SVN_URL = $1 if $info_line =~ m{^URL: (.*)}; - $SVN_ROOT = $1 if $info_line =~ m{^Repository Root: (.*)}; - $SVN_REV = $1 if $info_line =~ m{^Revision: (.*)}; - } - my @paths; - my $BRANCH; - my $PROJECT; - my $svn_version; - # Only newer versions of svn supply Repository Root. - if ( $SVN_ROOT ) { - $SVN_URL =~ m/$SVN_ROOT(.*)/; - my $SVN_PATH = $1; +sub get_date { + my $date; + # Set the date using date -r + open(my $DATE_PIPE, "-|", "/bin/date '+%a, %d %b %Y %T %z'"); + [ $? == 0 ] or die "could not read output of date '+%a, %d %b %Y %T %z'"; + chomp($date = <$DATE_PIPE>); + close($DATE_PIPE); + return $date; +}; - @paths = split "/", $SVN_PATH; - # We get ( empty, project branch, svn_version...) - $PROJECT = $paths[1]; - $BRANCH = $paths[2]; - $svn_version = $paths[3]; - } else { - # This may not work with file or ssh+svn urls. In an - # http: url, we get ( Protocol, empty, server, project, - # branch, svn_version...) - @paths = split "/", $SVN_URL; - $PROJECT = $paths[3]; - $BRANCH = $paths[4]; - $svn_version = $paths[5]; - } +sub get_arch { + my @u = POSIX::uname(); + return $u[4]; +}; - if ( $BRANCH eq "trunk" | $BRANCH eq "branches" ) { - # Suffix -svn-rev to branch and trunk builds. - } else { - # Fix VERSION by stripping up to the first digit - $svn_version =~ s/^\D*//; - my $cruft = qr{[_.]}; - if ( $BRANCH eq "branches" ) { - # Branch names *should* have only 2 digits. - $svn_version =~ m{^(\d)$cruft?(\d)$cruft?(\w*)?}; - # We throw away anything other than the first - # two digits. - $VERSION = "$1.$2"; - # Make sure that the version indicates this is - # neither an RC or patch build. - $VERSION .= "branch"; - } else { - # We should have a tag, which *should* have 3 - # and maybe an rc## suffix - $svn_version =~ m{^(\d)$cruft?(\d)$cruft?(\d)$cruft?(\w*)?}; - $VERSION = "$1.$2.$3$4"; - } - } +sub read_file { + # $1 is the file name and must exist. + my $contents; + my $file = "$_[0]"; + my $f_handle; + # Autogen has been run, the file will be there. + if (-e $file) { + open($f_handle, "<", "$file") or + die "Could not open $file."; + chomp($contents = <$f_handle>); + close($f_handle); + + } else { + die "Could not find $file file. run config/set_full_version or ./autogen"; } - return $VERSION; + return $contents; } +sub fix_pkg_rev { + my $pkg_rev = "$_[0]"; + # $1 should be a package type, and we build the rest of the regex string + # here for simplicity + my $type_match_str = "$_[1]0?"; + # strip pkg_type and maybe a zero, else assign pkg_rev = 1 + $pkg_rev = $pkg_rev =~ s/$type_match_str// || 1; + return $pkg_rev; + } + my $pkg_type; # Check environment to see if it's something else. if (defined($ENV{'pkg_type'})) { @@ -116,13 +73,28 @@ elsif ( $ARGV[0] =~ /rpm/ ) { elsif ( $ARGV[0] =~ /sun/ ) { $pkg_type = "sun"; } +else { + die "Could not determine pkg_type either by environment variable, or + pathname of files to substitute ($ARGV[0])."; +} +# The keys to the hashes used are the "tags" we try to substitute. Each +# tag should be on a line by itself in the package file, as the whole line is +# replaced by a set of lines. The line may be commented. +my %replacement_filenames = ( + "%%COMMON_FUNCTIONS%%" => "packaging/common/common_functions.sh", + "%%PRE_INST_FUNCTIONS%%" => "packaging/common/pre_inst_functions.sh", + "%%POST_INST_FUNCTIONS%%" => "packaging/common/post_inst_functions.sh", + "%%POST_RM_FUNCTIONS%%" => "packaging/common/post_rm_functions.sh", +# TODO: PRE_UNINST? +); -# The surrounding line is preserved, and only the tag is replaced. This -# behavior is somewhat arbitrary, but hopefully keeps replacements in comments -# syntax legal. +# These are handled slightly differently: The surrounding line is preserved, +# and only the tag is replaced. This behavior is somewhat arbitrary, but +# hopefully keeps replacements in comments syntax legal. my %replacement_strings_common = ( - "%%VERSION%%" => get_version(), + "%%VERSION%%" => read_file("FULL_VERSION"), + "%%PKG_REV%%" => read_file("PKG_REV"), "%%AMANDAHOMEDIR%%" => "/var/lib/amanda", "%%LOGDIR%%" => "/var/log/amanda", ); @@ -141,12 +113,15 @@ my %replacement_strings_rpm = ( ); my %replacement_strings_sun = ( + "%%ARCH%%" => "", ); my %replacement_strings; if ( $pkg_type eq "deb" ) { %replacement_strings = ( %replacement_strings_deb, %replacement_strings_common ); + $replacement_strings{"%%PKG_REV%%"} = + fix_pkg_rev($replacement_strings{"%%PKG_REV%%"}, "deb"); # Let's determine the distro: # Ubuntu has /etc/lsb-release, debian does not open(my $LSB_RELEASE, "<", "/etc/lsb-release") or @@ -169,15 +144,10 @@ if ( $pkg_type eq "deb" ) { $replacement_strings{"%%DEB_REL%%"} = $line; close($DEB_RELEASE); } - # Set the date using date -r - open(my $DATE_PIPE, "-|", "/bin/date -R") or die "could not read output of date -r"; - chomp($line = <$DATE_PIPE>); - $replacement_strings{"%%DATE%%"} = $line; - close($DATE_PIPE); + $replacement_strings{"%%DATE%%"} = get_date(); # 32bit should use bitrock perl, while 64bit should use builtin. we # live on the edge and assume it's there. - my @uname=POSIX::uname(); - my $arch = $uname[4]; + my $arch = get_arch(); if ( $arch eq "x86_64" ) { $replacement_strings{"%%PERL%%"} = $^X; } @@ -188,12 +158,34 @@ if ( $pkg_type eq "deb" ) { elsif ( $pkg_type eq "rpm" ){ %replacement_strings = ( %replacement_strings_rpm, %replacement_strings_common ); + $replacement_strings{"%%PKG_REV%%"} = + fix_pkg_rev($replacement_strings{"%%PKG_REV%%"}, "rpm"); } else { %replacement_strings = ( %replacement_strings_sun, %replacement_strings_common ); + $replacement_strings{"%%PKG_REV%%"} = + fix_pkg_rev($replacement_strings{"%%PKG_REV%%"}, "sun"); + $replacement_strings{"%%DATE%%"} = get_date(); + my $arch = get_arch(); + if ( $arch eq "sun4u" ) { + $replacement_strings{"%%ARCH%%"} = "sparc"; + } + elsif ( $arch eq "i86pc" ) { + $replacement_strings{"%%ARCH%%"} = "intel"; + } + else { + die "Unknown solaris platform!"; + } } +# Make a hash of tags and the contents of replacement files +my %replacement_data; +while (my ($tag, $filename) = each %replacement_filenames) { + open(my $file, "<", $filename) or die "could not read \"$filename\": $!"; + $replacement_data{$tag} = join "", <$file>; + close($file); +} open my $src, "<", $ARGV[0] or die "could not read $ARGV[0]: $!"; open my $dst, ">", $ARGV[1] or die "could not write $ARGV[1]: $!"; select $dst; @@ -201,8 +193,12 @@ while (<$src>) { chomp; # check for tags, using non greedy matching if ( m/(%%.+?%%)/ ) { + # Data replaces the line + if ( defined($replacement_data{$1})) { + print $replacement_data{$1}; + } # strings just replace the tag. - if ( defined($replacement_strings{$1})) { + elsif ( defined($replacement_strings{$1})) { s/(%%.+?%%)/$replacement_strings{$1}/g; print "$_\n"; } diff --git a/packaging/common/test_sh_libs.sh b/packaging/common/test_sh_libs.sh new file mode 100755 index 0000000..85711f1 --- /dev/null +++ b/packaging/common/test_sh_libs.sh @@ -0,0 +1,644 @@ +#!/bin/sh +# This script is uses ShUnit to test packaging/common/*. Currently +# it only tests the functions as they perform for rpm and deb building. +# As support is added for other styles of package, these tests should be +# updated. + +####################### +# If EXECUTING WITH ROOT ACCESS SCRIPT DELETES AND CREATES USERS. +# EXECUTE WITH CAUTION. +####################### + +#set -x + +# Note on conflicting variable names: +# SHUNIT_* and SHU_* are shunit2 variables +# test_* should only be used by test functions. +# All other variables will probably be used by pre/post/common functions. + +# shunit2 assumes _inc is, but we might run from a separate builddir. So try to +# use srcdir, as defined by automake, or otherwise `pwd`. +SHUNIT_INC="${srcdir=`pwd`}/packaging/common"; export SHUNIT_INC + +TMPDIR=`pwd`/shunit-test; export TMPDIR +amanda_user=test_amandabackup; export amanda_user +amanda_group=test_disk; export amanda_group +AMANDAHOMEDIR=$TMPDIR/amanda; export AMANDAHOMEDIR +AMANDATES=$AMANDAHOMEDIR/amandates; export AMANDATES +os=`uname`; export os +dist=Fedora; export dist +SYSCONFDIR=$TMPDIR/etc; export SYSCONFDIR +SBINDIR=$TMPDIR/sbin; export SBINDIR +# Don't potentially conflict with a real value... +deb_uid=63000; export deb_uid + + +# Append stuff to this when you make temp files if they are outside TMPDIR +test_cleanup_files="$TMPDIR"; export sh_cleanup_files + +# This can't be part of one-time setup, because TMPDIR must exist before +# shunit2 is sourced. +mkdir -p ${TMPDIR} || exit 1 +{ + LOGFILE=` + (umask 077 && mktemp "$TMPDIR/test-log.XXXX") 2> /dev/null + ` && + test -f "$LOGFILE" +} || { + LOGFILE=$TMPDIR/test-log.$$.$RANDOM + (umask 077 && touch "$LOGFILE") +} || { + echo "Unable to create log file!" + exit 1 +} +export LOGFILE + +oneTimeSetUp() { + msg_prefix="oneTimeSetUp: " + if [ "$IAmRoot" ]; then + # Delete an existing user. + echo "$msg_prefix attempting to delete an existing user." + userdel -f -r ${amanda_user} + # If the user exists, our tests will act wrong, so exit + grep "${amanda_user}" ${SYSCONFDIR}/passwd &> /dev/null || { \ + echo "$msg_prefix ${amanda_user} still exists, or no ${SYSCONFDIR}/passwd."; + exit 1; } + else + echo "Not root, cleanup skipped" + fi + # Make all directories which might be needed. + mkdir -p ${AMANDAHOMEDIR}/example + if [ ! "$IAmRoot" ]; then + mkdir -p ${SYSCONFDIR}/xinetd.d + mkdir -p ${SYSCONFDIR}/init.d + fi +} + +oneTimeTearDown() { + if [ ${__shunit_assertsFailed} -eq 0 ]; then + rm -rf $test_cleanup_files + else + echo "Check ${test_cleanup_files} for logs and error info." + fi +} + +test_cleanup_files="$LOGFILE ${test_cleanup_files}" + +# errors before the tests are run. +. ${SHUNIT_INC}/common_functions.sh +. ${SHUNIT_INC}/pre_inst_functions.sh +. ${SHUNIT_INC}/post_inst_functions.sh +. ${SHUNIT_INC}/post_rm_functions.sh + +# Use this to skip root requiring tests. +# id -u is not portable to solaris. +tester_id=`id | sed 's/gid=\([0-9]*\).*/\1/'` +if [ "$tester_id" = "0" ]; then + # Same as SHUNIT_TRUE, but we can't use that yet... + IAmRoot=0 +else + IAmRoot= +fi +# A list of flag files that must be present to avoid spurious output. +# Each mock util gets one whether it is used or not. + +# CAUTION: using real values if we are root. +if [ "$IAmRoot" ]; then + amanda_group=disk; export amanda_group + SYSCONFDIR=/etc; export SYSCONFDIR + SBINDDIR=/sbin; export SBINDDIR +fi + +# Source our mock utils. +. ${SHUNIT_INC}/mock_utils.sh +###################################### +# Common functions + +# shUnit reorders tests alphabetically. We need the logger and cleanup tests +# to run first. +test___logger() { + # Write a line to the log, test that it got there. + TEST_MSG="Test01_logger message" + LOG_LINE="`date +'%b %e %Y %T'`: ${TEST_MSG}" + # It's important for the log messages to be quoted, or funny stuff happens. + logger "${TEST_MSG}" + assertEquals "logger() return code" 0 $? + LOG_TAIL=`tail -1 ${LOGFILE}` + assertEquals "logger() did not write <${LOG_LINE}> " \ + "${LOG_LINE}" "${LOG_TAIL}" + # Leave this outside the unit test framework. if the logger is + # broken we must exit. + if [ ! `grep -c "${LOG_LINE}" ${LOGFILE}` = "1" ]; then + echo "error: logger(): Incorrect content in ${LOGFILE}: " `cat ${LOGFILE}` + exit 1 + fi +} + +test__log_output_of() { + # Use log_output_of to append to the log + TEST_MSG="Test02_log_output_of message" + log_output_of echo "${TEST_MSG}" + assertEquals "log_output_of()" 0 $? + COUNT=`grep -c "${TEST_MSG}" ${LOGFILE}` + assertEquals "log_output_of(): incorrect content in log" \ + 1 ${COUNT} + # Leave this outside the unit test framework. if the logger is + # broken we must exit. + if [ ! ${COUNT} = '1' ]; then + echo "error: log_output_of(): Incorrect content in ${LOGFILE}: " `cat ${LOGFILE}` + exit 1 + fi +} + + +# NOTE: check_xinetd and check_inetd tests end up simply duplicating the +# code of the function itself + +test_check_smf() { + logger "test_check_smf" + [ "$os" = "SunOS" ] || { startSkipping; echo "test_check_smf: skipped"; } + # Test existing service + touch ${MOCKDIR}/prexisting_service + check_smf + assertEquals "check_smf preexisting services" 0 $? + rm ${MOCKDIR}/prexisting_service + check_smf + assertEquals "check_smf no amanda service" 1 $? +} + +test_check_superserver_running() { + logger "test_check_superserver_running" + [ "$IAmRoot" ] && { startSkipping; echo "test_check_superserver_running: skipped"; } + # Test the positive cases + # running changes the output of mocked ps + touch ${MOCKDIR}/running + check_superserver_running inetd + assertEquals "check_superserver_running inetd" 0 $? + assertSame "ps args: -e" "`cat $mock_ps_flags`" + if [ `uname` = 'Darwin' ]; then + [ "$IAmRoot" ] && startSkipping + check_superserver_running launchd + assertEquals "check_superserver_running launchd" 0 $? + assertSame "ps args: aux" "`cat $mock_ps_flags`" + endSkipping + else + endSkipping + check_superserver_running launchd + assertEquals 2 $? + fi + # Test the negative case, skip if root + [ "$IAmRoot" ] && startSkipping + rm ${MOCKDIR}/running + check_superserver_running inetd + assertEquals "check_superserver_running inetd returned 0 when inetd was not running" 1 $? + assertSame "ps args: -e" "`cat $mock_ps_flags`" + check_superserver_running xinetd + assertNotEquals "check_superserver_running xinetd incorrectly returned 0" \ + 0 $? + assertSame "ps args: -e" "`cat $mock_ps_flags`" +} + +test_backup_xinetd() { + logger "test_backup_xinetd" + touch ${SYSCONFDIR}/xinetd.d/amandaserver + backup_xinetd "amandaserver" + assertEquals "backup_xinetd returns 0" 0 $? + assertTrue "[ -f ${AMANDAHOMEDIR}/example/*.amandaserver.orig ]" +} + +test_backup_inetd() { + logger "test_backup_inetd" + case $os in + SunOS) inetd_dir=${SYSCONFDIR}/inet ;; + *) inetd_dir=${SYSCONFDIR} ;; + esac + [ -d "${inetd_dir}" ] || mkdir -p ${inetd_dir} + touch ${inetd_dir}/inetd.conf + echo "amanda foo/bar/baz amandad" >> ${inetd_dir}/inetd.conf + backup_inetd + assertEquals "backup_inetd returns 0" 0 $? + assertTrue "[ -f ${AMANDAHOMEDIR}/example/inetd.orig ]" +} + +test_backup_smf() { + logger "test_backup_smf" + : + # TODO: how to mock this? +} + +test_install_xinetd() { + logger "test_install_xinetd" + if [ "$os" = "SunOS" ] ; then + # Solaris has install_xinetd_sol + startSkipping + echo "test_install_xinetd: skipped" + return + fi + # Test success: + touch ${MOCKDIR}/success + touch ${AMANDAHOMEDIR}/example/xinetd.amandaserver + install_xinetd "amandaserver" + assertEquals "install_xinetd returns 0" 0 $? + # Test "install" failure + rm ${MOCKDIR}/success + install_xinetd "amandaserver" + assertEquals "install_xinetd returns 1" 1 $? +} + +test_install_inetd() { + logger "test_install_inetd" + case $os in + SunOS) inetd_dir=${BASEDIR}/${SYSCONFDIR}/inet ;; + *) inetd_dir=${SYSCONFDIR} ;; + esac + [ -f ${inetd_dir}/inetd.conf ] || touch ${inetd_dir}/inetd.conf + test_inetd_entry='amanda foo/bar/baz amandad' + if [ ! -f ${AMANDAHOMEDIR}/example/inetd.conf ]; then + echo "${test_inetd_entry}" > ${AMANDAHOMEDIR}/example/inetd.conf.amandaserver + fi + install_inetd amandaserver + assertEquals "install_inetd returns 0" 0 $? + assertSame "${test_inetd_entry}" "`tail -1 ${inetd_dir}/inetd.conf`" +} + +# TODO: test_install_smf() { +# Needs mocks for: inetconv, inetadm, svcadm. + +test_reload_xinetd() { + logger "test_reload_xinetd" + # Might need init script. + if [ "$IAmRoot" ]; then + startSkipping + echo "test_install_smf: skipped" + return + elif [ ! -f "${SYSCONFDIR}/init.d/xinetd" ]; then + mv ${MOCKDIR}/xinetd ${SYSCONFDIR}/init.d + fi + # Test bad argument + reload_xinetd foo + assertEquals "reload_xinetd should reject argument 'foo'" 1 $? + # Test success + touch ${MOCKDIR}/success + reload_xinetd "reload" + assertEquals "reload_xinetd" 0 $? + # Test failure + rm ${MOCKDIR}/success + reload_xinetd "reload" + assertEquals "reload_xinetd" 1 $? + tail -4 ${LOGFILE}|grep "\ ${SYSCONFDIR}/passwd + echo "test_create_user: tests skipped." + #TODO: mock useradd. + return + fi + # Case 1: create_user should succeed. + create_user + assertEquals "create_user()" 0 $? +} + +good_group_entry="${amanda_group}:x:100:${amanda_user}" +export good_group_entry +test_check_user_group() { + logger "test_check_user_group" + touch ${SYSCONFDIR}/group + # Non-root adds and entry to the mock group file + [ ! "$IAmRoot" ] && echo $good_group_entry > ${SYSCONFDIR}/group + + # Case 1: Amanda_user is correct. + touch ${MOCKDIR}/is_member + check_user "group" "${amanda_group}" + assertEquals "'check_user group ${amanda_group}': id returns member" \ + 0 $? + + # Case 2: Amanda_user is not a member of the the correct group. + rm ${MOCKDIR}/is_member + check_user "group" "${amanda_group}" + assertEquals "'check_user group ${amanda_group}' when not a member" 1 $? +} + +test_check_user_shell() { + logger "test_check_user_shell" + if [ ! "$IAmRoot" ]; then + echo "$good_passwd_entry" > ${SYSCONFDIR}/passwd + fi + # Case 1: Provide a matching shell + check_user "shell" "/bin/bash" + assertEquals "check_user shell /bin/bash (matching)" 0 $? + # Case 2: Provid a non-matching shell. + check_user "shell" "/bin/sh" + assertEquals "check_user shell /bin/ksh (not matching)" 1 $? +} + +test_check_user_homedir() { + logger 'test_check_user_homedir' + if [ ! "$IAmRoot" ]; then + echo "$good_passwd_entry" > ${SYSCONFDIR}/passwd + fi + # Case 1: Assume amanda_user is correct. + check_user "homedir" "${AMANDAHOMEDIR}" + assertEquals "check_user homedir ${AMANDAHOMEDIR}" 0 $? + # Case 2: Provide an incorrect homedir + check_user "homedir" "/tmp" + assertEquals "check_user homedir /tmp" 1 $? +} + +test_check_homedir_dir_missing() { + logger "test_check_homedir_dir_missing" + # First make sure the dir is missing + rm -rf ${AMANDAHOMEDIR} + check_homedir + assertNotEquals "check_homedir returned 0, but homedir did not exist" 0 $? +} + +test_create_homedir() { + logger "test_create_homedir" + rm -rf ${AMANDAHOMEDIR} + create_homedir + assertEquals "create_homedir returns 0" 0 $? + assertTrue "${AMANDAHOMEDIR} did not get created" "[ -d ${AMANDAHOMEDIR} ]" + if [ "$IAmRoot" ]; then + # Check real owner + real_owner=`ls -ld $AMANDAHOMEDIR | awk '{ print $3":"$4; }'` + assertSame "${amanda_user}:${amanda_group}" "$real_owner" + else + assertSame \ + "chown args: -R ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}" \ + "`cat $mock_chown_flags`" + fi + # A second run should succeed too. + create_homedir + assertEquals "When homedir exists, create_homedir returns 0:" 0 $? + # Later tests use ${AMANDAHOMEDIR}, so leave the dir there. +} + +test_check_homedir_dir_existing() { + logger "test_check_homedir_dir_existing" + # Create the dir (example needed for other tests), then check again. + mkdir -p ${AMANDAHOMEDIR}/example + check_homedir + assertEquals "Homedir exists; check_homedir" 0 $? +} + +test_create_logdir() { + logger "test_create_logdir" + # The logdir variable for the shell libs, not shunit2. + LOGDIR=$TMPDIR/amanda_log; export LOGDIR + rm -rf ${LOGDIR} + rm -rf ${LOGDIR}.save + create_logdir + assertEquals "create_logdir clean system" 0 $? + if [ -n "$IAmRoot" ]; then + real_owner=`ls -ld $LOGDIR | awk '{ print $3":"$4; }'` + assertSame "${amanda_user}:${amanda_group}" "$real_owner" + else + assertSame \ + "chown args: -R ${amanda_user}:${amanda_group} ${LOGDIR}"\ + "`cat $mock_chown_flags`" + fi + assertTrue "${LOGDIR} exists" "[ -d ${LOGDIR} ]" + # What happens if logdir is a file? + rm -rf ${LOGDIR} + touch ${LOGDIR} + create_logdir + assertEquals "create_logdir" 0 $? + assertTrue "${LOGDIR} exists" "[ -d ${LOGDIR} ]" + assertTrue "${LOGDIR}/amanda_log.save backup exists" \ + "[ -f ${LOGDIR}/amanda_log.save ]" +} + +test_create_amandates() { + logger "test_create_amandates" + rm -f ${AMANDATES} + create_amandates + assertEquals "create_amandates" 0 $? + assertTrue "[ -f ${AMANDATES} ]" +} + +test_check_amandates() { + logger "test_check_amandates" + touch $mock_chown_flags + touch $mock_chmod_flags + check_amandates + assertEquals "check_amandates" 0 $? + [ "$IAmRoot" ] && { startSkipping; echo "test_check_amandates: skipped"; } + assertSame \ + "chown args: ${amanda_user}:${amanda_group} ${AMANDATES}" \ + "`cat $mock_chown_flags`" + assertSame \ + "chmod args: 0640 ${AMANDATES}" \ + "`cat $mock_chmod_flags`" +} + +test_create_gnupg() { + logger "test_create_gnupg" + create_gnupg + assertEquals "create_gnupg" 0 $? + assertTrue "[ -d ${AMANDAHOMEDIR}/.gnupg ]" +} + +test_check_gnupg() { + logger "test_check_gnupg" + check_gnupg + assertEquals "check_gnupg" 0 $? + [ "$IAmRoot" ] && { startSkipping; echo "test_check_gnupg: skipped"; } + assertSame \ + "chown args: ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}/.gnupg" \ + "`cat $mock_chown_flags`" + assertSame \ + "chmod args: 700 ${AMANDAHOMEDIR}/.gnupg" \ + "`cat $mock_chmod_flags`" +} + +test_create_amandahosts() { + logger "test_create_amandahosts" + create_amandahosts + assertEquals "create_amandahosts:" 0 $? + assertEquals "${AMANDAHOMEDIR}/.amandahosts exists:" 0 $? + assertEquals "create_amandahosts" 0 $? + assertTrue "[ -f ${AMANDAHOMEDIR}/.amandahosts ]" +} + +test_check_amandahosts_entry() { + logger "test_check_amandahosts_entry" + if [ -f ${AMANDAHOMEDIR}/.amandahosts ]; then + check_amandahosts_entry root amindexd amidxtaped + assertEquals "check_amandahosts_entry root amindexd amidxtaped" \ + 0 $? + else + echo "test_check_amandahosts_entry: ${AMANDAHOMEDIR}/.amandahosts missing. test skipped" + startSkipping + fi +} + +test_check_amandahosts_perm() { + logger "test_check_amandahosts_perm" + check_amandahosts_perms + assertEquals "check_amandahosts_perms" 0 $? + [ "$IAmRoot" ] && { startSkipping; echo "test_check_amandahosts_perm: skipped"; } + assertSame \ + "chown args: ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}/.amandahosts" \ + "`cat $mock_chown_flags`" + assertSame \ + "chmod args: 0600 ${AMANDAHOMEDIR}/.amandahosts" \ + "`cat $mock_chmod_flags`" +} + +test_create_ssh_key() { + logger "test_create_ssh_key" + keydir=${AMANDAHOMEDIR}/.ssh + rm -rf ${keydir} + create_ssh_key server + assertEquals "create_ssh_key" 0 $? + assertTrue "[ -f ${keydir}/id_rsa_amdump ]" + [ "$IAmRoot" ] && { startSkipping; echo "test_create_ssh_key: skipped"; } + assertSame \ + "chown args: ${amanda_user}:${amanda_group} ${keydir} ${keydir}/id_rsa_amdump ${keydir}/id_rsa_amdump.pub" \ + "`cat $mock_chown_flags`" + # Chmod is called twice, but we only get the 2nd invocation. + assertSame \ + "chmod args: 0600 ${keydir}/id_rsa_amdump ${keydir}/id_rsa_amdump.pub" \ + "`cat $mock_chmod_flags`" + endSkipping + + rm -rf ${keydir} + # What happens if .ssh is a file? + touch ${AMANDAHOMEDIR}/.ssh + create_ssh_key client + assertEquals "create_ssh_key" 0 $? + assertTrue "[ -f ${keydir}.save ]" + assertTrue "[ -f ${keydir}/id_rsa_amrecover ]" +} + +test_create_profile() { + logger "test_create_profile" + rm -f ${AMANDAHOMEDIR}/.profile + create_profile + assertEquals "create_profile" 0 $? + assertTrue "[ -f ${AMANDAHOMEDIR}/.profile ]" +} + +test_check_profile() { + logger "test_check_profile" + [ -f "${AMANDAHOMEDIR}/.profile" ] || touch ${AMANDAHOMEDIR}/.profile + check_profile + assertEquals "check_profile" 0 $? + assertTrue "[ -s ${AMANDAHOMEDIR}/.profile ]" + [ "$IAmRoot" ] && { startSkipping; echo "test_check_profile: skipped"; } + assertSame \ + "chown args: ${amanda_user}:${amanda_group} ${AMANDAHOMEDIR}/.profile" \ + "`cat $mock_chown_flags`" + assertSame \ + "chmod args: 0640 ${AMANDAHOMEDIR}/.profile" \ + "`cat $mock_chmod_flags`" +} + +test_install_client_conf() { + logger "test_install_client_conf" + # Test success + touch ${MOCKDIR}/success + install_client_conf + assertEquals "install_client_conf" 0 $? + prefix="install args:" + inst_files="${AMANDAHOMEDIR}/example/amanda-client.conf ${SYSCONFDIR}/amanda/" + case $os in + SunOS) assertSame \ + "`cat $mock_install_flags`" \ + "${prefix} -m 0600 -u ${amanda_user} -g ${amanda_group} ${inst_files}" + ;; + *) assertSame \ + "`cat $mock_install_flags`" \ + "${prefix} -m 0600 -o ${amanda_user} -g ${amanda_group} ${inst_files}" + esac +} + +#TODO: create_ampassphrase, create_amtmp + +###################################### +#TODO: post_rm_functions + +# Run a single test, or let shunit run all tests +if [ $# -gt 0 ]; then + echo $1 + SPECIFIC_TESTS="$*" + suite() { + __shunit_suite="test___logger" + __shunit_suite="$__shunit_suite test__log_output_of" + __shunit_suite="$__shunit_suite $SPECIFIC_TESTS" + # Set the test total including the 3 base tests. + __shunit_testsTotal=`expr 2 + $#` + suite_addTest test___logger + } +fi + +# Importing shunit2 triggers test enumeration, so must happen after +# all tests are defined. +. ${SHUNIT_INC}/shunit2 + +echo "shunit2 log is: ${LOGFILE}" +echo "mockdir is: ${MOCKDIR}" diff --git a/packaging/deb/buildpkg b/packaging/deb/buildpkg index ef93708..516d1d9 100755 --- a/packaging/deb/buildpkg +++ b/packaging/deb/buildpkg @@ -40,6 +40,9 @@ then exit 1 fi +# Until we get package revisioning in community. +[ -f "PKG_REV" ] || echo "1" > PKG_REV + #### Build functions do_substitute() { diff --git a/packaging/deb/preinst b/packaging/deb/preinst index 645a662..6180b1f 100755 --- a/packaging/deb/preinst +++ b/packaging/deb/preinst @@ -17,7 +17,7 @@ echo "`date +'%b %e %Y %T'`: Preparing to install Amanda" >${TMPFILE} # Check for the '${amanda_user}' user echo "`date +'%b %e %Y %T'`: Checking for ${amanda_user} user..." >>${TMPFILE} if [ "`id -u ${amanda_user} >/dev/null 2>&1 && echo 0 || echo 1`" != "0" ] ; then - useradd -c "Amanda" -g ${amanda_group} -d /var/lib/amanda -s /bin/sh ${amanda_user} + useradd -c "Amanda" -g ${amanda_group} -d /var/lib/amanda -s /bin/bash ${amanda_user} # Lock the ${amanda_user} account until admin sets password passwd -l ${amanda_user} >>/dev/null PASSWD_EXIT=$? @@ -66,7 +66,7 @@ else echo "`date +'%b %e %Y %T'`: please see that the following parameters are set for that" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: user.:" >>${TMPFILE} echo "`date +'%b %e %Y %T'`:" >>${TMPFILE} - echo "`date +'%b %e %Y %T'`: SHELL: /bin/sh" >>${TMPFILE} + echo "`date +'%b %e %Y %T'`: SHELL: /bin/bash" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: HOME: /var/lib/amanda" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Default group: ${amanda_group}" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Verifying ${amanda_user} user parameters :" >>${TMPFILE} diff --git a/packaging/rpm/amanda.spec.src b/packaging/rpm/amanda.spec.src index d790786..ec55de8 100644 --- a/packaging/rpm/amanda.spec.src +++ b/packaging/rpm/amanda.spec.src @@ -456,7 +456,7 @@ echo "`date +'%b %e %Y %T'`: Preparing to install: %{amanda_version_info}" >${TM # Check for the 'amanda' user echo "`date +'%b %e %Y %T'`: Checking for '%{amanda_user}' user..." >>${TMPFILE} if [ "`id -u %{amanda_user} > /dev/null 2>&1 && echo 0 || echo 1`" != "0" ] ; then - useradd -c "Amanda" -M -g %{amanda_group} -d %{AMANDAHOMEDIR} -s /bin/sh %{amanda_user} + useradd -c "Amanda" -M -g %{amanda_group} -d %{AMANDAHOMEDIR} -s /bin/bash %{amanda_user} if [ %{dist} = "SuSE" ]; then PASSWD_EXIT=$? else @@ -509,7 +509,7 @@ else echo "`date +'%b %e %Y %T'`: please see that the following parameters are set for that" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: user.:" >>${TMPFILE} echo "`date +'%b %e %Y %T'`:" >>${TMPFILE} - echo "`date +'%b %e %Y %T'`: SHELL: /bin/sh" >>${TMPFILE} + echo "`date +'%b %e %Y %T'`: SHELL: /bin/bash" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: HOME: %{AMANDAHOMEDIR}" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Default group: %{amanda_group}" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Verifying %{amanda_user} parameters :" >>${TMPFILE} @@ -523,10 +523,10 @@ else echo "`date +'%b %e %Y %T'`: Verified group name of user 'amandabackup'" >>${TMPFILE} fi - if [ "`grep ^%{amanda_user} /etc/passwd|cut -d: -f7`" != "/bin/sh" ] ; then + if [ "`grep ^%{amanda_user} /etc/passwd|cut -d: -f7`" != "/bin/bash" ] ; then echo "`date +'%b %e %Y %T'`: !!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: !!! user 'amandabackup' default shell should be set to !!!" >>${TMPFILE} - echo "`date +'%b %e %Y %T'`: !!! /bin/sh, pl correct before start using Amanda !!!" >>${TMPFILE} + echo "`date +'%b %e %Y %T'`: !!! /bin/bash, pl correct before start using Amanda !!!" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: !!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" >>${TMPFILE} else echo "`date +'%b %e %Y %T'`: Verified Default shell for user 'amandabackup'" >>${TMPFILE} @@ -821,7 +821,7 @@ echo "`date +'%b %e %Y %T'`: Preparing to install: %{amanda_version_info}" >${TM # Check for the 'amanda' user echo "`date +'%b %e %Y %T'`: Checking for '%{amanda_user}' user..." >>${TMPFILE} if [ "`id -u %{amanda_user} > /dev/null 2>&1 && echo 0 || echo 1`" != "0" ] ; then - useradd -c "Amanda" -M -g %{amanda_group} -d %{AMANDAHOMEDIR} -s /bin/sh %{amanda_user} + useradd -c "Amanda" -M -g %{amanda_group} -d %{AMANDAHOMEDIR} -s /bin/bash %{amanda_user} if [ %{dist} = "SuSE" ]; then PASSWD_EXIT=$? else @@ -874,7 +874,7 @@ else echo "`date +'%b %e %Y %T'`: please see that the following parameters are set for that" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: user.:" >>${TMPFILE} echo "`date +'%b %e %Y %T'`:" >>${TMPFILE} - echo "`date +'%b %e %Y %T'`: SHELL: /bin/sh" >>${TMPFILE} + echo "`date +'%b %e %Y %T'`: SHELL: /bin/bash" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: HOME: %{AMANDAHOMEDIR}" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Default group: %{amanda_group}" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Verifying %{amanda_user} parameters :" >>${TMPFILE} @@ -888,10 +888,10 @@ else echo "`date +'%b %e %Y %T'`: Verified group name of user 'amandabackup'" >>${TMPFILE} fi - if [ "`grep ^%{amanda_user} /etc/passwd|cut -d: -f7`" != "/bin/sh" ] ; then + if [ "`grep ^%{amanda_user} /etc/passwd|cut -d: -f7`" != "/bin/bash" ] ; then echo "`date +'%b %e %Y %T'`: !!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: !!! user 'amandabackup' default shell should be set to !!!" >>${TMPFILE} - echo "`date +'%b %e %Y %T'`: !!! /bin/sh, pl correct before start using Amanda !!!" >>${TMPFILE} + echo "`date +'%b %e %Y %T'`: !!! /bin/bash, pl correct before start using Amanda !!!" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: !!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" >>${TMPFILE} else echo "`date +'%b %e %Y %T'`: Verified Default shell for user 'amandabackup'" >>${TMPFILE} @@ -1207,7 +1207,7 @@ echo "`date +'%b %e %Y %T'`: Preparing to install: %{amanda_version_info}" >${TM # Check for the 'amanda' user echo "`date +'%b %e %Y %T'`: Checking for '%{amanda_user}' user..." >>${TMPFILE} if [ "`id -u %{amanda_user} > /dev/null 2>&1 && echo 0 || echo 1`" != "0" ] ; then - useradd -c "Amanda" -M -g %{amanda_group} -d %{AMANDAHOMEDIR} -s /bin/sh %{amanda_user} >>${TMPFILE} 2>&1 + useradd -c "Amanda" -M -g %{amanda_group} -d %{AMANDAHOMEDIR} -s /bin/bash %{amanda_user} >>${TMPFILE} 2>&1 if [ %{dist} = "SuSE" ]; then PASSWD_EXIT=$? else @@ -1260,7 +1260,7 @@ else echo "`date +'%b %e %Y %T'`: please see that the following parameters are set for that" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: user.:" >>${TMPFILE} echo "`date +'%b %e %Y %T'`:" >>${TMPFILE} - echo "`date +'%b %e %Y %T'`: SHELL: /bin/sh" >>${TMPFILE} + echo "`date +'%b %e %Y %T'`: SHELL: /bin/bash" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: HOME: %{AMANDAHOMEDIR}" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Default group: %{amanda_group}" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: Verifying %{amanda_user} parameters :" >>${TMPFILE} @@ -1274,10 +1274,10 @@ else echo "`date +'%b %e %Y %T'`: Verified group name of user 'amandabackup'" >>${TMPFILE} fi - if [ "`grep ^%{amanda_user} /etc/passwd|cut -d: -f7`" != "/bin/sh" ] ; then + if [ "`grep ^%{amanda_user} /etc/passwd|cut -d: -f7`" != "/bin/bash" ] ; then echo "`date +'%b %e %Y %T'`: !!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: !!! user 'amandabackup' default shell should be set to !!!" >>${TMPFILE} - echo "`date +'%b %e %Y %T'`: !!! /bin/sh, pl correct before start using Amanda !!!" >>${TMPFILE} + echo "`date +'%b %e %Y %T'`: !!! /bin/bash, pl correct before start using Amanda !!!" >>${TMPFILE} echo "`date +'%b %e %Y %T'`: !!! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! !!!" >>${TMPFILE} else echo "`date +'%b %e %Y %T'`: Verified Default shell for user 'amandabackup'" >>${TMPFILE} diff --git a/packaging/rpm/buildpkg b/packaging/rpm/buildpkg index 7a09a25..ef6974c 100755 --- a/packaging/rpm/buildpkg +++ b/packaging/rpm/buildpkg @@ -27,6 +27,9 @@ if [ -z $AMVER ]; then AMVER=amanda-${VER} fi +# Until we get package revisioning in community. +[ -f "PKG_REV" ] || echo "1" > PKG_REV + # Substitute amanda.spec.src /usr/bin/perl packaging/common/substitute.pl \ packaging/rpm/amanda.spec.src packaging/rpm/amanda.spec diff --git a/packaging/sun-pkg/buildpkg b/packaging/sun-pkg/buildpkg new file mode 100755 index 0000000..af5d0a3 --- /dev/null +++ b/packaging/sun-pkg/buildpkg @@ -0,0 +1,303 @@ +#!/bin/sh +# This is useful for debugging +#set -x + +#### CHECKS +if [ ! -f common-src/amanda.h ]; then + echo "Error: 'buildpkg' must be run from the root of an otherwise unused amanda source" + echo " directory." >&2 + exit 1 +fi + +if [ ! -f configure ]; then + echo "Error: The source directory has not been autogen'd -- please download a source" + echo " distribution tarball or run ./autogen. You will need autoconf, automake," + echo " and libtool to run autogen (but not to compile from a distribution tarball)." + exit 1 +fi + +# Until we get package revisioning in community. +[ -f "PKG_REV" ] || echo "1" > PKG_REV + +pkg_root=packaging/sun-pkg +get_version() { + # Get our version using substitute.pl + echo "%%VERSION%%" > ${pkg_root}/version.src + /opt/csw/bin/perl packaging/common/substitute.pl ${pkg_root}/version.src ${pkg_root}/version || exit 1 + VERSION=`cat ${pkg_root}/version` + rm ${pkg_root}/version.src ${pkg_root}/version || exit 1 +} + +do_substitution() { + file_list="client/pkginfo \ + client/preinstall \ + client/postinstall \ + client/postremove \ + server/pkginfo \ + server/preinstall \ + server/postinstall \ + server/postremove" + for file in ${file_list}; do + /opt/csw/bin/perl packaging/common/substitute.pl \ + ${pkg_root}/${file}.src \ + ${pkg_root}/${file} || exit 1 + done + chmod ug+x ${pkg_root}/*/pre* ${pkg_root}/*/post* +} + +do_build() { + # Run for each server and client package. .pkg files don't get whacked. + # $1 must be "client" or "server" + [ x"$1" = x"client" ] || [ x"$1" = x"server" ] || \ + { echo "client or server not given" && exit 1; } + rm -rf ${INSTALL_DEST} ${PKG_DEST} + mkdir ${INSTALL_DEST} ${PKG_DEST} || exit 1 + make distclean + echo "Running configure.." + CONF="$CONF \ + STAR=/opt/csw/bin/star \ + GNUTAR=/opt/csw/bin/gtar \ + --quiet \ + --with-user=amandabackup \ + --with-group=disk \ + --prefix=/${PREFIX} \ + --exec-prefix=/${PREFIX} \ + --sbindir=/${PREFIX}/sbin \ + --sysconfdir=/${ETCDIR} \ + --with-amandates=/${ETCDIR}/amandates \ + --mandir=/${PREFIX}/share/man \ + --with-amlibexecdir=/${amlibdir}/amanda \ + --with-amperldir=/${amlibdir}/amanda/perl \ + --localstatedir=/${LOCALSTATEDIR} \ + --with-amdatadir=/${AMSTATEDIR} \ + --with-gnutar-listdir=/${AMSTATEDIR}/gnutar-lists \ + --with-index-server=localhost \ + --with-tape-server=localhost \ + --with-fqdn \ + --with-bsd-security \ + --with-bsdtcp-security \ + --with-bsdudp-security \ + --with-udpportrange=800,840 \ + --with-tcpportrange=11000,11040 \ + --with-low-tcpportrange=800,840 \ + --with-ssh-security \ + --with-debugging=/${DBGDIR} \ + --with-assertions \ + --with-readline \ + --disable-installperms \ + --disable-syntax-checks \ + --disable-static" + + # PKG_CONFIG_PATH was exported, so is in the environment. + ./configure CFLAGS="${CFLAGS}" \ + CPPFLAGS="${CPPFLAGS}" \ + LDFLAGS="${LDFLAGS}" \ + GLIB_CFLAGS="${GLIB_CFLAGS}" \ + GLIB_LIBS="${GLIB_LIBS}" \ + GLIB_GENMARSHAL=glib-genmarshal \ + GOBJECT_QUERY=gobject-query \ + GLIB_MKENUMS=glib-mkenums \ + ${CONF} || exit 1 + + echo "Building.." + + # rpcgen should be run natively on solaris, linux generated XDR stubs + # are not compatible. Specially when being compiled in 64 bit mode. + # Ideally this should be part of Make. + + (cd ndmp-src;rpcgen ndmp0.x;rpcgen ndmp2.x;rpcgen ndmp3.x;rpcgen ndmp4.x; rpcgen ndmp9.x) + + make || exit 1 + make DESTDIR=${INSTALL_DEST} install || exit 1 + + # the gnulib makefiles create $amlibdir/charset.alias in hopes of "merging" + # it with a similar file from other applications. This doesn't work with + # DESTDIR, and anyway Amanda doesn't need this kind of fanciness because it + # doesn't really use gettext. So we just kill the file. See bug 10955 for + # more detail. + rm -f ${INSTALL_DEST}/${amlibdir}/charset.alias + + echo "Amanda Enterprise Edition - version ${VERSION}" > ${INSTALL_DEST}/${PREFIX}/amanda-release || exit 1 +} + +do_package() { + # First parameter is the subpkg, in all lower case. + subpkg=${1} + gnu_triplet=`/bin/sh ${src_dir}/config/config.guess` + # Some but not all solaris packages have arch-plat-os dependent depend + # files. + if [ -f ${src_dir}/${pkg_root}/${subpkg}/depend-${gnu_triplet} ]; then + # Move the arch-plat-os specific depend file to "depend" + mv ${src_dir}/${pkg_root}/${subpkg}/depend-${gnu_triplet} \ + ${src_dir}/${pkg_root}/${subpkg}/depend || exit 1 + # Delete extra depend-${gnu_triplet} files + rm ${src_dir}/${pkg_root}/${subpkg}/depend-* + fi + cp ${src_dir}/${pkg_root}/${subpkg}/* ${PKG_DEST} || exit 1 + cd ${INSTALL_DEST} || exit 1 + + # amanda does not create /etc/amanda + mkdir -p ${AMSTATEDIR} || exit 1 + mkdir -p ${ETCDIR}/amanda || exit 1 + + # Add the contents of 'pkgproto' along with all installed files to + # 'prototype'. pkgproto will generate file list for provided base + # directories including the base dir. Including base dir in the pkg should + # be avoided as the pkg installation will try to alter the base directory + # permissions and ownership per pkg settings if included. + cat "${PKG_DEST}/pkgproto" \ + >> ${PKG_DEST}/prototype || exit 1 + pkgproto $PREFIX >> ${PKG_DEST}/prototype || exit 1 + + # Using --disable-installperms creates installperms.sh, which this bit of + # perl will merge into the prototype. Note that this perl script is + # perl-5.4 compatible + cat > "${src_dir}/process_proto" <<'EOF' +# make a hash from installperms +open(INSTPERM, "<" . shift @ARGV) or die("open installperms.sh: $!"); +my %installperms = map { + my ($u, $g, $m, $fn) = ($_ =~ /^installperm "([^:"]+)(?:([^:"]+))?" "([^"]*)" "(.*)"/); + $fn =~ s{^/}{}; # pkgproto has files without the leading slash + ($fn, [ $u, $g, $m ]); +} ; +# set user/group/mode from installperms, defaulting to amandabackup:disk +open(PROTO, "<" . shift @ARGV) or die("open proto: $!"); +for my $line () { + if ($line !~ /^[df]/) { + print $line; + next; + } + my ($type, $class, $file, $mode, $user, $group) = split(/ /, $line); + # default to amandabackup:disk, without changing mode + ($user, $group) = ( "amandabackup", "disk" ); + if (exists $installperms{$file}) { + ($u, $g, $m) = @{$installperms{$file}}; + $user = $u if $u; + $group = $g if $g; + $mode = $m if $m; + } + print "$type $class $file $mode $user $group\n"; +} +EOF + + perl "${src_dir}/process_proto" \ + "${src_dir}/installperms.sh" \ + "${PKG_DEST}/prototype" \ + > "${PKG_DEST}/prototype~" || exit 1 + mv "${PKG_DEST}/prototype~" "${PKG_DEST}/prototype" + + # Look for installed files in ${INSTALL_DEST}, send package to ${PKG_DEST} + pkgmk -r ${INSTALL_DEST} -o -f ${PKG_DEST}/prototype -d ${PKG_DEST} \ + || exit 1 + # pkgtrans puts the package back in our src_dir, where I would expected + # it, and "translates" it into a .pkg file at the same time. + + pkgtrans -s ${PKG_DEST} ${src_dir}/AMANamanda-${subpkg}-${VERSION}-${gnu_triplet}.pkg<&2 + exit 1 +fi +amanda_user=amandabackup; export amanda_user +amanda_group=disk; export amanda_group +AMANDAHOMEDIR="${BASEDIR}/%%AMANDAHOMEDIR%%"; export AMANDAHOMEDIR +os=SunOS; export os +arch=%%ARCH%%; export arch +LOGDIR="${BASEDIR}/%%LOGDIR%%"; export LOGDIR +INSTALL_LOG="${LOGDIR}/install.log"; export INSTALL_LOG +SYSCONFDIR="${BASEDIR}/etc"; export SYSCONFDIR +SBINDIR="${BASEDIR}/usr/sbin"; export SBINDIR +AMTMP="/tmp/amanda" + +AMANDATES=${SYSCONFDIR}/amandates; export AMANDATES + +exit_msg="Amanda installation log can be found in '${INSTALL_LOG}'." + +# ---------- Common functions ------------ +%%COMMON_FUNCTIONS%% +%%POST_INST_FUNCTIONS%% + +# -------- End Common functions ---------- + +add_service +rel=`uname -r` +if [ "$rel" = "5.8" ]; then + check_inetd "amandaclient" + case $? in + 0) backup_inetd "amandaclient" + install_inetd "amandaclient" + ;; + 1) install_inetd "amandaclient" ;; + 2) logger "Error: Amanda service not installed because inetd config was not found: either inetd config is not present or inetd is a directory." ;; + esac + # Amanda clients should not have the server xinetd installed. + check_inetd "amandaserver" + case $? in + 0) backup_inetd "amandaserver" ;; + esac + reload_inetd +else + # Solaris 10+ uses smf, but we can't differentiate server from client, all + # entries end up named "amanda" + case check_smf "amanda" + 0) backup_smf || logger "Warning: Backup of existing service failed. continuing..." + install_smf "amandaclient" || \ + logger "Warning: Amanda service not installed." + ;; + 1) install_smf "amandaclient" ;; + esac +fi + +create_amandates +check_amandates +create_gnupg +check_gnupg +create_amandahosts +check_amandahosts_entry ${amanda_user} amdump +check_amandahosts_perms +create_ssh_key client +create_profile +check_profile +install_client_conf +create_amtmp + +logger "Amanda installation complete." +cat $LOGFILE >> $INSTALL_LOG +rm $LOGFILE + +echo "${exit_msg}" diff --git a/packaging/sun-pkg/client/postremove.src b/packaging/sun-pkg/client/postremove.src new file mode 100755 index 0000000..287d939 --- /dev/null +++ b/packaging/sun-pkg/client/postremove.src @@ -0,0 +1,48 @@ +#!/bin/sh + +LOGFILE=`mktemp /tmp/amanda-client-rm-log.XXXXXXXXXXX` +if [ $? -ne 0 ]; then + echo "Unable to create log file!" + exit 1 +fi +amanda_user=amandabackup +amanda_group=disk +AMANDAHOMEDIR=%%AMANDAHOMEDIR%% +os=SunOS +dist=%%DISTRO%% + +LOGDIR=%%LOGDIR%% +REMOVE_LOG="/tmp/amanda-remove.log" +SYSCONFDIR=/etc + +# ---------- Common functions ------------ +# see packaging/common/ in the source tree +%%COMMON_FUNCTIONS%% +%%POST_RM_FUNCTIONS%% + +# -------- End Common functions ---------- + +rel=`uname -r` + +case $rel in + 5.8|5.9) + if check_inetd "amanda"; then + rm_inetd "amanda" || { \ + logger "Warning: Did not successfully remove $net_svc_name from SMF."; + exit 1; } + reload_inetd + fi + ;; + 5.10) + if check_smf "amanda"; then + rm_smf "amanda" || { \ + logger "Warning: Did not successfully remove $net_svc_name from SMF."; + exit 1; } + fi + ;; +esac + +logger "Amanda Client removed." + +cat $LOGFILE >> $REMOVE_LOG +rm $LOGFILE diff --git a/packaging/sun-pkg/client/preinstall.src b/packaging/sun-pkg/client/preinstall.src new file mode 100755 index 0000000..28228b0 --- /dev/null +++ b/packaging/sun-pkg/client/preinstall.src @@ -0,0 +1,41 @@ +#!/usr/bin/sh +PATH=/usr/bin:/usr/local/bin:/usr/sbin:/opt/csw/bin +export PATH + +LOGFILE=`mktemp /tmp/amanda-client-install.XXXXXXXXXXX` +if [ $? -ne 0 ]; then + echo "Unable to mktemp!" 1>&2 + exit 1 +fi +export LOGFILE +amanda_user=amandabackup; export amanda_user +amanda_group=disk; export amanda_group +# BASEDIR is set by either in pkginfo, or if not set, by pkgadd at installtime. +AMANDAHOMEDIR="${BASEDIR}/%%AMANDAHOMEDIR%%"; export AMANDAHOMEDIR +os=`uname`; export os +dist=%%DISTRO%%; export dist +LOGDIR="/var/log/amanda"; export LOGDIR +SYSCONFDIR=/etc; export SYSCONFDIR + +# See packaging/common/ for shell function libraries. +# ---------- Common functions ------------ +%%COMMON_FUNCTIONS%% +%%PRE_INST_FUNCTIONS%% + +# -------- End Common functions ---------- +logger "Preparing to install: Amanda Client %%VERSION%%" +create_user +if ! check_user "group" "${amanda_group}" ; then + add_group "${amanda_group}" +fi +if ! check_user "group" "tape" ; then + add_group "tape" +fi +check_user "shell" "/usr/bin/bash" +check_user "homedir" "${AMANDAHOMEDIR}" +if ! check_homedir ; then + create_homedir +fi +create_logdir + +logger "Preinstall done." diff --git a/packaging/sun-pkg/server/copyright b/packaging/sun-pkg/server/copyright new file mode 100644 index 0000000..cea671e --- /dev/null +++ b/packaging/sun-pkg/server/copyright @@ -0,0 +1,25 @@ +/* + * Amanda, The Advanced Maryland Automatic Network Disk Archiver + * Copyright (c) 1991-1998 University of Maryland at College Park + * All Rights Reserved. + * + * Permission to use, copy, modify, distribute, and sell this software and its + * documentation for any purpose is hereby granted without fee, provided that + * the above copyright notice appear in all copies and that both that + * copyright notice and this permission notice appear in supporting + * documentation, and that the name of U.M. not be used in advertising or + * publicity pertaining to distribution of the software without specific, + * written prior permission. U.M. makes no representations about the + * suitability of this software for any purpose. It is provided "as is" + * without express or implied warranty. + * + * U.M. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL U.M. + * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION + * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN + * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + * + * Authors: the Amanda Development Team. Its members are listed in a + * file named AUTHORS, in the root directory of this distribution. + */ diff --git a/packaging/sun-pkg/server/depend b/packaging/sun-pkg/server/depend new file mode 100644 index 0000000..5a23f14 --- /dev/null +++ b/packaging/sun-pkg/server/depend @@ -0,0 +1,14 @@ +P SUNWcsu Core Solaris +P SUNWbash GNU Bourne-again shell (bash) +P SUNWsshcu SSH Common +P SUNWscpu Source Compatibility +P SUNWgzip GNU Zip +P CSWgtar gnutar +P SUNWgnome-base-libs GNOME base GUI libraries +P CSWperl perl - A high-level, general-purpose programming language. +P CSWlibcurl4 libcurl +P SUNWflexruntime Lex Runtime Libraries +I AmandaEnterpriseBackupClient Amanda Enterprise Backup Client from Zmanda +I AmandaEnterpriseBackupServer Amanda Enterprise Backup Server from Zmanda +I ZMANae-client Amanda Enterprise Backup Client from Zmanda +I ZMANae-server Amanda Enterprise Backup Server from Zmanda diff --git a/packaging/sun-pkg/server/pkginfo.src b/packaging/sun-pkg/server/pkginfo.src new file mode 100644 index 0000000..4df1aa3 --- /dev/null +++ b/packaging/sun-pkg/server/pkginfo.src @@ -0,0 +1,19 @@ +PKG="AMANamanda-server" +ARCH="%%ARCH%%" +VERSION="%%VERSION%%-%%PKG_REV%%" +CATEGORY="system" +VENDOR="Amanda Project, http://www.amanda.org/" +EMAIL="support@zmanda.com" +BASEDIR="/" +CLASSES="none" +MAXINST=1 +INTONLY=1 +NAME="Amanda Community Backup Server" +DESC="Amanda is the leading Open-Source Backup and Archiving software. + +This package contains the Amanda client and server. The Amanda server package +needs to be installed on every server system. + +Documentation: http://wiki.zmanda.com/ +Mailing Lists: http://www.amanda.org/support/mailinglists.php +Forums: http://forums.zmanda.com/ diff --git a/packaging/sun-pkg/server/pkgproto b/packaging/sun-pkg/server/pkgproto new file mode 100644 index 0000000..c8019f4 --- /dev/null +++ b/packaging/sun-pkg/server/pkgproto @@ -0,0 +1,6 @@ +i pkginfo=./pkginfo +i depend=./depend +i preinstall=./preinstall +i postinstall=./postinstall +i postrm=./postremove +i copyright=./copyright diff --git a/packaging/sun-pkg/server/postinstall.src b/packaging/sun-pkg/server/postinstall.src new file mode 100755 index 0000000..c4ab56e --- /dev/null +++ b/packaging/sun-pkg/server/postinstall.src @@ -0,0 +1,75 @@ +#!/bin/sh + +LOGFILE=`mktemp /tmp/deb-log-amanda_enterprise-client.XXXXXXXXXXX` +if [ $? -ne 0 ]; then + echo "Unable to mktemp!" 1>&2 + exit 1 +fi +amanda_user=amandabackup; export amanda_user +amanda_group=disk; export amanda_group +AMANDAHOMEDIR="${BASEDIR}/%%AMANDAHOMEDIR%%"; export AMANDAHOMEDIR +os=SunOS; export os +arch=%%ARCH%%; export arch +LOGDIR="${BASEDIR}/%%LOGDIR%%"; export LOGDIR +INSTALL_LOG="${LOGDIR}/install.log"; export INSTALL_LOG +SYSCONFDIR="${BASEDIR}/etc"; export SYSCONFDIR +SBINDIR="${BASEDIR}/usr/sbin"; export SBINDIR +AMTMP="/tmp/amanda" + +AMANDATES=${SYSCONFDIR}/amandates; export AMANDATES + +exit_msg="Amanda installation log can be found in '${INSTALL_LOG}'." + +# ---------- Common functions ------------ +%%COMMON_FUNCTIONS%% +%%POST_INST_FUNCTIONS%% + +# -------- End Common functions ---------- + +add_service +rel=`uname -r` +if [ "$rel" = "5.8" ]; then + check_inetd "amandaserver" + case $? in + 0) backup_inetd "amandaserver" + install_inetd "amandaserver" + ;; + 1) install_inetd "amandaserver" ;; + 2) logger "Error: Amanda service not installed because inetd config was not found: either inetd config is not present or inetd is a directory." ;; + esac + # Amanda clients should not have the server xinetd installed. + check_inetd "amandaclient" + case $? in + 0) backup_inetd "amandaclient" ;; + esac + reload_inetd +else + # Solaris 10+ uses smf, but we can't differentiate server from client, all + # entries end up named "amanda" + case check_smf "amanda" + 0) backup_smf || logger "Warning: Backup of existing service failed. continuing..." + install_smf "amandaserver" || \ + logger "Warning: Amanda service not installed." + ;; + 1) install_smf "amandaserver" ;; + esac +fi + +create_amandates +check_amandates +create_gnupg +check_gnupg +create_amandahosts +check_amandahosts_entry ${amanda_user} amdump +check_amandahosts_perms +create_ssh_key client +create_profile +check_profile +install_client_conf +create_amtmp + +logger "Amanda installation complete." +cat $LOGFILE >> $INSTALL_LOG +rm $LOGFILE + +echo "${exit_msg}" diff --git a/packaging/sun-pkg/server/postremove.src b/packaging/sun-pkg/server/postremove.src new file mode 100755 index 0000000..e0184ac --- /dev/null +++ b/packaging/sun-pkg/server/postremove.src @@ -0,0 +1,48 @@ +#!/bin/sh + +LOGFILE=`mktemp /tmp/amanda-server-rm-log.XXXXXXXXXXX` +if [ $? -ne 0 ]; then + echo "Unable to create log file!" + exit 1 +fi +amanda_user=amandabackup +amanda_group=disk +AMANDAHOMEDIR=%%AMANDAHOMEDIR%% +os=SunOS +dist=%%DISTRO%% + +LOGDIR=%%LOGDIR%% +REMOVE_LOG="/tmp/amanda-remove.log" +SYSCONFDIR=/etc + +# ---------- Common functions ------------ +# see packaging/common/ in the source tree +%%COMMON_FUNCTIONS%% +%%POST_RM_FUNCTIONS%% + +# -------- End Common functions ---------- + +rel=`uname -r` + +case $rel in + 5.8|5.9) + if check_inetd "amanda"; then + rm_inetd "amanda" || { \ + logger "Warning: Did not successfully remove $net_svc_name from SMF."; + exit 1; } + reload_inetd + fi + ;; + 5.10) + if check_smf "amanda"; then + rm_smf "amanda" || { \ + logger "Warning: Did not successfully remove $net_svc_name from SMF."; + exit 1; } + fi + ;; +esac + +logger "Amanda Server removed." + +cat $LOGFILE >> $REMOVE_LOG +rm $LOGFILE diff --git a/packaging/sun-pkg/server/preinstall.src b/packaging/sun-pkg/server/preinstall.src new file mode 100755 index 0000000..b986e4e --- /dev/null +++ b/packaging/sun-pkg/server/preinstall.src @@ -0,0 +1,41 @@ +#!/usr/bin/sh +PATH=/usr/bin:/usr/local/bin:/usr/sbin:/opt/csw/bin +export PATH + +LOGFILE=`mktemp /tmp/amanda-server-install.XXXXXXXXXXX` +if [ $? -ne 0 ]; then + echo "Unable to mktemp!" 1>&2 + exit 1 +fi +export LOGFILE +amanda_user=amandabackup; export amanda_user +amanda_group=disk; export amanda_group +# BASEDIR is set by either in pkginfo, or if not set, by pkgadd at installtime. +AMANDAHOMEDIR="${BASEDIR}/%%AMANDAHOMEDIR%%"; export AMANDAHOMEDIR +os=`uname`; export os +dist=%%DISTRO%%; export dist +LOGDIR="${BASEDIR}/%%LOGDIR%%"; export LOGDIR +SYSCONFDIR="${BASEDIR}/%%SYSCONFDIR%%"; export SYSCONFDIR + +# See packaging/common/ for shell function libraries. +# ---------- Common functions ------------ +%%COMMON_FUNCTIONS%% +%%PRE_INST_FUNCTIONS%% + +# -------- End Common functions ---------- +logger "Preparing to install: Amanda Server %%VERSION%%" +create_user +if ! check_user "group" "${amanda_group}" ; then + add_group "${amanda_group}" +fi +if ! check_user "group" "tape" ; then + add_group "tape" +fi +check_user "shell" "/usr/bin/bash" +check_user "homedir" "${AMANDAHOMEDIR}" +if ! check_homedir ; then + create_homedir +fi +create_logdir + +logger "Preinstall done." diff --git a/perl/Amanda/Application.c b/perl/Amanda/Application.c index c2d6a1d..605ac6e 100644 --- a/perl/Amanda/Application.c +++ b/perl/Amanda/Application.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1495,7 +1524,7 @@ static swig_module_info swig_module = {swig_types, 6, 0, 0, 0, 0}; #define SWIG_name "Amanda::Applicationc::boot_Amanda__Application" #define SWIG_prefix "Amanda::Applicationc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION diff --git a/perl/Amanda/Application.pm b/perl/Amanda/Application.pm index 657f6ac..a0b22be 100644 --- a/perl/Amanda/Application.pm +++ b/perl/Amanda/Application.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Archive.c b/perl/Amanda/Archive.c index a77cc17..3fbfc23 100644 --- a/perl/Amanda/Archive.c +++ b/perl/Amanda/Archive.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1500,7 +1529,7 @@ static swig_module_info swig_module = {swig_types, 11, 0, 0, 0, 0}; #define SWIG_name "Amanda::Archivec::boot_Amanda__Archive" #define SWIG_prefix "Amanda::Archivec::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -2039,7 +2068,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; diff --git a/perl/Amanda/Archive.pm b/perl/Amanda/Archive.pm index f10079b..b992591 100644 --- a/perl/Amanda/Archive.pm +++ b/perl/Amanda/Archive.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Changer.pm b/perl/Amanda/Changer.pm index 2a80135..ddb7f66 100644 --- a/perl/Amanda/Changer.pm +++ b/perl/Amanda/Changer.pm @@ -385,6 +385,7 @@ Each slot is represented by a hash with the following keys: =head3 make_new_tape_label $chg->make_new_tape_label(barcode => $barcode, + slot => $slot, meta => $meta); To devise a new name for a volume using the C and C arguments. @@ -1087,7 +1088,7 @@ sub make_error { $self->{'fatal_error'} = $err if ($err->fatal); - $cb->($err); + $cb->($err) if $cb; } return $err; @@ -1256,6 +1257,7 @@ sub make_new_tape_label { return undef if !defined $self->{'labelstr'}; my $template = $self->{'autolabel'}->{'template'}; my $labelstr = $self->{'labelstr'}; + my $slot_digit = 1; if (!$template) { return (undef, "template is not set, you must set autolabel"); @@ -1265,12 +1267,19 @@ sub make_new_tape_label { $template =~ s/\$m/SUBSTITUTE_META/g; $template =~ s/\$o/SUBSTITUTE_ORG/g; $template =~ s/\$c/SUBSTITUTE_CONFIG/g; + if ($template =~ /\$([0-9]*)s/) { + $slot_digit = $1; + $slot_digit = 1 if $slot_digit < 1; + $template =~ s/\$[0-9]*s/SUBSTITUTE_SLOT/g; + } my $org = getconf($CNF_ORG); my $config = Amanda::Config::get_config_name(); my $barcode = $params{'barcode'}; $barcode = '' if !defined $barcode; my $meta = $params{'meta'}; + my $slot = $params{'slot'}; + $slot = '' if !defined $slot; $meta = $self->make_new_meta_label(%params) if !defined $meta; $meta = '' if !defined $meta; @@ -1278,24 +1287,28 @@ sub make_new_tape_label { $template =~ s/SUBSTITUTE_ORG/$org/g; $template =~ s/SUBSTITUTE_CONFIG/$config/g; $template =~ s/SUBSTITUTE_META/$meta/g; - # Do not susbtitute the barcode now + # Do not susbtitute the barcode and slot now (my $npercents = $template) =~ s/[^%]*(%+)[^%]*/length($1)/e; - my $nlabels = 10 ** $npercents; + $npercents = 0 if $npercents eq $template; my $label; if ($npercents == 0) { - if ($template =~ /SUBSTITUTE_BARCODE/ && defined $barcode) { - $label = $template; - $label =~ s/SUBSTITUTE_BARCODE/$barcode/g; - if ($tl->lookup_tapelabel($label)) { - return (undef, "Label '$label' already exists"); - } - } elsif ($template =~ /SUBSTITUTE_BARCODE/ && !defined $barcode) { - return (undef, "Can't generate new label because volume have no barcode"); - } else { + $label = $template; + $label =~ s/SUBSTITUTE_BARCODE/$barcode/g; + if ($template =~ /SUBSTITUTE_SLOT/) { + my $slot_label = sprintf("%0*d", $slot_digit, $slot); + $label =~ s/SUBSTITUTE_SLOT/$slot_label/g; + } + if ($template =~ /SUBSTITUTE_BARCODE/ && !defined $barcode) { + return (undef, "Can't generate new label because volume has no barcode"); + } elsif ($template =~ /SUBSTITUTE_SLOT/ && !defined $slot) { + return (undef, "Can't generate new label because volume has no slot"); + } elsif ($label eq $template) { return (undef, "autolabel require at least one '%'"); + } elsif ($tl->lookup_tapelabel($label)) { + return (undef, "Label '$label' already exists"); } } else { # make up a sprintf pattern @@ -1314,14 +1327,19 @@ sub make_new_tape_label { } } + my $nlabels = 10 ** $npercents; my ($i); for ($i = 1; $i < $nlabels; $i++) { $label = sprintf($sprintf_pat, $i); last unless (exists $existing_labels{$label}); } - # susbtitute the barcode + # susbtitute the barcode and slot $label =~ s/SUBSTITUTE_BARCODE/$barcode/g; + if ($template =~ /SUBSTITUTE_SLOT/) { + my $slot_label = sprintf("%0*d", $slot_digit, $slot); + $label =~ s/SUBSTITUTE_SLOT/$slot_label/g; + } # bail out if we didn't find an unused label return (undef, "Can't label unlabeled volume: All label used") @@ -1366,6 +1384,7 @@ sub make_new_meta_label { (my $npercents = $template) =~ s/[^%]*(%+)[^%]*/length($1)/e; + $npercents = 0 if $npercents eq $template; my $nlabels = 10 ** $npercents; # make up a sprintf pattern @@ -1401,9 +1420,11 @@ sub volume_is_labelable { if (!defined $dev_status) { return 0; } elsif ($dev_status & $DEVICE_STATUS_VOLUME_UNLABELED and - $f_type == $Amanda::Header::F_EMPTY) { + defined $f_type and + $f_type == $Amanda::Header::F_EMPTY) { return 0 if (!$autolabel->{'empty'}); } elsif ($dev_status & $DEVICE_STATUS_VOLUME_UNLABELED and + defined $f_type and $f_type == $Amanda::Header::F_WEIRD) { return 0 if (!$autolabel->{'non_amanda'}); } elsif ($dev_status & $DEVICE_STATUS_VOLUME_ERROR) { @@ -1527,7 +1548,10 @@ sub release { my $self = shift; my %params = @_; - return if $self->{'released'}; + if ($self->{'released'}) { + $params{'finished_cb'}->(undef) if exists $params{'finished_cb'}; + return; + } # always finish the device on release; it's illegal for anything # else to use the device after this point, anyway, so we want to @@ -1579,6 +1603,7 @@ sub make_new_tape_label { $params{'barcode'} = $self->{'barcode'} if !defined $params{'barcode'}; $params{'meta'} = $self->{'meta'} if !defined $params{'meta'}; + $params{'slot'} = $self->{'this_slot'} if !defined $params{'slot'}; return $self->{'chg'}->make_new_tape_label(%params); } @@ -1592,7 +1617,7 @@ sub make_new_meta_label { package Amanda::Changer::Config; use Amanda::Config qw( :getconf string_to_boolean ); -use Amanda::Device; +use Amanda::Device qw( :constants ); sub new { my $class = shift; @@ -1653,7 +1678,12 @@ sub configure_device { while (my ($propname, $propinfo) = each(%properties)) { for my $value (@{$propinfo->{'values'}}) { if (!$device->property_set($propname, $value)) { - my $msg = "Error setting '$propname' on device '".$device->device_name."'"; + my $msg; + if ($device->status == $DEVICE_STATUS_SUCCESS) { + $msg = "Error setting '$propname' on device '".$device->device_name."'"; + } else { + $msg = $device->error() . " on device '".$device->device_name."'"; + } if (exists $propinfo->{'optional'}) { if ($propinfo->{'optional'} eq 'warn') { warn("$msg (ignored)"); diff --git a/perl/Amanda/Changer/compat.pm b/perl/Amanda/Changer/compat.pm index c57417b..fccc226 100644 --- a/perl/Amanda/Changer/compat.pm +++ b/perl/Amanda/Changer/compat.pm @@ -689,6 +689,11 @@ sub set_label { return; } + if (!defined $params{'label'}) { + $params{'finished_cb'}->(undef) if $params{'finished_cb'}; + return; + } + my $run_cb = sub { my ($exitval, $slot, $rest) = @_; if ($exitval == 0) { diff --git a/perl/Amanda/Changer/disk.pm b/perl/Amanda/Changer/disk.pm index 5b5b3b9..8172791 100644 --- a/perl/Amanda/Changer/disk.pm +++ b/perl/Amanda/Changer/disk.pm @@ -267,6 +267,8 @@ sub with_disk_locked_state { }; step locked => sub { + my $err = shift; + return $cb->($err) if $err; $self->with_locked_state($self->{'state_filename'}, sub { my @args = @_; $self->try_unlock(); @@ -595,9 +597,8 @@ sub _validate() { my $dir = $self->{'dir'}; unless (-d $dir) { - $self->{'fatal_error'} = Amanda::Changer->make_error("fatal", undef, + return $self->make_error("fatal", undef, message => "directory '$dir' does not exist"); - return; } if ($self->{'removable'}) { @@ -611,9 +612,9 @@ sub _validate() { } } if ($dev == $pdev) { - $self->{'fatal_error'} = Amanda::Changer->make_error("fatal", undef, + return $self->make_error("failed", undef, + reason => "notfound", message => "No removable disk mounted on '$dir'"); - return; } } @@ -623,24 +624,22 @@ sub _validate() { if (!-e $slot_dir) { if ($self->{'auto-create-slot'}) { if (!mkdir ($slot_dir)) { - $self->{'fatal_error'} = Amanda::Changer->make_error("fatal", undef, + return $self->make_error("fatal", undef, message => "Can't create '$slot_dir': $!"); - return; } } else { - $self->{'fatal_error'} = Amanda::Changer->make_error("fatal", undef, + return $self->make_error("fatal", undef, message => "slot $i doesn't exists '$slot_dir'"); - return; } } } } else { if ($self->{'auto-create-slot'}) { - $self->{'fatal_error'} = Amanda::Changer->make_error("fatal", undef, + return $self->make_error("fatal", undef, message => "property 'auto-create-slot' set but property 'num-slot' is not set"); - return; } } + return undef; } sub try_lock { @@ -656,7 +655,7 @@ sub try_lock { !$self->{'fl'}->locked()) { return $steps->{'lock'}->(); } - $steps->{'done'}->(); + $steps->{'lock_done'}->(); }; step lock => sub { @@ -673,15 +672,14 @@ sub try_lock { $self->{'umount_src'}->remove(); $self->{'umount_src'} = undef; } - return $steps->{'done'}->(); + return $steps->{'lock_done'}->(); } }; - step done => sub { - $self->_validate(); - $cb->(); + step lock_done => sub { + my $err = $self->_validate(); + $cb->($err); }; - } sub try_umount { diff --git a/perl/Amanda/Changer/multi.pm b/perl/Amanda/Changer/multi.pm index 53921e6..9324a54 100644 --- a/perl/Amanda/Changer/multi.pm +++ b/perl/Amanda/Changer/multi.pm @@ -56,6 +56,7 @@ See the amanda-changers(7) manpage for usage information. # pid - the pid that reserved that slot. # state - SLOT_FULL/SLOT_EMPTY/SLOT_UNKNOWN # device_status - the status of the device after the open or read_label +# device_error - error message from the device # f_type - the F_TYPE of the fileheader. # label - the label, if known, of the volume in this slot @@ -110,6 +111,7 @@ sub new { } my $state_filename = Amanda::Config::config_dir_relative($config->{'changerfile'}); + Amanda::Debug::debug("Using state file: $state_filename"); my $self = { slots => \@slots, @@ -362,10 +364,14 @@ sub update { my $slot = $res->{'this_slot'}; my $dev = $res->{device}; - $dev->read_label(); - my $label = $dev->volume_label; $self->_update_slot_state(state => $state, dev => $dev, slot =>$slot); - $user_msg_fn->("recording volume '$label' in slot $slot"); + if ($dev->status() == $DEVICE_STATUS_SUCCESS) { + my $label = $dev->volume_label; + $user_msg_fn->("recording volume '$label' in slot $slot"); + } else { + my $status = $dev->error_or_status; + $user_msg_fn->("recording device error '" . $status . "' in slot $slot"); + } $res->release( finished_cb => $steps->{'released'}, unlocked => 1, @@ -407,10 +413,17 @@ sub inventory { if (defined $state->{slots}->{$unaliased}) { $s->{'device_status'} = $state->{slots}->{$unaliased}->{device_status}; + if ($s->{'device_status'} != $DEVICE_STATUS_SUCCESS) { + $s->{'device_error'} = + $state->{slots}->{$unaliased}->{device_error}; + } else { + $s->{'device_error'} = undef; + } $s->{'f_type'} = $state->{slots}->{$unaliased}->{f_type}; $s->{'label'} = $state->{slots}->{$unaliased}->{label}; } else { $s->{'device_status'} = undef; + $s->{'device_error'} = undef; $s->{'f_type'} = undef; $s->{'label'} = undef; } @@ -552,6 +565,11 @@ sub _update_slot_state { my $slot = $params{slot}; my $unaliased = $self->{unaliased}->{$slot}; $state->{slots}->{$unaliased}->{device_status} = "".scalar($dev->status); + if ($dev->status != $DEVICE_STATUS_SUCCESS) { + $state->{slots}->{$unaliased}->{device_error} = $dev->error; + } else { + $state->{slots}->{$unaliased}->{device_error} = undef; + } my $label = $dev->volume_label; $state->{slots}->{$unaliased}->{state} = Amanda::Changer::SLOT_FULL; $state->{slots}->{$unaliased}->{label} = $label; @@ -647,12 +665,23 @@ sub set_label { my $label = $params{'label'}; my $slot = $self->{'this_slot'}; my $unaliased = $chg->{unaliased}->{$slot}; + my $dev = $self->{'device'}; $state->{slots}->{$unaliased}->{label} = $label; $state->{slots}->{$unaliased}->{device_status} = - "".$DEVICE_STATUS_SUCCESS; - $state->{slots}->{$unaliased}->{f_type} = - "".scalar($Amanda::Header::F_TAPESTART); + "".$dev->status; + if ($dev->status != $DEVICE_STATUS_SUCCESS) { + $state->{slots}->{$unaliased}->{device_error} = $dev->error; + } else { + $state->{slots}->{$unaliased}->{device_error} = undef; + } + my $volume_header = $dev->volume_header; + if (defined $volume_header) { + $state->{slots}->{$unaliased}->{f_type} = + "".$volume_header->{type}; + } else { + $state->{slots}->{$unaliased}->{f_type} = undef; + } $finished_cb->(); }); } @@ -665,6 +694,10 @@ sub do_release { # then never mind return unless $self->{'chg'}; + $self->{'device'}->eject() if (exists $self->{'device'} and + exists $params{'eject'} and + $params{'eject'}); + # unref the device, for good measure $self->{'device'} = undef; diff --git a/perl/Amanda/Changer/robot.pm b/perl/Amanda/Changer/robot.pm index aa53f98..d13e342 100644 --- a/perl/Amanda/Changer/robot.pm +++ b/perl/Amanda/Changer/robot.pm @@ -68,6 +68,7 @@ See the amanda-changers(7) manpage for usage information. # as values. Each slot's hash has keys # state - SLOT_FULL/SLOT_EMPTY/SLOT_UNKNOWN # device_status - the status of the device +# device_error - the error message of the device # f_type - The f_type of the header # label - volume label, if known # barcode - volume barcode, if available @@ -266,7 +267,7 @@ sub new { } # status-interval, eject-delay, unload-delay - for my $propname qw(status-interval eject-delay unload-delay) { + for my $propname (qw(status-interval eject-delay unload-delay)) { next unless exists $config->{'properties'}->{$propname}; if (@{$config->{'properties'}->{$propname}->{'values'}} > 1) { return Amanda::Changer->make_error("fatal", undef, @@ -617,9 +618,7 @@ sub load_unlocked { } elsif ($device->status & $DEVICE_STATUS_VOLUME_UNLABELED) { $label = undef; } else { - return $self->make_error("fatal", $params{'res_cb'}, - message => "while waiting for '$device_name' to become ready: " - . $device->error_or_status()); + $label = undef; } # success! @@ -637,6 +636,7 @@ sub load_unlocked { # update metadata with this new information $state->{'slots'}->{$slot}->{'state'} = Amanda::Changer::SLOT_FULL; $state->{'slots'}->{$slot}->{'device_status'} = $device->status; + $state->{'slots'}->{$slot}->{'device_error'} = $device->error; if (defined $device->{'volume_header'}) { $state->{'slots'}->{$slot}->{'f_type'} = $device->{'volume_header'}->{type}; } else { @@ -659,6 +659,7 @@ sub load_unlocked { # update metadata with this new information $state->{'slots'}->{$slot}->{'state'} = Amanda::Changer::SLOT_FULL; $state->{'slots'}->{$slot}->{'device_status'} = $device->status; + $state->{'slots'}->{$slot}->{'device_error'} = $device->error; if (defined $device->{'volume_header'}) { $state->{'slots'}->{$slot}->{'f_type'} = $device->{'volume_header'}->{type}; } else { @@ -687,7 +688,7 @@ sub load_unlocked { $state->{'drives'}->{$drive}->{'label'} = $label; $state->{'drives'}->{$drive}->{'state'} = Amanda::Changer::SLOT_FULL; $state->{'drives'}->{$drive}->{'barcode'} = $state->{'slots'}->{$slot}->{'barcode'}; - #$state->{'slots'}->{$slot}->{'device_status'} = 9; + $state->{'slots'}->{$slot}->{'device_status'} = $device->status; if ($label and $state->{'slots'}->{$slot}->{'barcode'}) { $state->{'bc2lb'}->{$state->{'slots'}->{$slot}->{'barcode'}} = $label; } @@ -828,9 +829,13 @@ sub _set_label_unlocked { $state->{'drives'}->{$drive}->{'label'} = $label; if (defined $slot) { - delete $state->{'slots'}->{$slot}->{'unkknown_state'}; $state->{'slots'}->{$slot}->{'state'} = Amanda::Changer::SLOT_FULL; $state->{'slots'}->{$slot}->{'device_status'} = "".$dev->status; + if ($dev->status != $DEVICE_STATUS_SUCCESS) { + $state->{'slots'}->{$slot}->{'device_error'} = $dev->error; + } else { + $state->{'slots'}->{$slot}->{'device_error'} = undef; + } my $volume_header = $dev->volume_header; if (defined $volume_header) { $state->{'slots'}->{$slot}->{'f_type'} = "".$volume_header->{type}; @@ -1090,6 +1095,7 @@ sub update_unlocked { while (my ($sl, $inf) = each %{$state->{'slots'}}) { if ($inf->{'label'} and $inf->{'label'} eq $label) { delete $inf->{'device_status'}; + delete $inf->{'device_error'}; delete $inf->{'f_type'}; delete $inf->{'label'}; } @@ -1152,6 +1158,7 @@ sub update_unlocked { if (!defined $state->{'slots'}->{$slot}->{'barcode'}) { $state->{'slots'}->{$slot}->{'label'} = undef; $state->{'slots'}->{$slot}->{'device_status'} = undef; + $state->{'slots'}->{$slot}->{'device_error'} = undef; $state->{'slots'}->{$slot}->{'f_type'} = undef; if (defined $state->{'slots'}->{$slot}->{'loaded_in'}) { my $drive = $state->{'slots'}->{$slot}->{'loaded_in'}; @@ -1230,6 +1237,7 @@ sub inventory_unlocked { $i->{'slot'} = $slot_name; $i->{'state'} = $slot->{'state'}; $i->{'device_status'} = $slot->{'device_status'}; + $i->{'device_error'} = $slot->{'device_error'}; $i->{'f_type'} = $slot->{'f_type'}; $i->{'label'} = $slot->{'label'}; $i->{'barcode'} = $slot->{'barcode'} @@ -1526,6 +1534,7 @@ sub _with_updated_state { $new_slots->{$slot} = { state => Amanda::Changer::SLOT_EMPTY, device_status => undef, + device_error => undef, f_type => undef, label => undef, barcode => undef, @@ -1542,6 +1551,7 @@ sub _with_updated_state { $new_slots->{$slot} = { state => Amanda::Changer::SLOT_FULL, device_status => $state->{'slots'}->{$slot}->{device_status}, + device_error => $state->{'slots'}->{$slot}->{device_error}, f_type => $state->{'slots'}->{$slot}->{f_type}, label => $label, barcode => $info->{'barcode'}, @@ -1558,6 +1568,7 @@ sub _with_updated_state { $new_slots->{$slot} = { state => Amanda::Changer::SLOT_FULL, device_status => undef, + device_error => undef, f_type => undef, label => undef, barcode => undef, @@ -1653,6 +1664,7 @@ sub _with_updated_state { $state->{'slots'}->{$info->{'orig_slot'}} = { state => $info->{'state'}, device_status => $old_state->{'device_status'}, + device_error => $old_state->{'device_error'}, f_type => $old_state->{'f_type'}, label => $info->{'label'}, barcode => $info->{'barcode'}, @@ -1876,14 +1888,28 @@ sub status { synchronized($self->{'lock'}, $status_cb, sub { my ($status_cb) = @_; + my ($counter) = 120; + + my $sys_cb; + my $run_mtx = make_cb(run_mtx => sub { + my @nobarcode = ('nobarcode') if $self->{'ignore_barcodes'}; + $self->_run_system_command($sys_cb, + $self->{'mtx'}, "-f", $self->{'device_name'}, @nobarcode, + 'status'); + }); - my $sys_cb = make_cb(sys_cb => sub { + $sys_cb = make_cb(sys_cb => sub { my ($exitstatus, $output) = @_; if ($exitstatus != 0) { my $err = $output; # if it's a regular SCSI error, just show the sense key my ($sensekey) = ($err =~ /mtx: Request Sense: Sense Key=(.*)\n/); $err = "SCSI error; Sense Key=$sensekey" if $sensekey; + $counter--; + if ($sensekey eq "Not Ready" and $counter > 0) { + debug("$output"); + return Amanda::MainLoop::call_after(1000, $run_mtx); + } return $status_cb->("error from mtx: " . $err, {}); } else { my %status; @@ -1932,9 +1958,7 @@ sub status { } }); - my @nobarcode = ('nobarcode') if $self->{'ignore_barcodes'}; - $self->_run_system_command($sys_cb, - $self->{'mtx'}, "-f", $self->{'device_name'}, @nobarcode, 'status'); + $run_mtx->(); }); } diff --git a/perl/Amanda/Changer/single.pm b/perl/Amanda/Changer/single.pm index 0edc07d..75e0469 100644 --- a/perl/Amanda/Changer/single.pm +++ b/perl/Amanda/Changer/single.pm @@ -166,6 +166,10 @@ sub do_release { my $self = shift; my %params = @_; + $self->{'device'}->eject() if (exists $self->{'device'} and + exists $params{'eject'} and + $params{'eject'}); + $self->{'chg'}->{'reserved'} = 0; # unref the device, for good measure diff --git a/perl/Amanda/Cmdline.c b/perl/Amanda/Cmdline.c index bc9ea2e..e572b98 100644 --- a/perl/Amanda/Cmdline.c +++ b/perl/Amanda/Cmdline.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1498,7 +1527,7 @@ static swig_module_info swig_module = {swig_types, 9, 0, 0, 0, 0}; #define SWIG_name "Amanda::Cmdlinec::boot_Amanda__Cmdline" #define SWIG_prefix "Amanda::Cmdlinec::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1665,7 +1694,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -2674,17 +2705,17 @@ XS(SWIG_init) { } SWIG_TypeClientData(SWIGTYPE_p_dumpspec_t, (void*) "Amanda::Cmdline::dumpspec_t"); - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CMDLINE_PARSE_DATESTAMP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CMDLINE_PARSE_DATESTAMP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CMDLINE_PARSE_LEVEL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CMDLINE_PARSE_LEVEL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CMDLINE_EMPTY_TO_WILDCARD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CMDLINE_EMPTY_TO_WILDCARD))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Cmdline.pm b/perl/Amanda/Cmdline.pm index 2c49536..c7853b0 100644 --- a/perl/Amanda/Cmdline.pm +++ b/perl/Amanda/Cmdline.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Config.c b/perl/Amanda/Config.c index dbc4f7a..cacd064 100644 --- a/perl/Amanda/Config.c +++ b/perl/Amanda/Config.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1507,7 +1536,7 @@ static swig_module_info swig_module = {swig_types, 18, 0, 0, 0, 0}; #define SWIG_name "Amanda::Configc::boot_Amanda__Config" #define SWIG_prefix "Amanda::Configc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1828,7 +1857,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -5433,1257 +5464,1267 @@ XS(SWIG_init) { SvREADONLY_on(sv); } - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_ORG", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_ORG))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_CONF", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_CONF))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AMDUMP_SERVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AMDUMP_SERVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_INDEX_SERVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_INDEX_SERVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPE_SERVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPE_SERVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AUTH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AUTH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_SSH_KEYS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_SSH_KEYS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AMANDAD_PATH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AMANDAD_PATH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_CLIENT_USERNAME", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_CLIENT_USERNAME))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_CLIENT_PORT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_CLIENT_PORT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_GNUTAR_LIST_DIR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_GNUTAR_LIST_DIR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AMANDATES", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AMANDATES))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_MAILER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_MAILER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_MAILTO", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_MAILTO))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DUMPUSER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DUMPUSER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPEDEV", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPEDEV))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEVICE_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEVICE_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_CHANGERDEV", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_CHANGERDEV))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_CHANGERFILE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_CHANGERFILE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_LABELSTR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_LABELSTR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AUTOLABEL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AUTOLABEL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_META_AUTOLABEL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_META_AUTOLABEL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPELIST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPELIST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DISKFILE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DISKFILE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_INFOFILE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_INFOFILE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_LOGDIR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_LOGDIR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_INDEXDIR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_INDEXDIR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPETYPE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPETYPE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DUMPCYCLE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DUMPCYCLE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_RUNSPERCYCLE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_RUNSPERCYCLE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPECYCLE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPECYCLE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_NETUSAGE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_NETUSAGE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_INPARALLEL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_INPARALLEL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DUMPORDER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DUMPORDER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_BUMPPERCENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_BUMPPERCENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_BUMPSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_BUMPSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_BUMPMULT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_BUMPMULT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_BUMPDAYS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_BUMPDAYS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TPCHANGER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TPCHANGER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_RUNTAPES", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_RUNTAPES))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { + SV *sv = get_sv((char*) SWIG_prefix "CNF_MAX_DLE_BY_VOLUME", TRUE | 0x2 | GV_ADDMULTI); + sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_MAX_DLE_BY_VOLUME))); + SvREADONLY_on(sv); + } while(0) /*@SWIG@*/; + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_MAXDUMPS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_MAXDUMPS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_ETIMEOUT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_ETIMEOUT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DTIMEOUT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DTIMEOUT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_CTIMEOUT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_CTIMEOUT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEVICE_OUTPUT_BUFFER_SIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEVICE_OUTPUT_BUFFER_SIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_PRINTER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_PRINTER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AUTOFLUSH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AUTOFLUSH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_RESERVE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_RESERVE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_MAXDUMPSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_MAXDUMPSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_COLUMNSPEC", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_COLUMNSPEC))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AMRECOVER_DO_FSF", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AMRECOVER_DO_FSF))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AMRECOVER_CHECK_LABEL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AMRECOVER_CHECK_LABEL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_AMRECOVER_CHANGER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_AMRECOVER_CHANGER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPERALGO", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPERALGO))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_FLUSH_THRESHOLD_DUMPED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_FLUSH_THRESHOLD_DUMPED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_FLUSH_THRESHOLD_SCHEDULED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_FLUSH_THRESHOLD_SCHEDULED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPERFLUSH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPERFLUSH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DISPLAYUNIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DISPLAYUNIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_KRB5KEYTAB", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_KRB5KEYTAB))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_KRB5PRINCIPAL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_KRB5PRINCIPAL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_LABEL_NEW_TAPES", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_LABEL_NEW_TAPES))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_USETIMESTAMPS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_USETIMESTAMPS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_REP_TRIES", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_REP_TRIES))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_CONNECT_TRIES", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_CONNECT_TRIES))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_REQ_TRIES", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_REQ_TRIES))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_AMANDAD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_AMANDAD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_RECOVERY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_RECOVERY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_AMIDXTAPED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_AMIDXTAPED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_AMINDEXD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_AMINDEXD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_AMRECOVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_AMRECOVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_AUTH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_AUTH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_EVENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_EVENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_HOLDING", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_HOLDING))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_PROTOCOL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_PROTOCOL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_PLANNER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_PLANNER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_DRIVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_DRIVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_DUMPER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_DUMPER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_CHUNKER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_CHUNKER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_TAPER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_TAPER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_SELFCHECK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_SELFCHECK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_SENDSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_SENDSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_DEBUG_SENDBACKUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_DEBUG_SENDBACKUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_RESERVED_UDP_PORT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_RESERVED_UDP_PORT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_RESERVED_TCP_PORT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_RESERVED_TCP_PORT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_UNRESERVED_TCP_PORT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_UNRESERVED_TCP_PORT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_HOLDINGDISK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_HOLDINGDISK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_SEND_AMREPORT_ON", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_SEND_AMREPORT_ON))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPER_PARALLEL_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPER_PARALLEL_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_RECOVERY_LIMIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_RECOVERY_LIMIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_INTERACTIVITY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_INTERACTIVITY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CNF_TAPERSCAN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_TAPERSCAN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { + SV *sv = get_sv((char*) SWIG_prefix "CNF_EJECT_VOLUME", TRUE | 0x2 | GV_ADDMULTI); + sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CNF_EJECT_VOLUME))); + SvREADONLY_on(sv); + } while(0) /*@SWIG@*/; + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_LBL_TEMPL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_LBL_TEMPL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_BLOCKSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_BLOCKSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_READBLOCKSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_READBLOCKSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_LENGTH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_LENGTH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_FILEMARK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_FILEMARK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_SPEED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_SPEED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_PART_SIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_PART_SIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_PART_CACHE_TYPE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_PART_CACHE_TYPE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_PART_CACHE_DIR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_PART_CACHE_DIR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPETYPE_PART_CACHE_MAX_SIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPETYPE_PART_CACHE_MAX_SIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_PROGRAM", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_PROGRAM))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SRVCOMPPROG", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SRVCOMPPROG))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_CLNTCOMPPROG", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_CLNTCOMPPROG))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SRV_ENCRYPT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SRV_ENCRYPT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_CLNT_ENCRYPT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_CLNT_ENCRYPT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_AMANDAD_PATH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_AMANDAD_PATH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_CLIENT_USERNAME", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_CLIENT_USERNAME))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_CLIENT_PORT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_CLIENT_PORT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SSH_KEYS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SSH_KEYS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_AUTH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_AUTH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_EXCLUDE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_EXCLUDE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_INCLUDE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_INCLUDE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_PRIORITY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_PRIORITY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_DUMPCYCLE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_DUMPCYCLE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_MAXDUMPS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_MAXDUMPS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_MAXPROMOTEDAY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_MAXPROMOTEDAY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_BUMPPERCENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_BUMPPERCENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_BUMPSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_BUMPSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_BUMPDAYS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_BUMPDAYS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_BUMPMULT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_BUMPMULT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_STARTTIME", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_STARTTIME))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_STRATEGY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_STRATEGY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_ESTIMATELIST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_ESTIMATELIST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_COMPRESS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_COMPRESS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_ENCRYPT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_ENCRYPT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SRV_DECRYPT_OPT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SRV_DECRYPT_OPT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_CLNT_DECRYPT_OPT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_CLNT_DECRYPT_OPT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_COMPRATE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_COMPRATE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_TAPE_SPLITSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_TAPE_SPLITSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_FALLBACK_SPLITSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_FALLBACK_SPLITSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SPLIT_DISKBUFFER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SPLIT_DISKBUFFER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_RECORD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_RECORD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SKIP_INCR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SKIP_INCR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SKIP_FULL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SKIP_FULL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_HOLDINGDISK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_HOLDINGDISK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_KENCRYPT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_KENCRYPT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_IGNORE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_IGNORE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_INDEX", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_INDEX))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_APPLICATION", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_APPLICATION))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_SCRIPTLIST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_SCRIPTLIST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_DATA_PATH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_DATA_PATH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_ALLOW_SPLIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_ALLOW_SPLIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_RECOVERY_LIMIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_RECOVERY_LIMIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DUMPTYPE_DUMP_LIMIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DUMPTYPE_DUMP_LIMIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "INTER_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(INTER_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "INTER_MAXUSAGE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(INTER_MAXUSAGE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "HOLDING_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(HOLDING_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "HOLDING_DISKDIR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(HOLDING_DISKDIR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "HOLDING_DISKSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(HOLDING_DISKSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "HOLDING_CHUNKSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(HOLDING_CHUNKSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "APPLICATION_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(APPLICATION_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "APPLICATION_PLUGIN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(APPLICATION_PLUGIN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "APPLICATION_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(APPLICATION_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "APPLICATION_CLIENT_NAME", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(APPLICATION_CLIENT_NAME))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_PLUGIN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_PLUGIN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_EXECUTE_ON", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_EXECUTE_ON))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_EXECUTE_WHERE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_EXECUTE_WHERE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_ORDER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_ORDER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_SINGLE_EXECUTION", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_SINGLE_EXECUTION))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PP_SCRIPT_CLIENT_NAME", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PP_SCRIPT_CLIENT_NAME))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_CONFIG_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_CONFIG_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_CONFIG_TAPEDEV", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_CONFIG_TAPEDEV))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_CONFIG_DEVICE_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_CONFIG_DEVICE_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CHANGER_CONFIG_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CHANGER_CONFIG_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CHANGER_CONFIG_TAPEDEV", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CHANGER_CONFIG_TAPEDEV))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CHANGER_CONFIG_TPCHANGER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CHANGER_CONFIG_TPCHANGER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CHANGER_CONFIG_CHANGERDEV", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CHANGER_CONFIG_CHANGERDEV))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CHANGER_CONFIG_CHANGERFILE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CHANGER_CONFIG_CHANGERFILE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CHANGER_CONFIG_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CHANGER_CONFIG_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CHANGER_CONFIG_DEVICE_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CHANGER_CONFIG_DEVICE_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "INTERACTIVITY_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(INTERACTIVITY_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "INTERACTIVITY_PLUGIN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(INTERACTIVITY_PLUGIN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "INTERACTIVITY_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(INTERACTIVITY_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPERSCAN_COMMENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPERSCAN_COMMENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPERSCAN_PLUGIN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPERSCAN_PLUGIN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "TAPERSCAN_PROPERTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(TAPERSCAN_PROPERTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "HOLD_NEVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(HOLD_NEVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "HOLD_AUTO", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(HOLD_AUTO))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "HOLD_REQUIRED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(HOLD_REQUIRED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "COMP_NONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(COMP_NONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "COMP_FAST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(COMP_FAST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "COMP_BEST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(COMP_BEST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "COMP_CUST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(COMP_CUST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "COMP_SERVER_FAST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(COMP_SERVER_FAST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "COMP_SERVER_BEST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(COMP_SERVER_BEST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "COMP_SERVER_CUST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(COMP_SERVER_CUST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ENCRYPT_NONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ENCRYPT_NONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ENCRYPT_CUST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ENCRYPT_CUST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ENCRYPT_SERV_CUST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ENCRYPT_SERV_CUST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_SKIP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_SKIP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_STANDARD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_STANDARD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_NOFULL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_NOFULL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_NOINC", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_NOINC))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_4", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_4))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_5", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_5))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_HANOI", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_HANOI))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DS_INCRONLY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DS_INCRONLY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ES_CLIENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ES_CLIENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ES_SERVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ES_SERVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ES_CALCSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ES_CALCSIZE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "AL_OTHER_CONFIG", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(AL_OTHER_CONFIG))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "AL_NON_AMANDA", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(AL_NON_AMANDA))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "AL_VOLUME_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(AL_VOLUME_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "AL_EMPTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(AL_EMPTY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ALGO_FIRST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ALGO_FIRST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ALGO_FIRSTFIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ALGO_FIRSTFIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ALGO_LARGEST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ALGO_LARGEST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ALGO_LARGESTFIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ALGO_LARGESTFIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ALGO_SMALLEST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ALGO_SMALLEST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ALGO_LAST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ALGO_LAST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_AMCHECK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_AMCHECK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_DLE_AMCHECK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_DLE_AMCHECK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_HOST_AMCHECK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_HOST_AMCHECK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_AMCHECK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_AMCHECK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_DLE_AMCHECK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_DLE_AMCHECK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_HOST_AMCHECK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_HOST_AMCHECK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_ESTIMATE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_ESTIMATE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_DLE_ESTIMATE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_DLE_ESTIMATE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_HOST_ESTIMATE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_HOST_ESTIMATE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_ESTIMATE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_ESTIMATE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_DLE_ESTIMATE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_DLE_ESTIMATE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_HOST_ESTIMATE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_HOST_ESTIMATE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_BACKUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_BACKUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_DLE_BACKUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_DLE_BACKUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_PRE_HOST_BACKUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_PRE_HOST_BACKUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_BACKUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_BACKUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_DLE_BACKUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_DLE_BACKUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "EXECUTE_ON_POST_HOST_BACKUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(EXECUTE_ON_POST_HOST_BACKUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "SEND_AMREPORT_ALL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(SEND_AMREPORT_ALL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "SEND_AMREPORT_STRANGE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(SEND_AMREPORT_STRANGE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "SEND_AMREPORT_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(SEND_AMREPORT_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "SEND_AMREPORT_NEVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(SEND_AMREPORT_NEVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DATA_PATH_AMANDA", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DATA_PATH_AMANDA))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DATA_PATH_DIRECTTCP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DATA_PATH_DIRECTTCP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PART_CACHE_TYPE_NONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PART_CACHE_TYPE_NONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PART_CACHE_TYPE_DISK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PART_CACHE_TYPE_DISK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PART_CACHE_TYPE_MEMORY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PART_CACHE_TYPE_MEMORY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CFGERR_OK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CFGERR_OK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CFGERR_WARNINGS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CFGERR_WARNINGS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CFGERR_ERRORS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CFGERR_ERRORS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONFIG_INIT_EXPLICIT_NAME", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONFIG_INIT_EXPLICIT_NAME))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONFIG_INIT_USE_CWD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONFIG_INIT_USE_CWD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONFIG_INIT_CLIENT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONFIG_INIT_CLIENT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONFIG_INIT_OVERLAY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONFIG_INIT_OVERLAY))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Config.pm b/perl/Amanda/Config.pm index d76971c..79b2e5b 100644 --- a/perl/Amanda/Config.pm +++ b/perl/Amanda/Config.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. @@ -164,6 +164,7 @@ package Amanda::Config; *CNF_BUMPDAYS = *Amanda::Configc::CNF_BUMPDAYS; *CNF_TPCHANGER = *Amanda::Configc::CNF_TPCHANGER; *CNF_RUNTAPES = *Amanda::Configc::CNF_RUNTAPES; +*CNF_MAX_DLE_BY_VOLUME = *Amanda::Configc::CNF_MAX_DLE_BY_VOLUME; *CNF_MAXDUMPS = *Amanda::Configc::CNF_MAXDUMPS; *CNF_ETIMEOUT = *Amanda::Configc::CNF_ETIMEOUT; *CNF_DTIMEOUT = *Amanda::Configc::CNF_DTIMEOUT; @@ -215,6 +216,7 @@ package Amanda::Config; *CNF_RECOVERY_LIMIT = *Amanda::Configc::CNF_RECOVERY_LIMIT; *CNF_INTERACTIVITY = *Amanda::Configc::CNF_INTERACTIVITY; *CNF_TAPERSCAN = *Amanda::Configc::CNF_TAPERSCAN; +*CNF_EJECT_VOLUME = *Amanda::Configc::CNF_EJECT_VOLUME; *TAPETYPE_COMMENT = *Amanda::Configc::TAPETYPE_COMMENT; *TAPETYPE_LBL_TEMPL = *Amanda::Configc::TAPETYPE_LBL_TEMPL; *TAPETYPE_BLOCKSIZE = *Amanda::Configc::TAPETYPE_BLOCKSIZE; @@ -736,9 +738,9 @@ sub confparm_key_to_string { return $enumval; } -push @EXPORT_OK, qw( $CNF_ORG $CNF_CONF $CNF_AMDUMP_SERVER $CNF_INDEX_SERVER $CNF_TAPE_SERVER $CNF_AUTH $CNF_SSH_KEYS $CNF_AMANDAD_PATH $CNF_CLIENT_USERNAME $CNF_CLIENT_PORT $CNF_GNUTAR_LIST_DIR $CNF_AMANDATES $CNF_MAILER $CNF_MAILTO $CNF_DUMPUSER $CNF_TAPEDEV $CNF_DEVICE_PROPERTY $CNF_PROPERTY $CNF_CHANGERDEV $CNF_CHANGERFILE $CNF_LABELSTR $CNF_AUTOLABEL $CNF_META_AUTOLABEL $CNF_TAPELIST $CNF_DISKFILE $CNF_INFOFILE $CNF_LOGDIR $CNF_INDEXDIR $CNF_TAPETYPE $CNF_DUMPCYCLE $CNF_RUNSPERCYCLE $CNF_TAPECYCLE $CNF_NETUSAGE $CNF_INPARALLEL $CNF_DUMPORDER $CNF_BUMPPERCENT $CNF_BUMPSIZE $CNF_BUMPMULT $CNF_BUMPDAYS $CNF_TPCHANGER $CNF_RUNTAPES $CNF_MAXDUMPS $CNF_ETIMEOUT $CNF_DTIMEOUT $CNF_CTIMEOUT $CNF_DEVICE_OUTPUT_BUFFER_SIZE $CNF_PRINTER $CNF_AUTOFLUSH $CNF_RESERVE $CNF_MAXDUMPSIZE $CNF_COLUMNSPEC $CNF_AMRECOVER_DO_FSF $CNF_AMRECOVER_CHECK_LABEL $CNF_AMRECOVER_CHANGER $CNF_TAPERALGO $CNF_FLUSH_THRESHOLD_DUMPED $CNF_FLUSH_THRESHOLD_SCHEDULED $CNF_TAPERFLUSH $CNF_DISPLAYUNIT $CNF_KRB5KEYTAB $CNF_KRB5PRINCIPAL $CNF_LABEL_NEW_TAPES $CNF_USETIMESTAMPS $CNF_REP_TRIES $CNF_CONNECT_TRIES $CNF_REQ_TRIES $CNF_DEBUG_AMANDAD $CNF_DEBUG_RECOVERY $CNF_DEBUG_AMIDXTAPED $CNF_DEBUG_AMINDEXD $CNF_DEBUG_AMRECOVER $CNF_DEBUG_AUTH $CNF_DEBUG_EVENT $CNF_DEBUG_HOLDING $CNF_DEBUG_PROTOCOL $CNF_DEBUG_PLANNER $CNF_DEBUG_DRIVER $CNF_DEBUG_DUMPER $CNF_DEBUG_CHUNKER $CNF_DEBUG_TAPER $CNF_DEBUG_SELFCHECK $CNF_DEBUG_SENDSIZE $CNF_DEBUG_SENDBACKUP $CNF_RESERVED_UDP_PORT $CNF_RESERVED_TCP_PORT $CNF_UNRESERVED_TCP_PORT $CNF_HOLDINGDISK $CNF_SEND_AMREPORT_ON $CNF_TAPER_PARALLEL_WRITE $CNF_RECOVERY_LIMIT $CNF_INTERACTIVITY $CNF_TAPERSCAN); -push @{$EXPORT_TAGS{"confparm_key"}}, qw( $CNF_ORG $CNF_CONF $CNF_AMDUMP_SERVER $CNF_INDEX_SERVER $CNF_TAPE_SERVER $CNF_AUTH $CNF_SSH_KEYS $CNF_AMANDAD_PATH $CNF_CLIENT_USERNAME $CNF_CLIENT_PORT $CNF_GNUTAR_LIST_DIR $CNF_AMANDATES $CNF_MAILER $CNF_MAILTO $CNF_DUMPUSER $CNF_TAPEDEV $CNF_DEVICE_PROPERTY $CNF_PROPERTY $CNF_CHANGERDEV $CNF_CHANGERFILE $CNF_LABELSTR $CNF_AUTOLABEL $CNF_META_AUTOLABEL $CNF_TAPELIST $CNF_DISKFILE $CNF_INFOFILE $CNF_LOGDIR $CNF_INDEXDIR $CNF_TAPETYPE $CNF_DUMPCYCLE $CNF_RUNSPERCYCLE $CNF_TAPECYCLE $CNF_NETUSAGE $CNF_INPARALLEL $CNF_DUMPORDER $CNF_BUMPPERCENT $CNF_BUMPSIZE $CNF_BUMPMULT $CNF_BUMPDAYS $CNF_TPCHANGER $CNF_RUNTAPES $CNF_MAXDUMPS $CNF_ETIMEOUT $CNF_DTIMEOUT $CNF_CTIMEOUT $CNF_DEVICE_OUTPUT_BUFFER_SIZE $CNF_PRINTER $CNF_AUTOFLUSH $CNF_RESERVE $CNF_MAXDUMPSIZE $CNF_COLUMNSPEC $CNF_AMRECOVER_DO_FSF $CNF_AMRECOVER_CHECK_LABEL $CNF_AMRECOVER_CHANGER $CNF_TAPERALGO $CNF_FLUSH_THRESHOLD_DUMPED $CNF_FLUSH_THRESHOLD_SCHEDULED $CNF_TAPERFLUSH $CNF_DISPLAYUNIT $CNF_KRB5KEYTAB $CNF_KRB5PRINCIPAL $CNF_LABEL_NEW_TAPES $CNF_USETIMESTAMPS $CNF_REP_TRIES $CNF_CONNECT_TRIES $CNF_REQ_TRIES $CNF_DEBUG_AMANDAD $CNF_DEBUG_RECOVERY $CNF_DEBUG_AMIDXTAPED $CNF_DEBUG_AMINDEXD $CNF_DEBUG_AMRECOVER $CNF_DEBUG_AUTH $CNF_DEBUG_EVENT $CNF_DEBUG_HOLDING $CNF_DEBUG_PROTOCOL $CNF_DEBUG_PLANNER $CNF_DEBUG_DRIVER $CNF_DEBUG_DUMPER $CNF_DEBUG_CHUNKER $CNF_DEBUG_TAPER $CNF_DEBUG_SELFCHECK $CNF_DEBUG_SENDSIZE $CNF_DEBUG_SENDBACKUP $CNF_RESERVED_UDP_PORT $CNF_RESERVED_TCP_PORT $CNF_UNRESERVED_TCP_PORT $CNF_HOLDINGDISK $CNF_SEND_AMREPORT_ON $CNF_TAPER_PARALLEL_WRITE $CNF_RECOVERY_LIMIT $CNF_INTERACTIVITY $CNF_TAPERSCAN); - foreach (qw( CNF_ORG CNF_CONF CNF_AMDUMP_SERVER CNF_INDEX_SERVER CNF_TAPE_SERVER CNF_AUTH CNF_SSH_KEYS CNF_AMANDAD_PATH CNF_CLIENT_USERNAME CNF_CLIENT_PORT CNF_GNUTAR_LIST_DIR CNF_AMANDATES CNF_MAILER CNF_MAILTO CNF_DUMPUSER CNF_TAPEDEV CNF_DEVICE_PROPERTY CNF_PROPERTY CNF_CHANGERDEV CNF_CHANGERFILE CNF_LABELSTR CNF_AUTOLABEL CNF_META_AUTOLABEL CNF_TAPELIST CNF_DISKFILE CNF_INFOFILE CNF_LOGDIR CNF_INDEXDIR CNF_TAPETYPE CNF_DUMPCYCLE CNF_RUNSPERCYCLE CNF_TAPECYCLE CNF_NETUSAGE CNF_INPARALLEL CNF_DUMPORDER CNF_BUMPPERCENT CNF_BUMPSIZE CNF_BUMPMULT CNF_BUMPDAYS CNF_TPCHANGER CNF_RUNTAPES CNF_MAXDUMPS CNF_ETIMEOUT CNF_DTIMEOUT CNF_CTIMEOUT CNF_DEVICE_OUTPUT_BUFFER_SIZE CNF_PRINTER CNF_AUTOFLUSH CNF_RESERVE CNF_MAXDUMPSIZE CNF_COLUMNSPEC CNF_AMRECOVER_DO_FSF CNF_AMRECOVER_CHECK_LABEL CNF_AMRECOVER_CHANGER CNF_TAPERALGO CNF_FLUSH_THRESHOLD_DUMPED CNF_FLUSH_THRESHOLD_SCHEDULED CNF_TAPERFLUSH CNF_DISPLAYUNIT CNF_KRB5KEYTAB CNF_KRB5PRINCIPAL CNF_LABEL_NEW_TAPES CNF_USETIMESTAMPS CNF_REP_TRIES CNF_CONNECT_TRIES CNF_REQ_TRIES CNF_DEBUG_AMANDAD CNF_DEBUG_RECOVERY CNF_DEBUG_AMIDXTAPED CNF_DEBUG_AMINDEXD CNF_DEBUG_AMRECOVER CNF_DEBUG_AUTH CNF_DEBUG_EVENT CNF_DEBUG_HOLDING CNF_DEBUG_PROTOCOL CNF_DEBUG_PLANNER CNF_DEBUG_DRIVER CNF_DEBUG_DUMPER CNF_DEBUG_CHUNKER CNF_DEBUG_TAPER CNF_DEBUG_SELFCHECK CNF_DEBUG_SENDSIZE CNF_DEBUG_SENDBACKUP CNF_RESERVED_UDP_PORT CNF_RESERVED_TCP_PORT CNF_UNRESERVED_TCP_PORT CNF_HOLDINGDISK CNF_SEND_AMREPORT_ON CNF_TAPER_PARALLEL_WRITE CNF_RECOVERY_LIMIT CNF_INTERACTIVITY CNF_TAPERSCAN)) { $_confparm_key_VALUES{$_} = $$_; } +push @EXPORT_OK, qw( $CNF_ORG $CNF_CONF $CNF_AMDUMP_SERVER $CNF_INDEX_SERVER $CNF_TAPE_SERVER $CNF_AUTH $CNF_SSH_KEYS $CNF_AMANDAD_PATH $CNF_CLIENT_USERNAME $CNF_CLIENT_PORT $CNF_GNUTAR_LIST_DIR $CNF_AMANDATES $CNF_MAILER $CNF_MAILTO $CNF_DUMPUSER $CNF_TAPEDEV $CNF_DEVICE_PROPERTY $CNF_PROPERTY $CNF_CHANGERDEV $CNF_CHANGERFILE $CNF_LABELSTR $CNF_AUTOLABEL $CNF_META_AUTOLABEL $CNF_TAPELIST $CNF_DISKFILE $CNF_INFOFILE $CNF_LOGDIR $CNF_INDEXDIR $CNF_TAPETYPE $CNF_DUMPCYCLE $CNF_RUNSPERCYCLE $CNF_TAPECYCLE $CNF_NETUSAGE $CNF_INPARALLEL $CNF_DUMPORDER $CNF_BUMPPERCENT $CNF_BUMPSIZE $CNF_BUMPMULT $CNF_BUMPDAYS $CNF_TPCHANGER $CNF_RUNTAPES $CNF_MAX_DLE_BY_VOLUME $CNF_MAXDUMPS $CNF_ETIMEOUT $CNF_DTIMEOUT $CNF_CTIMEOUT $CNF_DEVICE_OUTPUT_BUFFER_SIZE $CNF_PRINTER $CNF_AUTOFLUSH $CNF_RESERVE $CNF_MAXDUMPSIZE $CNF_COLUMNSPEC $CNF_AMRECOVER_DO_FSF $CNF_AMRECOVER_CHECK_LABEL $CNF_AMRECOVER_CHANGER $CNF_TAPERALGO $CNF_FLUSH_THRESHOLD_DUMPED $CNF_FLUSH_THRESHOLD_SCHEDULED $CNF_TAPERFLUSH $CNF_DISPLAYUNIT $CNF_KRB5KEYTAB $CNF_KRB5PRINCIPAL $CNF_LABEL_NEW_TAPES $CNF_USETIMESTAMPS $CNF_REP_TRIES $CNF_CONNECT_TRIES $CNF_REQ_TRIES $CNF_DEBUG_AMANDAD $CNF_DEBUG_RECOVERY $CNF_DEBUG_AMIDXTAPED $CNF_DEBUG_AMINDEXD $CNF_DEBUG_AMRECOVER $CNF_DEBUG_AUTH $CNF_DEBUG_EVENT $CNF_DEBUG_HOLDING $CNF_DEBUG_PROTOCOL $CNF_DEBUG_PLANNER $CNF_DEBUG_DRIVER $CNF_DEBUG_DUMPER $CNF_DEBUG_CHUNKER $CNF_DEBUG_TAPER $CNF_DEBUG_SELFCHECK $CNF_DEBUG_SENDSIZE $CNF_DEBUG_SENDBACKUP $CNF_RESERVED_UDP_PORT $CNF_RESERVED_TCP_PORT $CNF_UNRESERVED_TCP_PORT $CNF_HOLDINGDISK $CNF_SEND_AMREPORT_ON $CNF_TAPER_PARALLEL_WRITE $CNF_RECOVERY_LIMIT $CNF_INTERACTIVITY $CNF_TAPERSCAN $CNF_EJECT_VOLUME); +push @{$EXPORT_TAGS{"confparm_key"}}, qw( $CNF_ORG $CNF_CONF $CNF_AMDUMP_SERVER $CNF_INDEX_SERVER $CNF_TAPE_SERVER $CNF_AUTH $CNF_SSH_KEYS $CNF_AMANDAD_PATH $CNF_CLIENT_USERNAME $CNF_CLIENT_PORT $CNF_GNUTAR_LIST_DIR $CNF_AMANDATES $CNF_MAILER $CNF_MAILTO $CNF_DUMPUSER $CNF_TAPEDEV $CNF_DEVICE_PROPERTY $CNF_PROPERTY $CNF_CHANGERDEV $CNF_CHANGERFILE $CNF_LABELSTR $CNF_AUTOLABEL $CNF_META_AUTOLABEL $CNF_TAPELIST $CNF_DISKFILE $CNF_INFOFILE $CNF_LOGDIR $CNF_INDEXDIR $CNF_TAPETYPE $CNF_DUMPCYCLE $CNF_RUNSPERCYCLE $CNF_TAPECYCLE $CNF_NETUSAGE $CNF_INPARALLEL $CNF_DUMPORDER $CNF_BUMPPERCENT $CNF_BUMPSIZE $CNF_BUMPMULT $CNF_BUMPDAYS $CNF_TPCHANGER $CNF_RUNTAPES $CNF_MAX_DLE_BY_VOLUME $CNF_MAXDUMPS $CNF_ETIMEOUT $CNF_DTIMEOUT $CNF_CTIMEOUT $CNF_DEVICE_OUTPUT_BUFFER_SIZE $CNF_PRINTER $CNF_AUTOFLUSH $CNF_RESERVE $CNF_MAXDUMPSIZE $CNF_COLUMNSPEC $CNF_AMRECOVER_DO_FSF $CNF_AMRECOVER_CHECK_LABEL $CNF_AMRECOVER_CHANGER $CNF_TAPERALGO $CNF_FLUSH_THRESHOLD_DUMPED $CNF_FLUSH_THRESHOLD_SCHEDULED $CNF_TAPERFLUSH $CNF_DISPLAYUNIT $CNF_KRB5KEYTAB $CNF_KRB5PRINCIPAL $CNF_LABEL_NEW_TAPES $CNF_USETIMESTAMPS $CNF_REP_TRIES $CNF_CONNECT_TRIES $CNF_REQ_TRIES $CNF_DEBUG_AMANDAD $CNF_DEBUG_RECOVERY $CNF_DEBUG_AMIDXTAPED $CNF_DEBUG_AMINDEXD $CNF_DEBUG_AMRECOVER $CNF_DEBUG_AUTH $CNF_DEBUG_EVENT $CNF_DEBUG_HOLDING $CNF_DEBUG_PROTOCOL $CNF_DEBUG_PLANNER $CNF_DEBUG_DRIVER $CNF_DEBUG_DUMPER $CNF_DEBUG_CHUNKER $CNF_DEBUG_TAPER $CNF_DEBUG_SELFCHECK $CNF_DEBUG_SENDSIZE $CNF_DEBUG_SENDBACKUP $CNF_RESERVED_UDP_PORT $CNF_RESERVED_TCP_PORT $CNF_UNRESERVED_TCP_PORT $CNF_HOLDINGDISK $CNF_SEND_AMREPORT_ON $CNF_TAPER_PARALLEL_WRITE $CNF_RECOVERY_LIMIT $CNF_INTERACTIVITY $CNF_TAPERSCAN $CNF_EJECT_VOLUME); + foreach (qw( CNF_ORG CNF_CONF CNF_AMDUMP_SERVER CNF_INDEX_SERVER CNF_TAPE_SERVER CNF_AUTH CNF_SSH_KEYS CNF_AMANDAD_PATH CNF_CLIENT_USERNAME CNF_CLIENT_PORT CNF_GNUTAR_LIST_DIR CNF_AMANDATES CNF_MAILER CNF_MAILTO CNF_DUMPUSER CNF_TAPEDEV CNF_DEVICE_PROPERTY CNF_PROPERTY CNF_CHANGERDEV CNF_CHANGERFILE CNF_LABELSTR CNF_AUTOLABEL CNF_META_AUTOLABEL CNF_TAPELIST CNF_DISKFILE CNF_INFOFILE CNF_LOGDIR CNF_INDEXDIR CNF_TAPETYPE CNF_DUMPCYCLE CNF_RUNSPERCYCLE CNF_TAPECYCLE CNF_NETUSAGE CNF_INPARALLEL CNF_DUMPORDER CNF_BUMPPERCENT CNF_BUMPSIZE CNF_BUMPMULT CNF_BUMPDAYS CNF_TPCHANGER CNF_RUNTAPES CNF_MAX_DLE_BY_VOLUME CNF_MAXDUMPS CNF_ETIMEOUT CNF_DTIMEOUT CNF_CTIMEOUT CNF_DEVICE_OUTPUT_BUFFER_SIZE CNF_PRINTER CNF_AUTOFLUSH CNF_RESERVE CNF_MAXDUMPSIZE CNF_COLUMNSPEC CNF_AMRECOVER_DO_FSF CNF_AMRECOVER_CHECK_LABEL CNF_AMRECOVER_CHANGER CNF_TAPERALGO CNF_FLUSH_THRESHOLD_DUMPED CNF_FLUSH_THRESHOLD_SCHEDULED CNF_TAPERFLUSH CNF_DISPLAYUNIT CNF_KRB5KEYTAB CNF_KRB5PRINCIPAL CNF_LABEL_NEW_TAPES CNF_USETIMESTAMPS CNF_REP_TRIES CNF_CONNECT_TRIES CNF_REQ_TRIES CNF_DEBUG_AMANDAD CNF_DEBUG_RECOVERY CNF_DEBUG_AMIDXTAPED CNF_DEBUG_AMINDEXD CNF_DEBUG_AMRECOVER CNF_DEBUG_AUTH CNF_DEBUG_EVENT CNF_DEBUG_HOLDING CNF_DEBUG_PROTOCOL CNF_DEBUG_PLANNER CNF_DEBUG_DRIVER CNF_DEBUG_DUMPER CNF_DEBUG_CHUNKER CNF_DEBUG_TAPER CNF_DEBUG_SELFCHECK CNF_DEBUG_SENDSIZE CNF_DEBUG_SENDBACKUP CNF_RESERVED_UDP_PORT CNF_RESERVED_TCP_PORT CNF_UNRESERVED_TCP_PORT CNF_HOLDINGDISK CNF_SEND_AMREPORT_ON CNF_TAPER_PARALLEL_WRITE CNF_RECOVERY_LIMIT CNF_INTERACTIVITY CNF_TAPERSCAN CNF_EJECT_VOLUME)) { $_confparm_key_VALUES{$_} = $$_; } #copy symbols in confparm_key to getconf push @{$EXPORT_TAGS{"getconf"}}, @{$EXPORT_TAGS{"confparm_key"}}; @@ -747,7 +749,7 @@ use Amanda::Config::FoldingHash; =pod -Global Parameters: C<$CNF_ORG> C<$CNF_CONF> C<$CNF_AMDUMP_SERVER> C<$CNF_INDEX_SERVER> C<$CNF_TAPE_SERVER> C<$CNF_AUTH> C<$CNF_SSH_KEYS> C<$CNF_AMANDAD_PATH> C<$CNF_CLIENT_USERNAME> C<$CNF_CLIENT_PORT> C<$CNF_GNUTAR_LIST_DIR> C<$CNF_AMANDATES> C<$CNF_MAILER> C<$CNF_MAILTO> C<$CNF_DUMPUSER> C<$CNF_TAPEDEV> C<$CNF_DEVICE_PROPERTY> C<$CNF_PROPERTY> C<$CNF_CHANGERDEV> C<$CNF_CHANGERFILE> C<$CNF_LABELSTR> C<$CNF_AUTOLABEL> C<$CNF_META_AUTOLABEL> C<$CNF_TAPELIST> C<$CNF_DISKFILE> C<$CNF_INFOFILE> C<$CNF_LOGDIR> C<$CNF_INDEXDIR> C<$CNF_TAPETYPE> C<$CNF_DUMPCYCLE> C<$CNF_RUNSPERCYCLE> C<$CNF_TAPECYCLE> C<$CNF_NETUSAGE> C<$CNF_INPARALLEL> C<$CNF_DUMPORDER> C<$CNF_BUMPPERCENT> C<$CNF_BUMPSIZE> C<$CNF_BUMPMULT> C<$CNF_BUMPDAYS> C<$CNF_TPCHANGER> C<$CNF_RUNTAPES> C<$CNF_MAXDUMPS> C<$CNF_ETIMEOUT> C<$CNF_DTIMEOUT> C<$CNF_CTIMEOUT> C<$CNF_DEVICE_OUTPUT_BUFFER_SIZE> C<$CNF_PRINTER> C<$CNF_AUTOFLUSH> C<$CNF_RESERVE> C<$CNF_MAXDUMPSIZE> C<$CNF_COLUMNSPEC> C<$CNF_AMRECOVER_DO_FSF> C<$CNF_AMRECOVER_CHECK_LABEL> C<$CNF_AMRECOVER_CHANGER> C<$CNF_TAPERALGO> C<$CNF_FLUSH_THRESHOLD_DUMPED> C<$CNF_FLUSH_THRESHOLD_SCHEDULED> C<$CNF_TAPERFLUSH> C<$CNF_DISPLAYUNIT> C<$CNF_KRB5KEYTAB> C<$CNF_KRB5PRINCIPAL> C<$CNF_LABEL_NEW_TAPES> C<$CNF_USETIMESTAMPS> C<$CNF_REP_TRIES> C<$CNF_CONNECT_TRIES> C<$CNF_REQ_TRIES> C<$CNF_DEBUG_AMANDAD> C<$CNF_DEBUG_RECOVERY> C<$CNF_DEBUG_AMIDXTAPED> C<$CNF_DEBUG_AMINDEXD> C<$CNF_DEBUG_AMRECOVER> C<$CNF_DEBUG_AUTH> C<$CNF_DEBUG_EVENT> C<$CNF_DEBUG_HOLDING> C<$CNF_DEBUG_PROTOCOL> C<$CNF_DEBUG_PLANNER> C<$CNF_DEBUG_DRIVER> C<$CNF_DEBUG_DUMPER> C<$CNF_DEBUG_CHUNKER> C<$CNF_DEBUG_TAPER> C<$CNF_DEBUG_SELFCHECK> C<$CNF_DEBUG_SENDSIZE> C<$CNF_DEBUG_SENDBACKUP> C<$CNF_RESERVED_UDP_PORT> C<$CNF_RESERVED_TCP_PORT> C<$CNF_UNRESERVED_TCP_PORT> C<$CNF_HOLDINGDISK> C<$CNF_SEND_AMREPORT_ON> C<$CNF_TAPER_PARALLEL_WRITE> C<$CNF_RECOVERY_LIMIT> C<$CNF_INTERACTIVITY> C<$CNF_TAPERSCAN> +Global Parameters: C<$CNF_ORG> C<$CNF_CONF> C<$CNF_AMDUMP_SERVER> C<$CNF_INDEX_SERVER> C<$CNF_TAPE_SERVER> C<$CNF_AUTH> C<$CNF_SSH_KEYS> C<$CNF_AMANDAD_PATH> C<$CNF_CLIENT_USERNAME> C<$CNF_CLIENT_PORT> C<$CNF_GNUTAR_LIST_DIR> C<$CNF_AMANDATES> C<$CNF_MAILER> C<$CNF_MAILTO> C<$CNF_DUMPUSER> C<$CNF_TAPEDEV> C<$CNF_DEVICE_PROPERTY> C<$CNF_PROPERTY> C<$CNF_CHANGERDEV> C<$CNF_CHANGERFILE> C<$CNF_LABELSTR> C<$CNF_AUTOLABEL> C<$CNF_META_AUTOLABEL> C<$CNF_TAPELIST> C<$CNF_DISKFILE> C<$CNF_INFOFILE> C<$CNF_LOGDIR> C<$CNF_INDEXDIR> C<$CNF_TAPETYPE> C<$CNF_DUMPCYCLE> C<$CNF_RUNSPERCYCLE> C<$CNF_TAPECYCLE> C<$CNF_NETUSAGE> C<$CNF_INPARALLEL> C<$CNF_DUMPORDER> C<$CNF_BUMPPERCENT> C<$CNF_BUMPSIZE> C<$CNF_BUMPMULT> C<$CNF_BUMPDAYS> C<$CNF_TPCHANGER> C<$CNF_RUNTAPES> C<$CNF_MAX_DLE_BY_VOLUME> C<$CNF_MAXDUMPS> C<$CNF_ETIMEOUT> C<$CNF_DTIMEOUT> C<$CNF_CTIMEOUT> C<$CNF_DEVICE_OUTPUT_BUFFER_SIZE> C<$CNF_PRINTER> C<$CNF_AUTOFLUSH> C<$CNF_RESERVE> C<$CNF_MAXDUMPSIZE> C<$CNF_COLUMNSPEC> C<$CNF_AMRECOVER_DO_FSF> C<$CNF_AMRECOVER_CHECK_LABEL> C<$CNF_AMRECOVER_CHANGER> C<$CNF_TAPERALGO> C<$CNF_FLUSH_THRESHOLD_DUMPED> C<$CNF_FLUSH_THRESHOLD_SCHEDULED> C<$CNF_TAPERFLUSH> C<$CNF_DISPLAYUNIT> C<$CNF_KRB5KEYTAB> C<$CNF_KRB5PRINCIPAL> C<$CNF_LABEL_NEW_TAPES> C<$CNF_USETIMESTAMPS> C<$CNF_REP_TRIES> C<$CNF_CONNECT_TRIES> C<$CNF_REQ_TRIES> C<$CNF_DEBUG_AMANDAD> C<$CNF_DEBUG_RECOVERY> C<$CNF_DEBUG_AMIDXTAPED> C<$CNF_DEBUG_AMINDEXD> C<$CNF_DEBUG_AMRECOVER> C<$CNF_DEBUG_AUTH> C<$CNF_DEBUG_EVENT> C<$CNF_DEBUG_HOLDING> C<$CNF_DEBUG_PROTOCOL> C<$CNF_DEBUG_PLANNER> C<$CNF_DEBUG_DRIVER> C<$CNF_DEBUG_DUMPER> C<$CNF_DEBUG_CHUNKER> C<$CNF_DEBUG_TAPER> C<$CNF_DEBUG_SELFCHECK> C<$CNF_DEBUG_SENDSIZE> C<$CNF_DEBUG_SENDBACKUP> C<$CNF_RESERVED_UDP_PORT> C<$CNF_RESERVED_TCP_PORT> C<$CNF_UNRESERVED_TCP_PORT> C<$CNF_HOLDINGDISK> C<$CNF_SEND_AMREPORT_ON> C<$CNF_TAPER_PARALLEL_WRITE> C<$CNF_RECOVERY_LIMIT> C<$CNF_INTERACTIVITY> C<$CNF_TAPERSCAN> C<$CNF_EJECT_VOLUME> =cut diff --git a/perl/Amanda/Config.swg b/perl/Amanda/Config.swg index 3049a13..4780ce9 100644 --- a/perl/Amanda/Config.swg +++ b/perl/Amanda/Config.swg @@ -93,6 +93,7 @@ APPLY(CNF_BUMPMULT)\ APPLY(CNF_BUMPDAYS)\ APPLY(CNF_TPCHANGER)\ APPLY(CNF_RUNTAPES)\ +APPLY(CNF_MAX_DLE_BY_VOLUME)\ APPLY(CNF_MAXDUMPS)\ APPLY(CNF_ETIMEOUT)\ APPLY(CNF_DTIMEOUT)\ @@ -143,7 +144,8 @@ APPLY(CNF_SEND_AMREPORT_ON)\ APPLY(CNF_TAPER_PARALLEL_WRITE)\ APPLY(CNF_RECOVERY_LIMIT) \ APPLY(CNF_INTERACTIVITY) \ -APPLY(CNF_TAPERSCAN) +APPLY(CNF_TAPERSCAN) \ +APPLY(CNF_EJECT_VOLUME) amglue_add_enum_tag_fns(confparm_key); amglue_add_constants(FOR_ALL_CONFPARM_KEY, confparm_key); diff --git a/perl/Amanda/DB/Catalog.pm b/perl/Amanda/DB/Catalog.pm index 162c731..0aa88fa 100644 --- a/perl/Amanda/DB/Catalog.pm +++ b/perl/Amanda/DB/Catalog.pm @@ -401,11 +401,10 @@ TODO: add_dump =cut -use Amanda::Logfile qw( :constants match_disk match_host - match_datestamp match_level ); +use Amanda::Logfile qw( :constants ); use Amanda::Tapelist; use Amanda::Config qw( :init :getconf config_dir_relative ); -use Amanda::Util qw( quote_string weaken_ref ); +use Amanda::Util qw( quote_string weaken_ref match_disk match_host match_datestamp match_level); use File::Glob qw( :glob ); use warnings; use strict; @@ -903,7 +902,7 @@ sub sort_dumps { for my $key (@$keys) { my ($rev, $k) = ($key =~ /^(-?)(.*)$/); - if ($k =~ /^(nparts|level)$/) { + if ($k =~ /^(nparts|level|filenum)$/) { # compare dump components numerically $res = $a->{$k} <=> $b->{$k}; } else { # ($k =~ /^(hostname|diskname|write_timestamp|dump_timestamp)$/) diff --git a/perl/Amanda/Debug.c b/perl/Amanda/Debug.c index c4876fc..103aa3f 100644 --- a/perl/Amanda/Debug.c +++ b/perl/Amanda/Debug.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1495,7 +1524,7 @@ static swig_module_info swig_module = {swig_types, 6, 0, 0, 0, 0}; #define SWIG_name "Amanda::Debugc::boot_Amanda__Debug" #define SWIG_prefix "Amanda::Debugc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1609,7 +1638,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; diff --git a/perl/Amanda/Debug.pm b/perl/Amanda/Debug.pm index ddb4d50..512202e 100644 --- a/perl/Amanda/Debug.pm +++ b/perl/Amanda/Debug.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Device.c b/perl/Amanda/Device.c index b3701bd..cfbb55f 100644 --- a/perl/Amanda/Device.c +++ b/perl/Amanda/Device.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1506,7 +1535,7 @@ static swig_module_info swig_module = {swig_types, 17, 0, 0, 0, 0}; #define SWIG_name "Amanda::Devicec::boot_Amanda__Device" #define SWIG_prefix "Amanda::Devicec::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1829,7 +1858,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -2037,15 +2068,16 @@ SWIGINTERN gboolean Device_property_set(Device *self,DevicePropertyBase *pbase,S memset(&gval, 0, sizeof(gval)); g_value_init(&gval, pbase->type); if (!set_gvalue_from_sv(sv, &gval)) - goto fail; + goto failunset; if (!device_property_set(self, pbase->ID, &gval)) - goto fail; + goto failunset; g_value_unset(&gval); return TRUE; - fail: + failunset: g_value_unset(&gval); + fail: return FALSE; } SWIGINTERN gboolean Device_property_set_ex(Device *self,DevicePropertyBase *pbase,SV *sv,PropertySurety surety,PropertySource source){ @@ -2080,6 +2112,7 @@ SWIGINTERN DeviceStatusFlags Device_status(Device *self){ return self->status; } SWIGINTERN gsize Device_min_block_size(Device *self){ return self->min_block_size; } SWIGINTERN gsize Device_max_block_size(Device *self){ return self->max_block_size; } SWIGINTERN gsize Device_block_size(Device *self){ return self->block_size; } +SWIGINTERN gsize Device_header_block_size(Device *self){ return self->header_block_size; } SWIGINTERN dumpfile_t *Device_volume_header(Device *self){ return self->volume_header; } @@ -4109,6 +4142,41 @@ XS(_wrap_Device_block_size) { } +XS(_wrap_Device_header_block_size) { + { + Device *arg1 = (Device *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int argvi = 0; + gsize result; + dXSARGS; + + if ((items < 1) || (items > 1)) { + SWIG_croak("Usage: Device_header_block_size(self);"); + } + res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Device, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "Device_header_block_size" "', argument " "1"" of type '" "Device *""'"); + } + arg1 = (Device *)(argp1); + result = Device_header_block_size(arg1); + { + SV *for_stack; + SP += argvi; PUTBACK; + for_stack = sv_2mortal(amglue_newSVu64(result)); + SPAGAIN; SP -= argvi; + ST(argvi) = for_stack; + argvi++; + } + + XSRETURN(argvi); + fail: + + SWIG_croak_null(); + } +} + + XS(_wrap_Device_volume_header) { { Device *arg1 = (Device *) 0 ; @@ -4472,6 +4540,7 @@ static swig_command_info swig_commands[] = { {"Amanda::Devicec::Device_min_block_size", _wrap_Device_min_block_size}, {"Amanda::Devicec::Device_max_block_size", _wrap_Device_max_block_size}, {"Amanda::Devicec::Device_block_size", _wrap_Device_block_size}, +{"Amanda::Devicec::Device_header_block_size", _wrap_Device_header_block_size}, {"Amanda::Devicec::Device_volume_header", _wrap_Device_volume_header}, {"Amanda::Devicec::rait_device_open_from_children", _wrap_rait_device_open_from_children}, {"Amanda::Devicec::write_random_to_device", _wrap_write_random_to_device}, @@ -4777,232 +4846,232 @@ XS(SWIG_init) { SWIG_TypeClientData(SWIGTYPE_p_DirectTCPConnection, (void*) "Amanda::Device::DirectTCPConnection"); SWIG_TypeClientData(SWIGTYPE_p_Device, (void*) "Amanda::Device::Device"); - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ACCESS_NULL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ACCESS_NULL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ACCESS_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ACCESS_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ACCESS_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ACCESS_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "ACCESS_APPEND", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(ACCESS_APPEND))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_STATUS_SUCCESS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_STATUS_SUCCESS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_STATUS_DEVICE_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_STATUS_DEVICE_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_STATUS_DEVICE_BUSY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_STATUS_DEVICE_BUSY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_STATUS_VOLUME_MISSING", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_STATUS_VOLUME_MISSING))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_STATUS_VOLUME_UNLABELED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_STATUS_VOLUME_UNLABELED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_STATUS_VOLUME_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_STATUS_VOLUME_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "DEVICE_STATUS_FLAGS_MAX", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(DEVICE_STATUS_FLAGS_MAX))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_BEFORE_START", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_BEFORE_START))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_BETWEEN_FILE_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_BETWEEN_FILE_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_INSIDE_FILE_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_INSIDE_FILE_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_BETWEEN_FILE_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_BETWEEN_FILE_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_INSIDE_FILE_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_INSIDE_FILE_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_MAX", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_MAX))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_MASK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_MASK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_PHASE_SHIFT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_PHASE_SHIFT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_GET_BEFORE_START", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_GET_BEFORE_START))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_GET_BETWEEN_FILE_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_GET_BETWEEN_FILE_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_GET_INSIDE_FILE_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_GET_INSIDE_FILE_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_GET_BETWEEN_FILE_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_GET_BETWEEN_FILE_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_GET_INSIDE_FILE_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_GET_INSIDE_FILE_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_SET_BEFORE_START", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_SET_BEFORE_START))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_SET_BETWEEN_FILE_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_SET_BETWEEN_FILE_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_SET_INSIDE_FILE_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_SET_INSIDE_FILE_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_SET_BETWEEN_FILE_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_SET_BETWEEN_FILE_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_SET_INSIDE_FILE_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_SET_INSIDE_FILE_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_GET_MASK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_GET_MASK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_ACCESS_SET_MASK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_ACCESS_SET_MASK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONCURRENCY_PARADIGM_EXCLUSIVE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONCURRENCY_PARADIGM_EXCLUSIVE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONCURRENCY_PARADIGM_SHARED_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONCURRENCY_PARADIGM_SHARED_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONCURRENCY_PARADIGM_RANDOM_ACCESS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONCURRENCY_PARADIGM_RANDOM_ACCESS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "STREAMING_REQUIREMENT_NONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(STREAMING_REQUIREMENT_NONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "STREAMING_REQUIREMENT_DESIRED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(STREAMING_REQUIREMENT_DESIRED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "STREAMING_REQUIREMENT_REQUIRED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(STREAMING_REQUIREMENT_REQUIRED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "MEDIA_ACCESS_MODE_READ_ONLY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(MEDIA_ACCESS_MODE_READ_ONLY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "MEDIA_ACCESS_MODE_WORM", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(MEDIA_ACCESS_MODE_WORM))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "MEDIA_ACCESS_MODE_READ_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(MEDIA_ACCESS_MODE_READ_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "MEDIA_ACCESS_MODE_WRITE_ONLY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(MEDIA_ACCESS_MODE_WRITE_ONLY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_SURETY_BAD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_SURETY_BAD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_SURETY_GOOD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_SURETY_GOOD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_SOURCE_DEFAULT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_SOURCE_DEFAULT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_SOURCE_DETECTED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_SOURCE_DETECTED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "PROPERTY_SOURCE_USER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(PROPERTY_SOURCE_USER))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Device.pm b/perl/Amanda/Device.pm index 17caeec..cdd0af6 100644 --- a/perl/Amanda/Device.pm +++ b/perl/Amanda/Device.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. @@ -158,6 +158,7 @@ sub DESTROY { *min_block_size = *Amanda::Devicec::Device_min_block_size; *max_block_size = *Amanda::Devicec::Device_max_block_size; *block_size = *Amanda::Devicec::Device_block_size; +*header_block_size = *Amanda::Devicec::Device_header_block_size; *volume_header = *Amanda::Devicec::Device_volume_header; sub DISOWN { my $self = shift; diff --git a/perl/Amanda/Device.swg b/perl/Amanda/Device.swg index e661934..d400316 100644 --- a/perl/Amanda/Device.swg +++ b/perl/Amanda/Device.swg @@ -503,15 +503,16 @@ typedef struct Device { memset(&gval, 0, sizeof(gval)); g_value_init(&gval, pbase->type); if (!set_gvalue_from_sv(sv, &gval)) - goto fail; + goto failunset; if (!device_property_set(self, pbase->ID, &gval)) - goto fail; + goto failunset; g_value_unset(&gval); return TRUE; - fail: + failunset: g_value_unset(&gval); + fail: return FALSE; } @@ -553,6 +554,7 @@ typedef struct Device { gsize min_block_size(void) { return self->min_block_size; } gsize max_block_size(void) { return self->max_block_size; } gsize block_size(void) { return self->block_size; } + gsize header_block_size(void) { return self->header_block_size; } dumpfile_t *volume_header(void) { return self->volume_header; } }; diff --git a/perl/Amanda/Disklist.c b/perl/Amanda/Disklist.c index 6999799..0a9874b 100644 --- a/perl/Amanda/Disklist.c +++ b/perl/Amanda/Disklist.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1478,15 +1507,16 @@ SWIG_Perl_SetModule(swig_module_info *module) { /* -------- TYPES TABLE (BEGIN) -------- */ #define SWIGTYPE_p_HV swig_types[0] -#define SWIGTYPE_p_char swig_types[1] -#define SWIGTYPE_p_double swig_types[2] -#define SWIGTYPE_p_dumptype_t swig_types[3] -#define SWIGTYPE_p_float swig_types[4] -#define SWIGTYPE_p_int swig_types[5] -#define SWIGTYPE_p_interface_t swig_types[6] -#define SWIGTYPE_p_unsigned_char swig_types[7] -static swig_type_info *swig_types[9]; -static swig_module_info swig_module = {swig_types, 8, 0, 0, 0, 0}; +#define SWIGTYPE_p_am_feature_t swig_types[1] +#define SWIGTYPE_p_char swig_types[2] +#define SWIGTYPE_p_double swig_types[3] +#define SWIGTYPE_p_dumptype_t swig_types[4] +#define SWIGTYPE_p_float swig_types[5] +#define SWIGTYPE_p_int swig_types[6] +#define SWIGTYPE_p_interface_t swig_types[7] +#define SWIGTYPE_p_unsigned_char swig_types[8] +static swig_type_info *swig_types[10]; +static swig_module_info swig_module = {swig_types, 9, 0, 0, 0, 0}; #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name) #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name) @@ -1497,7 +1527,7 @@ static swig_module_info swig_module = {swig_types, 8, 0, 0, 0, 0}; #define SWIG_name "Amanda::Disklistc::boot_Amanda__Disklist" #define SWIG_prefix "Amanda::Disklistc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1772,6 +1802,26 @@ SWIG_AsCharPtrAndSize(SV *obj, char** cptr, size_t* psize, int *alloc) + +SWIGINTERNINLINE SV * +SWIG_FromCharPtrAndSize(const char* carray, size_t size) +{ + SV *obj = sv_newmortal(); + if (carray) { + sv_setpvn(obj, carray, size); + } else { + sv_setsv(obj, &PL_sv_undef); + } + return obj; +} + + +SWIGINTERNINLINE SV * +SWIG_FromCharPtr(const char *cptr) +{ + return SWIG_FromCharPtrAndSize(cptr, (cptr ? strlen(cptr) : 0)); +} + #ifdef __cplusplus extern "C" { #endif @@ -1900,10 +1950,50 @@ XS(_wrap_read_disklist_internal) { } +XS(_wrap_clean_dle_str_for_client) { + { + char *arg1 = (char *) 0 ; + am_feature_t *arg2 = (am_feature_t *) 0 ; + int res1 ; + char *buf1 = 0 ; + int alloc1 = 0 ; + void *argp2 = 0 ; + int res2 = 0 ; + int argvi = 0; + char *result = 0 ; + dXSARGS; + + if ((items < 2) || (items > 2)) { + SWIG_croak("Usage: clean_dle_str_for_client(dle_str,their_features);"); + } + res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "clean_dle_str_for_client" "', argument " "1"" of type '" "char *""'"); + } + arg1 = (char *)(buf1); + res2 = SWIG_ConvertPtr(ST(1), &argp2,SWIGTYPE_p_am_feature_t, 0 | 0 ); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "clean_dle_str_for_client" "', argument " "2"" of type '" "am_feature_t *""'"); + } + arg2 = (am_feature_t *)(argp2); + result = (char *)clean_dle_str_for_client(arg1,arg2); + ST(argvi) = SWIG_FromCharPtr((const char *)result); argvi++ ; + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + + XSRETURN(argvi); + fail: + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + + SWIG_croak_null(); + } +} + + /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */ static swig_type_info _swigt__p_HV = {"_p_HV", "HV *", 0, 0, (void*)0, 0}; +static swig_type_info _swigt__p_am_feature_t = {"_p_am_feature_t", "am_feature_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_char = {"_p_char", "gchar *|char *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_double = {"_p_double", "double *|gdouble *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_dumptype_t = {"_p_dumptype_t", "dumptype_t *", 0, 0, (void*)0, 0}; @@ -1914,6 +2004,7 @@ static swig_type_info _swigt__p_unsigned_char = {"_p_unsigned_char", "guchar *|u static swig_type_info *swig_type_initial[] = { &_swigt__p_HV, + &_swigt__p_am_feature_t, &_swigt__p_char, &_swigt__p_double, &_swigt__p_dumptype_t, @@ -1924,6 +2015,7 @@ static swig_type_info *swig_type_initial[] = { }; static swig_cast_info _swigc__p_HV[] = { {&_swigt__p_HV, 0, 0, 0},{0, 0, 0, 0}}; +static swig_cast_info _swigc__p_am_feature_t[] = { {&_swigt__p_am_feature_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_double[] = { {&_swigt__p_double, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_dumptype_t[] = { {&_swigt__p_dumptype_t, 0, 0, 0},{0, 0, 0, 0}}; @@ -1934,6 +2026,7 @@ static swig_cast_info _swigc__p_unsigned_char[] = { {&_swigt__p_unsigned_char, static swig_cast_info *swig_cast_initial[] = { _swigc__p_HV, + _swigc__p_am_feature_t, _swigc__p_char, _swigc__p_double, _swigc__p_dumptype_t, @@ -1957,6 +2050,7 @@ static swig_variable_info swig_variables[] = { }; static swig_command_info swig_commands[] = { {"Amanda::Disklistc::read_disklist_internal", _wrap_read_disklist_internal}, +{"Amanda::Disklistc::clean_dle_str_for_client", _wrap_clean_dle_str_for_client}, {0,0} }; /* ----------------------------------------------------------------------------- diff --git a/perl/Amanda/Disklist.pm b/perl/Amanda/Disklist.pm index f61b4df..e7aa99c 100644 --- a/perl/Amanda/Disklist.pm +++ b/perl/Amanda/Disklist.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. @@ -51,6 +51,7 @@ sub this { package Amanda::Disklist; *read_disklist_internal = *Amanda::Disklistc::read_disklist_internal; +*clean_dle_str_for_client = *Amanda::Disklistc::clean_dle_str_for_client; # ------- VARIABLE STUBS -------- diff --git a/perl/Amanda/Disklist.swg b/perl/Amanda/Disklist.swg index 50c842a..9a6eb57 100644 --- a/perl/Amanda/Disklist.swg +++ b/perl/Amanda/Disklist.swg @@ -316,3 +316,4 @@ push @EXPORT_OK, qw( read_disklist get_interface all_interfaces); %} +char *clean_dle_str_for_client(char *dle_str, am_feature_t *their_features); diff --git a/perl/Amanda/Feature.c b/perl/Amanda/Feature.c index 9b90e8f..6ad571a 100644 --- a/perl/Amanda/Feature.c +++ b/perl/Amanda/Feature.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1479,13 +1508,14 @@ SWIG_Perl_SetModule(swig_module_info *module) { #define SWIGTYPE_p_Set swig_types[0] #define SWIGTYPE_p_am_feature_e swig_types[1] -#define SWIGTYPE_p_char swig_types[2] -#define SWIGTYPE_p_double swig_types[3] -#define SWIGTYPE_p_float swig_types[4] -#define SWIGTYPE_p_int swig_types[5] -#define SWIGTYPE_p_unsigned_char swig_types[6] -static swig_type_info *swig_types[8]; -static swig_module_info swig_module = {swig_types, 7, 0, 0, 0, 0}; +#define SWIGTYPE_p_am_feature_t swig_types[2] +#define SWIGTYPE_p_char swig_types[3] +#define SWIGTYPE_p_double swig_types[4] +#define SWIGTYPE_p_float swig_types[5] +#define SWIGTYPE_p_int swig_types[6] +#define SWIGTYPE_p_unsigned_char swig_types[7] +static swig_type_info *swig_types[9]; +static swig_module_info swig_module = {swig_types, 8, 0, 0, 0, 0}; #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name) #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name) @@ -1496,7 +1526,7 @@ static swig_module_info swig_module = {swig_types, 7, 0, 0, 0, 0}; #define SWIG_name "Amanda::Featurec::boot_Amanda__Feature" #define SWIG_prefix "Amanda::Featurec::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1575,7 +1605,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -2072,11 +2104,40 @@ XS(_wrap_am_init_feature_set) { } +XS(_wrap_am_features) { + { + Set *arg1 = (Set *) 0 ; + void *argp1 = 0 ; + int res1 = 0 ; + int argvi = 0; + am_feature_t *result = 0 ; + dXSARGS; + + if ((items < 1) || (items > 1)) { + SWIG_croak("Usage: am_features(Set *);"); + } + res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_Set, 0 | 0 ); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "am_features" "', argument " "1"" of type '" "Set *""'"); + } + arg1 = (Set *)(argp1); + result = (am_feature_t *)am_features(arg1); + ST(argvi) = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_am_feature_t, 0 | 0); argvi++ ; + + XSRETURN(argvi); + fail: + + SWIG_croak_null(); + } +} + + /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */ static swig_type_info _swigt__p_Set = {"_p_Set", "Set *", 0, 0, (void*)"Amanda::Feature::Set", 0}; static swig_type_info _swigt__p_am_feature_e = {"_p_am_feature_e", "enum am_feature_e *|am_feature_e *", 0, 0, (void*)0, 0}; +static swig_type_info _swigt__p_am_feature_t = {"_p_am_feature_t", "am_feature_t *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_char = {"_p_char", "gchar *|char *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_double = {"_p_double", "double *|gdouble *", 0, 0, (void*)0, 0}; static swig_type_info _swigt__p_float = {"_p_float", "float *|gfloat *", 0, 0, (void*)0, 0}; @@ -2086,6 +2147,7 @@ static swig_type_info _swigt__p_unsigned_char = {"_p_unsigned_char", "guchar *|u static swig_type_info *swig_type_initial[] = { &_swigt__p_Set, &_swigt__p_am_feature_e, + &_swigt__p_am_feature_t, &_swigt__p_char, &_swigt__p_double, &_swigt__p_float, @@ -2095,6 +2157,7 @@ static swig_type_info *swig_type_initial[] = { static swig_cast_info _swigc__p_Set[] = { {&_swigt__p_Set, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_am_feature_e[] = { {&_swigt__p_am_feature_e, 0, 0, 0},{0, 0, 0, 0}}; +static swig_cast_info _swigc__p_am_feature_t[] = { {&_swigt__p_am_feature_t, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_char[] = { {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_double[] = { {&_swigt__p_double, 0, 0, 0},{0, 0, 0, 0}}; static swig_cast_info _swigc__p_float[] = { {&_swigt__p_float, 0, 0, 0},{0, 0, 0, 0}}; @@ -2104,6 +2167,7 @@ static swig_cast_info _swigc__p_unsigned_char[] = { {&_swigt__p_unsigned_char, static swig_cast_info *swig_cast_initial[] = { _swigc__p_Set, _swigc__p_am_feature_e, + _swigc__p_am_feature_t, _swigc__p_char, _swigc__p_double, _swigc__p_float, @@ -2133,6 +2197,7 @@ static swig_command_info swig_commands[] = { {"Amanda::Featurec::am_string_to_feature", _wrap_am_string_to_feature}, {"Amanda::Featurec::am_set_default_feature_set", _wrap_am_set_default_feature_set}, {"Amanda::Featurec::am_init_feature_set", _wrap_am_init_feature_set}, +{"Amanda::Featurec::am_features", _wrap_am_features}, {0,0} }; /* ----------------------------------------------------------------------------- @@ -2427,507 +2492,512 @@ XS(SWIG_init) { SvREADONLY_on(sv); } - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "have_feature_support", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(have_feature_support))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_auth", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_auth))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_selfcheck_req", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_selfcheck_req))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_selfcheck_req_device", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_selfcheck_req_device))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_selfcheck_rep", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_selfcheck_rep))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendsize_req_no_options", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendsize_req_no_options))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendsize_req_options", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendsize_req_options))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendsize_req_device", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendsize_req_device))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendsize_rep", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendsize_rep))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendbackup_req", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendbackup_req))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendbackup_req_device", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendbackup_req_device))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendbackup_rep", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendbackup_rep))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_noop_req", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_noop_req))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_noop_rep", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_noop_rep))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_program_dump", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_program_dump))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_program_gnutar", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_program_gnutar))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_program_application_api", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_program_application_api))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_compress_fast", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_compress_fast))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_compress_best", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_compress_best))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_srvcomp_fast", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_srvcomp_fast))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_srvcomp_best", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_srvcomp_best))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_no_record", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_no_record))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_index", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_index))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_exclude_file", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_exclude_file))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_exclude_list", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_exclude_list))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_multiple_exclude", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_multiple_exclude))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_optional_exclude", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_optional_exclude))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_include_file", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_include_file))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_include_list", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_include_list))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_multiple_include", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_multiple_include))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_optional_include", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_optional_include))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_bsd_auth", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_bsd_auth))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_krb4_auth", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_krb4_auth))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_kencrypt", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_kencrypt))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_req_options_maxdumps", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_req_options_maxdumps))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_req_options_hostname", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_req_options_hostname))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_req_options_features", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_req_options_features))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_rep_options_maxdumps", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_rep_options_maxdumps))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_rep_options_hostname", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_rep_options_hostname))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_rep_options_features", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_rep_options_features))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_rep_options_sendbackup_options", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_rep_options_sendbackup_options))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_fileno_in_OLSD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_fileno_in_OLSD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_fileno_in_ORLD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_fileno_in_ORLD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_fsf", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_fsf))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_label", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_label))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_device", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_device))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_host", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_host))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_disk", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_disk))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_datestamp", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_datestamp))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_header", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_header))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_nargs", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_nargs))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_config", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_config))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_partial_estimate", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_partial_estimate))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_calcsize_estimate", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_calcsize_estimate))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_selfcheck_calcsize", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_selfcheck_calcsize))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_recover_splits", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_recover_splits))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_exchange_features", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_exchange_features))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_compress_cust", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_compress_cust))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_srvcomp_cust", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_srvcomp_cust))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_encrypt_cust", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_encrypt_cust))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_encrypt_serv_cust", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_encrypt_serv_cust))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_client_decrypt_option", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_client_decrypt_option))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_options_server_decrypt_option", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_options_server_decrypt_option))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_marshall_in_OLSD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_marshall_in_OLSD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_marshall_in_ORLD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_marshall_in_ORLD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_marshall_in_DHST", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_marshall_in_DHST))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_FEEDME", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_FEEDME))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_timestamp", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_timestamp))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_interface_quoted_text", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_interface_quoted_text))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_program_star", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_program_star))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_options_hostname", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_options_hostname))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_options_features", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_options_features))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_options_auth", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_options_auth))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_options_hostname", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_options_hostname))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_options_features", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_options_features))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_options_auth", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_options_auth))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_message", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_message))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_feedme_tape", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_feedme_tape))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_req_options_config", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_req_options_config))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_rep_sendsize_quoted_error", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_rep_sendsize_quoted_error))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_req_xml", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_req_xml))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_pp_script", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_pp_script))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_DLE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_DLE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_dle_in_header", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_dle_in_header))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_xml_estimate", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_xml_estimate))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_xml_property_priority", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_xml_property_priority))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendsize_rep_warning", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendsize_rep_warning))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_xml_estimatelist", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_xml_estimatelist))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_xml_level_server", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_xml_level_server))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_xml_data_path", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_xml_data_path))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_xml_directtcp_list", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_xml_directtcp_list))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_datapath", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_datapath))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_sendbackup_noop", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_sendbackup_noop))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_origsize_in_header", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_origsize_in_header))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amidxtaped_abort", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amidxtaped_abort))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_correct_disk_quoting", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_correct_disk_quoting))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amindexd_quote_label", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amindexd_quote_label))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_amrecover_receive_unfiltered", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_amrecover_receive_unfiltered))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_application_client_name", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_application_client_name))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "fe_script_client_name", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_script_client_name))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { + SV *sv = get_sv((char*) SWIG_prefix "fe_dumptype_property", TRUE | 0x2 | GV_ADDMULTI); + sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(fe_dumptype_property))); + SvREADONLY_on(sv); + } while(0) /*@SWIG@*/; + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "last_feature", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(last_feature))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Feature.pm b/perl/Amanda/Feature.pm index 7e2fb8c..1e0645f 100644 --- a/perl/Amanda/Feature.pm +++ b/perl/Amanda/Feature.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. @@ -52,6 +52,7 @@ package Amanda::Feature; *am_string_to_feature = *Amanda::Featurec::am_string_to_feature; *am_set_default_feature_set = *Amanda::Featurec::am_set_default_feature_set; *am_init_feature_set = *Amanda::Featurec::am_init_feature_set; +*am_features = *Amanda::Featurec::am_features; ############# Class : Amanda::Feature::Set ############## @@ -198,6 +199,7 @@ package Amanda::Feature; *fe_amrecover_receive_unfiltered = *Amanda::Featurec::fe_amrecover_receive_unfiltered; *fe_application_client_name = *Amanda::Featurec::fe_application_client_name; *fe_script_client_name = *Amanda::Featurec::fe_script_client_name; +*fe_dumptype_property = *Amanda::Featurec::fe_dumptype_property; *last_feature = *Amanda::Featurec::last_feature; @EXPORT_OK = (); @@ -425,6 +427,18 @@ If set, amindexd quote the label (holdingdisk filename) If set, amidxtaped do not decompress/decrypt client compressed/decrypted stream. +=item fe_application_client_name + +If set, add the 'client_name' for application in the xml code. + +=item fe_script_client_name + +If set, add the 'client_name' for script in the xml code. + +=item fe_dumptype_property + +If set, add the dumptype property in the xml code. + =back =cut @@ -453,6 +467,12 @@ sub Amanda::Feature::Set::mine { return Amanda::Feature::am_init_feature_set(); } +sub Amanda::Feature::Set::features { + my $class = shift; + return Amanmda::Feature::features(); +} + + package Amanda::Feature; 1; diff --git a/perl/Amanda/Feature.pod b/perl/Amanda/Feature.pod index 0d88739..7a6019d 100644 --- a/perl/Amanda/Feature.pod +++ b/perl/Amanda/Feature.pod @@ -241,6 +241,18 @@ If set, amindexd quote the label (holdingdisk filename) If set, amidxtaped do not decompress/decrypt client compressed/decrypted stream. +=item fe_application_client_name + +If set, add the 'client_name' for application in the xml code. + +=item fe_script_client_name + +If set, add the 'client_name' for script in the xml code. + +=item fe_dumptype_property + +If set, add the dumptype property in the xml code. + =back =cut diff --git a/perl/Amanda/Feature.swg b/perl/Amanda/Feature.swg index e20e4b6..a66f39a 100644 --- a/perl/Amanda/Feature.swg +++ b/perl/Amanda/Feature.swg @@ -63,7 +63,9 @@ extern Set *am_string_to_feature(char *s); %newobject am_set_default_feature_set; extern Set *am_set_default_feature_set(void); %newobject am_init_feature_set; -extern Set *am_init_feature_set(void); +extern Set *am_init_feature_set(); +%newobject features; +extern am_feature_t *am_features(Set *); %perlcode %{ @@ -89,6 +91,12 @@ sub Amanda::Feature::Set::mine { return Amanda::Feature::am_init_feature_set(); } +sub Amanda::Feature::Set::features { + my $class = shift; + return Amanmda::Feature::features(); +} + + package Amanda::Feature; %} diff --git a/perl/Amanda/Header.c b/perl/Amanda/Header.c index 06c84ec..25b2bc5 100644 --- a/perl/Amanda/Header.c +++ b/perl/Amanda/Header.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1506,7 +1535,7 @@ static swig_module_info swig_module = {swig_types, 17, 0, 0, 0, 0}; #define SWIG_name "Amanda::Headerc::boot_Amanda__Header" #define SWIG_prefix "Amanda::Headerc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1579,7 +1608,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -7032,42 +7063,42 @@ XS(SWIG_init) { SvREADONLY_on(sv); } - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_UNKNOWN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_UNKNOWN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_WEIRD", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_WEIRD))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_TAPESTART", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_TAPESTART))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_TAPEEND", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_TAPEEND))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_DUMPFILE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_DUMPFILE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_CONT_DUMPFILE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_CONT_DUMPFILE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_SPLIT_DUMPFILE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_SPLIT_DUMPFILE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "F_EMPTY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(F_EMPTY))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Header.pm b/perl/Amanda/Header.pm index f569ae6..d8cc692 100644 --- a/perl/Amanda/Header.pm +++ b/perl/Amanda/Header.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Holding.pm b/perl/Amanda/Holding.pm index b397cce..a0108fc 100644 --- a/perl/Amanda/Holding.pm +++ b/perl/Amanda/Holding.pm @@ -197,29 +197,43 @@ sub _is_datestr { } sub _walk { - my ($file_fn) = @_; + my ($file_fn, $verbose) = @_; # walk disks, directories, and files with nested loops for my $disk (disks()) { my $diskh = IO::Dir->new($disk); - next unless defined $diskh; + if (!defined $diskh) { + print $verbose "could not open holding dir '$disk': $!\n" if $verbose; + next; + } while (defined(my $datestr = $diskh->read())) { - next unless (_is_datestr($datestr)); + next if $datestr eq '.' or $datestr eq '..'; + + my $dirfn = File::Spec->catfile($disk, $datestr); + + if (!_is_datestr($datestr)) { + print $verbose "holding dir '$dirfn' is not a datestamp\n" if $verbose; + next; + } + if (!-d $dirfn) { + print $verbose "holding dir '$dirfn' is not a directory\n" if $verbose; + next; + } - my $dirh = IO::Dir->new(File::Spec->catfile($disk, $datestr)); + my $dirh = IO::Dir->new($dirfn); while (defined(my $dirent = $dirh->read)) { next if $dirent eq '.' or $dirent eq '..'; my $filename = File::Spec->catfile($disk, $datestr, $dirent); - next unless -f $filename; + if (!-f $filename) { + print $verbose "holding file '$filename' is not a file\n" if $verbose; + next; + } my $hdr = get_header($filename); next unless defined($hdr); - # ignore chunks and anything bogus - next if ($hdr->{'type'} != $Amanda::Header::F_DUMPFILE); - $file_fn->($filename, $hdr); } } @@ -246,17 +260,78 @@ sub disks { } sub files { + my $verbose = shift; my @results; my $each_file_fn = sub { my ($filename, $header) = @_; + return if $header->{'type'} != $Amanda::Header::F_DUMPFILE; + push @results, $filename; }; - _walk($each_file_fn); + _walk($each_file_fn, $verbose); return @results; } +sub all_files { + my $verbose = shift; + my @results; + + my $each_file_fn = sub { + my ($filename, $header) = @_; + push @results, { filename => $filename, header => $header }; + }; + _walk($each_file_fn, $verbose); + + return @results; +} + +sub merge_all_files { + my @files = @_; + my %hfiles; + my @result; + + for my $file (@files) { + $hfiles{$file->{'filename'}} = $file->{'header'}; + } + + foreach my $filename (keys %hfiles) { + next if !exists $hfiles{$filename}; + if ($hfiles{$filename}->{'type'} == $Amanda::Header::F_DUMPFILE) { + push @result, {filename => $filename, header => $hfiles{$filename}}; + my $is_tmp = ($filename =~ /\.tmp$/); + my $cont_filename = $filename; + my $cfilename = $hfiles{$cont_filename}->{'cont_filename'}; + my $cf = $cfilename; + $cf .= ".tmp" if $is_tmp; + while (defined $cfilename && $cfilename ne "" && -f $cf) { + delete $hfiles{$cont_filename}; + $cont_filename = $cf; + $cfilename = $hfiles{$cont_filename}->{'cont_filename'}; + $cf = $cfilename; + $cf .= ".tmp" if $is_tmp; + } + delete $hfiles{$cont_filename}; + } elsif ($hfiles{$filename}->{'type'} != $Amanda::Header::F_CONT_DUMPFILE) { + push @result, {filename => $filename, header => $hfiles{$filename}}; + delete $hfiles{$filename} + } else { + # do nothing for F_CONTFILE + } + } + + foreach my $filename (keys %hfiles) { + next if !exists $hfiles{$filename}; + if ($hfiles{$filename}->{'type'} == $Amanda::Header::F_CONT_DUMPFILE) { + push @result, {filename => $filename, header => $hfiles{$filename}}; + } else { + delete $hfiles{$filename} + } + } + return @result; +} + sub file_chunks { my ($filename) = @_; my @results; @@ -279,6 +354,47 @@ sub file_chunks { return @results; } +sub file_tmp_chunks { + my ($filename) = @_; + my @results; + + while (1) { + last unless -f $filename; + my $hdr = get_header($filename); + last unless defined($hdr); + + push @results, $filename; + + if ($hdr->{'cont_filename'}) { + $filename = $hdr->{'cont_filename'} . ".tmp"; + } else { + # no continuation -> we're done + last; + } + } + + return @results; +} + +sub rename_tmp { + my ($filename) = shift; + my ($complete) = shift; + + my @files = file_tmp_chunks($filename); + while (my $tmp_filename = pop @files) { + my $hdr = get_header($tmp_filename); + if ($hdr->{'is_partial'} == 0 and $complete == 0) { + $hdr->{'is_partial'} = 1; + write_header($tmp_filename, $hdr); + } + my $hfilename = $tmp_filename; + $hfilename =~ s/\.tmp$//; + rename $tmp_filename, $hfilename; + } + + return +} + sub get_header { my ($filename) = @_; return unless -f $filename; @@ -288,13 +404,31 @@ sub get_header { my $hdr_bytes = Amanda::Util::full_read($fd, DISK_BLOCK_BYTES); POSIX::close($fd); - if (length($hdr_bytes) < DISK_BLOCK_BYTES) { - return; + if (length($hdr_bytes) == 0) { + my $hdr = Amanda::Header->new(); + $hdr->{'type'} = $Amanda::Header::F_EMPTY; + return $hdr; + } elsif (length($hdr_bytes) < DISK_BLOCK_BYTES) { + my $hdr = Amanda::Header->new(); + $hdr->{'type'} = $Amanda::Header::F_UNKNOWN; + return $hdr; } return Amanda::Header->from_string($hdr_bytes); } +sub write_header { + my $filename = shift; + my $hdr = shift; + + return unless -f $filename; + my $fd = POSIX::open($filename, O_RDWR); + return unless $fd; + my $header = $hdr->to_string(DISK_BLOCK_BYTES, DISK_BLOCK_BYTES); + Amanda::Util::full_write($fd, $header, DISK_BLOCK_BYTES); + POSIX::close($fd); +} + sub file_unlink { my ($filename) = @_; @@ -305,6 +439,33 @@ sub file_unlink { return 1; } +sub filetmp_unlink { + my ($filename) = @_; + + for my $chunk (filetmp_chunks($filename)) { + unlink($chunk) or return 0; + } + + return 1; +} + +sub dir_unlink { + # walk disks, directories, and files with nested loops + for my $disk (disks()) { + my $diskh = IO::Dir->new($disk); + next unless defined $diskh; + + while (defined(my $datestr = $diskh->read())) { + next if $datestr eq '.' or $datestr eq '..'; + + my $dirfn = File::Spec->catfile($disk, $datestr); + next unless _is_datestr($datestr); + next unless -d $dirfn; + rmdir $dirfn; + } + } +} + sub file_size { my ($filename, $ignore_headers) = @_; my $total = Math::BigInt->new(0); @@ -327,6 +488,8 @@ sub get_files_for_flush { my $each_file_fn = sub { my ($filename, $header) = @_; + return if $header->{'type'} != $Amanda::Header::F_DUMPFILE; + if (@dateargs && !grep { $_ eq $header->{'datestamp'}; } @dateargs) { return; } @@ -337,7 +500,7 @@ sub get_files_for_flush { push @results, $filename; }; - _walk($each_file_fn); + _walk($each_file_fn, 0); return sort @results; } @@ -347,9 +510,11 @@ sub get_all_datestamps { my $each_file_fn = sub { my ($filename, $header) = @_; + return if $header->{'type'} != $Amanda::Header::F_DUMPFILE; + $datestamps{$header->{'datestamp'}} = 1; }; - _walk($each_file_fn); + _walk($each_file_fn, 0); return sort keys %datestamps; } diff --git a/perl/Amanda/IPC/Binary.c b/perl/Amanda/IPC/Binary.c index 65ae4ac..5739c47 100644 --- a/perl/Amanda/IPC/Binary.c +++ b/perl/Amanda/IPC/Binary.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1501,7 +1530,7 @@ static swig_module_info swig_module = {swig_types, 12, 0, 0, 0, 0}; #define SWIG_name "Amanda::IPC::Binaryc::boot_Amanda__IPC__Binary" #define SWIG_prefix "Amanda::IPC::Binaryc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1575,7 +1604,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -2677,12 +2708,12 @@ XS(SWIG_init) { SvREADONLY_on(sv); } - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "IPC_BINARY_STRING", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(IPC_BINARY_STRING))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "IPC_BINARY_OPTIONAL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(IPC_BINARY_OPTIONAL))); SvREADONLY_on(sv); diff --git a/perl/Amanda/IPC/Binary.pm b/perl/Amanda/IPC/Binary.pm index 480ef9d..ef3d4da 100644 --- a/perl/Amanda/IPC/Binary.pm +++ b/perl/Amanda/IPC/Binary.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Logfile.c b/perl/Amanda/Logfile.c index 44bb2ab..7c39763 100644 --- a/perl/Amanda/Logfile.c +++ b/perl/Amanda/Logfile.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1499,7 +1528,7 @@ static swig_module_info swig_module = {swig_types, 10, 0, 0, 0, 0}; #define SWIG_name "Amanda::Logfilec::boot_Amanda__Logfile" #define SWIG_prefix "Amanda::Logfilec::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1663,7 +1692,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -3059,190 +3090,6 @@ XS(_wrap_dumps_match_dumpspecs) { } -XS(_wrap_match_host) { - { - char *arg1 = (char *) 0 ; - char *arg2 = (char *) 0 ; - int res1 ; - char *buf1 = 0 ; - int alloc1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int argvi = 0; - gboolean result; - dXSARGS; - - if ((items < 2) || (items > 2)) { - SWIG_croak("Usage: match_host(pat,value);"); - } - res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_host" "', argument " "1"" of type '" "char *""'"); - } - arg1 = (char *)(buf1); - res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_host" "', argument " "2"" of type '" "char *""'"); - } - arg2 = (char *)(buf2); - result = (gboolean)match_host(arg1,arg2); - { - if (result) - ST(argvi) = &PL_sv_yes; - else - ST(argvi) = &PL_sv_no; - argvi++; - } - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - XSRETURN(argvi); - fail: - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - SWIG_croak_null(); - } -} - - -XS(_wrap_match_disk) { - { - char *arg1 = (char *) 0 ; - char *arg2 = (char *) 0 ; - int res1 ; - char *buf1 = 0 ; - int alloc1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int argvi = 0; - gboolean result; - dXSARGS; - - if ((items < 2) || (items > 2)) { - SWIG_croak("Usage: match_disk(pat,value);"); - } - res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_disk" "', argument " "1"" of type '" "char *""'"); - } - arg1 = (char *)(buf1); - res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_disk" "', argument " "2"" of type '" "char *""'"); - } - arg2 = (char *)(buf2); - result = (gboolean)match_disk(arg1,arg2); - { - if (result) - ST(argvi) = &PL_sv_yes; - else - ST(argvi) = &PL_sv_no; - argvi++; - } - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - XSRETURN(argvi); - fail: - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - SWIG_croak_null(); - } -} - - -XS(_wrap_match_datestamp) { - { - char *arg1 = (char *) 0 ; - char *arg2 = (char *) 0 ; - int res1 ; - char *buf1 = 0 ; - int alloc1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int argvi = 0; - gboolean result; - dXSARGS; - - if ((items < 2) || (items > 2)) { - SWIG_croak("Usage: match_datestamp(pat,value);"); - } - res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_datestamp" "', argument " "1"" of type '" "char *""'"); - } - arg1 = (char *)(buf1); - res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_datestamp" "', argument " "2"" of type '" "char *""'"); - } - arg2 = (char *)(buf2); - result = (gboolean)match_datestamp(arg1,arg2); - { - if (result) - ST(argvi) = &PL_sv_yes; - else - ST(argvi) = &PL_sv_no; - argvi++; - } - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - XSRETURN(argvi); - fail: - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - SWIG_croak_null(); - } -} - - -XS(_wrap_match_level) { - { - char *arg1 = (char *) 0 ; - char *arg2 = (char *) 0 ; - int res1 ; - char *buf1 = 0 ; - int alloc1 = 0 ; - int res2 ; - char *buf2 = 0 ; - int alloc2 = 0 ; - int argvi = 0; - gboolean result; - dXSARGS; - - if ((items < 2) || (items > 2)) { - SWIG_croak("Usage: match_level(pat,value);"); - } - res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); - if (!SWIG_IsOK(res1)) { - SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_level" "', argument " "1"" of type '" "char *""'"); - } - arg1 = (char *)(buf1); - res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); - if (!SWIG_IsOK(res2)) { - SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_level" "', argument " "2"" of type '" "char *""'"); - } - arg2 = (char *)(buf2); - result = (gboolean)match_level(arg1,arg2); - { - if (result) - ST(argvi) = &PL_sv_yes; - else - ST(argvi) = &PL_sv_no; - argvi++; - } - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - XSRETURN(argvi); - fail: - if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); - if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); - SWIG_croak_null(); - } -} - - /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */ @@ -3337,10 +3184,6 @@ static swig_command_info swig_commands[] = { {"Amanda::Logfilec::search_holding_disk", _wrap_search_holding_disk}, {"Amanda::Logfilec::dumps_match", _wrap_dumps_match}, {"Amanda::Logfilec::dumps_match_dumpspecs", _wrap_dumps_match_dumpspecs}, -{"Amanda::Logfilec::match_host", _wrap_match_host}, -{"Amanda::Logfilec::match_disk", _wrap_match_disk}, -{"Amanda::Logfilec::match_datestamp", _wrap_match_datestamp}, -{"Amanda::Logfilec::match_level", _wrap_match_level}, {0,0} }; /* ----------------------------------------------------------------------------- @@ -3635,172 +3478,172 @@ XS(SWIG_init) { SvREADONLY_on(sv); } - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_BOGUS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_BOGUS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_FATAL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_FATAL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_WARNING", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_WARNING))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_INFO", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_INFO))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_SUMMARY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_SUMMARY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_START", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_START))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_FINISH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_FINISH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_DISK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_DISK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_DONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_DONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_PART", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_PART))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_PARTPARTIAL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_PARTPARTIAL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_SUCCESS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_SUCCESS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_PARTIAL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_PARTIAL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_FAIL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_FAIL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_STRANGE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_STRANGE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_CHUNK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_CHUNK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_CHUNKSUCCESS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_CHUNKSUCCESS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_STATS", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_STATS))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_MARKER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_MARKER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "L_CONT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(L_CONT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_UNKNOWN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_UNKNOWN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_PLANNER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_PLANNER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_DRIVER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_DRIVER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_REPORTER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_REPORTER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_DUMPER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_DUMPER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_CHUNKER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_CHUNKER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_TAPER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_TAPER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_AMFLUSH", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_AMFLUSH))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_AMDUMP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_AMDUMP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_AMIDXTAPED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_AMIDXTAPED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_AMFETCHDUMP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_AMFETCHDUMP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_AMCHECKDUMP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_AMCHECKDUMP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "P_AMVAULT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(P_AMVAULT))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Logfile.pm b/perl/Amanda/Logfile.pm index c179c43..8d36cfb 100644 --- a/perl/Amanda/Logfile.pm +++ b/perl/Amanda/Logfile.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. @@ -61,10 +61,6 @@ package Amanda::Logfile; *search_holding_disk = *Amanda::Logfilec::search_holding_disk; *dumps_match = *Amanda::Logfilec::dumps_match; *dumps_match_dumpspecs = *Amanda::Logfilec::dumps_match_dumpspecs; -*match_host = *Amanda::Logfilec::match_host; -*match_disk = *Amanda::Logfilec::match_disk; -*match_datestamp = *Amanda::Logfilec::match_datestamp; -*match_level = *Amanda::Logfilec::match_level; ############# Class : Amanda::Logfile::find_result_t ############## @@ -365,16 +361,6 @@ the same result, that result will be returned multiple times. All of these functions can be imported by name. -=head1 MATCHING - -The following functions are available to match strings against patterns using -the rules described in amanda(8): - - match_host($pat, $str); - match_disk($pat, $str); - match_datestamp($pat, $str); - match_level($pat, $str); - =head1 DEBUG LOGGING HANDLER This package provides C<$amanda_log_trace_log>, which sends C @@ -610,8 +596,7 @@ $_program_t_VALUES{"P_AMVAULT"} = $P_AMVAULT; #copy symbols in program_t to constants push @{$EXPORT_TAGS{"constants"}}, @{$EXPORT_TAGS{"program_t"}}; -push @EXPORT_OK, qw(find_log search_logfile dumps_match log_rename - match_host match_disk match_datestamp match_level); +push @EXPORT_OK, qw(find_log search_logfile dumps_match log_rename); push @EXPORT_OK, qw($amanda_log_trace_log); diff --git a/perl/Amanda/Logfile.pod b/perl/Amanda/Logfile.pod index 6b5bf32..9c1286c 100644 --- a/perl/Amanda/Logfile.pod +++ b/perl/Amanda/Logfile.pod @@ -206,16 +206,6 @@ the same result, that result will be returned multiple times. All of these functions can be imported by name. -=head1 MATCHING - -The following functions are available to match strings against patterns using -the rules described in amanda(8): - - match_host($pat, $str); - match_disk($pat, $str); - match_datestamp($pat, $str); - match_level($pat, $str); - =head1 DEBUG LOGGING HANDLER This package provides C<$amanda_log_trace_log>, which sends C diff --git a/perl/Amanda/Logfile.swg b/perl/Amanda/Logfile.swg index 9d1a1de..07047a0 100644 --- a/perl/Amanda/Logfile.swg +++ b/perl/Amanda/Logfile.swg @@ -251,7 +251,6 @@ typedef struct { amglue_export_ok( find_log search_logfile dumps_match log_rename - match_host match_disk match_datestamp match_level ); char **find_log(void); @@ -289,13 +288,6 @@ find_result_t *dumps_match_dumpspecs(find_result_t *output_find, amglue_dumpspec_list *dumpspecs, gboolean ok); -/* these are actually available for clients as well, but they do not deserve - * their own perl module, so they're stuck here */ -gboolean match_host(char *pat, char *value); -gboolean match_disk(char *pat, char *value); -gboolean match_datestamp(char *pat, char *value); -gboolean match_level(char *pat, char *value); - %immutable; amanda_log_handler_t *amanda_log_trace_log; %mutable; diff --git a/perl/Amanda/MainLoop.c b/perl/Amanda/MainLoop.c index ebffa29..eeb96b1 100644 --- a/perl/Amanda/MainLoop.c +++ b/perl/Amanda/MainLoop.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1497,7 +1526,7 @@ static swig_module_info swig_module = {swig_types, 8, 0, 0, 0, 0}; #define SWIG_name "Amanda::MainLoopc::boot_Amanda__MainLoop" #define SWIG_prefix "Amanda::MainLoopc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1808,7 +1837,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -2599,32 +2630,32 @@ XS(SWIG_init) { } SWIG_TypeClientData(SWIGTYPE_p_amglue_Source, (void*) "Amanda::MainLoop::Source"); - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "G_IO_IN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(G_IO_IN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "G_IO_OUT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(G_IO_OUT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "G_IO_PRI", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(G_IO_PRI))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "G_IO_ERR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(G_IO_ERR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "G_IO_HUP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(G_IO_HUP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "G_IO_NVAL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(G_IO_NVAL))); SvREADONLY_on(sv); diff --git a/perl/Amanda/MainLoop.pm b/perl/Amanda/MainLoop.pm index 98ce06f..bc50535 100644 --- a/perl/Amanda/MainLoop.pm +++ b/perl/Amanda/MainLoop.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/NDMP.c b/perl/Amanda/NDMP.c index 527a74c..cc7e75a 100644 --- a/perl/Amanda/NDMP.c +++ b/perl/Amanda/NDMP.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1502,7 +1531,7 @@ static swig_module_info swig_module = {swig_types, 13, 0, 0, 0, 0}; #define SWIG_name "Amanda::NDMPc::boot_Amanda__NDMP" #define SWIG_prefix "Amanda::NDMPc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1652,7 +1681,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -3004,202 +3035,202 @@ XS(SWIG_init) { glib_init(); SWIG_TypeClientData(SWIGTYPE_p_NDMPConnection, (void*) "Amanda::NDMP::NDMPConnection"); - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_SCSI_DATA_DIR_NONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_SCSI_DATA_DIR_NONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_SCSI_DATA_DIR_IN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_SCSI_DATA_DIR_IN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_SCSI_DATA_DIR_OUT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_SCSI_DATA_DIR_OUT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_TAPE_READ_MODE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_TAPE_READ_MODE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_TAPE_RDWR_MODE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_TAPE_RDWR_MODE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_TAPE_RAW_MODE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_TAPE_RAW_MODE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MTIO_FSF", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MTIO_FSF))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MTIO_BSF", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MTIO_BSF))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MTIO_FSR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MTIO_FSR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MTIO_BSR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MTIO_BSR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MTIO_REW", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MTIO_REW))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MTIO_EOF", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MTIO_EOF))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MTIO_OFF", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MTIO_OFF))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_MODE_READ", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_MODE_READ))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_MODE_WRITE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_MODE_WRITE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_ADDR_LOCAL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_ADDR_LOCAL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_ADDR_TCP", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_ADDR_TCP))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_ADDR_AS_CONNECTED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_ADDR_AS_CONNECTED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_STATE_IDLE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_STATE_IDLE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_STATE_LISTEN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_STATE_LISTEN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_STATE_ACTIVE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_STATE_ACTIVE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_STATE_PAUSED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_STATE_PAUSED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_STATE_HALTED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_STATE_HALTED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_STATE_STANDBY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_STATE_STANDBY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_DATA_HALT_NA", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_DATA_HALT_NA))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_DATA_HALT_SUCCESSFUL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_DATA_HALT_SUCCESSFUL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_DATA_HALT_ABORTED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_DATA_HALT_ABORTED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_DATA_HALT_INTERNAL_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_DATA_HALT_INTERNAL_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_DATA_HALT_CONNECT_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_DATA_HALT_CONNECT_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_HALT_NA", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_HALT_NA))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_HALT_CONNECT_CLOSED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_HALT_CONNECT_CLOSED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_HALT_ABORTED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_HALT_ABORTED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_HALT_INTERNAL_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_HALT_INTERNAL_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_HALT_CONNECT_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_HALT_CONNECT_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_PAUSE_NA", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_PAUSE_NA))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_PAUSE_EOM", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_PAUSE_EOM))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_PAUSE_EOF", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_PAUSE_EOF))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_PAUSE_SEEK", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_PAUSE_SEEK))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_PAUSE_MEDIA_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_PAUSE_MEDIA_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "NDMP9_MOVER_PAUSE_EOW", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(NDMP9_MOVER_PAUSE_EOW))); SvREADONLY_on(sv); diff --git a/perl/Amanda/NDMP.pm b/perl/Amanda/NDMP.pm index 2ee4bb0..30bf257 100644 --- a/perl/Amanda/NDMP.pm +++ b/perl/Amanda/NDMP.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Recovery/Clerk.pm b/perl/Amanda/Recovery/Clerk.pm index 810621f..7531421 100644 --- a/perl/Amanda/Recovery/Clerk.pm +++ b/perl/Amanda/Recovery/Clerk.pm @@ -69,7 +69,7 @@ Amanda::Recovery::Clerk - handle assembling dumpfiles from multiple parts =head1 OVERVIEW -This package is the counterpart to L, and handles +This package is the counterpart to L, and handles re-assembling dumpfiles from multiple parts, possibly distributed over several volumes. @@ -228,7 +228,7 @@ sub get_xfer_src { my $self = shift; my %params = @_; - for my $rq_param qw(dump xfer_src_cb) { + for my $rq_param (qw(dump xfer_src_cb)) { croak "required parameter '$rq_param' missing" unless exists $params{$rq_param}; } @@ -262,7 +262,7 @@ sub start_recovery { my %params = @_; $self->dbg("starting recovery"); - for my $rq_param qw(xfer recovery_cb) { + for my $rq_param (qw(xfer recovery_cb)) { croak "required parameter '$rq_param' missing" unless exists $params{$rq_param}; } diff --git a/perl/Amanda/Recovery/Planner.pm b/perl/Amanda/Recovery/Planner.pm index 03cb3e6..a310062 100644 --- a/perl/Amanda/Recovery/Planner.pm +++ b/perl/Amanda/Recovery/Planner.pm @@ -228,7 +228,7 @@ sub make_plan { my $self = shift; my %params = @_; - for my $rq_param qw(changer plan_cb dumpspecs) { + for my $rq_param (qw(changer plan_cb dumpspecs)) { croak "required parameter '$rq_param' mising" unless exists $params{$rq_param}; } @@ -339,7 +339,7 @@ sub make_holding_plan { my $self = shift; my %params = @_; - for my $rq_param qw(holding_file plan_cb) { + for my $rq_param (qw(holding_file plan_cb)) { croak "required parameter '$rq_param' mising" unless exists $params{$rq_param}; } @@ -390,7 +390,7 @@ sub make_plan_from_filelist { my $self = shift; my %params = @_; - for my $rq_param qw(filelist plan_cb) { + for my $rq_param (qw(filelist plan_cb)) { croak "required parameter '$rq_param' mising" unless exists $params{$rq_param}; } diff --git a/perl/Amanda/Recovery/Scan.pm b/perl/Amanda/Recovery/Scan.pm index c1d28fb..5a9fa72 100644 --- a/perl/Amanda/Recovery/Scan.pm +++ b/perl/Amanda/Recovery/Scan.pm @@ -163,6 +163,7 @@ sub new { #until we have a config for it. $scan_conf = Amanda::Recovery::Scan::Config->new(); $chg = Amanda::Changer->new() if !defined $chg; + return $chg if $chg->isa("Amanda::Changer::Error"); my $self = { initial_chg => $chg, diff --git a/perl/Amanda/Report.pm b/perl/Amanda/Report.pm index 78a3c30..f94b0fc 100644 --- a/perl/Amanda/Report.pm +++ b/perl/Amanda/Report.pm @@ -510,10 +510,22 @@ sub read_line if ( $type == $L_CONT ) { ${$self->{nbline_ref}}++; - push @{$self->{contline}}, $str if ${$self->{nbline_ref}} <= 100; + if ($str =~ /^\|/) { + $self->{nb_strange}++; + push @{$self->{contline}}, $str if $self->{nb_strange} + $self->{nb_error} <= 100; + } elsif ($str =~ /^\?/) { + $self->{nb_error}++; + push @{$self->{contline}}, $str if $self->{nb_error} <= 100; + } else { + $self->{nb_normal}++; + push @{$self->{contline}}, $str if ${$self->{nbline_ref}} <= 100; + } return; } $self->{contline} = undef; + $self->{nb_normal} = 0; + $self->{nb_strange} = 0; + $self->{nb_error} = 0; if ( $prog == $P_PLANNER ) { return $self->_handle_planner_line( $type, $str ); @@ -806,6 +818,9 @@ sub _handle_dumper_line $self->{contline} = $dumper->{stranges} ||= []; $dumper->{nb_stranges} = 0; $self->{nbline_ref} = \$dumper->{nb_stranges}; + $self->{nb_normal} = 0; + $self->{nb_strange} = 0; + $self->{nb_error} = 0; return $self->{flags}{exit_status} |= STATUS_STRANGE @@ -1153,6 +1168,9 @@ sub _handle_fail_line $self->{contline} = $program_d->{errors} ||= []; $program_d->{nb_errors} = 0; $self->{nbline_ref} = \$program_d->{nb_errors}; + $self->{nb_normal} = 0; + $self->{nb_strange} = 0; + $self->{nb_error} = 0; } } diff --git a/perl/Amanda/ScanInventory.pm b/perl/Amanda/ScanInventory.pm index c76fc02..d47f675 100644 --- a/perl/Amanda/ScanInventory.pm +++ b/perl/Amanda/ScanInventory.pm @@ -68,13 +68,14 @@ sub new { #until we have a config for it. $scan_conf = Amanda::ScanInventory::Config->new(); - $chg = Amanda::Changer->new() if !defined $chg; + $chg = Amanda::Changer->new(undef, tapelist => $tapelist) if !defined $chg; my $self = { initial_chg => $chg, chg => $chg, scanning => 0, scan_conf => $scan_conf, + tapelist => $tapelist, interactivity => $interactivity, seen => {}, scan_num => 0 @@ -115,6 +116,7 @@ sub _scan { my $action; my $action_slot; my $res; + my $label; my %seen = (); my $inventory; my $current; @@ -146,7 +148,7 @@ sub _scan { if ($err && $err->notimpl) { #inventory not implemented die("no inventory"); - } elsif ($err) { + } elsif ($err and $err->fatal) { #inventory fail return $steps->{'call_result_cb'}->($err, undef); } @@ -447,10 +449,10 @@ sub _scan { # use a new changer my $new_chg; if (ref($message) eq 'HASH' and $message == $DEFAULT_CHANGER) { - $new_chg = Amanda::Changer->new(); - } else { - $new_chg = Amanda::Changer->new($message); + $message = undef; } + $new_chg = Amanda::Changer->new($message, + tapelist => $self->{'tapelist'}); if ($new_chg->isa("Amanda::Changer::Error")) { return $steps->{'scan_interactivity'}->("$new_chg"); } @@ -497,22 +499,87 @@ sub _scan { $self->{'scanning'} = 0; return $result_cb->($err, $res); } - my $label = $res->{'device'}->volume_label; + $label = $res->{'device'}->volume_label; if (!defined $label) { - ($label, my $make_err) = $res->make_new_tape_label(); - if (!defined $label) { - # make this fatal, rather than silently skipping new tapes - $self->{'scanning'} = 0; - return $result_cb->($make_err, $res); - } - $self->{'scanning'} = 0; - return $result_cb->(undef, $res, $label, $ACCESS_WRITE, 1); + $res->get_meta_label(finished_cb => $steps->{'got_meta_label'}); + return; } $self->{'scanning'} = 0; return $result_cb->(undef, $res, $label, $ACCESS_WRITE); }; + + step got_meta_label => sub { + my ($err, $meta) = @_; + if (defined $err) { + return $result_cb->($err, $res); + } + ($label, my $make_err) = $res->make_new_tape_label(meta => $meta); + if (!defined $label) { + # make this fatal, rather than silently skipping new tapes + $self->{'scanning'} = 0; + return $result_cb->($make_err, $res); + } + $self->{'scanning'} = 0; + return $result_cb->(undef, $res, $label, $ACCESS_WRITE, 1); + }; } +sub volume_is_labelable { + my $self = shift; + my $sl = shift; + my $dev_status = $sl->{'device_status'}; + my $f_type = $sl->{'f_type'}; + my $label = $sl->{'label'}; + my $slot = $sl->{'slot'}; + my $chg = $self->{'chg'}; + my $autolabel = $chg->{'autolabel'}; + + if (!defined $dev_status) { + return 0; + } elsif ($dev_status & $DEVICE_STATUS_VOLUME_UNLABELED and + defined $f_type and + $f_type == $Amanda::Header::F_EMPTY) { + if (!$autolabel->{'empty'}) { + $self->_user_msg(slot_result => 1, + empty => 1, + slot => $slot); + return 0; + } + } elsif ($dev_status & $DEVICE_STATUS_VOLUME_UNLABELED and + defined $f_type and + $f_type == $Amanda::Header::F_WEIRD) { + if (!$autolabel->{'non_amanda'}) { + $self->_user_msg(slot_result => 1, + non_amanda => 1, + slot => $slot); + return 0; + } + } elsif ($dev_status & $DEVICE_STATUS_VOLUME_ERROR) { + if (!$autolabel->{'volume_error'}) { + $self->_user_msg(slot_result => 1, + volume_error => 1, + slot => $slot); + return 0; + } + } elsif ($dev_status != $DEVICE_STATUS_SUCCESS) { + $self->_user_msg(slot_result => 1, + not_success => 1, + err => $sl->{'device_error'}, + slot => $slot); + return 0; + } elsif ($dev_status & $DEVICE_STATUS_SUCCESS and + $f_type == $Amanda::Header::F_TAPESTART and + $label !~ /$self->{'labelstr'}/) { + if (!$autolabel->{'other_config'}) { + $self->_user_msg(slot_result => 1, + other_config => 1, + slot => $slot); + return 0; + } + } + + return 1; +} package Amanda::ScanInventory::Config; sub new { diff --git a/perl/Amanda/Script_App.pm b/perl/Amanda/Script_App.pm index 0b8c3f9..aac85e6 100644 --- a/perl/Amanda/Script_App.pm +++ b/perl/Amanda/Script_App.pm @@ -61,6 +61,7 @@ sub new { $execute_where = "client"; } Amanda::Util::setup_application($name, $execute_where, $CONTEXT_DAEMON); + debug("Arguments: " . join(' ', @ARGV)); #initialize config client to get values from amanda-client.conf config_init($CONFIG_INIT_CLIENT, undef); diff --git a/perl/Amanda/Tapelist.c b/perl/Amanda/Tapelist.c index d49f67d..1800253 100644 --- a/perl/Amanda/Tapelist.c +++ b/perl/Amanda/Tapelist.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1494,7 +1523,7 @@ static swig_module_info swig_module = {swig_types, 5, 0, 0, 0, 0}; #define SWIG_name "Amanda::Tapelistc::boot_Amanda__Tapelist" #define SWIG_prefix "Amanda::Tapelistc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1551,7 +1580,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; diff --git a/perl/Amanda/Tapelist.pm b/perl/Amanda/Tapelist.pm index b028127..2680311 100644 --- a/perl/Amanda/Tapelist.pm +++ b/perl/Amanda/Tapelist.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. @@ -309,7 +309,7 @@ sub remove_tapelabel { sub add_tapelabel { my $self = shift; - my ($datestamp, $label, $comment, $reuse, $meta, $barcode) = @_; + my ($datestamp, $label, $comment, $reuse, $meta, $barcode, $blocksize) = @_; $reuse = 1 if !defined $reuse; # prepend this (presumably new) volume to the beginning of the list @@ -319,6 +319,7 @@ sub add_tapelabel { 'reuse' => $reuse, 'barcode' => $barcode, 'meta' => $meta, + 'blocksize' => $blocksize, 'comment' => $comment, }; my $tles = $self->{'tles'}; @@ -357,8 +358,9 @@ sub write { my $reuse = $tle->{'reuse'} ? 'reuse' : 'no-reuse'; my $barcode = (defined $tle->{'barcode'})? (" BARCODE:" . $tle->{'barcode'}) : ''; my $meta = (defined $tle->{'meta'})? (" META:" . $tle->{'meta'}) : ''; + my $blocksize = (defined $tle->{'blocksize'})? (" BLOCKSIZE:" . $tle->{'blocksize'}) : ''; my $comment = (defined $tle->{'comment'})? (" #" . $tle->{'comment'}) : ''; - $result &&= print $fhn "$datestamp $label $reuse$barcode$meta$comment\n"; + $result &&= print $fhn "$datestamp $label $reuse$barcode$meta$blocksize$comment\n"; } my $result_close = close($fhn); $result &&= $result_close; @@ -410,8 +412,8 @@ sub _read_tapelist { my @tles; open(my $fh, "<", $self->{'filename'}) or return $self; while (my $line = <$fh>) { - my ($datestamp, $label, $reuse, $barcode, $meta, $comment) - = $line =~ m/^([0-9]*)\s([^\s]*)\s(reuse|no-reuse)\s*(?:BARCODE:([^\s]*))?\s*(?:META:([^\s]*))?\s*(?:\#(.*))?$/mx; + my ($datestamp, $label, $reuse, $barcode, $meta, $blocksize, $comment) + = $line =~ m/^([0-9]*)\s([^\s]*)\s(reuse|no-reuse)\s*(?:BARCODE:([^\s]*))?\s*(?:META:([^\s]*))?\s*(?:BLOCKSIZE:([^\s]*))?\s*(?:\#(.*))?$/mx; next if !defined $datestamp; # silently filter out bogus lines push @tles, { 'datestamp' => $datestamp, @@ -419,6 +421,7 @@ sub _read_tapelist { 'reuse' => ($reuse eq 'reuse'), 'barcode' => $barcode, 'meta' => $meta, + 'blocksize' => $blocksize, 'comment' => $comment, }; } diff --git a/perl/Amanda/Tapelist.swg b/perl/Amanda/Tapelist.swg index d15217a..b514cac 100644 --- a/perl/Amanda/Tapelist.swg +++ b/perl/Amanda/Tapelist.swg @@ -124,7 +124,7 @@ sub remove_tapelabel { sub add_tapelabel { my $self = shift; - my ($datestamp, $label, $comment, $reuse, $meta, $barcode) = @_; + my ($datestamp, $label, $comment, $reuse, $meta, $barcode, $blocksize) = @_; $reuse = 1 if !defined $reuse; # prepend this (presumably new) volume to the beginning of the list @@ -134,6 +134,7 @@ sub add_tapelabel { 'reuse' => $reuse, 'barcode' => $barcode, 'meta' => $meta, + 'blocksize' => $blocksize, 'comment' => $comment, }; my $tles = $self->{'tles'}; @@ -172,8 +173,9 @@ sub write { my $reuse = $tle->{'reuse'} ? 'reuse' : 'no-reuse'; my $barcode = (defined $tle->{'barcode'})? (" BARCODE:" . $tle->{'barcode'}) : ''; my $meta = (defined $tle->{'meta'})? (" META:" . $tle->{'meta'}) : ''; + my $blocksize = (defined $tle->{'blocksize'})? (" BLOCKSIZE:" . $tle->{'blocksize'}) : ''; my $comment = (defined $tle->{'comment'})? (" #" . $tle->{'comment'}) : ''; - $result &&= print $fhn "$datestamp $label $reuse$barcode$meta$comment\n"; + $result &&= print $fhn "$datestamp $label $reuse$barcode$meta$blocksize$comment\n"; } my $result_close = close($fhn); $result &&= $result_close; @@ -225,8 +227,8 @@ sub _read_tapelist { my @tles; open(my $fh, "<", $self->{'filename'}) or return $self; while (my $line = <$fh>) { - my ($datestamp, $label, $reuse, $barcode, $meta, $comment) - = $line =~ m/^([0-9]*)\s([^\s]*)\s(reuse|no-reuse)\s*(?:BARCODE:([^\s]*))?\s*(?:META:([^\s]*))?\s*(?:\#(.*))?$/mx; + my ($datestamp, $label, $reuse, $barcode, $meta, $blocksize, $comment) + = $line =~ m/^([0-9]*)\s([^\s]*)\s(reuse|no-reuse)\s*(?:BARCODE:([^\s]*))?\s*(?:META:([^\s]*))?\s*(?:BLOCKSIZE:([^\s]*))?\s*(?:\#(.*))?$/mx; next if !defined $datestamp; # silently filter out bogus lines push @tles, { 'datestamp' => $datestamp, @@ -234,6 +236,7 @@ sub _read_tapelist { 'reuse' => ($reuse eq 'reuse'), 'barcode' => $barcode, 'meta' => $meta, + 'blocksize' => $blocksize, 'comment' => $comment, }; } diff --git a/perl/Amanda/Taper/Controller.pm b/perl/Amanda/Taper/Controller.pm index 1cf0141..f6c839f 100644 --- a/perl/Amanda/Taper/Controller.pm +++ b/perl/Amanda/Taper/Controller.pm @@ -104,7 +104,7 @@ sub start { } else { $msg = $params{'error'}; } - log_add($L_ERROR, $msg); + log_add($L_ERROR, "$msg"); print STDERR "$msg\n"; $self->{'proto'}->send(Amanda::Taper::Protocol::BAD_COMMAND, message => $msg); @@ -265,6 +265,14 @@ sub msg_FAILED { $worker->FAILED(@_); } +sub msg_CLOSE_VOLUME { + my $self = shift; + my ($msgtype, %params) = @_; + + my $worker = $self->{'worker'}->{$params{'worker_name'}}; + $worker->CLOSE_VOLUME(@_); +} + sub msg_TAKE_SCRIBE_FROM { my $self = shift; my ($msgtype, %params) = @_; diff --git a/perl/Amanda/Taper/Protocol.pm b/perl/Amanda/Taper/Protocol.pm index 32fc5c2..89066ec 100644 --- a/perl/Amanda/Taper/Protocol.pm +++ b/perl/Amanda/Taper/Protocol.pm @@ -129,4 +129,8 @@ use constant DUMPER_STATUS => message("DUMPER-STATUS", format => [ qw( handle ) ], ); +use constant CLOSE_VOLUME => message("CLOSE-VOLUME", + format => [ qw( worker_name ) ], +); + 1; diff --git a/perl/Amanda/Taper/Scan/lexical.pm b/perl/Amanda/Taper/Scan/lexical.pm index 3070fc8..c69279c 100644 --- a/perl/Amanda/Taper/Scan/lexical.pm +++ b/perl/Amanda/Taper/Scan/lexical.pm @@ -153,17 +153,13 @@ sub analyze { if ($vol_tle->{'datestamp'} eq '0') { push @new_labeled, $sl; } - } elsif ($self->{'chg'}->volume_is_labelable($sl->{'device_status'}, - $sl->{'f_type'}, - $sl->{'label'})) { + } elsif ($self->volume_is_labelable($sl)) { $first_new_volume = $sl if !$first_new_volume; $new_volume = $sl if $current && !$new_volume; push @new_volume, $sl; } } - } elsif ($self->{'chg'}->volume_is_labelable($sl->{'device_status'}, - $sl->{'f_type'}, - $sl->{'label'})) { + } elsif ($self->volume_is_labelable($sl)) { $first_new_volume = $sl if !$first_new_volume; $new_volume = $sl if $current && !$new_volume; push @new_volume, $sl; @@ -209,6 +205,7 @@ sub analyze { for my $sl (@new_volume) { $sl->{'label'} = $self->{'chg'}->make_new_tape_label( barcode => $sl->{'barcode'}, + slot => $sl->{'slot'}, meta => $sl->{'meta'}); $new_volume = $sl if defined $last_label and $new_volume->{'label'} ne $sl->{'label'} and diff --git a/perl/Amanda/Taper/Scan/oldest.pm b/perl/Amanda/Taper/Scan/oldest.pm index 3c9fc6a..a7945a8 100644 --- a/perl/Amanda/Taper/Scan/oldest.pm +++ b/perl/Amanda/Taper/Scan/oldest.pm @@ -131,17 +131,13 @@ sub analyze { if ($vol_tle->{'datestamp'} eq '0') { push @new_labeled, $sl; } - } elsif ($self->{'chg'}->volume_is_labelable($sl->{'device_status'}, - $sl->{'f_type'}, - $sl->{'label'})) { + } elsif ($self->volume_is_labelable($sl)) { $first_new_volume = $sl if !$first_new_volume; $new_volume = $sl if $current && !$new_volume; push @new_volume, $sl; } } - } elsif ($self->{'chg'}->volume_is_labelable($sl->{'device_status'}, - $sl->{'f_type'}, - $sl->{'label'})) { + } elsif ($self->volume_is_labelable($sl)) { $first_new_volume = $sl if !$first_new_volume; $new_volume = $sl if $current && !$new_volume; push @new_volume, $sl; @@ -184,6 +180,7 @@ sub analyze { for my $sl (@new_volume) { $sl->{'label'} = $self->{'chg'}->make_new_tape_label( barcode => $sl->{'barcode'}, + slot => $sl->{'slot'}, meta => $sl->{'meta'}); $new_volume = $sl if defined $last_label and $new_volume->{'label'} ne $sl->{'label'} and diff --git a/perl/Amanda/Taper/Scan/traditional.pm b/perl/Amanda/Taper/Scan/traditional.pm index 9581d26..7c8235c 100644 --- a/perl/Amanda/Taper/Scan/traditional.pm +++ b/perl/Amanda/Taper/Scan/traditional.pm @@ -221,122 +221,6 @@ sub stage_1 { }; } -sub try_volume { - my $self = shift; - my ($res, $result_cb) = @_; - - my $slot = $res->{'this_slot'}; - my $dev = $res->{'device'}; - my $status = $dev->status; - my $labelstr = $res->{'chg'}->{'labelstr'}; - my $label; - my $autolabel = $res->{'chg'}->{'autolabel'}; - - if ($status == $DEVICE_STATUS_SUCCESS) { - $label = $dev->volume_label; - - if ($label !~ /$labelstr/) { - if (!$autolabel->{'other_config'}) { - $self->_user_msg(slot_result => 1, - does_not_match_labelstr => 1, - labelstr => $labelstr, - slot => $slot, - label => $label, - res => $res); - return 0; - } - } else { - # verify that the label is in the tapelist - my $tle = $self->{'tapelist'}->lookup_tapelabel($label); - if (!$tle) { - $self->_user_msg(slot_result => 1, - not_in_tapelist => 1, - slot => $slot, - label => $label, - res => $res); - return 0; - } - - # see if it's reusable - if (!$self->is_reusable_volume(label => $label, new_label_ok => 1)) { - $self->_user_msg(slot_result => 1, - active => 1, - slot => $slot, - label => $label, - res => $res); - return 0; - } - $self->_user_msg(slot_result => 1, - slot => $slot, - label => $label, - res => $res); - $self->scan_result(res => $res, label => $label, - mode => $ACCESS_WRITE, is_new => 0, result_cb => $result_cb); - return 1; - } - } - - if (!defined $autolabel->{'template'} || - $autolabel->{'template'} eq "") { - $self->_user_msg(slot_result => 1, - not_autolabel => 1, - slot => $slot, - res => $res); - return 0; - } - - $self->_user_msg(slot_result => 1, slot => $slot, res => $res); - - if ($status & $DEVICE_STATUS_VOLUME_UNLABELED and - $dev->volume_header and - $dev->volume_header->{'type'} == $Amanda::Header::F_EMPTY) { - if (!$autolabel->{'empty'}) { - $self->_user_msg(slot_result => 1, - empty => 1, - slot => $slot, - res => $res); - return 0; - } - } elsif ($status & $DEVICE_STATUS_VOLUME_UNLABELED and - $dev->volume_header and - $dev->volume_header->{'type'} == $Amanda::Header::F_WEIRD) { - if (!$autolabel->{'non_amanda'}) { - $self->_user_msg(slot_result => 1, - non_amanda => 1, - slot => $slot, - res => $res); - return 0; - } - } elsif ($status & $DEVICE_STATUS_VOLUME_ERROR) { - if (!$autolabel->{'volume_error'}) { - $self->_user_msg(slot_result => 1, - volume_error => 1, - err => $dev->error_or_status(), - slot => $slot, - res => $res); - return 0; - } - } elsif ($status != $DEVICE_STATUS_SUCCESS) { - $self->_user_msg(slot_result => 1, - not_success => 1, - err => $dev->error_or_status(), - slot => $slot, - res => $res); - return 0; - } - - ($label, my $err) = $res->make_new_tape_label(); - if (!defined $label) { - # make this fatal, rather than silently skipping new tapes - $self->scan_result(error => $err, res => $res, result_cb => $result_cb); - return 1; - } - - $self->scan_result(res => $res, label => $label, mode => $ACCESS_WRITE, - is_new => 1, result_cb => $result_cb); - return 1; -} - ## # stage 2: scan for any usable volume @@ -362,6 +246,7 @@ sub stage_2 { my $load_current = ($self->{'scan_num'} == 1); my $steps = define_steps cb_ref => \$result_cb; + my $res; step load => sub { my ($err) = @_; @@ -397,7 +282,7 @@ sub stage_2 { }; step loaded => sub { - my ($err, $res) = @_; + (my $err, $res) = @_; my $loaded_current = $load_current; $load_current = 0; # don't load current a second time @@ -447,9 +332,145 @@ sub stage_2 { $self->{'seen'}->{$res->{'this_slot'}} = 1; - # we're done if try_volume calls result_cb (with success or an error) - return if ($self->try_volume($res, $result_cb)); + $steps->{'try_volume'}->(); + }; + + step try_volume => sub { + my $slot = $res->{'this_slot'}; + my $dev = $res->{'device'}; + my $status = $dev->status; + my $labelstr = $res->{'chg'}->{'labelstr'}; + my $label; + my $autolabel = $res->{'chg'}->{'autolabel'}; + + if ($status == $DEVICE_STATUS_SUCCESS) { + $label = $dev->volume_label; + + if ($label !~ /$labelstr/) { + if (!$autolabel->{'other_config'}) { + $self->_user_msg(slot_result => 1, + does_not_match_labelstr => 1, + labelstr => $labelstr, + slot => $slot, + label => $label, + res => $res); + return $steps->{'try_continue'}->(); + } + } else { + # verify that the label is in the tapelist + my $tle = $self->{'tapelist'}->lookup_tapelabel($label); + if (!$tle) { + $self->_user_msg(slot_result => 1, + not_in_tapelist => 1, + slot => $slot, + label => $label, + res => $res); + return $steps->{'try_continue'}->(); + } + + # see if it's reusable + if (!$self->is_reusable_volume(label => $label, new_label_ok => 1)) { + $self->_user_msg(slot_result => 1, + active => 1, + slot => $slot, + label => $label, + res => $res); + return $steps->{'try_continue'}->(); + } + $self->_user_msg(slot_result => 1, + slot => $slot, + label => $label, + res => $res); + $self->scan_result(res => $res, label => $label, + mode => $ACCESS_WRITE, is_new => 0, + result_cb => $result_cb); + return; + } + } + + if (!defined $autolabel->{'template'} || + $autolabel->{'template'} eq "") { + $self->_user_msg(slot_result => 1, + not_autolabel => 1, + slot => $slot, + res => $res); + return $steps->{'try_continue'}->(); + } + + if ($status & $DEVICE_STATUS_VOLUME_UNLABELED and + $dev->volume_header and + $dev->volume_header->{'type'} == $Amanda::Header::F_EMPTY) { + if (!$autolabel->{'empty'}) { + $self->_user_msg(slot_result => 1, + empty => 1, + slot => $slot, + res => $res); + return $steps->{'try_continue'}->(); + } + } elsif ($status & $DEVICE_STATUS_VOLUME_UNLABELED and + $dev->volume_header and + $dev->volume_header->{'type'} == $Amanda::Header::F_WEIRD) { + if (!$autolabel->{'non_amanda'}) { + $self->_user_msg(slot_result => 1, + non_amanda => 1, + slot => $slot, + res => $res); + return $steps->{'try_continue'}->(); + } + } elsif ($status & $DEVICE_STATUS_VOLUME_ERROR) { + if (!$autolabel->{'volume_error'}) { + $self->_user_msg(slot_result => 1, + volume_error => 1, + err => $dev->error_or_status(), + slot => $slot, + res => $res); + return $steps->{'try_continue'}->(); + } + } elsif ($status != $DEVICE_STATUS_SUCCESS) { + $self->_user_msg(slot_result => 1, + not_success => 1, + err => $dev->error_or_status(), + slot => $slot, + res => $res); + return $steps->{'try_continue'}->(); + } + + $self->_user_msg(slot_result => 1, slot => $slot, res => $res); + $res->get_meta_label(finished_cb => $steps->{'got_meta_label'}); + return; + }; + + step got_meta_label => sub { + my ($err, $meta) = @_; + + if (defined $err) { + $self->scan_result(error => $err, res => $res, + result_cb => $result_cb); + return; + } + + ($meta, $err) = $res->make_new_meta_label() if !defined $meta; + if (defined $err) { + $self->scan_result(error => $err, res => $res, + result_cb => $result_cb); + return; + } + + (my $label, $err) = $res->make_new_tape_label(meta => $meta); + + + if (!defined $label) { + # make this fatal, rather than silently skipping new tapes + $self->scan_result(error => $err, res => $res, result_cb => $result_cb); + return; + } + + $self->scan_result(res => $res, label => $label, mode => $ACCESS_WRITE, + is_new => 1, result_cb => $result_cb); + return; + }; + step try_continue => sub { # no luck -- release this reservation and get the next $last_slot = $res->{'this_slot'}; diff --git a/perl/Amanda/Taper/Scribe.pm b/perl/Amanda/Taper/Scribe.pm index dbfce4a..d135e3a 100644 --- a/perl/Amanda/Taper/Scribe.pm +++ b/perl/Amanda/Taper/Scribe.pm @@ -442,7 +442,7 @@ sub new { my %params = @_; my $decide_debug = $Amanda::Config::debug_taper || $params{'debug'}; - for my $rq_param qw(taperscan feedback) { + for my $rq_param (qw(taperscan feedback)) { croak "required parameter '$rq_param' mising" unless exists $params{$rq_param}; } @@ -451,6 +451,7 @@ sub new { taperscan => $params{'taperscan'}, feedback => $params{'feedback'}, debug => $decide_debug, + eject_volume => $params{'eject_volume'}, write_timestamp => undef, started => 0, @@ -463,6 +464,7 @@ sub new { device => undef, device_size => undef, device_at_eom => undef, # device still exists, but is full + close_volume => undef, # callback passed to start_dump dump_cb => undef, @@ -491,7 +493,7 @@ sub start { my $self = shift; my %params = @_; - for my $rq_param qw(write_timestamp finished_cb) { + for my $rq_param (qw(write_timestamp finished_cb)) { croak "required parameter '$rq_param' missing" unless exists $params{$rq_param}; } @@ -615,7 +617,7 @@ sub get_xfer_dest { my $self = shift; my %params = @_; - for my $rq_param qw(max_memory) { + for my $rq_param (qw(max_memory)) { croak "required parameter '$rq_param' missing" unless exists $params{$rq_param}; } @@ -790,6 +792,12 @@ sub cancel_dump { $self->{'xfer'} = undef; } +sub close_volume { + my $self = shift; + + $self->{'close_volume'} = 1; +} + sub get_bytes_written { my ($self) = @_; @@ -813,6 +821,11 @@ sub _start_part { return } + if ($self->{'close_volume'}) { + $self->{'close_volume'} = undef; + return $self->_get_new_volume(); + } + # we need an actual, permitted device at this point, so if we don't have # one, then defer this start_part call until we do. The device may still # exist, but be at EOM, if the last dump failed at EOM and was not retried @@ -939,11 +952,12 @@ sub _xmsg_part_done { # if the part was unsuccessful, but the xfer dest has reason to believe # this is not due to EOM, then the dump is done if (!$msg->{'successful'}) { - my $msg = "unknown error while dumping"; if ($self->{'device'}->status() != $DEVICE_STATUS_SUCCESS) { $msg = $self->{'device'}->error_or_status(); + $self->_operation_failed(device_error => $msg); + } else { + $self->_operation_failed(); } - $self->_operation_failed(device_error => $msg); return; } @@ -990,7 +1004,8 @@ sub _dump_done { # determine the correct final status - DONE if we're done, PARTIAL # if we've started writing to the volume, otherwise FAILED - if (@{$self->{'device_errors'}} or $self->{'config_denial_message'}) { + if (@{$self->{'device_errors'}} or $self->{'config_denial_message'} or + !$self->{'last_part_successful'}) { $result = $self->{'started_writing'}? 'PARTIAL' : 'FAILED'; } else { $result = 'DONE'; @@ -1031,7 +1046,7 @@ sub _operation_failed { my $error_message = $params{'device_error'} || $params{'config_denial_message'} - || 'no reason'; + || 'input error'; $self->dbg("operation failed: $error_message"); # tuck the message away as desired @@ -1063,11 +1078,13 @@ sub _release_reservation { my $self = shift; my %params = @_; my @errors; + my $do_eject = 0; my ($label, $fm, $kb); # if we've already written a volume, log it if ($self->{'device'} and defined $self->{'device'}->volume_label) { + $do_eject = 1 if $self->{'eject_volume'}; $label = $self->{'device'}->volume_label(); $fm = $self->{'device'}->file(); $kb = $self->{'device_size'} / 1024; @@ -1088,7 +1105,7 @@ sub _release_reservation { $self->{'device'} = undef; $self->{'device_at_eom'} = 0; - $self->{'reservation'}->release(finished_cb => sub { + $self->{'reservation'}->release(eject => $do_eject, finished_cb => sub { my ($err) = @_; push @errors, "$err" if $err; @@ -1352,11 +1369,6 @@ sub _device_start { if ($is_new) { # generate the new label and write it to the tapelist file $tl->reload(1); - ($new_label, my $err) = $reservation->make_new_tape_label(); - if (!defined $new_label) { - $tl->unlock(); - return $finished_cb->($err); - } if (!$meta) { ($meta, $err) = $reservation->make_new_meta_label(); if (defined $err) { @@ -1364,7 +1376,14 @@ sub _device_start { return $finished_cb->($err); } } - $tl->add_tapelabel('0', $new_label, undef, $meta, $reservation->{'barcode'}); + ($new_label, my $err) = $reservation->make_new_tape_label( + meta => $meta); + if (!defined $new_label) { + $tl->unlock(); + return $finished_cb->($err); + } + $tl->add_tapelabel('0', $new_label, undef, 1, $meta, + $reservation->{'barcode'}); $tl->write(); $self->dbg("generate new label '$new_label'"); } elsif (!defined $meta) { @@ -1390,7 +1409,8 @@ sub _device_start { $meta = $tle->{'meta'} if !$meta && $tle->{'meta'}; $tl->remove_tapelabel($new_label); $tl->add_tapelabel($self->{'write_timestamp'}, $new_label, - $tle? $tle->{'comment'} : undef, 1, $meta); + $tle? $tle->{'comment'} : undef, 1, $meta, + $reservation->{'barcode'}, $device->block_size/1024); $tl->write(); $reservation->set_meta_label(meta => $meta, @@ -1559,6 +1579,7 @@ sub scribe_notif_tape_done { package Amanda::Taper::Scribe::DevHandling; use Amanda::MainLoop; use Carp; +use Amanda::Debug qw( :logging ); # This class handles scanning for volumes, requesting permission for those # volumes (the driver likes to feel like it's in control), and providing those @@ -1622,7 +1643,7 @@ sub quit { my $self = shift; my %params = @_; - for my $rq_param qw(finished_cb) { + for my $rq_param (qw(finished_cb)) { croak "required parameter '$rq_param' mising" unless exists $params{$rq_param}; } @@ -1727,16 +1748,16 @@ sub _start_scanning { } } elsif ($params{'empty'}) { $self->{'feedback'}->scribe_notif_log_info( - message => "Slot $params{'slot'} is empty"); + message => "Slot $params{'slot'} is empty, autolabel disabled"); } elsif ($params{'non_amanda'}) { $self->{'feedback'}->scribe_notif_log_info( - message => "Slot $params{'slot'} is a non-amanda volume"); + message => "Slot $params{'slot'} is a non-amanda volume, autolabel disabled"); } elsif ($params{'volume_error'}) { $self->{'feedback'}->scribe_notif_log_info( - message => "Slot $params{'slot'} is a volume in error: $params{'err'}"); + message => "Slot $params{'slot'} is a volume in error: $params{'err'}, autolabel disabled"); } elsif ($params{'not_success'}) { $self->{'feedback'}->scribe_notif_log_info( - message => "Slot $params{'slot'} is a device in error: $params{'err'}"); + message => "Slot $params{'slot'} is a device in error: $params{'err'}, autolabel disabled"); } elsif ($params{'err'}) { $self->{'feedback'}->scribe_notif_log_info( message => "$params{'err'}"); @@ -1761,15 +1782,12 @@ sub _start_scanning { $self->{'scan_running'} = 0; $self->{'scan_finished'} = 1; - if ($error) { - $self->{'scan_error'} = $error; - } else { - $self->{'reservation'} = $reservation; - $self->{'device'} = $reservation->{'device'}; - $self->{'volume_label'} = $volume_label; - $self->{'access_mode'} = $access_mode; - $self->{'is_new'} = $is_new; - } + $self->{'scan_error'} = $error; + $self->{'reservation'} = $reservation; + $self->{'device'} = $reservation->{'device'} if $reservation; + $self->{'volume_label'} = $volume_label; + $self->{'access_mode'} = $access_mode; + $self->{'is_new'} = $is_new; $self->_maybe_callback(); }); diff --git a/perl/Amanda/Taper/Worker.pm b/perl/Amanda/Taper/Worker.pm index 08d1f53..7e6b9ea 100644 --- a/perl/Amanda/Taper/Worker.pm +++ b/perl/Amanda/Taper/Worker.pm @@ -100,7 +100,8 @@ sub new { my $scribe = Amanda::Taper::Scribe->new( taperscan => $controller->{'taperscan'}, feedback => $self, - debug => $Amanda::Config::debug_taper); + debug => $Amanda::Config::debug_taper, + eject_volume => getconf($CNF_EJECT_VOLUME)); $self->{'scribe'} = $scribe; $self->{'scribe'}->start(write_timestamp => $write_timestamp, @@ -240,6 +241,15 @@ sub FAILED { } } +sub CLOSE_VOLUME { + my $self = shift; + my ($msgtype, %params) = @_; + + $self->_assert_in_state("idle") or return; + + $self->{'scribe'}->close_volume(); +} + sub result_cb { my $self = shift; my %params = %{$self->{'dump_params'}}; @@ -373,7 +383,7 @@ sub scribe_notif_new_tape { # TODO: if $params{error} is set, report it back to the driver # (this will be a change to the protocol) - log_add($L_INFO, $params{'error'}) if defined $params{'error'}; + log_add($L_INFO, "$params{'error'}") if defined $params{'error'}; if ($params{'volume_label'}) { $self->{'label'} = $params{'volume_label'}; @@ -438,7 +448,8 @@ sub scribe_notif_log_info { my $self = shift; my %params = @_; - log_add($L_INFO, $params{'message'}); + debug("$params{'message'}"); + log_add($L_INFO, "$params{'message'}"); } ## @@ -525,7 +536,7 @@ sub send_port_and_get_header { if ($xmsg->{'type'} == $XMSG_INFO) { info($xmsg->{'message'}); } elsif ($xmsg->{'type'} == $XMSG_ERROR) { - $errmsg = $xmsg->{'messsage'}; + $errmsg = $xmsg->{'message'}; } elsif ($xmsg->{'type'} == $XMSG_DONE) { if ($errmsg) { $finished_cb->($errmsg); diff --git a/perl/Amanda/Tests.c b/perl/Amanda/Tests.c index 44697d7..5177c57 100644 --- a/perl/Amanda/Tests.c +++ b/perl/Amanda/Tests.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1502,7 +1531,7 @@ static swig_module_info swig_module = {swig_types, 13, 0, 0, 0, 0}; #define SWIG_name "Amanda::Testsc::boot_Amanda__Tests" #define SWIG_prefix "Amanda::Testsc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1821,7 +1850,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; diff --git a/perl/Amanda/Tests.pm b/perl/Amanda/Tests.pm index 1a4c68c..e6b6b41 100644 --- a/perl/Amanda/Tests.pm +++ b/perl/Amanda/Tests.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/Util.c b/perl/Amanda/Util.c index 4c5799a..164245d 100644 --- a/perl/Amanda/Util.c +++ b/perl/Amanda/Util.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1498,7 +1527,7 @@ static swig_module_info swig_module = {swig_types, 9, 0, 0, 0, 0}; #define SWIG_name "Amanda::Utilc::boot_Amanda__Util" #define SWIG_prefix "Amanda::Utilc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1678,7 +1707,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -3016,6 +3047,190 @@ XS(_wrap_check_security) { } +XS(_wrap_match_host) { + { + char *arg1 = (char *) 0 ; + char *arg2 = (char *) 0 ; + int res1 ; + char *buf1 = 0 ; + int alloc1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + int argvi = 0; + gboolean result; + dXSARGS; + + if ((items < 2) || (items > 2)) { + SWIG_croak("Usage: match_host(pat,value);"); + } + res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_host" "', argument " "1"" of type '" "char *""'"); + } + arg1 = (char *)(buf1); + res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_host" "', argument " "2"" of type '" "char *""'"); + } + arg2 = (char *)(buf2); + result = (gboolean)match_host(arg1,arg2); + { + if (result) + ST(argvi) = &PL_sv_yes; + else + ST(argvi) = &PL_sv_no; + argvi++; + } + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + XSRETURN(argvi); + fail: + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + SWIG_croak_null(); + } +} + + +XS(_wrap_match_disk) { + { + char *arg1 = (char *) 0 ; + char *arg2 = (char *) 0 ; + int res1 ; + char *buf1 = 0 ; + int alloc1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + int argvi = 0; + gboolean result; + dXSARGS; + + if ((items < 2) || (items > 2)) { + SWIG_croak("Usage: match_disk(pat,value);"); + } + res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_disk" "', argument " "1"" of type '" "char *""'"); + } + arg1 = (char *)(buf1); + res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_disk" "', argument " "2"" of type '" "char *""'"); + } + arg2 = (char *)(buf2); + result = (gboolean)match_disk(arg1,arg2); + { + if (result) + ST(argvi) = &PL_sv_yes; + else + ST(argvi) = &PL_sv_no; + argvi++; + } + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + XSRETURN(argvi); + fail: + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + SWIG_croak_null(); + } +} + + +XS(_wrap_match_datestamp) { + { + char *arg1 = (char *) 0 ; + char *arg2 = (char *) 0 ; + int res1 ; + char *buf1 = 0 ; + int alloc1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + int argvi = 0; + gboolean result; + dXSARGS; + + if ((items < 2) || (items > 2)) { + SWIG_croak("Usage: match_datestamp(pat,value);"); + } + res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_datestamp" "', argument " "1"" of type '" "char *""'"); + } + arg1 = (char *)(buf1); + res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_datestamp" "', argument " "2"" of type '" "char *""'"); + } + arg2 = (char *)(buf2); + result = (gboolean)match_datestamp(arg1,arg2); + { + if (result) + ST(argvi) = &PL_sv_yes; + else + ST(argvi) = &PL_sv_no; + argvi++; + } + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + XSRETURN(argvi); + fail: + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + SWIG_croak_null(); + } +} + + +XS(_wrap_match_level) { + { + char *arg1 = (char *) 0 ; + char *arg2 = (char *) 0 ; + int res1 ; + char *buf1 = 0 ; + int alloc1 = 0 ; + int res2 ; + char *buf2 = 0 ; + int alloc2 = 0 ; + int argvi = 0; + gboolean result; + dXSARGS; + + if ((items < 2) || (items > 2)) { + SWIG_croak("Usage: match_level(pat,value);"); + } + res1 = SWIG_AsCharPtrAndSize(ST(0), &buf1, NULL, &alloc1); + if (!SWIG_IsOK(res1)) { + SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "match_level" "', argument " "1"" of type '" "char *""'"); + } + arg1 = (char *)(buf1); + res2 = SWIG_AsCharPtrAndSize(ST(1), &buf2, NULL, &alloc2); + if (!SWIG_IsOK(res2)) { + SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "match_level" "', argument " "2"" of type '" "char *""'"); + } + arg2 = (char *)(buf2); + result = (gboolean)match_level(arg1,arg2); + { + if (result) + ST(argvi) = &PL_sv_yes; + else + ST(argvi) = &PL_sv_no; + argvi++; + } + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + XSRETURN(argvi); + fail: + if (alloc1 == SWIG_NEWOBJ) free((char*)buf1); + if (alloc2 == SWIG_NEWOBJ) free((char*)buf2); + SWIG_croak_null(); + } +} + + XS(_wrap_set_pname) { { char *arg1 = (char *) 0 ; @@ -3303,6 +3518,10 @@ static swig_command_info swig_commands[] = { {"Amanda::Utilc::stream_server", _wrap_stream_server}, {"Amanda::Utilc::stream_accept", _wrap_stream_accept}, {"Amanda::Utilc::check_security", _wrap_check_security}, +{"Amanda::Utilc::match_host", _wrap_match_host}, +{"Amanda::Utilc::match_disk", _wrap_match_disk}, +{"Amanda::Utilc::match_datestamp", _wrap_match_datestamp}, +{"Amanda::Utilc::match_level", _wrap_match_level}, {"Amanda::Utilc::set_pname", _wrap_set_pname}, {"Amanda::Utilc::get_pname", _wrap_get_pname}, {"Amanda::Utilc::set_ptype", _wrap_set_ptype}, @@ -3605,63 +3824,63 @@ XS(SWIG_init) { SvREADONLY_on(sv); } - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "RUNNING_AS_ANY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(RUNNING_AS_ANY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "RUNNING_AS_ROOT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(RUNNING_AS_ROOT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "RUNNING_AS_DUMPUSER", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(RUNNING_AS_DUMPUSER))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "RUNNING_AS_DUMPUSER_PREFERRED", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(RUNNING_AS_DUMPUSER_PREFERRED))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "RUNNING_AS_CLIENT_LOGIN", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(RUNNING_AS_CLIENT_LOGIN))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "RUNNING_AS_UID_ONLY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(RUNNING_AS_UID_ONLY))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONTEXT_DEFAULT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONTEXT_DEFAULT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONTEXT_CMDLINE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONTEXT_CMDLINE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONTEXT_DAEMON", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONTEXT_DAEMON))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "CONTEXT_SCRIPTUTIL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(CONTEXT_SCRIPTUTIL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; SWIG_TypeClientData(SWIGTYPE_p_file_lock, (void*) "Amanda::Util::file_lock"); - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "AF_INET", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(AF_INET))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "STREAM_BUFSIZE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(STREAM_BUFSIZE))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Util.pm b/perl/Amanda/Util.pm index 2334e57..1443cb5 100644 --- a/perl/Amanda/Util.pm +++ b/perl/Amanda/Util.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. @@ -67,6 +67,10 @@ package Amanda::Util; *stream_server = *Amanda::Utilc::stream_server; *stream_accept = *Amanda::Utilc::stream_accept; *check_security = *Amanda::Utilc::check_security; +*match_host = *Amanda::Utilc::match_host; +*match_disk = *Amanda::Utilc::match_disk; +*match_datestamp = *Amanda::Utilc::match_datestamp; +*match_level = *Amanda::Utilc::match_level; *set_pname = *Amanda::Utilc::set_pname; *get_pname = *Amanda::Utilc::get_pname; *set_ptype = *Amanda::Utilc::set_ptype; @@ -542,7 +546,17 @@ function always completely overwrites the file. burp $filename, $header; These functions can (and should) be exported to the main namespace - + +=head1 MATCHING + +The following functions are available to match strings against patterns using +the rules described in amanda(8): + + match_host($pat, $str); + match_disk($pat, $str); + match_datestamp($pat, $str); + match_level($pat, $str); + =cut @@ -955,6 +969,8 @@ sub unmarshal_tapespec { } +push @EXPORT_OK, qw(match_host match_disk match_datestamp match_level); + sub check_std_fds { fcntl(STDIN, F_GETFD, 0) or critical("Standard input is not open"); fcntl(STDOUT, F_GETFD, 0) or critical("Standard output is not open"); diff --git a/perl/Amanda/Util.pod b/perl/Amanda/Util.pod index 3ee51aa..1b45a8c 100644 --- a/perl/Amanda/Util.pod +++ b/perl/Amanda/Util.pod @@ -421,7 +421,17 @@ function always completely overwrites the file. burp $filename, $header; These functions can (and should) be exported to the main namespace - + +=head1 MATCHING + +The following functions are available to match strings against patterns using +the rules described in amanda(8): + + match_host($pat, $str); + match_disk($pat, $str); + match_datestamp($pat, $str); + match_level($pat, $str); + =cut %} diff --git a/perl/Amanda/Util.swg b/perl/Amanda/Util.swg index f7ebaca..e325a9e 100644 --- a/perl/Amanda/Util.swg +++ b/perl/Amanda/Util.swg @@ -633,6 +633,16 @@ sub unmarshal_tapespec { %} +amglue_export_ok( + match_host match_disk match_datestamp match_level +); + +gboolean match_host(char *pat, char *value); +gboolean match_disk(char *pat, char *value); +gboolean match_datestamp(char *pat, char *value); +gboolean match_level(char *pat, char *value); + + /* ------------------------------------------------------------------------- * Functions below this line are only meant to be called within this module; * do not call them externally. */ diff --git a/perl/Amanda/Xfer.c b/perl/Amanda/Xfer.c index c18c951..4d3c0fc 100644 --- a/perl/Amanda/Xfer.c +++ b/perl/Amanda/Xfer.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1505,7 +1534,7 @@ static swig_module_info swig_module = {swig_types, 16, 0, 0, 0, 0}; #define SWIG_name "Amanda::Xferc::boot_Amanda__Xfer" #define SWIG_prefix "Amanda::Xferc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1649,7 +1678,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; @@ -3406,52 +3437,52 @@ XS(SWIG_init) { /* We need GType and GThread initialized to use xfers */ glib_init(); - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XFER_INIT", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XFER_INIT))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XFER_START", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XFER_START))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XFER_RUNNING", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XFER_RUNNING))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XFER_DONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XFER_DONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XMSG_INFO", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XMSG_INFO))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XMSG_ERROR", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XMSG_ERROR))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XMSG_DONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XMSG_DONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XMSG_CANCEL", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XMSG_CANCEL))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XMSG_PART_DONE", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XMSG_PART_DONE))); SvREADONLY_on(sv); } while(0) /*@SWIG@*/; - /*@SWIG:/usr/share/swig/1.3.39/perl5/perltypemaps.swg,65,%set_constant@*/ do { + /*@SWIG:/usr/share/swig/2.0.4/perl5/perltypemaps.swg,65,%set_constant@*/ do { SV *sv = get_sv((char*) SWIG_prefix "XMSG_READY", TRUE | 0x2 | GV_ADDMULTI); sv_setsv(sv, SWIG_From_int SWIG_PERL_CALL_ARGS_1((int)(XMSG_READY))); SvREADONLY_on(sv); diff --git a/perl/Amanda/Xfer.pm b/perl/Amanda/Xfer.pm index c77c933..2b8c3ff 100644 --- a/perl/Amanda/Xfer.pm +++ b/perl/Amanda/Xfer.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Amanda/XferServer.c b/perl/Amanda/XferServer.c index 8498069..4e4e80d 100644 --- a/perl/Amanda/XferServer.c +++ b/perl/Amanda/XferServer.c @@ -1,6 +1,6 @@ /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). - * Version 1.3.39 + * Version 2.0.4 * * This file is not intended to be easily readable and contains a number of * coding conventions designed to improve portability and efficiency. Do not make @@ -176,7 +176,7 @@ /* Flags/methods for returning states. - The SWIG conversion methods, as ConvertPtr, return and integer + The SWIG conversion methods, as ConvertPtr, return an integer that tells if the conversion was successful or not. And if not, an error code can be returned (see swigerrors.swg for the codes). @@ -897,6 +897,7 @@ SWIG_Perl_ErrorType(int code) { /* for raw pointers */ #define SWIG_ConvertPtr(obj, pp, type, flags) SWIG_Perl_ConvertPtr(SWIG_PERL_OBJECT_CALL obj, pp, type, flags) +#define SWIG_ConvertPtrAndOwn(obj, pp, type, flags,own) SWIG_Perl_ConvertPtrAndOwn(SWIG_PERL_OBJECT_CALL obj, pp, type, flags, own) #define SWIG_NewPointerObj(p, type, flags) SWIG_Perl_NewPointerObj(SWIG_PERL_OBJECT_CALL p, type, flags) /* for raw packed data */ @@ -1113,10 +1114,14 @@ SWIG_TypeProxyCheck(const char *c, swig_type_info *ty) { /* Function for getting a pointer value */ SWIGRUNTIME int -SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { +SWIG_Perl_ConvertPtrAndOwn(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags, int *own) { swig_cast_info *tc; void *voidptr = (void *)0; SV *tsv = 0; + + if (own) + *own = 0; + /* If magical, apply more magic */ if (SvGMAGICAL(sv)) mg_get(sv); @@ -1148,8 +1153,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } else if (SvTYPE(sv) == SVt_RV) { /* Check for NULL pointer */ if (!SvROK(sv)) { - *(ptr) = (void *) 0; - return SWIG_OK; + /* In Perl 5.12 and later, SVt_RV == SVt_IV, so sv could be a valid integer value. */ + if (SvIOK(sv)) { + return SWIG_ERROR; + } else { + /* NULL pointer (reference to undef). */ + *(ptr) = (void *) 0; + return SWIG_OK; + } } else { return SWIG_ERROR; } @@ -1166,7 +1177,11 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * { int newmemory = 0; *ptr = SWIG_TypeCast(tc,voidptr,&newmemory); - assert(!newmemory); /* newmemory handling not yet implemented */ + if (newmemory == SWIG_CAST_NEW_MEMORY) { + assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */ + if (own) + *own = *own | SWIG_CAST_NEW_MEMORY; + } } } else { *ptr = voidptr; @@ -1181,7 +1196,7 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * */ SV *obj = sv; HV *stash = SvSTASH(SvRV(obj)); - GV *gv = *(GV**) hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (isGV(gv)) { HV *hv = GvHVn(gv); /* @@ -1196,9 +1211,14 @@ SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info * return SWIG_OK; } +SWIGRUNTIME int +SWIG_Perl_ConvertPtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void **ptr, swig_type_info *_t, int flags) { + return SWIG_Perl_ConvertPtrAndOwn(sv, ptr, _t, flags, 0); +} + SWIGRUNTIME void SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, int flags) { - if (ptr && (flags & SWIG_SHADOW)) { + if (ptr && (flags & (SWIG_SHADOW | SWIG_POINTER_OWN))) { SV *self; SV *obj=newSV(0); HV *hash=newHV(); @@ -1207,7 +1227,7 @@ SWIG_Perl_MakePtr(SWIG_MAYBE_PERL_OBJECT SV *sv, void *ptr, swig_type_info *t, i stash=SvSTASH(SvRV(obj)); if (flags & SWIG_POINTER_OWN) { HV *hv; - GV *gv=*(GV**)hv_fetch(stash, "OWNER", 5, TRUE); + GV *gv = *(GV**)hv_fetch(stash, "OWNER", 5, TRUE); if (!isGV(gv)) gv_init(gv, stash, "OWNER", 5, FALSE); hv=GvHVn(gv); @@ -1373,6 +1393,9 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef do_close #undef do_close #endif +#ifdef do_exec + #undef do_exec +#endif #ifdef scalar #undef scalar #endif @@ -1463,6 +1486,12 @@ SWIG_Perl_SetModule(swig_module_info *module) { #ifdef bind #undef bind #endif +#ifdef access + #undef access +#endif +#ifdef stat + #undef stat +#endif @@ -1502,7 +1531,7 @@ static swig_module_info swig_module = {swig_types, 13, 0, 0, 0, 0}; #define SWIG_name "Amanda::XferServerc::boot_Amanda__XferServer" #define SWIG_prefix "Amanda::XferServerc::" -#define SWIGVERSION 0x010339 +#define SWIGVERSION 0x020004 #define SWIG_VERSION SWIGVERSION @@ -1562,7 +1591,9 @@ SWIG_AsVal_double SWIG_PERL_DECL_ARGS_2(SV *obj, double *val) const char *nptr = SvPV_nolen(obj); if (nptr) { char *endptr; - double v = strtod(nptr, &endptr); + double v; + errno = 0; + v = strtod(nptr, &endptr); if (errno == ERANGE) { errno = 0; return SWIG_OverflowError; diff --git a/perl/Amanda/XferServer.pm b/perl/Amanda/XferServer.pm index 9ab00da..a1d30ff 100644 --- a/perl/Amanda/XferServer.pm +++ b/perl/Amanda/XferServer.pm @@ -1,5 +1,5 @@ # This file was automatically generated by SWIG (http://www.swig.org). -# Version 1.3.39 +# Version 2.0.4 # # Do not make changes to this file unless you know what you are doing--modify # the SWIG interface file instead. diff --git a/perl/Makefile.am b/perl/Makefile.am index f58c970..7c953c1 100644 --- a/perl/Makefile.am +++ b/perl/Makefile.am @@ -53,7 +53,7 @@ endif html: make_html amperl.css $(PM_FILES) rm -rf html-tmp/ && mkdir html-tmp/ cp amperl.css html-tmp/ - $(PERL) make_html html-tmp/ $(PM_FILES) + $(PERL) make_html --homeurl "$(POD_HOME_URL)" html-tmp/ $(PM_FILES) cd html-tmp/ && tar -zcf $(abs_builddir)/html.tar.gz . rm -rf html-tmp/ ## diff --git a/perl/Makefile.in b/perl/Makefile.in index 12efc10..87e58ab 100644 --- a/perl/Makefile.in +++ b/perl/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -706,6 +706,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -1138,6 +1139,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -1187,6 +1189,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -1195,6 +1198,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -1202,6 +1206,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1346,6 +1352,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1379,6 +1386,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1421,7 +1429,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -2861,7 +2868,7 @@ uninstall-Amanda_DBDATA: # (which will cause the Makefiles to be regenerated when you run `make'); # (2) otherwise, pass the desired values on the `make' command line. $(RECURSIVE_TARGETS): - @failcom='exit 1'; \ + @fail= failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ @@ -2886,7 +2893,7 @@ $(RECURSIVE_TARGETS): fi; test -z "$$fail" $(RECURSIVE_CLEAN_TARGETS): - @failcom='exit 1'; \ + @fail= failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ @@ -3384,7 +3391,7 @@ dist-hook: dist-scripts html: make_html amperl.css $(PM_FILES) rm -rf html-tmp/ && mkdir html-tmp/ cp amperl.css html-tmp/ - $(PERL) make_html html-tmp/ $(PM_FILES) + $(PERL) make_html --homeurl "$(POD_HOME_URL)" html-tmp/ $(PM_FILES) cd html-tmp/ && tar -zcf $(abs_builddir)/html.tar.gz . rm -rf html-tmp/ diff --git a/perl/amglue/Makefile.in b/perl/amglue/Makefile.in index c5cd863..f12ba03 100644 --- a/perl/amglue/Makefile.in +++ b/perl/amglue/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -399,6 +399,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -831,6 +832,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -880,6 +882,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -888,6 +891,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -895,6 +899,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1039,6 +1045,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1072,6 +1079,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1114,7 +1122,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/po/Makefile.in b/po/Makefile.in index 21e93fe..0acd669 100644 --- a/po/Makefile.in +++ b/po/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -259,6 +259,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -691,6 +692,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = msgfmt @@ -740,6 +742,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -750,6 +753,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -757,6 +761,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -901,6 +907,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -934,6 +941,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -976,7 +984,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = $(datadir)/locale localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/recover-src/Makefile.in b/recover-src/Makefile.in index 3ba913b..fa8f5e4 100644 --- a/recover-src/Makefile.in +++ b/recover-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -377,6 +377,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -809,6 +810,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -858,6 +860,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -866,6 +869,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -873,6 +877,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1017,6 +1023,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1050,6 +1057,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1092,7 +1100,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ diff --git a/recover-src/amrecover.c b/recover-src/amrecover.c index 2764abb..e0d7c18 100644 --- a/recover-src/amrecover.c +++ b/recover-src/amrecover.c @@ -41,6 +41,7 @@ #include "event.h" #include "security.h" #include "conffile.h" +#include "getopt.h" #define amrecover_debug(i, ...) do { \ if ((i) <= debug_amrecover) { \ @@ -48,13 +49,18 @@ } \ } while (0) +static struct option long_options[] = { + {"version" , 0, NULL, 1}, + {NULL, 0, NULL, 0} +}; + extern int process_line(char *line); int get_line(void); int grab_reply(int show); void sigint_handler(int signum); int main(int argc, char **argv); -#define USAGE _("Usage: amrecover [[-C] ] [-s ] [-t ] [-d ] [-o ]*\n") +#define USAGE _("Usage: amrecover [--version] [[-C] ] [-s ] [-t ] [-d ] [-o ]*\n") char *server_name = NULL; int server_socket; @@ -65,6 +71,7 @@ char *disk_name = NULL; /* disk we are restoring */ dle_t *dump_dle = NULL; char *mount_point = NULL; /* where disk was mounted */ char *disk_path = NULL; /* path relative to mount point */ +char *disk_tpath = NULL; /* translated path relative to mount point */ char dump_date[STR_SIZE]; /* date on which we are restoring */ int quit_prog; /* set when time to exit parser */ char *tape_server_name = NULL; @@ -272,7 +279,7 @@ sigint_handler( } -void +char * clean_pathname( char * s) { @@ -290,6 +297,8 @@ clean_pathname( /* remove "/." at end of path */ if(strcmp(&(s[length-2]),"/.")==0) s[length-2]='\0'; + + return s; } @@ -360,8 +369,12 @@ main( } /* now parse regular command-line '-' options */ - while ((i = getopt(argc, argv, "o:C:s:t:d:Uh:")) != EOF) { + while ((i = getopt_long(argc, argv, "o:C:s:t:d:Uh:", long_options, NULL)) != EOF) { switch (i) { + case 1: + printf("amrecover-%s\n", VERSION); + return(0); + break; case 'C': add_config_override(cfg_ovr, "conf", optarg); break; @@ -487,6 +500,7 @@ main( amfree(disk_name); amfree(mount_point); amfree(disk_path); + amfree(disk_tpath); dump_date[0] = '\0'; /* Don't die when child closes pipe */ @@ -831,3 +845,40 @@ stop_amindexd(void) } } } + + +char * +translate_octal( + char *line) +{ + char *s = line, *s1, *s2; + char *p = line; + int i; + + if (!translate_mode) + return strdup(line); + + while(*s != '\0') { + if ((s == line || *(s-1) != '\\') && *s == '\\') { + s++; + s1 = s+1; + s2 = s+2; + if (g_ascii_isdigit(*s) && *s1 != '\0' && + g_ascii_isdigit(*s1) && + g_ascii_isdigit(*s2)) { + i = ((*s)-'0')*64 + ((*s1)-'0')*8 + ((*s2)-'0'); + *p++ = i; + s += 3; + } else { + *p++ = *s++; + } + + } else { + *p++ = *s++; + } + } + *p = '\0'; + + return line; +} + diff --git a/recover-src/amrecover.h b/recover-src/amrecover.h index e63e7f4..efbfa89 100644 --- a/recover-src/amrecover.h +++ b/recover-src/amrecover.h @@ -42,6 +42,7 @@ typedef struct DIR_ITEM int level; char *tape; char *path; + char *tpath; /* translated path */ off_t fileno; struct DIR_ITEM *next; @@ -56,6 +57,7 @@ extern char *disk_name; /* disk we are restoring */ extern dle_t *dump_dle; extern char *mount_point; /* where disk was mounted */ extern char *disk_path; /* path relative to mount point */ +extern char *disk_tpath; /* translated path relative to mount point */ extern char dump_date[STR_SIZE]; /* date on which we are restoring */ extern int quit_prog; /* set when time to exit parser */ extern char *tape_server_name; @@ -67,6 +69,7 @@ extern am_feature_t *indexsrv_features; extern am_feature_t *tapesrv_features; extern pid_t extract_restore_child_pid; extern proplist_t proplist; +extern gboolean translate_mode; extern void free_dir_item(DIR_ITEM *item); @@ -93,6 +96,7 @@ extern int cd_regex(char *dir, int verbose); extern int cd_dir(char *dir, char *default_dir, int verbose); extern void set_tape(char *tape); extern void set_device(char *host, char *device); +extern void set_translate(char *translate); extern void show_directory(void); extern void set_mode(int mode); extern void show_mode(void); @@ -106,7 +110,7 @@ extern DIR_ITEM *get_dir_list(void); extern DIR_ITEM *get_next_dir_item(DIR_ITEM *this); extern void suck_dir_list_from_server(void); extern void clear_dir_list(void); -extern void clean_pathname(char *s); +extern char *clean_pathname(char *s); extern void display_extract_list(char *file); extern void clear_extract_list(void); extern int is_extract_list_nonempty(void); @@ -124,3 +128,4 @@ extern void extract_files(void); extern char *get_security(void); extern void stop_amindexd(void); +extern char *translate_octal(char *line); diff --git a/recover-src/display_commands.c b/recover-src/display_commands.c index 165de61..d18b868 100644 --- a/recover-src/display_commands.c +++ b/recover-src/display_commands.c @@ -33,6 +33,8 @@ #include "amrecover.h" #include "util.h" +gboolean translate_mode = TRUE; + DIR_ITEM *get_dir_list(void); DIR_ITEM *get_next_dir_item(DIR_ITEM *this); @@ -83,6 +85,7 @@ free_dir_item( amfree(item->date); amfree(item->tape); amfree(item->path); + amfree(item->tpath); amfree(item); item = next; } @@ -110,6 +113,7 @@ add_dir_list_item( next->tape = stralloc(tape); next->fileno = fileno; next->path = stralloc(path); + next->tpath = translate_octal(g_strdup(path)); next->next = dir_list; dir_list = next; @@ -313,11 +317,11 @@ list_directory(void) fp = stdout; } amfree(pager_command); - i = strlen(disk_path); + i = strlen(disk_tpath); if (i != 1) - i++; /* so disk_path != "/" */ + i++; /* so disk_tpath != "/" */ for (item = get_dir_list(); item != NULL; item=get_next_dir_item(item)) { - quoted = quote_string(item->path + i); + quoted = quote_string(item->tpath + i); g_fprintf(fp, "%s %s\n", item->date, quoted); amfree(quoted); } diff --git a/recover-src/extract_list.c b/recover-src/extract_list.c index 9f7217b..a5a4251 100644 --- a/recover-src/extract_list.c +++ b/recover-src/extract_list.c @@ -49,6 +49,7 @@ typedef struct EXTRACT_LIST_ITEM { char *path; + char *tpath; struct EXTRACT_LIST_ITEM *next; } EXTRACT_LIST_ITEM; @@ -272,6 +273,7 @@ clear_tape_list( { next = this->next; amfree(this->path); + amfree(this->tpath); amfree(this); this = next; } @@ -385,6 +387,7 @@ clean_tape_list( ofn2 = fn2; fn2 = fn2->next; amfree(ofn2->path); + amfree(ofn2->tpath); amfree(ofn2); pfn2->next = fn2; } else if (remove_fn1 == 0) { @@ -396,10 +399,11 @@ clean_tape_list( if(remove_fn1 != 0) { /* fn2->path is always valid */ /*@i@*/ dbprintf(_("removing path %s, it is included in %s\n"), - /*@i@*/ fn1->path, fn2->path); + /*@i@*/ fn1->tpath, fn2->tpath); ofn1 = fn1; fn1 = fn1->next; amfree(ofn1->path); + amfree(ofn1->tpath); if(pfn1 == NULL) { amfree(tape_list->files); tape_list->files = fn1; @@ -583,7 +587,7 @@ add_extract_item( { EXTRACT_LIST *this, *this1; EXTRACT_LIST_ITEM *that, *curr; - char *ditem_path = NULL; + char *ditem_path; ditem_path = stralloc(ditem->path); clean_pathname(ditem_path); @@ -598,16 +602,16 @@ add_extract_item( while(curr!=NULL) { if (strcmp(curr->path,ditem_path) == 0) { - amfree(ditem_path); + g_free(ditem_path); return 1; } curr=curr->next; } that = (EXTRACT_LIST_ITEM *)alloc(sizeof(EXTRACT_LIST_ITEM)); - that->path = stralloc(ditem_path); + that->path = ditem_path; + that->tpath = clean_pathname(g_strdup(ditem->tpath)); that->next = this->files; this->files = that; /* add at front since easiest */ - amfree(ditem_path); return 0; } } @@ -619,7 +623,8 @@ add_extract_item( this->fileno = ditem->fileno; this->date = stralloc(ditem->date); that = (EXTRACT_LIST_ITEM *)alloc(sizeof(EXTRACT_LIST_ITEM)); - that->path = stralloc(ditem_path); + that->path = ditem_path; + that->tpath = clean_pathname(g_strdup(ditem->tpath)); that->next = NULL; this->files = that; @@ -630,7 +635,6 @@ add_extract_item( { this->next = extract_list; extract_list = this; - amfree(ditem_path); return 0; } for (this1 = extract_list; this1->next != NULL; this1 = this1->next) @@ -640,14 +644,12 @@ add_extract_item( { this->next = this1->next; this1->next = this; - amfree(ditem_path); return 0; } } /* add at end */ this->next = NULL; this1->next = this; - amfree(ditem_path); return 0; } @@ -678,6 +680,7 @@ delete_extract_item( /* first on list */ this->files = that->next; amfree(that->path); + amfree(that->tpath); amfree(that); /* if list empty delete it */ if (this->files == NULL) @@ -693,6 +696,7 @@ delete_extract_item( { prev->next = that->next; amfree(that->path); + amfree(that->tpath); amfree(that); amfree(ditem_path); return 0; @@ -826,12 +830,12 @@ add_file( char * regex) { DIR_ITEM *ditem, lditem; - char *path_on_disk = NULL; + char *tpath_on_disk = NULL; char *cmd = NULL; char *err = NULL; int i; ssize_t j; - char *dir, *dir_undo, dir_undo_ch = '\0'; + char *dir_undo, dir_undo_ch = '\0'; char *ditem_path = NULL; char *qditem_path = NULL; char *l = NULL; @@ -865,34 +869,34 @@ add_file( if (strcmp(disk_path, "/") == 0) { if (*regex == '/') { /* No mods needed if already starts with '/' */ - path_on_disk = stralloc(regex); + tpath_on_disk = g_strdup(regex); } else { /* Prepend '/' */ - path_on_disk = stralloc2("/", regex); + tpath_on_disk = g_strconcat("/", regex, NULL); } } else { - char *clean_disk_path = clean_regex(disk_path, 0); - path_on_disk = vstralloc(clean_disk_path, "/", regex, NULL); - amfree(clean_disk_path); + char *clean_disk_tpath = clean_regex(disk_tpath, 0); + tpath_on_disk = g_strjoin(NULL, clean_disk_tpath, "/", regex, NULL); + amfree(clean_disk_tpath); } - dbprintf(_("add_file: Converted path=\"%s\" to path_on_disk=\"%s\"\n"), - regex, path_on_disk); + dbprintf(_("add_file: Converted path=\"%s\" to tpath_on_disk=\"%s\"\n"), + regex, tpath_on_disk); found_one = 0; dir_entries = 0; for (ditem=get_dir_list(); ditem!=NULL; ditem=get_next_dir_item(ditem)) { dir_entries++; - quoted = quote_string(ditem->path); + quoted = quote_string(ditem->tpath); dbprintf(_("add_file: Pondering ditem->path=%s\n"), quoted); amfree(quoted); - if (match(path_on_disk, ditem->path)) + if (match(tpath_on_disk, ditem->tpath)) { found_one = 1; - j = (ssize_t)strlen(ditem->path); - if((j > 0 && ditem->path[j-1] == '/') - || (j > 1 && ditem->path[j-2] == '/' && ditem->path[j-1] == '.')) + j = (ssize_t)strlen(ditem->tpath); + if((j > 0 && ditem->tpath[j-1] == '/') + || (j > 1 && ditem->tpath[j-2] == '/' && ditem->tpath[j-1] == '.')) { /* It is a directory */ ditem_path = newstralloc(ditem_path, ditem->path); clean_pathname(ditem_path); @@ -903,7 +907,7 @@ add_file( if(send_command(cmd) == -1) { amfree(cmd); amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); exit(1); } amfree(cmd); @@ -911,25 +915,28 @@ add_file( /* skip preamble */ if ((i = get_reply_line()) == -1) { amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); exit(1); } if(i==0) { /* assume something wrong */ amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); l = reply_line(); g_printf("%s\n", l); return; } dir_undo = NULL; added=0; - lditem.path = newstralloc(lditem.path, ditem->path); + g_free(lditem.path); + g_free(lditem.tpath); + lditem.path = g_strdup(ditem->path); + lditem.tpath = g_strdup(ditem->tpath); /* skip the last line -- duplicate of the preamble */ while ((i = get_reply_line()) != 0) { if (i == -1) { amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); exit(1); } if(err) { @@ -1000,7 +1007,6 @@ add_file( err = _("bad reply: missing directory field"); continue; } - dir = s - 1; skip_quoted_string(s, ch); dir_undo = s - 1; dir_undo_ch = *dir_undo; @@ -1013,7 +1019,7 @@ add_file( break; case 0: - quoted = quote_string(lditem.path); + quoted = quote_string(lditem.tpath); g_printf(_("Added dir %s at date %s\n"), quoted, lditem.date); dbprintf(_("add_file: (Successful) Added dir %s at date %s\n"), @@ -1049,14 +1055,14 @@ add_file( break; case 0: - quoted = quote_string(ditem->path); + quoted = quote_string(ditem->tpath); g_printf(_("Added file %s\n"), quoted); dbprintf(_("add_file: (Successful) Added %s\n"), quoted); amfree(quoted); break; case 1: - quoted = quote_string(ditem->path); + quoted = quote_string(ditem->tpath); g_printf(_("File %s already added\n"), quoted); dbprintf(_("add_file: file %s already added\n"), quoted); amfree(quoted); @@ -1067,9 +1073,10 @@ add_file( amfree(cmd); amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); amfree(lditem.path); + amfree(lditem.tpath); amfree(lditem.date); amfree(lditem.tape); @@ -1181,11 +1188,11 @@ delete_regex( void delete_file( - char * path, + char * tpath, char * regex) { DIR_ITEM *ditem, lditem; - char *path_on_disk = NULL; + char *tpath_on_disk = NULL; char *cmd = NULL; char *err = NULL; int i; @@ -1194,8 +1201,8 @@ delete_file( char *tape, *tape_undo, tape_undo_ch = '\0'; char *dir_undo, dir_undo_ch = '\0'; int level = 0; - off_t fileno; char *ditem_path = NULL; + char *ditem_tpath = NULL; char *qditem_path; char *l = NULL; int deleted; @@ -1210,7 +1217,7 @@ delete_file( } memset(&lditem, 0, sizeof(lditem)); /* Prevent use of bogus data... */ - dbprintf(_("delete_file: Looking for \"%s\"\n"), path); + dbprintf(_("delete_file: Looking for \"%s\"\n"), tpath); if (strcmp(regex, "[^/]*[/]*$") == 0) { /* Looking for * find everything but single . */ @@ -1226,38 +1233,40 @@ delete_file( if (*regex == '/') { if (strcmp(regex, "/[/]*$") == 0) { /* We want "/" to match the directory itself: "/." */ - path_on_disk = stralloc("/\\.[/]*$"); + tpath_on_disk = stralloc("/\\.[/]*$"); } else { /* No mods needed if already starts with '/' */ - path_on_disk = stralloc(regex); + tpath_on_disk = stralloc(regex); } } else { /* Prepend '/' */ - path_on_disk = stralloc2("/", regex); + tpath_on_disk = g_strconcat("/", regex, NULL); } } else { - char *clean_disk_path = clean_regex(disk_path, 0); - path_on_disk = vstralloc(clean_disk_path, "/", regex, NULL); - amfree(clean_disk_path); + char *clean_disk_tpath = clean_regex(disk_tpath, 0); + tpath_on_disk = g_strjoin(NULL, clean_disk_tpath, "/", regex, NULL); + amfree(clean_disk_tpath); } - dbprintf(_("delete_file: Converted path=\"%s\" to path_on_disk=\"%s\"\n"), - regex, path_on_disk); + dbprintf(_("delete_file: Converted path=\"%s\" to tpath_on_disk=\"%s\"\n"), + regex, tpath_on_disk); found_one = 0; for (ditem=get_dir_list(); ditem!=NULL; ditem=get_next_dir_item(ditem)) { - quoted = quote_string(ditem->path); + quoted = quote_string(ditem->tpath); dbprintf(_("delete_file: Pondering ditem->path=%s\n"), quoted); amfree(quoted); - if (match(path_on_disk, ditem->path)) + if (match(tpath_on_disk, ditem->tpath)) { found_one = 1; - j = (ssize_t)strlen(ditem->path); - if((j > 0 && ditem->path[j-1] == '/') - || (j > 1 && ditem->path[j-2] == '/' && ditem->path[j-1] == '.')) + j = (ssize_t)strlen(ditem->tpath); + if((j > 0 && ditem->tpath[j-1] == '/') + || (j > 1 && ditem->tpath[j-2] == '/' && ditem->tpath[j-1] == '.')) { /* It is a directory */ ditem_path = newstralloc(ditem_path, ditem->path); + ditem_tpath = newstralloc(ditem_tpath, ditem->tpath); clean_pathname(ditem_path); + clean_pathname(ditem_tpath); qditem_path = quote_string(ditem_path); cmd = newstralloc2(cmd, "ORLD ", qditem_path); @@ -1265,26 +1274,27 @@ delete_file( if(send_command(cmd) == -1) { amfree(cmd); amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); exit(1); } amfree(cmd); /* skip preamble */ if ((i = get_reply_line()) == -1) { amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); exit(1); } if(i==0) /* assume something wrong */ { amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); l = reply_line(); g_printf("%s\n", l); return; } deleted=0; lditem.path = newstralloc(lditem.path, ditem->path); + lditem.tpath = newstralloc(lditem.tpath, ditem->tpath); amfree(cmd); tape_undo = dir_undo = NULL; /* skip the last line -- duplicate of the preamble */ @@ -1292,7 +1302,7 @@ delete_file( { if (i == -1) { amfree(ditem_path); - amfree(path_on_disk); + amfree(tpath_on_disk); exit(1); } if(err) { @@ -1352,7 +1362,6 @@ delete_file( err = _("bad reply: cannot parse fileno field"); continue; } - fileno = (off_t)fileno_; skip_integer(s, ch); } @@ -1368,16 +1377,17 @@ delete_file( lditem.date = newstralloc(lditem.date, date); lditem.level=level; - lditem.tape = newstralloc(lditem.tape, tape); + g_free(lditem.tape); + lditem.tape = unquote_string(tape); switch(delete_extract_item(&lditem)) { case -1: g_printf(_("System error\n")); dbprintf(_("delete_file: (Failed) System error\n")); break; case 0: - g_printf(_("Deleted dir %s at date %s\n"), ditem_path, date); + g_printf(_("Deleted dir %s at date %s\n"), ditem_tpath, date); dbprintf(_("delete_file: (Successful) Deleted dir %s at date %s\n"), - ditem_path, date); + ditem_tpath, date); deleted=1; break; case 1: @@ -1393,9 +1403,9 @@ delete_file( puts(cmd); } else if(deleted == 0) { g_printf(_("Warning - dir '%s' not on tape list\n"), - ditem_path); + ditem_tpath); dbprintf(_("delete_file: dir '%s' not on tape list\n"), - ditem_path); + ditem_tpath); } } else @@ -1406,15 +1416,15 @@ delete_file( dbprintf(_("delete_file: (Failed) System error\n")); break; case 0: - g_printf(_("Deleted %s\n"), ditem->path); + g_printf(_("Deleted %s\n"), ditem->tpath); dbprintf(_("delete_file: (Successful) Deleted %s\n"), - ditem->path); + ditem->tpath); break; case 1: g_printf(_("Warning - file '%s' not on tape list\n"), - ditem->path); + ditem->tpath); dbprintf(_("delete_file: file '%s' not on tape list\n"), - ditem->path); + ditem->tpath); break; } } @@ -1422,12 +1432,13 @@ delete_file( } amfree(cmd); amfree(ditem_path); - amfree(path_on_disk); + amfree(ditem_tpath); + amfree(tpath_on_disk); if(! found_one) { - g_printf(_("File %s doesn't exist in directory\n"), path); + g_printf(_("File %s doesn't exist in directory\n"), tpath); dbprintf(_("delete_file: (Failed) File %s doesn't exist in directory\n"), - path); + tpath); } } @@ -1479,7 +1490,7 @@ display_extract_list( g_fprintf(fp, _("TAPE %s LEVEL %d DATE %s\n"), this->tape, this->level, this->date); for (that = this->files; that != NULL; that = that->next) - g_fprintf(fp, "\t%s\n", that->path); + g_fprintf(fp, "\t%s\n", that->tpath); } if (file == NULL) { @@ -1688,7 +1699,14 @@ extract_files_setup( tt = newstralloc2(tt, "FEATURES=", our_features_string); send_to_tape_server(amidxtaped_streams[CTLFD].fd, tt); get_amidxtaped_line(); - if(strncmp_const(amidxtaped_line,"FEATURES=") == 0) { + if (!amidxtaped_line) { + g_fprintf(stderr, _("amrecover - amidxtaped closed the connection\n")); + stop_amidxtaped(); + amfree(disk_regex); + amfree(host_regex); + amfree(clean_datestamp); + return -1; + } else if(strncmp_const(amidxtaped_line,"FEATURES=") == 0) { tapesrv_features = am_string_to_feature(amidxtaped_line+9); } else { g_fprintf(stderr, _("amrecover - expecting FEATURES line from amidxtaped\n")); @@ -1907,7 +1925,6 @@ extract_files_child( case IS_DUMP: g_ptr_array_add(argv_ptr, stralloc("restore")); #ifdef AIX_BACKUP - restore_args[j++] = stralloc("-xB"); g_ptr_array_add(argv_ptr, stralloc("-xB")); #else #if defined(XFSDUMP) diff --git a/recover-src/help.c b/recover-src/help.c index b56082b..f045de3 100644 --- a/recover-src/help.c +++ b/recover-src/help.c @@ -66,5 +66,6 @@ help_list(void) g_printf(_("setdevice [[-h host] device] - select tape server and/or device\n")); g_printf(_("setproperty [append] [priority] name [value ...] - set a property\n")); g_printf(_("setmode smb|tar - select the method used to extract SMB shares\n")); + g_printf(_("settranslate [on|off] - set/unset translation of non-ASCII characters\n")); g_printf("\n"); } diff --git a/recover-src/set_commands.c b/recover-src/set_commands.c index 1125364..e741287 100644 --- a/recover-src/set_commands.c +++ b/recover-src/set_commands.c @@ -69,6 +69,7 @@ set_date( g_printf(_("No index records for cwd on new date\n")); g_printf(_("Setting cwd to mount point\n")); disk_path = newstralloc(disk_path, "/"); /* fake it */ + disk_tpath = newstralloc(disk_tpath, "/"); /* fake it */ clear_dir_list(); } } @@ -165,6 +166,7 @@ set_host( amfree(disk_name); amfree(mount_point); amfree(disk_path); + amfree(disk_tpath); clear_dir_list(); } amfree(cmd); @@ -254,6 +256,7 @@ set_disk( if (server_happy()) { disk_path = newstralloc(disk_path, "/"); + disk_tpath = newstralloc(disk_tpath, "/"); suck_dir_list_from_server(); /* get list of directory contents */ } else @@ -261,6 +264,7 @@ set_disk( g_printf(_("No index records for disk for specified date\n")); g_printf(_("If date correct, notify system administrator\n")); disk_path = newstralloc(disk_path, "/"); /* fake it */ + disk_tpath = newstralloc(disk_tpath, "/"); /* fake it */ clear_dir_list(); } amfree(uqmtpt); @@ -423,7 +427,7 @@ cd_glob( char *uqglob; int result; - char *path_on_disk = NULL; + char *tpath_on_disk = NULL; if (disk_name == NULL) { g_printf(_("Must select disk before changing directory\n")); @@ -455,17 +459,17 @@ cd_glob( /* convert path (assumed in cwd) to one on disk */ if (strcmp(disk_path, "/") == 0) - path_on_disk = stralloc2("/", regex_path); + tpath_on_disk = stralloc2("/", regex_path); else { - char *clean_disk_path = clean_regex(disk_path, 0); - path_on_disk = vstralloc(clean_disk_path, "/", regex_path, NULL); - amfree(clean_disk_path); + char *clean_disk_tpath = clean_regex(disk_tpath, 0); + tpath_on_disk = vstralloc(clean_disk_tpath, "/", regex_path, NULL); + amfree(clean_disk_tpath); } - result = cd_dir(path_on_disk, uqglob, verbose); + result = cd_dir(tpath_on_disk, uqglob, verbose); amfree(regex_path); - amfree(path_on_disk); + amfree(tpath_on_disk); amfree(uqglob); return result; @@ -482,7 +486,7 @@ cd_regex( int len_uqregex; int result; - char *path_on_disk = NULL; + char *tpath_on_disk = NULL; if (disk_name == NULL) { g_printf(_("Must select disk before changing directory\n")); @@ -513,16 +517,16 @@ cd_regex( /* convert path (assumed in cwd) to one on disk */ if (strcmp(disk_path, "/") == 0) - path_on_disk = stralloc2("/", uqregex); + tpath_on_disk = stralloc2("/", uqregex); else { - char *clean_disk_path = clean_regex(disk_path, 0); - path_on_disk = vstralloc(clean_disk_path, "/", regex, NULL); - amfree(clean_disk_path); + char *clean_disk_tpath = clean_regex(disk_tpath, 0); + tpath_on_disk = vstralloc(clean_disk_tpath, "/", regex, NULL); + amfree(clean_disk_tpath); } - result = cd_dir(path_on_disk, uq_orig_regex, verbose); + result = cd_dir(tpath_on_disk, uq_orig_regex, verbose); - amfree(path_on_disk); + amfree(tpath_on_disk); amfree(uqregex); amfree(uq_orig_regex); @@ -531,9 +535,9 @@ cd_regex( int cd_dir( - char * path_on_disk, - char * default_dir, - int verbose) + char *tpath_on_disk, + char *default_dir, + int verbose) { char *dir = NULL; char *s; @@ -543,7 +547,7 @@ cd_dir( DIR_ITEM *ditem; - if ((s = validate_regexp(path_on_disk)) != NULL) { + if ((s = validate_regexp(tpath_on_disk)) != NULL) { result = set_directory(default_dir, verbose); return result; } @@ -553,11 +557,11 @@ cd_dir( for (ditem=get_dir_list(); ditem!=NULL && nb_found <= 1; ditem=get_next_dir_item(ditem)) { - if (match(path_on_disk, ditem->path)) + if (match(tpath_on_disk, ditem->tpath)) { - i = strlen(ditem->path); - if((i > 0 && ditem->path[i-1] == '/') - || (i > 1 && ditem->path[i-2] == '/' && ditem->path[i-1] == '.')) + i = strlen(ditem->tpath); + if((i > 0 && ditem->tpath[i-1] == '/') + || (i > 1 && ditem->tpath[i-2] == '/' && ditem->tpath[i-1] == '.')) { /* It is a directory */ char *dir1, *dir2; nb_found++; @@ -590,6 +594,7 @@ cd_dir( return result; } +/* dir is relative to dir_path or absolute with mount_point */ int set_directory( char * dir, @@ -707,6 +712,8 @@ set_directory( if (server_happy()) { disk_path = newstralloc(disk_path, new_dir); + g_free(disk_tpath); + disk_tpath = translate_octal(g_strdup(disk_path)); suck_dir_list_from_server(); /* get list of directory contents */ if (verbose) show_directory(); /* say where we moved to */ @@ -734,11 +741,11 @@ show_directory(void) if (mount_point == NULL || disk_path == NULL) g_printf(_("Must select disk first\n")); else if (strcmp(mount_point, "/") == 0) - g_printf("%s\n", disk_path); + g_printf("%s\n", disk_tpath); else if (strcmp(disk_path, "/") == 0) g_printf("%s\n", mount_point); else - g_printf("%s%s\n", mount_point, disk_path); + g_printf("%s%s\n", mount_point, disk_tpath); } @@ -821,6 +828,23 @@ set_device( server_name); } +void +set_translate( + char *translate) +{ + + if (translate == NULL) { + translate_mode = TRUE; + } else if (strcasecmp(translate, "yes") == 0 || + strcasecmp(translate, "true") == 0 || + strcasecmp(translate, "on") == 0) { + translate_mode = TRUE; + } else { + translate_mode = FALSE; + } + suck_dir_list_from_server(); /* get list of directory contents */ +} + void set_mode( int mode) diff --git a/recover-src/uparse.c b/recover-src/uparse.c index de8148d..1f25e4d 100644 --- a/recover-src/uparse.c +++ b/recover-src/uparse.c @@ -1,24 +1,21 @@ -/* A Bison parser, made by GNU Bison 2.3. */ +/* A Bison parser, made by GNU Bison 2.5. */ -/* Skeleton implementation for Bison's Yacc-like parsers in C - - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify +/* Bison implementation for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2011 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. - + the Free Software Foundation, either version 3 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. */ + along with this program. If not, see . */ /* As a special exception, you may create a larger work that contains part or all of the Bison parser skeleton and distribute that work @@ -29,7 +26,7 @@ special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. - + This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ @@ -47,7 +44,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.3" +#define YYBISON_VERSION "2.5" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -55,11 +52,54 @@ /* Pure parsers. */ #define YYPURE 0 +/* Push parsers. */ +#define YYPUSH 0 + +/* Pull parsers. */ +#define YYPULL 1 + /* Using locations. */ #define YYLSP_NEEDED 0 +/* Copy the first part of user declarations. */ + +/* Line 268 of yacc.c */ +#line 31 "uparse.y" + +#include "amanda.h" +#include "amrecover.h" + +#define DATE_ALLOC_SIZE sizeof("YYYY-MM-DD-HH-MM-SS") /* includes null */ + +void yyerror(char *s); +extern int yylex(void); +extern char * yytext; + + +/* Line 268 of yacc.c */ +#line 83 "uparse.c" + +/* Enabling traces. */ +#ifndef YYDEBUG +# define YYDEBUG 0 +#endif + +/* Enabling verbose error messages. */ +#ifdef YYERROR_VERBOSE +# undef YYERROR_VERBOSE +# define YYERROR_VERBOSE 1 +#else +# define YYERROR_VERBOSE 0 +#endif + +/* Enabling the token table. */ +#ifndef YYTOKEN_TABLE +# define YYTOKEN_TABLE 0 +#endif + + /* Tokens. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE @@ -98,8 +138,9 @@ TAR = 287, APPEND = 288, PRIORITY = 289, - NL = 290, - STRING = 291 + SETTRANSLATE = 290, + NL = 291, + STRING = 292 }; #endif /* Tokens. */ @@ -135,67 +176,41 @@ #define TAR 287 #define APPEND 288 #define PRIORITY 289 -#define NL 290 -#define STRING 291 - - - - -/* Copy the first part of user declarations. */ -#line 31 "uparse.y" - -#include "amanda.h" -#include "amrecover.h" - -#define DATE_ALLOC_SIZE sizeof("YYYY-MM-DD-HH-MM-SS") /* includes null */ - -void yyerror(char *s); -extern int yylex(void); -extern char * yytext; +#define SETTRANSLATE 290 +#define NL 291 +#define STRING 292 -/* Enabling traces. */ -#ifndef YYDEBUG -# define YYDEBUG 0 -#endif - -/* Enabling verbose error messages. */ -#ifdef YYERROR_VERBOSE -# undef YYERROR_VERBOSE -# define YYERROR_VERBOSE 1 -#else -# define YYERROR_VERBOSE 0 -#endif -/* Enabling the token table. */ -#ifndef YYTOKEN_TABLE -# define YYTOKEN_TABLE 0 -#endif #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef union YYSTYPE -#line 43 "uparse.y" { + +/* Line 293 of yacc.c */ +#line 43 "uparse.y" + int intval; double floatval; char * strval; int subtok; -} -/* Line 187 of yacc.c. */ -#line 186 "uparse.c" - YYSTYPE; + + + +/* Line 293 of yacc.c */ +#line 202 "uparse.c" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 -# define YYSTYPE_IS_TRIVIAL 1 #endif - /* Copy the second part of user declarations. */ -/* Line 216 of yacc.c. */ -#line 199 "uparse.c" +/* Line 343 of yacc.c */ +#line 214 "uparse.c" #ifdef short # undef short @@ -245,7 +260,7 @@ typedef short int yytype_int16; #define YYSIZE_MAXIMUM ((YYSIZE_T) -1) #ifndef YY_ -# if YYENABLE_NLS +# if defined YYENABLE_NLS && YYENABLE_NLS # if ENABLE_NLS # include /* INFRINGES ON USER NAME SPACE */ # define YY_(msgid) dgettext ("bison-runtime", msgid) @@ -270,14 +285,14 @@ typedef short int yytype_int16; #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static int -YYID (int i) +YYID (int yyi) #else static int -YYID (i) - int i; +YYID (yyi) + int yyi; #endif { - return i; + return yyi; } #endif @@ -298,11 +313,11 @@ YYID (i) # define alloca _alloca # else # define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # endif @@ -325,24 +340,24 @@ YYID (i) # ifndef YYSTACK_ALLOC_MAXIMUM # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM # endif -# if (defined __cplusplus && ! defined _STDLIB_H \ +# if (defined __cplusplus && ! defined EXIT_SUCCESS \ && ! ((defined YYMALLOC || defined malloc) \ && (defined YYFREE || defined free))) # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # ifndef YYMALLOC # define YYMALLOC malloc -# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free -# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif @@ -358,9 +373,9 @@ void free (void *); /* INFRINGES ON USER NAME SPACE */ /* A type that is properly aligned for any stack member. */ union yyalloc { - yytype_int16 yyss; - YYSTYPE yyvs; - }; + yytype_int16 yyss_alloc; + YYSTYPE yyvs_alloc; +}; /* The size of the maximum gap between one aligned stack and the next. */ # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1) @@ -371,6 +386,27 @@ union yyalloc ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM) +# define YYCOPY_NEEDED 1 + +/* Relocate STACK from its old location to the new one. The + local variables YYSIZE and YYSTACKSIZE give the old and new number of + elements in the stack, and YYPTR gives the new location of the + stack. Advance YYPTR to a properly aligned location for the next + stack. */ +# define YYSTACK_RELOCATE(Stack_alloc, Stack) \ + do \ + { \ + YYSIZE_T yynewbytes; \ + YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \ + Stack = &yyptr->Stack_alloc; \ + yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ + yyptr += yynewbytes / sizeof (*yyptr); \ + } \ + while (YYID (0)) + +#endif + +#if defined YYCOPY_NEEDED && YYCOPY_NEEDED /* Copy COUNT objects from FROM to TO. The source and destination do not overlap. */ # ifndef YYCOPY @@ -388,42 +424,25 @@ union yyalloc while (YYID (0)) # endif # endif - -/* Relocate STACK from its old location to the new one. The - local variables YYSIZE and YYSTACKSIZE give the old and new number of - elements in the stack, and YYPTR gives the new location of the - stack. Advance YYPTR to a properly aligned location for the next - stack. */ -# define YYSTACK_RELOCATE(Stack) \ - do \ - { \ - YYSIZE_T yynewbytes; \ - YYCOPY (&yyptr->Stack, Stack, yysize); \ - Stack = &yyptr->Stack; \ - yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \ - yyptr += yynewbytes / sizeof (*yyptr); \ - } \ - while (YYID (0)) - -#endif +#endif /* !YYCOPY_NEEDED */ /* YYFINAL -- State number of the termination state. */ -#define YYFINAL 104 +#define YYFINAL 107 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 166 +#define YYLAST 177 /* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 37 +#define YYNTOKENS 38 /* YYNNTS -- Number of nonterminals. */ #define YYNNTS 21 /* YYNRULES -- Number of rules. */ -#define YYNRULES 101 +#define YYNRULES 104 /* YYNRULES -- Number of states. */ -#define YYNSTATES 160 +#define YYNSTATES 166 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 -#define YYMAXUTOK 291 +#define YYMAXUTOK 292 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) @@ -460,7 +479,7 @@ static const yytype_uint8 yytranslate[] = 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, - 35, 36 + 35, 36, 37 }; #if YYDEBUG @@ -470,54 +489,55 @@ static const yytype_uint16 yyprhs[] = { 0, 0, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 30, 33, 37, 40, 44, - 47, 50, 54, 58, 61, 66, 70, 75, 77, 81, - 84, 88, 92, 98, 101, 105, 110, 116, 120, 125, - 130, 136, 139, 143, 147, 152, 156, 160, 163, 167, - 171, 174, 178, 182, 186, 190, 193, 196, 200, 203, - 207, 210, 213, 216, 219, 223, 226, 230, 233, 236, - 239, 242, 245, 248, 251, 254, 258, 261, 263, 267, - 270, 272, 276, 279, 281, 285, 288, 290, 293, 296, - 300, 304, 307, 310, 313, 316, 319, 322, 325, 327, - 330, 333 + 47, 50, 53, 58, 62, 66, 70, 73, 78, 82, + 87, 89, 93, 96, 100, 104, 110, 113, 117, 122, + 128, 132, 137, 142, 148, 151, 155, 159, 164, 168, + 172, 175, 179, 183, 186, 190, 194, 198, 202, 205, + 208, 212, 215, 219, 222, 225, 228, 231, 235, 238, + 242, 245, 248, 251, 254, 257, 260, 263, 266, 270, + 273, 275, 279, 282, 284, 288, 291, 293, 297, 300, + 302, 305, 308, 312, 316, 319, 322, 325, 328, 331, + 334, 337, 339, 342, 345 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ static const yytype_int8 yyrhs[] = { - 38, 0, -1, 39, -1, 40, -1, 41, -1, 42, - -1, 43, -1, 45, -1, 47, -1, 49, -1, 51, - -1, 52, -1, 53, -1, 54, -1, 3, 35, -1, - 3, 56, -1, 4, 36, 35, -1, 4, 35, -1, - 4, 36, 56, -1, 5, 35, -1, 5, 56, -1, - 6, 36, 35, -1, 6, 36, 56, -1, 6, 35, - -1, 7, 36, 36, 35, -1, 7, 36, 35, -1, - 7, 36, 36, 56, -1, 7, -1, 9, 36, 35, - -1, 9, 35, -1, 9, 36, 56, -1, 11, 36, - 35, -1, 11, 21, 36, 36, 35, -1, 11, 35, - -1, 11, 36, 56, -1, 11, 21, 36, 35, -1, - 11, 21, 36, 36, 56, -1, 12, 36, 55, -1, - 12, 33, 36, 55, -1, 12, 34, 36, 55, -1, - 12, 33, 34, 36, 55, -1, 12, 35, -1, 12, - 33, 35, -1, 12, 34, 35, -1, 12, 33, 34, - 35, -1, 13, 36, 35, -1, 13, 36, 56, -1, - 13, 35, -1, 14, 36, 35, -1, 14, 36, 56, - -1, 14, 35, -1, 10, 31, 35, -1, 10, 32, - 35, -1, 10, 31, 56, -1, 10, 32, 56, -1, - 10, 56, -1, 10, 35, -1, 8, 36, 35, -1, - 8, 35, -1, 8, 36, 56, -1, 16, 35, -1, - 16, 56, -1, 17, 35, -1, 17, 56, -1, 22, - 36, 35, -1, 22, 35, -1, 22, 36, 56, -1, - 25, 35, -1, 25, 56, -1, 26, 35, -1, 26, - 56, -1, 30, 35, -1, 30, 56, -1, 15, 35, - -1, 15, 56, -1, 18, 44, 35, -1, 44, 36, - -1, 36, -1, 19, 46, 35, -1, 46, 36, -1, - 36, -1, 23, 48, 35, -1, 48, 36, -1, 36, - -1, 24, 50, 35, -1, 50, 36, -1, 36, -1, - 29, 35, -1, 29, 56, -1, 28, 36, 35, -1, - 28, 36, 56, -1, 28, 35, -1, 27, 35, -1, - 27, 56, -1, 20, 35, -1, 20, 56, -1, 36, - 57, -1, 36, 55, -1, 35, -1, 36, 57, -1, - 36, 57, -1, 35, -1 + 39, 0, -1, 40, -1, 41, -1, 42, -1, 43, + -1, 44, -1, 46, -1, 48, -1, 50, -1, 52, + -1, 53, -1, 54, -1, 55, -1, 3, 36, -1, + 3, 57, -1, 4, 37, 36, -1, 4, 36, -1, + 4, 37, 57, -1, 5, 36, -1, 5, 57, -1, + 35, 36, -1, 35, 37, 57, 36, -1, 35, 37, + 36, -1, 6, 37, 36, -1, 6, 37, 57, -1, + 6, 36, -1, 7, 37, 37, 36, -1, 7, 37, + 36, -1, 7, 37, 37, 57, -1, 7, -1, 9, + 37, 36, -1, 9, 36, -1, 9, 37, 57, -1, + 11, 37, 36, -1, 11, 21, 37, 37, 36, -1, + 11, 36, -1, 11, 37, 57, -1, 11, 21, 37, + 36, -1, 11, 21, 37, 37, 57, -1, 12, 37, + 56, -1, 12, 33, 37, 56, -1, 12, 34, 37, + 56, -1, 12, 33, 34, 37, 56, -1, 12, 36, + -1, 12, 33, 36, -1, 12, 34, 36, -1, 12, + 33, 34, 36, -1, 13, 37, 36, -1, 13, 37, + 57, -1, 13, 36, -1, 14, 37, 36, -1, 14, + 37, 57, -1, 14, 36, -1, 10, 31, 36, -1, + 10, 32, 36, -1, 10, 31, 57, -1, 10, 32, + 57, -1, 10, 57, -1, 10, 36, -1, 8, 37, + 36, -1, 8, 36, -1, 8, 37, 57, -1, 16, + 36, -1, 16, 57, -1, 17, 36, -1, 17, 57, + -1, 22, 37, 36, -1, 22, 36, -1, 22, 37, + 57, -1, 25, 36, -1, 25, 57, -1, 26, 36, + -1, 26, 57, -1, 30, 36, -1, 30, 57, -1, + 15, 36, -1, 15, 57, -1, 18, 45, 36, -1, + 45, 37, -1, 37, -1, 19, 47, 36, -1, 47, + 37, -1, 37, -1, 23, 49, 36, -1, 49, 37, + -1, 37, -1, 24, 51, 36, -1, 51, 37, -1, + 37, -1, 29, 36, -1, 29, 57, -1, 28, 37, + 36, -1, 28, 37, 57, -1, 28, 36, -1, 27, + 36, -1, 27, 57, -1, 20, 36, -1, 20, 57, + -1, 37, 58, -1, 37, 56, -1, 36, -1, 37, + 58, -1, 37, 58, -1, 36, -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ @@ -528,12 +548,12 @@ static const yytype_uint16 yyrline[] = 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, - 119, 120, 121, 122, 123, 124, 125, 129, 175, 176, - 180, 181, 182, 183, 184, 185, 186, 187, 188, 189, - 190, 191, 192, 196, 197, 201, 205, 206, 210, 214, - 215, 219, 223, 224, 228, 232, 233, 237, 238, 239, - 243, 244, 248, 249, 253, 254, 258, 267, 268, 272, - 276, 277 + 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, + 132, 178, 179, 183, 184, 185, 186, 187, 188, 189, + 190, 191, 192, 193, 194, 195, 199, 200, 204, 208, + 209, 213, 217, 218, 222, 226, 227, 231, 235, 236, + 240, 241, 242, 246, 247, 251, 252, 256, 257, 261, + 270, 271, 275, 279, 280 }; #endif @@ -546,10 +566,10 @@ static const char *const yytname[] = "SETHOST", "SETDISK", "SETDATE", "SETTAPE", "SETMODE", "SETDEVICE", "SETPROPERTY", "CD", "CDX", "QUIT", "DHIST", "LS", "ADD", "ADDX", "EXTRACT", "DASH_H", "LIST", "DELETE", "DELETEX", "PWD", "CLEAR", "HELP", - "LCD", "LPWD", "MODE", "SMB", "TAR", "APPEND", "PRIORITY", "NL", - "STRING", "$accept", "ucommand", "set_command", "setdate_command", - "display_command", "quit_command", "add_command", "add_path", - "addx_command", "addx_path", "delete_command", "delete_path", + "LCD", "LPWD", "MODE", "SMB", "TAR", "APPEND", "PRIORITY", + "SETTRANSLATE", "NL", "STRING", "$accept", "ucommand", "set_command", + "setdate_command", "display_command", "quit_command", "add_command", + "add_path", "addx_command", "addx_path", "delete_command", "delete_path", "deletex_command", "deletex_path", "local_command", "help_command", "extract_command", "invalid_command", "property_value", "invalid_string", "bogus_string", 0 @@ -564,24 +584,24 @@ static const yytype_uint16 yytoknum[] = 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, - 285, 286, 287, 288, 289, 290, 291 + 285, 286, 287, 288, 289, 290, 291, 292 }; # endif /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint8 yyr1[] = { - 0, 37, 38, 38, 38, 38, 38, 38, 38, 38, - 38, 38, 38, 38, 39, 39, 39, 39, 39, 39, - 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, - 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, - 39, 39, 39, 39, 39, 39, 39, 39, 39, 39, - 39, 39, 39, 39, 39, 39, 39, 40, 40, 40, - 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, - 41, 41, 41, 42, 42, 43, 44, 44, 45, 46, - 46, 47, 48, 48, 49, 50, 50, 51, 51, 51, - 51, 51, 52, 52, 53, 53, 54, 55, 55, 56, - 57, 57 + 0, 38, 39, 39, 39, 39, 39, 39, 39, 39, + 39, 39, 39, 39, 40, 40, 40, 40, 40, 40, + 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, + 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, + 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, + 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, + 41, 41, 41, 42, 42, 42, 42, 42, 42, 42, + 42, 42, 42, 42, 42, 42, 43, 43, 44, 45, + 45, 46, 47, 47, 48, 49, 49, 50, 51, 51, + 52, 52, 52, 52, 52, 53, 53, 54, 54, 55, + 56, 56, 57, 58, 58 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ @@ -589,124 +609,133 @@ static const yytype_uint8 yyr2[] = { 0, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 3, 2, 3, 2, - 2, 3, 3, 2, 4, 3, 4, 1, 3, 2, - 3, 3, 5, 2, 3, 4, 5, 3, 4, 4, - 5, 2, 3, 3, 4, 3, 3, 2, 3, 3, - 2, 3, 3, 3, 3, 2, 2, 3, 2, 3, - 2, 2, 2, 2, 3, 2, 3, 2, 2, 2, - 2, 2, 2, 2, 2, 3, 2, 1, 3, 2, - 1, 3, 2, 1, 3, 2, 1, 2, 2, 3, - 3, 2, 2, 2, 2, 2, 2, 2, 1, 2, - 2, 1 + 2, 2, 4, 3, 3, 3, 2, 4, 3, 4, + 1, 3, 2, 3, 3, 5, 2, 3, 4, 5, + 3, 4, 4, 5, 2, 3, 3, 4, 3, 3, + 2, 3, 3, 2, 3, 3, 3, 3, 2, 2, + 3, 2, 3, 2, 2, 2, 2, 3, 2, 3, + 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, + 1, 3, 2, 1, 3, 2, 1, 3, 2, 1, + 2, 2, 3, 3, 2, 2, 2, 2, 2, 2, + 2, 1, 2, 2, 1 }; -/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state - STATE-NUM when YYTABLE doesn't specify something else to do. Zero +/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. + Performed when YYTABLE doesn't specify something else to do. Zero means the default is an error. */ static const yytype_uint8 yydefact[] = { - 0, 0, 0, 0, 0, 27, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, - 12, 13, 14, 0, 15, 17, 0, 19, 20, 23, - 0, 0, 58, 0, 29, 0, 0, 0, 56, 55, - 0, 33, 0, 0, 0, 41, 0, 47, 0, 50, - 0, 73, 74, 60, 61, 62, 63, 77, 0, 80, - 0, 94, 95, 65, 0, 83, 0, 86, 0, 67, - 68, 69, 70, 92, 93, 91, 0, 87, 88, 71, - 72, 101, 0, 96, 1, 99, 16, 18, 21, 22, - 25, 0, 57, 59, 28, 30, 51, 53, 52, 54, - 0, 31, 34, 0, 42, 0, 43, 0, 98, 0, - 37, 45, 46, 48, 49, 75, 76, 78, 79, 64, - 66, 81, 82, 84, 85, 89, 90, 100, 24, 26, - 35, 0, 44, 0, 38, 39, 97, 32, 36, 40 + 0, 2, 3, 4, 5, 6, 7, 8, 9, 10, + 11, 12, 13, 14, 0, 15, 17, 0, 19, 20, + 26, 0, 0, 61, 0, 32, 0, 0, 0, 59, + 58, 0, 36, 0, 0, 0, 44, 0, 50, 0, + 53, 0, 76, 77, 63, 64, 65, 66, 80, 0, + 83, 0, 97, 98, 68, 0, 86, 0, 89, 0, + 70, 71, 72, 73, 95, 96, 94, 0, 90, 91, + 74, 75, 21, 0, 104, 0, 99, 1, 102, 16, + 18, 24, 25, 28, 0, 60, 62, 31, 33, 54, + 56, 55, 57, 0, 34, 37, 0, 45, 0, 46, + 0, 101, 0, 40, 48, 49, 51, 52, 78, 79, + 81, 82, 67, 69, 84, 85, 87, 88, 92, 93, + 23, 0, 103, 27, 29, 38, 0, 47, 0, 41, + 42, 100, 22, 35, 39, 43 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int16 yydefgoto[] = { - -1, 29, 30, 31, 32, 33, 34, 78, 35, 80, - 36, 86, 37, 88, 38, 39, 40, 41, 130, 44, - 103 + -1, 30, 31, 32, 33, 34, 35, 79, 36, 81, + 37, 87, 38, 89, 39, 40, 41, 42, 133, 45, + 106 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ -#define YYPACT_NINF -124 +#define YYPACT_NINF -127 static const yytype_int16 yypact[] = { - 106, -22, -10, 2, 4, -20, 6, 9, -4, -18, - 0, 13, 20, 22, 26, 28, -14, -7, 33, 35, - 10, 15, 37, 39, 41, 43, 47, 49, 51, 66, - -124, -124, -124, -124, -124, -124, -124, -124, -124, -124, - -124, -124, -124, 51, -124, -124, 53, -124, -124, -124, - 55, 59, -124, 61, -124, 63, 65, 67, -124, -124, - 44, -124, 69, -27, 71, -124, 102, -124, 104, -124, - 108, -124, -124, -124, -124, -124, -124, -124, 110, -124, - 114, -124, -124, -124, 116, -124, 118, -124, 120, -124, - -124, -124, -124, -124, -124, -124, 122, -124, -124, -124, - -124, -124, 51, -124, -124, -124, -124, -124, -124, -124, - -124, 124, -124, -124, -124, -124, -124, -124, -124, -124, - 126, -124, -124, 128, -124, 102, -124, 102, -124, 102, - -124, -124, -124, -124, -124, -124, -124, -124, -124, -124, - -124, -124, -124, -124, -124, -124, -124, -124, -124, -124, - -124, 130, -124, 102, -124, -124, -124, -124, -124, -124 + 109, -29, 2, 4, 6, -34, 9, 13, -6, -8, + 0, 20, 22, 27, 33, 35, -28, -19, 37, 39, + -15, -10, 41, 43, 47, 49, 51, 53, 55, 59, + 52, -127, -127, -127, -127, -127, -127, -127, -127, -127, + -127, -127, -127, -127, 59, -127, -127, 61, -127, -127, + -127, 65, 67, -127, 69, -127, 71, 73, 104, -127, + -127, -2, -127, 106, -20, 111, -127, 113, -127, 115, + -127, 118, -127, -127, -127, -127, -127, -127, -127, 120, + -127, 122, -127, -127, -127, 124, -127, 126, -127, 128, + -127, -127, -127, -127, -127, -127, -127, 130, -127, -127, + -127, -127, -127, 132, -127, 59, -127, -127, -127, -127, + -127, -127, -127, -127, 134, -127, -127, -127, -127, -127, + -127, -127, -127, 136, -127, -127, 138, -127, 113, -127, + 113, -127, 113, -127, -127, -127, -127, -127, -127, -127, + -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, + -127, 11, -127, -127, -127, -127, 140, -127, 113, -127, + -127, -127, -127, -127, -127, -127 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int8 yypgoto[] = { - -124, -124, -124, -124, -124, -124, -124, -124, -124, -124, - -124, -124, -124, -124, -124, -124, -124, -124, -123, -3, - -42 + -127, -127, -127, -127, -127, -127, -127, -127, -127, -127, + -127, -127, -127, -127, -127, -127, -127, -127, -126, -3, + -43 }; /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which - number is the opposite. If zero, do what YYDEFACT says. - If YYTABLE_NINF, syntax error. */ + number is the opposite. If YYTABLE_NINF, syntax error. */ #define YYTABLE_NINF -1 static const yytype_uint8 yytable[] = { - 48, 105, 154, 60, 155, 59, 156, 123, 124, 125, - 72, 74, 76, 42, 43, 82, 51, 61, 62, 90, - 92, 94, 77, 98, 100, 45, 46, 56, 57, 79, - 159, 58, 43, 63, 64, 65, 66, 47, 43, 49, - 50, 52, 53, 107, 54, 55, 85, 109, 67, 68, - 113, 87, 115, 117, 119, 69, 70, 71, 43, 122, - 147, 73, 43, 75, 43, 132, 104, 134, 81, 43, - 83, 84, 89, 43, 91, 43, 93, 43, 95, 96, - 120, 140, 97, 43, 99, 43, 101, 102, 106, 43, - 108, 43, 0, 146, 110, 111, 112, 43, 114, 43, - 116, 43, 118, 43, 121, 43, 126, 127, 149, 1, - 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, - 12, 13, 14, 15, 16, 17, 18, 0, 19, 20, - 21, 22, 23, 24, 25, 26, 27, 128, 129, 131, - 43, 0, 28, 133, 43, 135, 136, 0, 158, 137, - 138, 139, 43, 141, 142, 143, 144, 145, 43, 148, - 43, 150, 151, 152, 153, 157, 43 + 49, 108, 159, 52, 160, 60, 161, 43, 44, 78, + 73, 75, 77, 61, 126, 83, 127, 128, 80, 91, + 93, 95, 86, 99, 101, 57, 58, 88, 62, 63, + 59, 44, 165, 64, 65, 123, 66, 67, 46, 47, + 48, 44, 50, 51, 110, 53, 54, 162, 112, 55, + 56, 116, 107, 118, 120, 122, 68, 69, 70, 71, + 125, 0, 152, 72, 44, 0, 135, 0, 137, 74, + 44, 76, 44, 82, 44, 84, 85, 90, 44, 92, + 44, 0, 143, 94, 44, 96, 97, 98, 44, 100, + 44, 102, 103, 0, 149, 104, 105, 109, 44, 0, + 151, 111, 44, 113, 114, 115, 44, 117, 44, 119, + 44, 154, 1, 2, 3, 4, 5, 6, 7, 8, + 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, + 0, 19, 20, 21, 22, 23, 24, 25, 26, 27, + 121, 44, 124, 44, 28, 0, 29, 129, 130, 131, + 132, 134, 44, 164, 136, 44, 138, 139, 140, 141, + 142, 44, 144, 145, 146, 147, 148, 44, 150, 44, + 153, 44, 155, 156, 157, 158, 163, 44 }; +#define yypact_value_is_default(yystate) \ + ((yystate) == (-127)) + +#define yytable_value_is_error(yytable_value) \ + YYID (0) + static const yytype_int16 yycheck[] = { - 3, 43, 125, 21, 127, 8, 129, 34, 35, 36, - 13, 14, 15, 35, 36, 18, 36, 35, 36, 22, - 23, 24, 36, 26, 27, 35, 36, 31, 32, 36, - 153, 35, 36, 33, 34, 35, 36, 35, 36, 35, - 36, 35, 36, 46, 35, 36, 36, 50, 35, 36, - 53, 36, 55, 56, 57, 35, 36, 35, 36, 62, - 102, 35, 36, 35, 36, 68, 0, 70, 35, 36, - 35, 36, 35, 36, 35, 36, 35, 36, 35, 36, - 36, 84, 35, 36, 35, 36, 35, 36, 35, 36, - 35, 36, -1, 96, 35, 36, 35, 36, 35, 36, - 35, 36, 35, 36, 35, 36, 35, 36, 111, 3, - 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, - 14, 15, 16, 17, 18, 19, 20, -1, 22, 23, - 24, 25, 26, 27, 28, 29, 30, 35, 36, 35, - 36, -1, 36, 35, 36, 35, 36, -1, 151, 35, - 36, 35, 36, 35, 36, 35, 36, 35, 36, 35, - 36, 35, 36, 35, 36, 35, 36 + 3, 44, 128, 37, 130, 8, 132, 36, 37, 37, + 13, 14, 15, 21, 34, 18, 36, 37, 37, 22, + 23, 24, 37, 26, 27, 31, 32, 37, 36, 37, + 36, 37, 158, 33, 34, 37, 36, 37, 36, 37, + 36, 37, 36, 37, 47, 36, 37, 36, 51, 36, + 37, 54, 0, 56, 57, 58, 36, 37, 36, 37, + 63, -1, 105, 36, 37, -1, 69, -1, 71, 36, + 37, 36, 37, 36, 37, 36, 37, 36, 37, 36, + 37, -1, 85, 36, 37, 36, 37, 36, 37, 36, + 37, 36, 37, -1, 97, 36, 37, 36, 37, -1, + 103, 36, 37, 36, 37, 36, 37, 36, 37, 36, + 37, 114, 3, 4, 5, 6, 7, 8, 9, 10, + 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, + -1, 22, 23, 24, 25, 26, 27, 28, 29, 30, + 36, 37, 36, 37, 35, -1, 37, 36, 37, 36, + 37, 36, 37, 156, 36, 37, 36, 37, 36, 37, + 36, 37, 36, 37, 36, 37, 36, 37, 36, 37, + 36, 37, 36, 37, 36, 37, 36, 37 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing @@ -715,20 +744,21 @@ static const yytype_uint8 yystos[] = { 0, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 22, - 23, 24, 25, 26, 27, 28, 29, 30, 36, 38, - 39, 40, 41, 42, 43, 45, 47, 49, 51, 52, - 53, 54, 35, 36, 56, 35, 36, 35, 56, 35, - 36, 36, 35, 36, 35, 36, 31, 32, 35, 56, - 21, 35, 36, 33, 34, 35, 36, 35, 36, 35, - 36, 35, 56, 35, 56, 35, 56, 36, 44, 36, - 46, 35, 56, 35, 36, 36, 48, 36, 50, 35, - 56, 35, 56, 35, 56, 35, 36, 35, 56, 35, - 56, 35, 36, 57, 0, 57, 35, 56, 35, 56, - 35, 36, 35, 56, 35, 56, 35, 56, 35, 56, - 36, 35, 56, 34, 35, 36, 35, 36, 35, 36, - 55, 35, 56, 35, 56, 35, 36, 35, 36, 35, - 56, 35, 36, 35, 36, 35, 56, 57, 35, 56, - 35, 36, 35, 36, 55, 55, 55, 35, 56, 55 + 23, 24, 25, 26, 27, 28, 29, 30, 35, 37, + 39, 40, 41, 42, 43, 44, 46, 48, 50, 52, + 53, 54, 55, 36, 37, 57, 36, 37, 36, 57, + 36, 37, 37, 36, 37, 36, 37, 31, 32, 36, + 57, 21, 36, 37, 33, 34, 36, 37, 36, 37, + 36, 37, 36, 57, 36, 57, 36, 57, 37, 45, + 37, 47, 36, 57, 36, 37, 37, 49, 37, 51, + 36, 57, 36, 57, 36, 57, 36, 37, 36, 57, + 36, 57, 36, 37, 36, 37, 58, 0, 58, 36, + 57, 36, 57, 36, 37, 36, 57, 36, 57, 36, + 57, 36, 57, 37, 36, 57, 34, 36, 37, 36, + 37, 36, 37, 56, 36, 57, 36, 57, 36, 37, + 36, 37, 36, 57, 36, 37, 36, 37, 36, 57, + 36, 57, 58, 36, 57, 36, 37, 36, 37, 56, + 56, 56, 36, 36, 57, 56 }; #define yyerrok (yyerrstatus = 0) @@ -743,9 +773,18 @@ static const yytype_uint8 yystos[] = /* Like YYERROR except do call yyerror. This remains here temporarily to ease the transition to the new meaning of YYERROR, for GCC. - Once GCC version 2 has supplanted version 1, this can go. */ + Once GCC version 2 has supplanted version 1, this can go. However, + YYFAIL appears to be in use. Nevertheless, it is formally deprecated + in Bison 2.4.2's NEWS entry, where a plan to phase it out is + discussed. */ #define YYFAIL goto yyerrlab +#if defined YYFAIL + /* This is here to suppress warnings from the GCC cpp's + -Wunused-macros. Normally we don't worry about that warning, but + some users do, and we want to make it easy for users to remove + YYFAIL uses, which will produce warnings from Bison 2.5. */ +#endif #define YYRECOVERING() (!!yyerrstatus) @@ -755,7 +794,6 @@ do \ { \ yychar = (Token); \ yylval = (Value); \ - yytoken = YYTRANSLATE (yychar); \ YYPOPSTACK (1); \ goto yybackup; \ } \ @@ -797,19 +835,10 @@ while (YYID (0)) #endif -/* YY_LOCATION_PRINT -- Print the location on the stream. - This macro was not mandated originally: define only if we know - we won't break user code: when these are the locations we know. */ +/* This macro is provided for backward compatibility. */ #ifndef YY_LOCATION_PRINT -# if YYLTYPE_IS_TRIVIAL -# define YY_LOCATION_PRINT(File, Loc) \ - fprintf (File, "%d.%d-%d.%d", \ - (Loc).first_line, (Loc).first_column, \ - (Loc).last_line, (Loc).last_column) -# else -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -# endif +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) #endif @@ -913,17 +942,20 @@ yy_symbol_print (yyoutput, yytype, yyvaluep) #if (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) static void -yy_stack_print (yytype_int16 *bottom, yytype_int16 *top) +yy_stack_print (yytype_int16 *yybottom, yytype_int16 *yytop) #else static void -yy_stack_print (bottom, top) - yytype_int16 *bottom; - yytype_int16 *top; +yy_stack_print (yybottom, yytop) + yytype_int16 *yybottom; + yytype_int16 *yytop; #endif { YYFPRINTF (stderr, "Stack now"); - for (; bottom <= top; ++bottom) - YYFPRINTF (stderr, " %d", *bottom); + for (; yybottom <= yytop; yybottom++) + { + int yybot = *yybottom; + YYFPRINTF (stderr, " %d", yybot); + } YYFPRINTF (stderr, "\n"); } @@ -957,11 +989,11 @@ yy_reduce_print (yyvsp, yyrule) /* The symbols being reduced. */ for (yyi = 0; yyi < yynrhs; yyi++) { - fprintf (stderr, " $%d = ", yyi + 1); + YYFPRINTF (stderr, " $%d = ", yyi + 1); yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi], &(yyvsp[(yyi + 1) - (yynrhs)]) ); - fprintf (stderr, "\n"); + YYFPRINTF (stderr, "\n"); } } @@ -998,7 +1030,6 @@ int yydebug; # define YYMAXDEPTH 10000 #endif - #if YYERROR_VERBOSE @@ -1101,115 +1132,142 @@ yytnamerr (char *yyres, const char *yystr) } # endif -/* Copy into YYRESULT an error message about the unexpected token - YYCHAR while in state YYSTATE. Return the number of bytes copied, - including the terminating null byte. If YYRESULT is null, do not - copy anything; just return the number of bytes that would be - copied. As a special case, return 0 if an ordinary "syntax error" - message will do. Return YYSIZE_MAXIMUM if overflow occurs during - size calculation. */ -static YYSIZE_T -yysyntax_error (char *yyresult, int yystate, int yychar) -{ - int yyn = yypact[yystate]; +/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message + about the unexpected token YYTOKEN for the state stack whose top is + YYSSP. - if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) - return 0; - else + Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is + not large enough to hold the message. In that case, also set + *YYMSG_ALLOC to the required number of bytes. Return 2 if the + required number of bytes is too large to store. */ +static int +yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, + yytype_int16 *yyssp, int yytoken) +{ + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + /* Internationalized format string. */ + const char *yyformat = 0; + /* Arguments of yyformat. */ + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + /* Number of reported tokens (one for the "unexpected", one per + "expected"). */ + int yycount = 0; + + /* There are many possibilities here to consider: + - Assume YYFAIL is not used. It's too flawed to consider. See + + for details. YYERROR is fine as it does not invoke this + function. + - If this state is a consistent state with a default action, then + the only way this function was invoked is if the default action + is an error action. In that case, don't check for expected + tokens because there are none. + - The only way there can be no lookahead present (in yychar) is if + this state is a consistent state with a default action. Thus, + detecting the absence of a lookahead is sufficient to determine + that there is no unexpected or expected token to report. In that + case, just report a simple "syntax error". + - Don't assume there isn't a lookahead just because this state is a + consistent state with a default action. There might have been a + previous inconsistent state, consistent state with a non-default + action, or user semantic action that manipulated yychar. + - Of course, the expected token list depends on states to have + correct lookahead information, and it depends on the parser not + to perform extra reductions after fetching a lookahead from the + scanner and before detecting a syntax error. Thus, state merging + (from LALR or IELR) and default reductions corrupt the expected + token list. However, the list is correct for canonical LR with + one exception: it will still contain any token that will not be + accepted due to an error action in a later state. + */ + if (yytoken != YYEMPTY) { - int yytype = YYTRANSLATE (yychar); - YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); - YYSIZE_T yysize = yysize0; - YYSIZE_T yysize1; - int yysize_overflow = 0; - enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; - char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; - int yyx; - -# if 0 - /* This is so xgettext sees the translatable formats that are - constructed on the fly. */ - YY_("syntax error, unexpected %s"); - YY_("syntax error, unexpected %s, expecting %s"); - YY_("syntax error, unexpected %s, expecting %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); -# endif - char *yyfmt; - char const *yyf; - static char const yyunexpected[] = "syntax error, unexpected %s"; - static char const yyexpecting[] = ", expecting %s"; - static char const yyor[] = " or %s"; - char yyformat[sizeof yyunexpected - + sizeof yyexpecting - 1 - + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) - * (sizeof yyor - 1))]; - char const *yyprefix = yyexpecting; - - /* Start YYX at -YYN if negative to avoid negative indexes in - YYCHECK. */ - int yyxbegin = yyn < 0 ? -yyn : 0; - - /* Stay within bounds of both yycheck and yytname. */ - int yychecklim = YYLAST - yyn + 1; - int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; - int yycount = 1; - - yyarg[0] = yytname[yytype]; - yyfmt = yystpcpy (yyformat, yyunexpected); - - for (yyx = yyxbegin; yyx < yyxend; ++yyx) - if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) - { - if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) - { - yycount = 1; - yysize = yysize0; - yyformat[sizeof yyunexpected - 1] = '\0'; - break; - } - yyarg[yycount++] = yytname[yyx]; - yysize1 = yysize + yytnamerr (0, yytname[yyx]); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - yyfmt = yystpcpy (yyfmt, yyprefix); - yyprefix = yyor; - } + int yyn = yypact[*yyssp]; + yyarg[yycount++] = yytname[yytoken]; + if (!yypact_value_is_default (yyn)) + { + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. In other words, skip the first -YYN actions for + this state because they are default actions. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yyx; + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR + && !yytable_value_is_error (yytable[yyx + yyn])) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + if (! (yysize <= yysize1 + && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + } + } - yyf = YY_(yyformat); - yysize1 = yysize + yystrlen (yyf); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; + switch (yycount) + { +# define YYCASE_(N, S) \ + case N: \ + yyformat = S; \ + break + YYCASE_(0, YY_("syntax error")); + YYCASE_(1, YY_("syntax error, unexpected %s")); + YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); + YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); + YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); + YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); +# undef YYCASE_ + } - if (yysize_overflow) - return YYSIZE_MAXIMUM; + yysize1 = yysize + yystrlen (yyformat); + if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; - if (yyresult) - { - /* Avoid sprintf, as that infringes on the user's name space. - Don't have undefined behavior even if the translation - produced a string with the wrong number of "%s"s. */ - char *yyp = yyresult; - int yyi = 0; - while ((*yyp = *yyf) != '\0') - { - if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) - { - yyp += yytnamerr (yyp, yyarg[yyi++]); - yyf += 2; - } - else - { - yyp++; - yyf++; - } - } - } - return yysize; + if (*yymsg_alloc < yysize) + { + *yymsg_alloc = 2 * yysize; + if (! (yysize <= *yymsg_alloc + && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) + *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; + return 1; } + + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + { + char *yyp = *yymsg; + int yyi = 0; + while ((*yyp = *yyformat) != '\0') + if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyformat += 2; + } + else + { + yyp++; + yyformat++; + } + } + return 0; } #endif /* YYERROR_VERBOSE */ - /*-----------------------------------------------. | Release the memory associated to this symbol. | @@ -1241,10 +1299,9 @@ yydestruct (yymsg, yytype, yyvaluep) break; } } - -/* Prevent warnings from -Wmissing-prototypes. */ +/* Prevent warnings from -Wmissing-prototypes. */ #ifdef YYPARSE_PARAM #if defined __STDC__ || defined __cplusplus int yyparse (void *YYPARSE_PARAM); @@ -1260,18 +1317,16 @@ int yyparse (); #endif /* ! YYPARSE_PARAM */ - -/* The look-ahead symbol. */ +/* The lookahead symbol. */ int yychar; -/* The semantic value of the look-ahead symbol. */ +/* The semantic value of the lookahead symbol. */ YYSTYPE yylval; /* Number of syntax errors so far. */ int yynerrs; - /*----------. | yyparse. | `----------*/ @@ -1298,66 +1353,66 @@ yyparse () #endif #endif { - - int yystate; - int yyn; - int yyresult; - /* Number of tokens to shift before error messages enabled. */ - int yyerrstatus; - /* Look-ahead token as an internal (translated) token number. */ - int yytoken = 0; -#if YYERROR_VERBOSE - /* Buffer for error messages, and its allocated size. */ - char yymsgbuf[128]; - char *yymsg = yymsgbuf; - YYSIZE_T yymsg_alloc = sizeof yymsgbuf; -#endif - - /* Three stacks and their tools: - `yyss': related to states, - `yyvs': related to semantic values, - `yyls': related to locations. + int yystate; + /* Number of tokens to shift before error messages enabled. */ + int yyerrstatus; - Refer to the stacks thru separate pointers, to allow yyoverflow - to reallocate them elsewhere. */ + /* The stacks and their tools: + `yyss': related to states. + `yyvs': related to semantic values. - /* The state stack. */ - yytype_int16 yyssa[YYINITDEPTH]; - yytype_int16 *yyss = yyssa; - yytype_int16 *yyssp; + Refer to the stacks thru separate pointers, to allow yyoverflow + to reallocate them elsewhere. */ - /* The semantic value stack. */ - YYSTYPE yyvsa[YYINITDEPTH]; - YYSTYPE *yyvs = yyvsa; - YYSTYPE *yyvsp; + /* The state stack. */ + yytype_int16 yyssa[YYINITDEPTH]; + yytype_int16 *yyss; + yytype_int16 *yyssp; + /* The semantic value stack. */ + YYSTYPE yyvsa[YYINITDEPTH]; + YYSTYPE *yyvs; + YYSTYPE *yyvsp; + YYSIZE_T yystacksize; -#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) - - YYSIZE_T yystacksize = YYINITDEPTH; - + int yyn; + int yyresult; + /* Lookahead token as an internal (translated) token number. */ + int yytoken; /* The variables used to return semantic value and location from the action routines. */ YYSTYPE yyval; +#if YYERROR_VERBOSE + /* Buffer for error messages, and its allocated size. */ + char yymsgbuf[128]; + char *yymsg = yymsgbuf; + YYSIZE_T yymsg_alloc = sizeof yymsgbuf; +#endif + +#define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N)) /* The number of symbols on the RHS of the reduced rule. Keep to zero when no symbol should be popped. */ int yylen = 0; + yytoken = 0; + yyss = yyssa; + yyvs = yyvsa; + yystacksize = YYINITDEPTH; + YYDPRINTF ((stderr, "Starting parse\n")); yystate = 0; yyerrstatus = 0; yynerrs = 0; - yychar = YYEMPTY; /* Cause a token to be read. */ + yychar = YYEMPTY; /* Cause a token to be read. */ /* Initialize stack pointers. Waste one element of value and location stack so that they stay on the same level as the state stack. The wasted elements are never initialized. */ - yyssp = yyss; yyvsp = yyvs; @@ -1387,7 +1442,6 @@ yyparse () YYSTYPE *yyvs1 = yyvs; yytype_int16 *yyss1 = yyss; - /* Each stack pointer address is followed by the size of the data in use in that stack, in bytes. This used to be a conditional around just the two extra args, but that might @@ -1395,7 +1449,6 @@ yyparse () yyoverflow (YY_("memory exhausted"), &yyss1, yysize * sizeof (*yyssp), &yyvs1, yysize * sizeof (*yyvsp), - &yystacksize); yyss = yyss1; @@ -1418,9 +1471,8 @@ yyparse () (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize)); if (! yyptr) goto yyexhaustedlab; - YYSTACK_RELOCATE (yyss); - YYSTACK_RELOCATE (yyvs); - + YYSTACK_RELOCATE (yyss_alloc, yyss); + YYSTACK_RELOCATE (yyvs_alloc, yyvs); # undef YYSTACK_RELOCATE if (yyss1 != yyssa) YYSTACK_FREE (yyss1); @@ -1431,7 +1483,6 @@ yyparse () yyssp = yyss + yysize - 1; yyvsp = yyvs + yysize - 1; - YYDPRINTF ((stderr, "Stack size increased to %lu\n", (unsigned long int) yystacksize)); @@ -1441,6 +1492,9 @@ yyparse () YYDPRINTF ((stderr, "Entering state %d\n", yystate)); + if (yystate == YYFINAL) + YYACCEPT; + goto yybackup; /*-----------. @@ -1449,16 +1503,16 @@ yyparse () yybackup: /* Do appropriate processing given the current state. Read a - look-ahead token if we need one and don't already have one. */ + lookahead token if we need one and don't already have one. */ - /* First try to decide what to do without reference to look-ahead token. */ + /* First try to decide what to do without reference to lookahead token. */ yyn = yypact[yystate]; - if (yyn == YYPACT_NINF) + if (yypact_value_is_default (yyn)) goto yydefault; - /* Not known => get a look-ahead token if don't already have one. */ + /* Not known => get a lookahead token if don't already have one. */ - /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol. */ + /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */ if (yychar == YYEMPTY) { YYDPRINTF ((stderr, "Reading a token: ")); @@ -1484,26 +1538,22 @@ yybackup: yyn = yytable[yyn]; if (yyn <= 0) { - if (yyn == 0 || yyn == YYTABLE_NINF) - goto yyerrlab; + if (yytable_value_is_error (yyn)) + goto yyerrlab; yyn = -yyn; goto yyreduce; } - if (yyn == YYFINAL) - YYACCEPT; - /* Count tokens shifted since error; after three, turn off error status. */ if (yyerrstatus) yyerrstatus--; - /* Shift the look-ahead token. */ + /* Shift the lookahead token. */ YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc); - /* Discard the shifted token unless it is eof. */ - if (yychar != YYEOF) - yychar = YYEMPTY; + /* Discard the shifted token. */ + yychar = YYEMPTY; yystate = yyn; *++yyvsp = yylval; @@ -1543,222 +1593,331 @@ yyreduce: switch (yyn) { case 14: + +/* Line 1806 of yacc.c */ #line 83 "uparse.y" { list_host(); } break; case 15: + +/* Line 1806 of yacc.c */ #line 84 "uparse.y" { yyerror("Invalid argument"); } break; case 16: + +/* Line 1806 of yacc.c */ #line 85 "uparse.y" { list_disk((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } break; case 17: + +/* Line 1806 of yacc.c */ #line 86 "uparse.y" { list_disk(NULL); } break; case 18: + +/* Line 1806 of yacc.c */ #line 87 "uparse.y" { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } break; case 19: + +/* Line 1806 of yacc.c */ #line 88 "uparse.y" { list_property(); } break; case 20: + +/* Line 1806 of yacc.c */ #line 89 "uparse.y" { yyerror("Invalid argument"); } break; case 21: + +/* Line 1806 of yacc.c */ #line 90 "uparse.y" - { set_host((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } + { set_translate(NULL); } break; case 22: + +/* Line 1806 of yacc.c */ #line 91 "uparse.y" - { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } + { yyerror("Invalid argument"); } break; case 23: + +/* Line 1806 of yacc.c */ #line 92 "uparse.y" - { yyerror("Argument required"); } + { set_translate((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } break; case 24: + +/* Line 1806 of yacc.c */ #line 93 "uparse.y" - { set_disk((yyvsp[(2) - (4)].strval), (yyvsp[(3) - (4)].strval)); amfree((yyvsp[(2) - (4)].strval)); amfree((yyvsp[(3) - (4)].strval)); } + { set_host((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } break; case 25: + +/* Line 1806 of yacc.c */ #line 94 "uparse.y" - { set_disk((yyvsp[(2) - (3)].strval), NULL); amfree((yyvsp[(2) - (3)].strval)); } + { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } break; case 26: + +/* Line 1806 of yacc.c */ #line 95 "uparse.y" - { yyerror("Invalid argument"); amfree((yyvsp[(2) - (4)].strval)); amfree((yyvsp[(3) - (4)].strval)); } + { yyerror("Argument required"); } break; case 27: + +/* Line 1806 of yacc.c */ #line 96 "uparse.y" - { yyerror("Argument required"); } + { set_disk((yyvsp[(2) - (4)].strval), (yyvsp[(3) - (4)].strval)); amfree((yyvsp[(2) - (4)].strval)); amfree((yyvsp[(3) - (4)].strval)); } break; case 28: + +/* Line 1806 of yacc.c */ #line 97 "uparse.y" - { set_tape((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } + { set_disk((yyvsp[(2) - (3)].strval), NULL); amfree((yyvsp[(2) - (3)].strval)); } break; case 29: + +/* Line 1806 of yacc.c */ #line 98 "uparse.y" - { set_tape("default"); } + { yyerror("Invalid argument"); amfree((yyvsp[(2) - (4)].strval)); amfree((yyvsp[(3) - (4)].strval)); } break; case 30: + +/* Line 1806 of yacc.c */ #line 99 "uparse.y" - { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } + { yyerror("Argument required"); } break; case 31: + +/* Line 1806 of yacc.c */ #line 100 "uparse.y" - { set_device(NULL, (yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } + { set_tape((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } break; case 32: + +/* Line 1806 of yacc.c */ #line 101 "uparse.y" - { set_device((yyvsp[(3) - (5)].strval), (yyvsp[(4) - (5)].strval)); amfree((yyvsp[(3) - (5)].strval)); amfree((yyvsp[(4) - (5)].strval)); } + { set_tape("default"); } break; case 33: + +/* Line 1806 of yacc.c */ #line 102 "uparse.y" - { set_device(NULL, NULL); } + { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } break; case 34: + +/* Line 1806 of yacc.c */ #line 103 "uparse.y" - { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } + { set_device(NULL, (yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } break; case 35: + +/* Line 1806 of yacc.c */ #line 104 "uparse.y" - { yyerror("Invalid argument"); amfree((yyvsp[(3) - (4)].strval)); } + { set_device((yyvsp[(3) - (5)].strval), (yyvsp[(4) - (5)].strval)); amfree((yyvsp[(3) - (5)].strval)); amfree((yyvsp[(4) - (5)].strval)); } break; case 36: + +/* Line 1806 of yacc.c */ #line 105 "uparse.y" - { yyerror("Invalid argument"); amfree((yyvsp[(3) - (5)].strval)); amfree((yyvsp[(4) - (5)].strval)); } + { set_device(NULL, NULL); } break; case 37: + +/* Line 1806 of yacc.c */ #line 106 "uparse.y" - { set_property_name((yyvsp[(2) - (3)].strval), 0); amfree((yyvsp[(2) - (3)].strval)); } + { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } break; case 38: + +/* Line 1806 of yacc.c */ #line 107 "uparse.y" - { set_property_name((yyvsp[(3) - (4)].strval), 1); amfree((yyvsp[(3) - (4)].strval)); } + { yyerror("Invalid argument"); amfree((yyvsp[(3) - (4)].strval)); } break; case 39: + +/* Line 1806 of yacc.c */ #line 108 "uparse.y" - { set_property_name((yyvsp[(3) - (4)].strval), 0); amfree((yyvsp[(3) - (4)].strval)); } + { yyerror("Invalid argument"); amfree((yyvsp[(3) - (5)].strval)); amfree((yyvsp[(4) - (5)].strval)); } break; case 40: + +/* Line 1806 of yacc.c */ #line 109 "uparse.y" - { set_property_name((yyvsp[(4) - (5)].strval), 1); amfree((yyvsp[(4) - (5)].strval)); } + { set_property_name((yyvsp[(2) - (3)].strval), 0); amfree((yyvsp[(2) - (3)].strval)); } break; case 41: + +/* Line 1806 of yacc.c */ #line 110 "uparse.y" - { yyerror("Invalid argument"); } + { set_property_name((yyvsp[(3) - (4)].strval), 1); amfree((yyvsp[(3) - (4)].strval)); } break; case 42: + +/* Line 1806 of yacc.c */ #line 111 "uparse.y" - { yyerror("Invalid argument"); } + { set_property_name((yyvsp[(3) - (4)].strval), 0); amfree((yyvsp[(3) - (4)].strval)); } break; case 43: + +/* Line 1806 of yacc.c */ #line 112 "uparse.y" - { yyerror("Invalid argument"); } + { set_property_name((yyvsp[(4) - (5)].strval), 1); amfree((yyvsp[(4) - (5)].strval)); } break; case 44: + +/* Line 1806 of yacc.c */ #line 113 "uparse.y" { yyerror("Invalid argument"); } break; case 45: + +/* Line 1806 of yacc.c */ #line 114 "uparse.y" - { cd_glob((yyvsp[(2) - (3)].strval), 1); amfree((yyvsp[(2) - (3)].strval)); } + { yyerror("Invalid argument"); } break; case 46: + +/* Line 1806 of yacc.c */ #line 115 "uparse.y" { yyerror("Invalid argument"); } break; case 47: + +/* Line 1806 of yacc.c */ #line 116 "uparse.y" - { yyerror("Argument required"); } + { yyerror("Invalid argument"); } break; case 48: + +/* Line 1806 of yacc.c */ #line 117 "uparse.y" - { cd_regex((yyvsp[(2) - (3)].strval), 1); amfree((yyvsp[(2) - (3)].strval)); } + { cd_glob((yyvsp[(2) - (3)].strval), 1); amfree((yyvsp[(2) - (3)].strval)); } break; case 49: + +/* Line 1806 of yacc.c */ #line 118 "uparse.y" - { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } + { yyerror("Invalid argument"); } break; case 50: + +/* Line 1806 of yacc.c */ #line 119 "uparse.y" { yyerror("Argument required"); } break; case 51: + +/* Line 1806 of yacc.c */ #line 120 "uparse.y" - { set_mode(SAMBA_SMBCLIENT); } + { cd_regex((yyvsp[(2) - (3)].strval), 1); amfree((yyvsp[(2) - (3)].strval)); } break; case 52: + +/* Line 1806 of yacc.c */ #line 121 "uparse.y" - { set_mode(SAMBA_TAR); } + { yyerror("Invalid argument"); amfree((yyvsp[(2) - (3)].strval)); } break; case 53: + +/* Line 1806 of yacc.c */ #line 122 "uparse.y" - { yyerror("Invalid argument"); } + { yyerror("Argument required"); } break; case 54: + +/* Line 1806 of yacc.c */ #line 123 "uparse.y" - { yyerror("Invalid argument"); } + { set_mode(SAMBA_SMBCLIENT); } break; case 55: + +/* Line 1806 of yacc.c */ #line 124 "uparse.y" - { yyerror("Invalid argument"); } + { set_mode(SAMBA_TAR); } break; case 56: + +/* Line 1806 of yacc.c */ #line 125 "uparse.y" - { yyerror("Argument required"); } + { yyerror("Invalid argument"); } break; case 57: -#line 129 "uparse.y" + +/* Line 1806 of yacc.c */ +#line 126 "uparse.y" + { yyerror("Invalid argument"); } + break; + + case 58: + +/* Line 1806 of yacc.c */ +#line 127 "uparse.y" + { yyerror("Invalid argument"); } + break; + + case 59: + +/* Line 1806 of yacc.c */ +#line 128 "uparse.y" + { yyerror("Argument required"); } + break; + + case 60: + +/* Line 1806 of yacc.c */ +#line 132 "uparse.y" { time_t now; struct tm *t; @@ -1807,181 +1966,251 @@ yyreduce: } break; - case 58: -#line 175 "uparse.y" - { yyerror("Argument required"); } - break; + case 61: - case 59: -#line 176 "uparse.y" - { yyerror("Invalid argument"); } +/* Line 1806 of yacc.c */ +#line 178 "uparse.y" + { yyerror("Argument required"); } break; - case 60: -#line 180 "uparse.y" - { list_disk_history(); } - break; + case 62: - case 61: -#line 181 "uparse.y" +/* Line 1806 of yacc.c */ +#line 179 "uparse.y" { yyerror("Invalid argument"); } break; - case 62: -#line 182 "uparse.y" - { list_directory(); } - break; - case 63: + +/* Line 1806 of yacc.c */ #line 183 "uparse.y" - { yyerror("Invalid argument"); } + { list_disk_history(); } break; case 64: + +/* Line 1806 of yacc.c */ #line 184 "uparse.y" - { display_extract_list((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } + { yyerror("Invalid argument"); } break; case 65: + +/* Line 1806 of yacc.c */ #line 185 "uparse.y" - { display_extract_list(NULL); } + { list_directory(); } break; case 66: + +/* Line 1806 of yacc.c */ #line 186 "uparse.y" { yyerror("Invalid argument"); } break; case 67: + +/* Line 1806 of yacc.c */ #line 187 "uparse.y" - { show_directory(); } + { display_extract_list((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } break; case 68: + +/* Line 1806 of yacc.c */ #line 188 "uparse.y" - { yyerror("Invalid argument"); } + { display_extract_list(NULL); } break; case 69: + +/* Line 1806 of yacc.c */ #line 189 "uparse.y" - { clear_extract_list(); } + { yyerror("Invalid argument"); } break; case 70: + +/* Line 1806 of yacc.c */ #line 190 "uparse.y" - { yyerror("Invalid argument"); } + { show_directory(); } break; case 71: + +/* Line 1806 of yacc.c */ #line 191 "uparse.y" - { show_mode (); } + { yyerror("Invalid argument"); } break; case 72: + +/* Line 1806 of yacc.c */ #line 192 "uparse.y" - { yyerror("Invalid argument"); } + { clear_extract_list(); } break; case 73: -#line 196 "uparse.y" - { quit(); } + +/* Line 1806 of yacc.c */ +#line 193 "uparse.y" + { yyerror("Invalid argument"); } break; case 74: -#line 197 "uparse.y" + +/* Line 1806 of yacc.c */ +#line 194 "uparse.y" + { show_mode (); } + break; + + case 75: + +/* Line 1806 of yacc.c */ +#line 195 "uparse.y" { yyerror("Invalid argument"); } break; case 76: -#line 205 "uparse.y" - { add_glob((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } + +/* Line 1806 of yacc.c */ +#line 199 "uparse.y" + { quit(); } break; case 77: -#line 206 "uparse.y" - { add_glob((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } + +/* Line 1806 of yacc.c */ +#line 200 "uparse.y" + { yyerror("Invalid argument"); } break; case 79: -#line 214 "uparse.y" - { add_regex((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } + +/* Line 1806 of yacc.c */ +#line 208 "uparse.y" + { add_glob((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 80: -#line 215 "uparse.y" - { add_regex((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } + +/* Line 1806 of yacc.c */ +#line 209 "uparse.y" + { add_glob((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } break; case 82: -#line 223 "uparse.y" - { delete_glob((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } + +/* Line 1806 of yacc.c */ +#line 217 "uparse.y" + { add_regex((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 83: -#line 224 "uparse.y" - { delete_glob((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } + +/* Line 1806 of yacc.c */ +#line 218 "uparse.y" + { add_regex((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } break; case 85: -#line 232 "uparse.y" - { delete_regex((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } + +/* Line 1806 of yacc.c */ +#line 226 "uparse.y" + { delete_glob((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } break; case 86: -#line 233 "uparse.y" + +/* Line 1806 of yacc.c */ +#line 227 "uparse.y" + { delete_glob((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } + break; + + case 88: + +/* Line 1806 of yacc.c */ +#line 235 "uparse.y" + { delete_regex((yyvsp[(2) - (2)].strval)); amfree((yyvsp[(2) - (2)].strval)); } + break; + + case 89: + +/* Line 1806 of yacc.c */ +#line 236 "uparse.y" { delete_regex((yyvsp[(1) - (1)].strval)); amfree((yyvsp[(1) - (1)].strval)); } break; - case 87: -#line 237 "uparse.y" + case 90: + +/* Line 1806 of yacc.c */ +#line 240 "uparse.y" { char * buf= g_get_current_dir(); puts(buf); free(buf); } break; - case 88: -#line 238 "uparse.y" + case 91: + +/* Line 1806 of yacc.c */ +#line 241 "uparse.y" { yyerror("Invalid argument"); } break; - case 89: -#line 239 "uparse.y" + case 92: + +/* Line 1806 of yacc.c */ +#line 242 "uparse.y" { local_cd((yyvsp[(2) - (3)].strval)); amfree((yyvsp[(2) - (3)].strval)); } break; - case 90: -#line 243 "uparse.y" + case 93: + +/* Line 1806 of yacc.c */ +#line 246 "uparse.y" { yyerror("Invalid argument"); } break; - case 91: -#line 244 "uparse.y" + case 94: + +/* Line 1806 of yacc.c */ +#line 247 "uparse.y" { yyerror("Argument required"); } break; - case 92: -#line 248 "uparse.y" + case 95: + +/* Line 1806 of yacc.c */ +#line 251 "uparse.y" { help_list(); } break; - case 93: -#line 249 "uparse.y" + case 96: + +/* Line 1806 of yacc.c */ +#line 252 "uparse.y" { yyerror("Invalid argument"); } break; - case 94: -#line 253 "uparse.y" + case 97: + +/* Line 1806 of yacc.c */ +#line 256 "uparse.y" { extract_files(); } break; - case 95: -#line 254 "uparse.y" + case 98: + +/* Line 1806 of yacc.c */ +#line 257 "uparse.y" { yyerror("Invalid argument"); } break; - case 96: -#line 258 "uparse.y" + case 99: + +/* Line 1806 of yacc.c */ +#line 261 "uparse.y" { char * errstr = vstralloc("Invalid command: ", (yyvsp[(1) - (2)].strval), NULL); yyerror(errstr); @@ -1990,36 +2219,58 @@ yyreduce: } break; - case 97: -#line 267 "uparse.y" + case 100: + +/* Line 1806 of yacc.c */ +#line 270 "uparse.y" { add_property_value((yyvsp[(1) - (2)].strval)); amfree( (yyvsp[(1) - (2)].strval)); } break; - case 98: -#line 268 "uparse.y" + case 101: + +/* Line 1806 of yacc.c */ +#line 271 "uparse.y" { ; } break; - case 99: -#line 272 "uparse.y" + case 102: + +/* Line 1806 of yacc.c */ +#line 275 "uparse.y" { amfree((yyvsp[(1) - (2)].strval)); } break; - case 100: -#line 276 "uparse.y" + case 103: + +/* Line 1806 of yacc.c */ +#line 279 "uparse.y" { amfree((yyvsp[(1) - (2)].strval)); } break; - case 101: -#line 277 "uparse.y" + case 104: + +/* Line 1806 of yacc.c */ +#line 280 "uparse.y" { ; } break; -/* Line 1267 of yacc.c. */ -#line 2021 "uparse.c" + +/* Line 1806 of yacc.c */ +#line 2261 "uparse.c" default: break; } + /* User semantic actions sometimes alter yychar, and that requires + that yytoken be updated with the new translation. We take the + approach of translating immediately before every use of yytoken. + One alternative is translating here after every semantic action, + but that translation would be missed if the semantic action invokes + YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or + if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an + incorrect destructor might then be invoked immediately. In the + case of YYERROR or YYBACKUP, subsequent parser actions might lead + to an incorrect destructor call or verbose syntax error message + before the lookahead is translated. */ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); YYPOPSTACK (yylen); @@ -2028,7 +2279,6 @@ yyreduce: *++yyvsp = yyval; - /* Now `shift' the result of the reduction. Determine what state that goes to, based on the state we popped back to and the rule number reduced by. */ @@ -2048,6 +2298,10 @@ yyreduce: | yyerrlab -- here on detecting error | `------------------------------------*/ yyerrlab: + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); + /* If not already recovering from an error, report this error. */ if (!yyerrstatus) { @@ -2055,37 +2309,36 @@ yyerrlab: #if ! YYERROR_VERBOSE yyerror (YY_("syntax error")); #else +# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ + yyssp, yytoken) { - YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); - if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) - { - YYSIZE_T yyalloc = 2 * yysize; - if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) - yyalloc = YYSTACK_ALLOC_MAXIMUM; - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); - yymsg = (char *) YYSTACK_ALLOC (yyalloc); - if (yymsg) - yymsg_alloc = yyalloc; - else - { - yymsg = yymsgbuf; - yymsg_alloc = sizeof yymsgbuf; - } - } - - if (0 < yysize && yysize <= yymsg_alloc) - { - (void) yysyntax_error (yymsg, yystate, yychar); - yyerror (yymsg); - } - else - { - yyerror (YY_("syntax error")); - if (yysize != 0) - goto yyexhaustedlab; - } + char const *yymsgp = YY_("syntax error"); + int yysyntax_error_status; + yysyntax_error_status = YYSYNTAX_ERROR; + if (yysyntax_error_status == 0) + yymsgp = yymsg; + else if (yysyntax_error_status == 1) + { + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); + if (!yymsg) + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + yysyntax_error_status = 2; + } + else + { + yysyntax_error_status = YYSYNTAX_ERROR; + yymsgp = yymsg; + } + } + yyerror (yymsgp); + if (yysyntax_error_status == 2) + goto yyexhaustedlab; } +# undef YYSYNTAX_ERROR #endif } @@ -2093,7 +2346,7 @@ yyerrlab: if (yyerrstatus == 3) { - /* If just tried and failed to reuse look-ahead token after an + /* If just tried and failed to reuse lookahead token after an error, discard it. */ if (yychar <= YYEOF) @@ -2110,7 +2363,7 @@ yyerrlab: } } - /* Else will try to reuse look-ahead token after shifting the error + /* Else will try to reuse lookahead token after shifting the error token. */ goto yyerrlab1; @@ -2144,7 +2397,7 @@ yyerrlab1: for (;;) { yyn = yypact[yystate]; - if (yyn != YYPACT_NINF) + if (!yypact_value_is_default (yyn)) { yyn += YYTERROR; if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) @@ -2167,9 +2420,6 @@ yyerrlab1: YY_STACK_PRINT (yyss, yyssp); } - if (yyn == YYFINAL) - YYACCEPT; - *++yyvsp = yylval; @@ -2194,7 +2444,7 @@ yyabortlab: yyresult = 1; goto yyreturn; -#ifndef yyoverflow +#if !defined(yyoverflow) || YYERROR_VERBOSE /*-------------------------------------------------. | yyexhaustedlab -- memory exhaustion comes here. | `-------------------------------------------------*/ @@ -2205,9 +2455,14 @@ yyexhaustedlab: #endif yyreturn: - if (yychar != YYEOF && yychar != YYEMPTY) - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval); + if (yychar != YYEMPTY) + { + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = YYTRANSLATE (yychar); + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + } /* Do not reclaim the symbols of the rule which action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); @@ -2231,7 +2486,9 @@ yyreturn: } -#line 280 "uparse.y" + +/* Line 2067 of yacc.c */ +#line 283 "uparse.y" void diff --git a/recover-src/uparse.h b/recover-src/uparse.h index de9ed57..9e4d4e7 100644 --- a/recover-src/uparse.h +++ b/recover-src/uparse.h @@ -1,24 +1,21 @@ -/* A Bison parser, made by GNU Bison 2.3. */ +/* A Bison parser, made by GNU Bison 2.5. */ -/* Skeleton interface for Bison's Yacc-like parsers in C - - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006 - Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify +/* Bison interface for Yacc-like parsers in C + + Copyright (C) 1984, 1989-1990, 2000-2011 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. - + the Free Software Foundation, either version 3 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. */ + along with this program. If not, see . */ /* As a special exception, you may create a larger work that contains part or all of the Bison parser skeleton and distribute that work @@ -29,10 +26,11 @@ special exception, which will cause the skeleton and the resulting Bison output files to be licensed under the GNU General Public License without this special exception. - + This special exception was added by the Free Software Foundation in version 2.2 of Bison. */ + /* Tokens. */ #ifndef YYTOKENTYPE # define YYTOKENTYPE @@ -71,8 +69,9 @@ TAR = 287, APPEND = 288, PRIORITY = 289, - NL = 290, - STRING = 291 + SETTRANSLATE = 290, + NL = 291, + STRING = 292 }; #endif /* Tokens. */ @@ -108,28 +107,35 @@ #define TAR 287 #define APPEND 288 #define PRIORITY 289 -#define NL 290 -#define STRING 291 +#define SETTRANSLATE 290 +#define NL 291 +#define STRING 292 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED typedef union YYSTYPE -#line 43 "uparse.y" { + +/* Line 2068 of yacc.c */ +#line 43 "uparse.y" + int intval; double floatval; char * strval; int subtok; -} -/* Line 1489 of yacc.c. */ -#line 128 "uparse.h" - YYSTYPE; + + + +/* Line 2068 of yacc.c */ +#line 133 "uparse.h" +} YYSTYPE; +# define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 -# define YYSTYPE_IS_TRIVIAL 1 #endif extern YYSTYPE yylval; + diff --git a/recover-src/uparse.y b/recover-src/uparse.y index 1562e9c..e947012 100644 --- a/recover-src/uparse.y +++ b/recover-src/uparse.y @@ -53,7 +53,7 @@ extern char * yytext; %token SETHOST SETDISK SETDATE SETTAPE SETMODE SETDEVICE SETPROPERTY %token CD CDX QUIT DHIST LS ADD ADDX EXTRACT DASH_H %token LIST DELETE DELETEX PWD CLEAR HELP LCD LPWD MODE SMB TAR -%token APPEND PRIORITY +%token APPEND PRIORITY SETTRANSLATE %token NL /* typed tokens */ @@ -87,6 +87,9 @@ set_command: | LISTDISK STRING invalid_string { yyerror("Invalid argument"); amfree($2); } | LISTPROPERTY NL { list_property(); } | LISTPROPERTY invalid_string { yyerror("Invalid argument"); } + | SETTRANSLATE NL { set_translate(NULL); } + | SETTRANSLATE STRING invalid_string NL { yyerror("Invalid argument"); } + | SETTRANSLATE STRING NL { set_translate($2); amfree($2); } | SETHOST STRING NL { set_host($2); amfree($2); } | SETHOST STRING invalid_string { yyerror("Invalid argument"); amfree($2); } | SETHOST NL { yyerror("Argument required"); } diff --git a/recover-src/uscan.c b/recover-src/uscan.c index dc8a9b1..5821f18 100644 --- a/recover-src/uscan.c +++ b/recover-src/uscan.c @@ -359,8 +359,8 @@ static void yy_fatal_error (yyconst char msg[] ); *yy_cp = '\0'; \ (yy_c_buf_p) = yy_cp; -#define YY_NUM_RULES 43 -#define YY_END_OF_BUFFER 44 +#define YY_NUM_RULES 44 +#define YY_END_OF_BUFFER 45 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -368,27 +368,28 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[175] = +static yyconst flex_int16_t yy_accept[183] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 44, 43, 42, 33, - 33, 41, 26, 41, 41, 41, 41, 41, 41, 41, - 41, 41, 41, 37, 37, 40, 40, 39, 43, 36, - 41, 41, 41, 41, 41, 42, 33, 33, 33, 41, - 41, 12, 41, 41, 41, 41, 41, 41, 41, 41, - 17, 41, 41, 41, 41, 37, 37, 40, 40, 0, - 40, 38, 11, 41, 41, 41, 41, 18, 13, 41, - 41, 41, 41, 41, 41, 27, 41, 41, 41, 23, - 41, 41, 32, 31, 41, 41, 19, 41, 41, 15, - - 41, 25, 41, 20, 28, 30, 14, 41, 41, 41, - 41, 41, 41, 41, 24, 41, 41, 41, 41, 41, - 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, - 21, 41, 41, 41, 41, 41, 41, 41, 41, 41, - 41, 41, 41, 34, 41, 22, 29, 16, 41, 41, - 41, 6, 41, 5, 4, 7, 41, 8, 41, 2, - 1, 41, 41, 41, 35, 41, 9, 41, 41, 41, - 41, 10, 3, 0 + 0, 0, 0, 0, 0, 0, 45, 44, 43, 34, + 34, 42, 27, 42, 42, 42, 42, 42, 42, 42, + 42, 42, 42, 38, 38, 41, 41, 40, 44, 37, + 42, 42, 42, 42, 42, 43, 34, 34, 34, 42, + 42, 13, 42, 42, 42, 42, 42, 42, 42, 42, + 18, 42, 42, 42, 42, 38, 38, 41, 41, 0, + 41, 39, 12, 42, 42, 42, 42, 19, 14, 42, + 42, 42, 42, 42, 42, 28, 42, 42, 42, 24, + 42, 42, 33, 32, 42, 42, 20, 42, 42, 16, + + 42, 26, 42, 21, 29, 31, 15, 42, 42, 42, + 42, 42, 42, 42, 25, 42, 42, 42, 42, 42, + 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, + 42, 22, 42, 42, 42, 42, 42, 42, 42, 42, + 42, 42, 42, 42, 42, 35, 42, 23, 30, 17, + 42, 42, 42, 6, 42, 5, 4, 7, 42, 8, + 42, 42, 2, 1, 42, 42, 42, 42, 36, 42, + 9, 42, 42, 42, 42, 42, 42, 10, 42, 3, + 11, 0 } ; static yyconst flex_int32_t yy_ec[256] = @@ -431,120 +432,122 @@ static yyconst flex_int32_t yy_meta[32] = 4 } ; -static yyconst flex_int16_t yy_base[179] = +static yyconst flex_int16_t yy_base[187] = { 0, - 0, 0, 30, 38, 42, 0, 242, 241, 44, 46, - 240, 239, 36, 52, 56, 59, 245, 250, 73, 80, - 83, 0, 0, 231, 55, 229, 212, 21, 76, 220, - 211, 212, 224, 0, 87, 91, 100, 250, 0, 250, - 222, 217, 225, 212, 209, 103, 106, 109, 112, 0, - 219, 201, 216, 211, 101, 210, 202, 213, 200, 195, - 0, 210, 209, 205, 194, 0, 116, 119, 122, 126, - 129, 250, 0, 208, 194, 195, 200, 185, 0, 204, - 199, 186, 187, 188, 183, 0, 182, 194, 192, 0, - 179, 121, 0, 0, 190, 182, 0, 178, 175, 0, - - 190, 0, 178, 122, 0, 0, 0, 132, 177, 176, - 172, 185, 174, 169, 0, 178, 179, 166, 173, 167, - 163, 160, 157, 159, 158, 169, 160, 158, 166, 162, - 147, 150, 144, 149, 148, 151, 157, 154, 152, 142, - 153, 144, 151, 0, 135, 0, 0, 0, 141, 131, - 123, 0, 129, 0, 0, 0, 125, 0, 107, 0, - 0, 86, 85, 73, 0, 72, 0, 54, 53, 14, - 7, 0, 0, 250, 148, 150, 155, 159 + 0, 0, 30, 38, 42, 0, 250, 249, 44, 46, + 248, 247, 36, 52, 56, 59, 253, 258, 73, 80, + 83, 0, 0, 239, 55, 237, 220, 21, 76, 228, + 219, 220, 232, 0, 87, 91, 100, 258, 0, 258, + 230, 225, 233, 220, 217, 103, 106, 109, 112, 0, + 227, 209, 224, 219, 101, 218, 210, 221, 208, 203, + 0, 218, 217, 213, 202, 0, 116, 119, 122, 126, + 129, 258, 0, 216, 202, 203, 208, 193, 0, 212, + 207, 194, 195, 196, 191, 0, 190, 202, 200, 0, + 187, 121, 0, 0, 198, 190, 0, 186, 183, 0, + + 198, 0, 186, 122, 0, 0, 0, 132, 185, 184, + 180, 128, 183, 178, 0, 187, 188, 175, 182, 176, + 172, 169, 166, 168, 167, 178, 169, 167, 178, 174, + 170, 155, 158, 152, 157, 156, 159, 165, 162, 160, + 150, 161, 152, 159, 152, 0, 145, 0, 0, 0, + 153, 143, 143, 0, 150, 0, 0, 0, 147, 0, + 126, 119, 0, 0, 135, 131, 117, 121, 0, 76, + 0, 73, 87, 70, 49, 53, 14, 0, 24, 0, + 0, 258, 152, 154, 159, 163 } ; -static yyconst flex_int16_t yy_def[179] = +static yyconst flex_int16_t yy_def[187] = { 0, - 174, 1, 175, 175, 1, 5, 5, 5, 5, 5, - 5, 5, 5, 5, 5, 5, 174, 174, 174, 174, - 174, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 177, 177, 174, 174, 174, 178, 174, - 176, 176, 176, 176, 176, 174, 174, 174, 174, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 177, 177, 174, 174, 174, - 174, 174, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 176, 176, 176, 176, 176, 176, 176, - 176, 176, 176, 0, 174, 174, 174, 174 + 182, 1, 183, 183, 1, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 182, 182, 182, 182, + 182, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 185, 185, 182, 182, 182, 186, 182, + 184, 184, 184, 184, 184, 182, 182, 182, 182, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 185, 185, 182, 182, 182, + 182, 182, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 184, 184, 184, 184, 184, 184, 184, 184, 184, + 184, 0, 182, 182, 182, 182 } ; -static yyconst flex_int16_t yy_nxt[282] = +static yyconst flex_int16_t yy_nxt[290] = { 0, 18, 19, 20, 21, 22, 18, 22, 23, 22, 24, 22, 25, 26, 27, 28, 22, 22, 29, 30, 22, 22, 31, 32, 22, 33, 22, 22, 22, 22, 22, - 22, 35, 36, 37, 56, 38, 57, 173, 39, 35, - 36, 37, 22, 38, 172, 44, 39, 40, 41, 22, + 22, 35, 36, 37, 56, 38, 57, 181, 39, 35, + 36, 37, 22, 38, 180, 44, 39, 40, 41, 22, 22, 22, 22, 22, 22, 22, 22, 45, 22, 22, 22, 44, 22, 22, 22, 22, 22, 52, 42, 43, - 42, 43, 53, 45, 46, 47, 48, 45, 171, 170, + 42, 43, 53, 45, 46, 47, 48, 45, 179, 178, 45, 46, 47, 48, 46, 49, 48, 58, 67, 68, - 69, 59, 70, 68, 69, 169, 168, 60, 167, 166, + 69, 59, 70, 68, 69, 177, 176, 60, 175, 174, 61, 70, 71, 69, 46, 47, 48, 46, 47, 48, 46, 49, 48, 46, 47, 48, 82, 67, 68, 69, 70, 68, 69, 70, 71, 69, 83, 70, 68, 69, - 70, 68, 69, 108, 119, 109, 120, 165, 164, 110, - 163, 122, 111, 121, 162, 123, 112, 124, 34, 34, - 34, 34, 34, 50, 50, 66, 161, 160, 66, 72, - 159, 72, 72, 72, 158, 157, 156, 155, 154, 153, + 70, 68, 69, 108, 119, 109, 120, 128, 173, 110, + 172, 122, 111, 121, 171, 123, 112, 124, 170, 169, + 168, 129, 34, 34, 34, 34, 34, 50, 50, 66, + 167, 166, 66, 72, 165, 72, 72, 72, 164, 163, + 162, 161, 160, 159, 158, 157, 156, 155, 154, 153, 152, 151, 150, 149, 148, 147, 146, 145, 144, 143, 142, 141, 140, 139, 138, 137, 136, 135, 134, 133, - 132, 131, 130, 129, 128, 127, 126, 125, 118, 117, - - 116, 115, 114, 113, 107, 106, 105, 104, 103, 102, - 101, 100, 99, 98, 97, 96, 95, 94, 93, 92, - 91, 90, 89, 88, 87, 86, 85, 84, 81, 80, - 79, 78, 77, 76, 75, 74, 73, 65, 64, 63, - 62, 55, 54, 51, 174, 22, 22, 22, 22, 17, - 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, - 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, - 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, - 174 + + 132, 131, 130, 127, 126, 125, 118, 117, 116, 115, + 114, 113, 107, 106, 105, 104, 103, 102, 101, 100, + 99, 98, 97, 96, 95, 94, 93, 92, 91, 90, + 89, 88, 87, 86, 85, 84, 81, 80, 79, 78, + 77, 76, 75, 74, 73, 65, 64, 63, 62, 55, + 54, 51, 182, 22, 22, 22, 22, 17, 182, 182, + 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, + 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, + 182, 182, 182, 182, 182, 182, 182, 182, 182 } ; -static yyconst flex_int16_t yy_chk[282] = +static yyconst flex_int16_t yy_chk[290] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 3, 3, 3, 28, 3, 28, 171, 3, 4, - 4, 4, 13, 4, 170, 13, 4, 5, 5, 5, + 1, 3, 3, 3, 28, 3, 28, 179, 3, 4, + 4, 4, 13, 4, 177, 13, 4, 5, 5, 5, 9, 5, 10, 5, 5, 5, 5, 13, 14, 5, 5, 14, 15, 5, 5, 16, 5, 25, 9, 9, - 10, 10, 25, 14, 19, 19, 19, 15, 169, 168, + 10, 10, 25, 14, 19, 19, 19, 15, 176, 175, 16, 20, 20, 20, 21, 21, 21, 29, 35, 35, - 35, 29, 36, 36, 36, 166, 164, 29, 163, 162, + 35, 29, 36, 36, 36, 174, 173, 29, 172, 170, 29, 37, 37, 37, 46, 46, 46, 47, 47, 47, 48, 48, 48, 49, 49, 49, 55, 67, 67, 67, 68, 68, 68, 69, 69, 69, 55, 70, 70, 70, - 71, 71, 71, 92, 104, 92, 104, 159, 157, 92, - 153, 108, 92, 104, 151, 108, 92, 108, 175, 175, - 175, 175, 175, 176, 176, 177, 150, 149, 177, 178, - 145, 178, 178, 178, 143, 142, 141, 140, 139, 138, - 137, 136, 135, 134, 133, 132, 131, 130, 129, 128, - 127, 126, 125, 124, 123, 122, 121, 120, 119, 118, - 117, 116, 114, 113, 112, 111, 110, 109, 103, 101, - - 99, 98, 96, 95, 91, 89, 88, 87, 85, 84, - 83, 82, 81, 80, 78, 77, 76, 75, 74, 65, - 64, 63, 62, 60, 59, 58, 57, 56, 54, 53, - 52, 51, 45, 44, 43, 42, 41, 33, 32, 31, - 30, 27, 26, 24, 17, 12, 11, 8, 7, 174, - 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, - 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, - 174, 174, 174, 174, 174, 174, 174, 174, 174, 174, - 174 + 71, 71, 71, 92, 104, 92, 104, 112, 168, 92, + 167, 108, 92, 104, 166, 108, 92, 108, 165, 162, + 161, 112, 183, 183, 183, 183, 183, 184, 184, 185, + 159, 155, 185, 186, 153, 186, 186, 186, 152, 151, + 147, 145, 144, 143, 142, 141, 140, 139, 138, 137, + 136, 135, 134, 133, 132, 131, 130, 129, 128, 127, + 126, 125, 124, 123, 122, 121, 120, 119, 118, 117, + + 116, 114, 113, 111, 110, 109, 103, 101, 99, 98, + 96, 95, 91, 89, 88, 87, 85, 84, 83, 82, + 81, 80, 78, 77, 76, 75, 74, 65, 64, 63, + 62, 60, 59, 58, 57, 56, 54, 53, 52, 51, + 45, 44, 43, 42, 41, 33, 32, 31, 30, 27, + 26, 24, 17, 12, 11, 8, 7, 182, 182, 182, + 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, + 182, 182, 182, 182, 182, 182, 182, 182, 182, 182, + 182, 182, 182, 182, 182, 182, 182, 182, 182 } ; static yy_state_type yy_last_accepting_state; @@ -624,7 +627,7 @@ int process_line(char *line); #line 66 "uscan.l" static char *string_buf = NULL; -#line 628 "uscan.c" +#line 631 "uscan.c" #define INITIAL 0 #define quotedstring 1 @@ -720,7 +723,7 @@ static int input (void ); /* This used to be an fputs(), but since the string might contain NUL's, * we now use fwrite(). */ -#define ECHO fwrite( yytext, yyleng, 1, yyout ) +#define ECHO do { if (fwrite( yytext, yyleng, 1, yyout )) {} } while (0) #endif /* Gets input and stuffs it into "buf". number of characters read, or YY_NULL, @@ -820,7 +823,7 @@ YY_DECL /* literal keyword tokens */ -#line 824 "uscan.c" +#line 827 "uscan.c" if ( !(yy_init) ) { @@ -873,13 +876,13 @@ yy_match: while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 175 ) + if ( yy_current_state >= 183 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; ++yy_cp; } - while ( yy_base[yy_current_state] != 250 ); + while ( yy_base[yy_current_state] != 258 ); yy_find_action: yy_act = yy_accept[yy_current_state]; @@ -956,22 +959,22 @@ YY_RULE_SETUP case 11: YY_RULE_SETUP #line 85 "uscan.l" -{ BEGIN(needstring); return DASH_H; } +{ BEGIN(needstring); return SETTRANSLATE; } YY_BREAK case 12: YY_RULE_SETUP #line 86 "uscan.l" -{ BEGIN(needstring); return CD; } +{ BEGIN(needstring); return DASH_H; } YY_BREAK case 13: YY_RULE_SETUP #line 87 "uscan.l" -{ BEGIN(needstring); return CDX; } +{ BEGIN(needstring); return CD; } YY_BREAK case 14: YY_RULE_SETUP #line 88 "uscan.l" -{ BEGIN(needstring); return QUIT; } +{ BEGIN(needstring); return CDX; } YY_BREAK case 15: YY_RULE_SETUP @@ -981,116 +984,121 @@ YY_RULE_SETUP case 16: YY_RULE_SETUP #line 90 "uscan.l" -{ BEGIN(needstring); return DHIST; } +{ BEGIN(needstring); return QUIT; } YY_BREAK case 17: YY_RULE_SETUP #line 91 "uscan.l" -{ BEGIN(needstring); return LS; } +{ BEGIN(needstring); return DHIST; } YY_BREAK case 18: YY_RULE_SETUP #line 92 "uscan.l" -{ BEGIN(needstring); return ADD; } +{ BEGIN(needstring); return LS; } YY_BREAK case 19: YY_RULE_SETUP #line 93 "uscan.l" -{ BEGIN(needstring); return ADDX; } +{ BEGIN(needstring); return ADD; } YY_BREAK case 20: YY_RULE_SETUP #line 94 "uscan.l" -{ BEGIN(needstring); return LIST; } +{ BEGIN(needstring); return ADDX; } YY_BREAK case 21: YY_RULE_SETUP #line 95 "uscan.l" -{ BEGIN(needstring); return DELETE; } +{ BEGIN(needstring); return LIST; } YY_BREAK case 22: YY_RULE_SETUP #line 96 "uscan.l" -{ BEGIN(needstring); return DELETEX; } +{ BEGIN(needstring); return DELETE; } YY_BREAK case 23: YY_RULE_SETUP #line 97 "uscan.l" -{ BEGIN(needstring); return PWD; } +{ BEGIN(needstring); return DELETEX; } YY_BREAK case 24: YY_RULE_SETUP #line 98 "uscan.l" -{ BEGIN(needstring); return CLEAR; } +{ BEGIN(needstring); return PWD; } YY_BREAK case 25: YY_RULE_SETUP #line 99 "uscan.l" -{ BEGIN(INITIAL); return HELP; } +{ BEGIN(needstring); return CLEAR; } YY_BREAK case 26: YY_RULE_SETUP #line 100 "uscan.l" -{ BEGIN(needstring); return HELP; } +{ BEGIN(INITIAL); return HELP; } YY_BREAK case 27: YY_RULE_SETUP #line 101 "uscan.l" -{ BEGIN(needstring); return LCD; } +{ BEGIN(needstring); return HELP; } YY_BREAK case 28: YY_RULE_SETUP #line 102 "uscan.l" -{ BEGIN(needstring); return LPWD; } +{ BEGIN(needstring); return LCD; } YY_BREAK case 29: YY_RULE_SETUP #line 103 "uscan.l" -{ BEGIN(needstring); return EXTRACT; } +{ BEGIN(needstring); return LPWD; } YY_BREAK case 30: YY_RULE_SETUP #line 104 "uscan.l" -{ BEGIN(needstring); return MODE; } +{ BEGIN(needstring); return EXTRACT; } YY_BREAK case 31: YY_RULE_SETUP #line 105 "uscan.l" -{ BEGIN(needstring); return TAR; } +{ BEGIN(needstring); return MODE; } YY_BREAK case 32: YY_RULE_SETUP #line 106 "uscan.l" -{ BEGIN(needstring); return SMB; } +{ BEGIN(needstring); return TAR; } YY_BREAK case 33: -/* rule 33 can match eol */ YY_RULE_SETUP #line 107 "uscan.l" +{ BEGIN(needstring); return SMB; } + YY_BREAK +case 34: +/* rule 34 can match eol */ +YY_RULE_SETUP +#line 108 "uscan.l" { BEGIN(INITIAL); return NL; } YY_BREAK /* quoted file names */ -case 34: +case 35: YY_RULE_SETUP -#line 113 "uscan.l" +#line 114 "uscan.l" { BEGIN(propertypriority); return APPEND; } YY_BREAK -case 35: +case 36: YY_RULE_SETUP -#line 118 "uscan.l" +#line 119 "uscan.l" { BEGIN(needstring); return PRIORITY; } YY_BREAK -case 36: +case 37: YY_RULE_SETUP -#line 123 "uscan.l" +#line 124 "uscan.l" { if(string_buf != NULL) { g_printf("ERROR:string_buf != NULL: %s\n",string_buf); @@ -1099,24 +1107,24 @@ YY_RULE_SETUP strappend(string_buf, yytext); } YY_BREAK -case 37: +case 38: YY_RULE_SETUP -#line 131 "uscan.l" +#line 132 "uscan.l" { strappend(string_buf, yytext); } YY_BREAK -case 38: +case 39: YY_RULE_SETUP -#line 135 "uscan.l" +#line 136 "uscan.l" { /* escaped character (including quote) */ strappend(string_buf, yytext); } YY_BREAK -case 39: +case 40: YY_RULE_SETUP -#line 140 "uscan.l" +#line 141 "uscan.l" { /* saw closing quote - all done */ strappend(string_buf, yytext); yylval.strval = string_buf; @@ -1125,10 +1133,10 @@ YY_RULE_SETUP return STRING; } YY_BREAK -case 40: -/* rule 40 can match eol */ +case 41: +/* rule 41 can match eol */ YY_RULE_SETUP -#line 148 "uscan.l" +#line 149 "uscan.l" { fprintf(stderr,"Unterminated quoted string\n"); string_buf = NULL; @@ -1139,9 +1147,9 @@ YY_RULE_SETUP /* file names */ -case 41: +case 42: YY_RULE_SETUP -#line 159 "uscan.l" +#line 160 "uscan.l" { yylval.strval = stralloc(yytext); BEGIN(needstring); @@ -1151,10 +1159,10 @@ YY_RULE_SETUP /* whitespace */ -case 42: -/* rule 42 can match eol */ +case 43: +/* rule 43 can match eol */ YY_RULE_SETUP -#line 169 "uscan.l" +#line 170 "uscan.l" ; /* whitespace */ YY_BREAK @@ -1166,12 +1174,12 @@ YY_RULE_SETUP . { yyerror("invalid character"); } #endif -case 43: +case 44: YY_RULE_SETUP -#line 182 "uscan.l" +#line 183 "uscan.l" ECHO; YY_BREAK -#line 1175 "uscan.c" +#line 1183 "uscan.c" case YY_STATE_EOF(INITIAL): case YY_STATE_EOF(quotedstring): case YY_STATE_EOF(needdevice): @@ -1470,7 +1478,7 @@ static int yy_get_next_buffer (void) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 175 ) + if ( yy_current_state >= 183 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -1498,11 +1506,11 @@ static int yy_get_next_buffer (void) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 175 ) + if ( yy_current_state >= 183 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; - yy_is_jam = (yy_current_state == 174); + yy_is_jam = (yy_current_state == 182); return yy_is_jam ? 0 : yy_current_state; } @@ -2176,7 +2184,7 @@ void yyfree (void * ptr ) #define YYTABLES_NAME "yytables" -#line 182 "uscan.l" +#line 183 "uscan.l" diff --git a/recover-src/uscan.l b/recover-src/uscan.l index e62575d..0e583b8 100644 --- a/recover-src/uscan.l +++ b/recover-src/uscan.l @@ -82,6 +82,7 @@ setmode { BEGIN(needmode); return SETMODE; } settape { BEGIN(needstring); return SETTAPE; } setdevice { BEGIN(needdevice); return SETDEVICE; } setproperty { BEGIN(propertyappend); return SETPROPERTY; } +settranslate { BEGIN(needstring); return SETTRANSLATE; } -h { BEGIN(needstring); return DASH_H; } cd { BEGIN(needstring); return CD; } cdx { BEGIN(needstring); return CDX; } diff --git a/server-src/Makefile.am b/server-src/Makefile.am index 1e7a7ed..4c7eabe 100644 --- a/server-src/Makefile.am +++ b/server-src/Makefile.am @@ -25,8 +25,7 @@ sbin_PROGRAMS = amadmin amcheck \ amlibexec_PROGRAMS = amindexd amtrmidx \ amtrmlog driver dumper \ - planner amcleanupdisk \ - chunker + planner chunker amlibexec_SCRIPTS_PERL = \ amlogroll \ @@ -41,6 +40,7 @@ sbin_SCRIPTS_PERL = \ amtoc \ amcheckdump \ amcleanup \ + amcleanupdisk \ amrmtape \ amlabel \ amreport \ diff --git a/server-src/Makefile.in b/server-src/Makefile.in index 421f12c..8d84135 100644 --- a/server-src/Makefile.in +++ b/server-src/Makefile.in @@ -1,4 +1,4 @@ -# Makefile.in generated by automake 1.11 from Makefile.am. +# Makefile.in generated by automake 1.11.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, @@ -193,7 +193,7 @@ DIST_COMMON = $(noinst_HEADERS) $(srcdir)/Makefile.am \ sbin_PROGRAMS = amadmin$(EXEEXT) amcheck$(EXEEXT) amflush$(EXEEXT) amlibexec_PROGRAMS = amindexd$(EXEEXT) amtrmidx$(EXEEXT) \ amtrmlog$(EXEEXT) driver$(EXEEXT) dumper$(EXEEXT) \ - planner$(EXEEXT) amcleanupdisk$(EXEEXT) chunker$(EXEEXT) + planner$(EXEEXT) chunker$(EXEEXT) @WANT_RESTORE_TRUE@am__append_2 = \ @WANT_RESTORE_TRUE@ amidxtaped @@ -405,11 +405,6 @@ amcheck_OBJECTS = amcheck.$(OBJEXT) amcheck_LDADD = $(LDADD) amcheck_DEPENDENCIES = ../common-src/libamanda.la libamserver.la \ ../device-src/libamdevice.la ../common-src/libamanda.la -amcleanupdisk_SOURCES = amcleanupdisk.c -amcleanupdisk_OBJECTS = amcleanupdisk.$(OBJEXT) -amcleanupdisk_LDADD = $(LDADD) -amcleanupdisk_DEPENDENCIES = ../common-src/libamanda.la libamserver.la \ - ../device-src/libamdevice.la ../common-src/libamanda.la amflush_SOURCES = amflush.c amflush_OBJECTS = amflush.$(OBJEXT) amflush_LDADD = $(LDADD) @@ -474,14 +469,14 @@ CCLD = $(CC) LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ $(LDFLAGS) -o $@ -SOURCES = $(libamserver_la_SOURCES) amadmin.c amcheck.c \ - amcleanupdisk.c amflush.c $(amindexd_SOURCES) amtrmidx.c \ - amtrmlog.c chunker.c $(diskfile_SOURCES) driver.c dumper.c \ - $(infofile_SOURCES) planner.c -DIST_SOURCES = $(libamserver_la_SOURCES) amadmin.c amcheck.c \ - amcleanupdisk.c amflush.c $(amindexd_SOURCES) amtrmidx.c \ - amtrmlog.c chunker.c $(diskfile_SOURCES) driver.c dumper.c \ - $(infofile_SOURCES) planner.c +SOURCES = $(libamserver_la_SOURCES) amadmin.c amcheck.c amflush.c \ + $(amindexd_SOURCES) amtrmidx.c amtrmlog.c chunker.c \ + $(diskfile_SOURCES) driver.c dumper.c $(infofile_SOURCES) \ + planner.c +DIST_SOURCES = $(libamserver_la_SOURCES) amadmin.c amcheck.c amflush.c \ + $(amindexd_SOURCES) amtrmidx.c amtrmlog.c chunker.c \ + $(diskfile_SOURCES) driver.c dumper.c $(infofile_SOURCES) \ + planner.c HEADERS = $(noinst_HEADERS) ETAGS = etags CTAGS = ctags @@ -550,6 +545,7 @@ DEFAULT_TAPE_DEVICE = @DEFAULT_TAPE_DEVICE@ DEFAULT_TAPE_SERVER = @DEFAULT_TAPE_SERVER@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ +DLLTOOL = @DLLTOOL@ DOC_BUILD_DATE = @DOC_BUILD_DATE@ DSYMUTIL = @DSYMUTIL@ DUMP = @DUMP@ @@ -982,6 +978,7 @@ LTLIBPTH = @LTLIBPTH@ LTLIBTHREAD = @LTLIBTHREAD@ MAILER = @MAILER@ MAKEINFO = @MAKEINFO@ +MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ MOUNT = @MOUNT@ MSGFMT = @MSGFMT@ @@ -1031,6 +1028,7 @@ NEXT_WCHAR_H = @NEXT_WCHAR_H@ NEXT_WCTYPE_H = @NEXT_WCTYPE_H@ NM = @NM@ NMEDIT = @NMEDIT@ +OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ @@ -1039,6 +1037,7 @@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ +PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PCAT = @PCAT@ @@ -1046,6 +1045,8 @@ PERL = @PERL@ PERLEXTLIBS = @PERLEXTLIBS@ PERL_INC = @PERL_INC@ PKG_CONFIG = @PKG_CONFIG@ +PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ +PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ POSUB = @POSUB@ PRAGMA_SYSTEM_HEADER = @PRAGMA_SYSTEM_HEADER@ PS = @PS@ @@ -1190,6 +1191,7 @@ TCPPORTRANGE = @TCPPORTRANGE@ TIME_H_DEFINES_STRUCT_TIMESPEC = @TIME_H_DEFINES_STRUCT_TIMESPEC@ UDPPORTRANGE = @UDPPORTRANGE@ UMOUNT = @UMOUNT@ +UNAME = @UNAME@ UNCOMPRESS_OPT = @UNCOMPRESS_OPT@ UNCOMPRESS_PATH = @UNCOMPRESS_PATH@ UNDEFINE_STRTOK_R = @UNDEFINE_STRTOK_R@ @@ -1223,6 +1225,7 @@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ +ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ @@ -1265,7 +1268,6 @@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ -lt_ECHO = @lt_ECHO@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ @@ -1344,8 +1346,8 @@ amlib_LTLIBRARIES = libamserver.la amlibexec_SCRIPTS_PERL = amlogroll amdumpd taper amcheck-device \ $(am__append_2) sbin_SCRIPTS_PERL = amaddclient amoverview amserverconfig amtoc \ - amcheckdump amcleanup amrmtape amlabel amreport amtape amvault \ - amdump amstatus $(am__append_3) + amcheckdump amcleanup amcleanupdisk amrmtape amlabel amreport \ + amtape amvault amdump amstatus $(am__append_3) sbin_SCRIPTS_SHELL = \ amcheckdb @@ -1557,9 +1559,6 @@ amadmin$(EXEEXT): $(amadmin_OBJECTS) $(amadmin_DEPENDENCIES) amcheck$(EXEEXT): $(amcheck_OBJECTS) $(amcheck_DEPENDENCIES) @rm -f amcheck$(EXEEXT) $(LINK) $(amcheck_OBJECTS) $(amcheck_LDADD) $(LIBS) -amcleanupdisk$(EXEEXT): $(amcleanupdisk_OBJECTS) $(amcleanupdisk_DEPENDENCIES) - @rm -f amcleanupdisk$(EXEEXT) - $(LINK) $(amcleanupdisk_OBJECTS) $(amcleanupdisk_LDADD) $(LIBS) amflush$(EXEEXT): $(amflush_OBJECTS) $(amflush_DEPENDENCIES) @rm -f amflush$(EXEEXT) $(LINK) $(amflush_OBJECTS) $(amflush_LDADD) $(LIBS) @@ -1667,7 +1666,6 @@ distclean-compile: @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amadmin.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amcheck.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amcleanupdisk.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amflush.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amindex.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/amindexd.Po@am__quote@ diff --git a/server-src/amadmin.c b/server-src/amadmin.c index 216f46a..bd26906 100644 --- a/server-src/amadmin.c +++ b/server-src/amadmin.c @@ -1723,7 +1723,10 @@ import_db( skip_whitespace(s, ch); if(ch == '\0' || sscanf(s - 1, "%d.%d.%d", &vers_maj, &vers_min, &vers_patch) != 3) { - goto bad_header; + vers_patch = -1; + if (sscanf(s - 1, "%d.%d", &vers_maj, &vers_min) != 2) { + goto bad_header; + } } skip_integer(s, ch); /* skip over major */ @@ -1732,11 +1735,15 @@ import_db( } ch = *s++; skip_integer(s, ch); /* skip over minor */ - if(ch != '.') { - goto bad_header; + if (vers_patch != -1) { + if (ch != '.') { + goto bad_header; + } + ch = *s++; + skip_integer(s, ch); /* skip over patch */ + } else { + vers_patch = 0; } - ch = *s++; - skip_integer(s, ch); /* skip over patch */ hdr = "comment"; if(ch == '\0') { @@ -2093,7 +2100,7 @@ disklist_one( hp = dp->host; ip = hp->netif; - g_printf("line %d:\n", dp->line); + g_printf("line %d (%s):\n", dp->line, dp->filename); g_printf(" host %s:\n", hp->hostname); g_printf(" interface %s\n", diff --git a/server-src/amcheck-device.pl b/server-src/amcheck-device.pl index a27d006..3a72bbe 100644 --- a/server-src/amcheck-device.pl +++ b/server-src/amcheck-device.pl @@ -38,6 +38,7 @@ my $config_overrides = new_config_overrides($#ARGV+1); my $overwrite = 0; Getopt::Long::Configure(qw{bundling}); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, 'w' => \$overwrite, ) or usage(); @@ -167,11 +168,20 @@ sub do_check { step result_cb => sub { (my $err, $res, $label, $mode) = @_; - return failure($err, $finished_cb) if $err; + if ($err) { + if ($res) { + $res->release(finished_cb => sub { + return failure($err, $finished_cb); + }); + return; + } else { + return failure($err, $finished_cb); + } + } my $modestr = ($mode == $ACCESS_APPEND)? "append" : "write"; my $slot = $res->{'this_slot'}; - if (defined $res->{'device'}->volume_label()) { + if (defined $res->{'device'} and defined $res->{'device'}->volume_label()) { print "Will $modestr to volume '$label' in slot $slot.\n"; } else { print "Will $modestr label '$label' to new volume in slot $slot.\n"; diff --git a/server-src/amcheck.c b/server-src/amcheck.c index 3acb991..5393976 100644 --- a/server-src/amcheck.c +++ b/server-src/amcheck.c @@ -48,6 +48,7 @@ #include "timestamp.h" #include "amxml.h" #include "physmem.h" +#include #define BUFFER_SIZE 32768 @@ -70,7 +71,7 @@ int test_server_pgm(FILE *outf, char *dir, char *pgm, int suid, uid_t dumpuid); void usage(void) { - g_printf(_("Usage: amcheck [-am] [-w] [-sclt] [-M
] [-o configoption]* [host [disk]* ]*\n")); + g_printf(_("Usage: amcheck [--version] [-am] [-w] [-sclt] [-M
] [--client-verbose] [-o configoption]* [host [disk]* ]*\n")); exit(1); /*NOTREACHED*/ } @@ -80,6 +81,13 @@ static char *our_feature_string = NULL; static char *displayunit; static long int unitdivisor; +static int client_verbose = FALSE; +static struct option long_options[] = { + {"client-verbose", 0, NULL, 1}, + {"version" , 0, NULL, 2}, + {NULL, 0, NULL, 0} +}; + int main( int argc, @@ -92,7 +100,7 @@ main( int do_clientchk, client_probs; int do_localchk, do_tapechk, server_probs; pid_t clientchk_pid, serverchk_pid; - int opt, tempfd, mainfd; + int tempfd, mainfd; size_t size; amwait_t retstat; pid_t pid; @@ -152,8 +160,20 @@ main( /* process arguments */ cfg_ovr = new_config_overrides(argc/2); - while((opt = getopt(argc, argv, "M:mawsclto:")) != EOF) { - switch(opt) { + while (1) { + int option_index = 0; + int c; + c = getopt_long (argc, argv, "M:mawsclto:", long_options, &option_index); + if (c == -1) { + break; + } + + switch(c) { + case 1: client_verbose = TRUE; + break; + case 2: printf("amcheck-%s\n", VERSION); + return(0); + break; case 'M': if (mailto) { g_printf(_("Multiple -M options\n")); exit(1); @@ -2105,6 +2125,7 @@ handle_result( char *t; int ch; int tch; + gboolean printed_hostname = FALSE; hostp = (am_host_t *)datap; hostp->up = HOST_READY; @@ -2155,7 +2176,15 @@ handle_result( continue; } + if (client_verbose && !printed_hostname) { + g_fprintf(outf, "HOST %s\n", hostp->hostname); + printed_hostname = TRUE; + } + if(strncmp_const(line, "OK ") == 0) { + if (client_verbose) { + g_fprintf(outf, "%s\n", line); + } continue; } diff --git a/server-src/amcheckdump.pl b/server-src/amcheckdump.pl index d8042bc..937f78d 100644 --- a/server-src/amcheckdump.pl +++ b/server-src/amcheckdump.pl @@ -70,8 +70,10 @@ my $opt_timestamp; my $opt_verbose = 0; my $config_overrides = new_config_overrides($#ARGV+1); +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'timestamp|t=s' => \$opt_timestamp, 'verbose|v' => \$opt_verbose, 'help|usage|?' => \&usage, diff --git a/server-src/amcleanup.pl b/server-src/amcleanup.pl index eb1730f..915e72f 100644 --- a/server-src/amcleanup.pl +++ b/server-src/amcleanup.pl @@ -28,13 +28,15 @@ use Amanda::Paths; use Amanda::Constants; use Amanda::Process; use Amanda::Logfile; - +use Amanda::Holding; +use Amanda::Debug qw( debug ); my $kill_enable=0; my $process_alive=0; my $verbose=0; +my $clean_holding=0; sub usage() { - print "Usage: amcleanup [-k] [-v] [-p] conf\n"; + print "Usage: amcleanup [-k] [-v] [-p] [-r] conf\n"; exit 1; } @@ -42,11 +44,14 @@ Amanda::Util::setup_application("amcleanup", "server", $CONTEXT_CMDLINE); my $config_overrides = new_config_overrides($#ARGV+1); +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'k' => \$kill_enable, 'p' => \$process_alive, 'v' => \$verbose, + 'r' => \$clean_holding, 'help|usage' => \&usage, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, ) or usage(); @@ -73,7 +78,7 @@ my $logdir=config_dir_relative(getconf($CNF_LOGDIR)); my $logfile = "$logdir/log"; my $amreport="$sbindir/amreport"; my $amtrmidx="$amlibexecdir/amtrmidx"; -my $amcleanupdisk="$amlibexecdir/amcleanupdisk"; +my $amcleanupdisk="$sbindir/amcleanupdisk"; if ( ! -e "$CONFIG_DIR/$config_name" ) { die "Configuration directory '$CONFIG_DIR/$config_name' doesn't exist\n"; @@ -195,10 +200,11 @@ foreach my $pname ("amdump", "amflush") { } } -if ($verbose) { - system $amcleanupdisk, "-v", $config_name; -} else { - system $amcleanupdisk, $config_name; -} +my @amcleanupdisk; +push @amcleanupdisk, $amcleanupdisk; +push @amcleanupdisk, "-v" if $verbose; +push @amcleanupdisk, "-r" if $clean_holding; +push @amcleanupdisk, $config_name; +system @amcleanupdisk; Amanda::Util::finish_application(); diff --git a/server-src/amcleanupdisk.c b/server-src/amcleanupdisk.c deleted file mode 100644 index 2ba6fb0..0000000 --- a/server-src/amcleanupdisk.c +++ /dev/null @@ -1,144 +0,0 @@ -/* - * Amanda, The Advanced Maryland Automatic Network Disk Archiver - * Copyright (c) 1991-1998 University of Maryland at College Park - * All Rights Reserved. - * - * Permission to use, copy, modify, distribute, and sell this software and its - * documentation for any purpose is hereby granted without fee, provided that - * the above copyright notice appear in all copies and that both that - * copyright notice and this permission notice appear in supporting - * documentation, and that the name of U.M. not be used in advertising or - * publicity pertaining to distribution of the software without specific, - * written prior permission. U.M. makes no representations about the - * suitability of this software for any purpose. It is provided "as is" - * without express or implied warranty. - * - * U.M. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL U.M. - * BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES - * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION - * OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN - * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - * - * Authors: the Amanda Development Team. Its members are listed in a - * file named AUTHORS, in the root directory of this distribution. - */ -/* - * $Id: amcleanupdisk.c 7238 2007-07-06 20:03:37Z dustin $ - */ -#include "amanda.h" - -#include "conffile.h" -#include "diskfile.h" -#include "clock.h" -#include "holding.h" -#include "infofile.h" -#include "server_util.h" - -/* Utility funcitons */ - -/* Call open_infofile() with the infofile from the configuration - */ -static void -init_infofile(void) -{ - char *conf_infofile = config_dir_relative(getconf_str(CNF_INFOFILE)); - if (open_infofile(conf_infofile) < 0) { - error(_("could not open info db \"%s\""), conf_infofile); - /*NOTREACHED*/ - } - amfree(conf_infofile); -} - -/* A callback for holding_cleanup to mark corrupt DLEs with force_no_bump - * for their next run. - * - * @param hostname: hostname of DLE - * @param disk: disk of DLE - */ -static void -corrupt_dle( - char *hostname, - char *disk) -{ - info_t info; - - dbprintf(_("Corrupted dump of DLE %s:%s found; setting force-no-bump.\n"), - hostname, disk); - - get_info(hostname, disk, &info); - CLR(info.command, FORCE_BUMP); - SET(info.command, FORCE_NO_BUMP); - if(put_info(hostname, disk, &info)) { - dbprintf(_("could not put info record for %s:%s: %s"), - hostname, disk, strerror(errno)); - } -} - -int -main( - int argc, - char ** argv) -{ - FILE *verbose_output = NULL; - char *cfg_opt = NULL; - char *conf_diskfile; - disklist_t diskq; - - /* - * Configure program for internationalization: - * 1) Only set the message locale for now. - * 2) Set textdomain for all amanda related programs to "amanda" - * We don't want to be forced to support dozens of message catalogs. - */ - setlocale(LC_MESSAGES, "C"); - textdomain("amanda"); - - safe_fd(-1, 0); - safe_cd(); - - set_pname("amcleanupdisk"); - - dbopen(DBG_SUBDIR_SERVER); - - if(argc < 2) { - error(_("Usage: amcleanupdisk ")); - /*NOTREACHED*/ - } - - /* parse options */ - if (argc >= 2 && strcmp(argv[1], "-v") == 0) { - verbose_output = stderr; - cfg_opt = argv[2]; - } else { - cfg_opt = argv[1]; - } - - config_init(CONFIG_INIT_EXPLICIT_NAME, - cfg_opt); - - conf_diskfile = config_dir_relative(getconf_str(CNF_DISKFILE)); - read_diskfile(conf_diskfile, &diskq); - /* diskq also ends up in a global, used by holding_cleanup */ - amfree(conf_diskfile); - - if (config_errors(NULL) >= CFGERR_WARNINGS) { - config_print_errors(); - if (config_errors(NULL) >= CFGERR_ERRORS) { - g_critical(_("errors processing config file")); - } - } - - check_running_as(RUNNING_AS_DUMPUSER); - - dbrename(get_config_name(), DBG_SUBDIR_SERVER); - - init_infofile(); - - /* actually perform the cleanup */ - holding_cleanup(corrupt_dle, verbose_output); - - close_infofile(); - return 0; -} - diff --git a/server-src/amcleanupdisk.pl b/server-src/amcleanupdisk.pl new file mode 100644 index 0000000..768e7a8 --- /dev/null +++ b/server-src/amcleanupdisk.pl @@ -0,0 +1,131 @@ +#!@PERL@ +# Copyright (c) 2008, 2010 Zmanda, Inc. All Rights Reserved. +# +# This program is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License version 2 as published +# by the Free Software Foundation. +# +# 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 +# +# Contact information: Zmanda Inc., 465 S. Mathilda Ave., Suite 300 +# Sunnyvale, CA 94086, USA, or: http://www.zmanda.com + +use lib '@amperldir@'; +use strict; +use warnings; + +use Getopt::Long; +use Amanda::Config qw( :init :getconf config_dir_relative ); +use Amanda::Util qw( :constants ); +use Amanda::Paths; +use Amanda::Constants; +use Amanda::Process; +use Amanda::Logfile; +use Amanda::Holding; +use Amanda::Debug qw( debug ); +my $kill_enable=0; +my $process_alive=0; +my $verbose=0; +my $clean_holding=0; + +sub usage() { + print "Usage: amcleanupdisk [-v] [-r] conf\n"; + exit 1; +} + +Amanda::Util::setup_application("amcleanupdisk", "server", $CONTEXT_CMDLINE); + +my $config_overrides = new_config_overrides($#ARGV+1); + +debug("Arguments: " . join(' ', @ARGV)); +Getopt::Long::Configure(qw(bundling)); +GetOptions( + 'version' => \&Amanda::Util::version_opt, + 'v' => \$verbose, + 'r' => \$clean_holding, + 'help|usage' => \&usage, + 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, +) or usage(); + +my $config_name = shift @ARGV or usage; + +set_config_overrides($config_overrides); +config_init($CONFIG_INIT_EXPLICIT_NAME, $config_name); +my ($cfgerr_level, @cfgerr_errors) = config_errors(); +if ($cfgerr_level >= $CFGERR_WARNINGS) { + config_print_errors(); + if ($cfgerr_level >= $CFGERR_ERRORS) { + die("errors processing config file"); + } +} + +Amanda::Util::finish_setup($RUNNING_AS_DUMPUSER); + +my $amcleanupdisk="$amlibexecdir/amcleanupdisk"; + +if ( ! -e "$CONFIG_DIR/$config_name" ) { + die "Configuration directory '$CONFIG_DIR/$config_name' doesn't exist\n"; +} +if ( ! -d "$CONFIG_DIR/$config_name" ) { + die "Configuration directory '$CONFIG_DIR/$config_name' is not a directory\n"; +} + +my $stdout; +open($stdout, ">&STDOUT") if $verbose;; +my @hfiles = Amanda::Holding::all_files($stdout); +close $stdout if $verbose; +@hfiles = Amanda::Holding::merge_all_files(@hfiles); +while (@hfiles) { + my $hfile = pop @hfiles; + if ($hfile->{'header'}->{'type'} == $Amanda::Header::F_DUMPFILE) { + if ($hfile->{'filename'} =~ /\.tmp$/) { + print "Rename tmp holding file: $hfile->{'filename'}\n" if $verbose; + Amanda::Holding::rename_tmp($hfile->{'filename'}, 0); + } else { + # normal holding file + } + } elsif ($hfile->{'header'}->{'type'} == $Amanda::Header::F_CONT_DUMPFILE) { + # orphan cont_dumpfile + if ($clean_holding) { + print "Remove orphan chunk file: $hfile->{'filename'}\n" if $verbose; + unlink $hfile->{'filename'}; + } else { + print "orphan chunk file: $hfile->{'filename'}\n" if $verbose; + } + } elsif ($hfile->{'header'}->{'type'} == $Amanda::Header::F_EMPTY) { + # empty file + if ($clean_holding) { + print "Remove empty file: $hfile->{'filename'}\n" if $verbose; + unlink $hfile->{'filename'}; + } else { + print "empty holding file: $hfile->{'filename'}\n" if $verbose; + } + } elsif ($hfile->{'header'}->{'type'} == $Amanda::Header::F_WEIRD) { + # weird file + if ($clean_holding) { + print "Remove non amanda file: $hfile->{'filename'}\n" if $verbose; + unlink $hfile->{'filename'}; + } else { + print "non amanda holding file: $hfile->{'filename'}\n" if $verbose; + } + } else { + # any other file + if ($clean_holding) { + print "Remove file: $hfile->{'filename'}\n" if $verbose; + unlink $hfile->{'filename'}; + } else { + print "unknown holding file: $hfile->{'filename'}\n" if $verbose; + } + } +} + +Amanda::Holding::dir_unlink(); + +Amanda::Util::finish_application(); diff --git a/server-src/amdump.pl b/server-src/amdump.pl index a86df00..04499f5 100644 --- a/server-src/amdump.pl +++ b/server-src/amdump.pl @@ -49,8 +49,11 @@ my @config_overrides_opts; my $opt_no_taper = 0; my $opt_from_client = 0; + +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'help|usage|?' => \&usage, 'no-taper' => \$opt_no_taper, 'from-client' => \$opt_from_client, @@ -150,6 +153,7 @@ sub bail_already_running { or die("cannot open a fake log to send an report - situation is dire"); print $fakelog < \&Amanda::Util::version_opt, diff --git a/server-src/amflush.c b/server-src/amflush.c index 66bf6dc..8403ac2 100644 --- a/server-src/amflush.c +++ b/server-src/amflush.c @@ -40,6 +40,12 @@ #include "holding.h" #include "server_util.h" #include "timestamp.h" +#include "getopt.h" + +static struct option long_options[] = { + {"version" , 0, NULL, 1}, + {NULL, 0, NULL, 0} +}; static char *conf_logdir; FILE *driver_stream; @@ -122,8 +128,12 @@ main( /* process arguments */ cfg_ovr = new_config_overrides(argc/2); - while((opt = getopt(argc, argv, "bfso:D:")) != EOF) { + while((opt = getopt_long(argc, argv, "bfso:D:", long_options, NULL)) != EOF) { switch(opt) { + case 1 : printf("amflush-%s\n", VERSION); + return(0); + break; + case 'b': batch = 1; break; case 'f': foreground = 1; diff --git a/server-src/amidxtaped.pl b/server-src/amidxtaped.pl index c156a00..855d59a 100644 --- a/server-src/amidxtaped.pl +++ b/server-src/amidxtaped.pl @@ -118,7 +118,7 @@ use Sys::Hostname; use Amanda::Debug qw( debug info warning ); use Amanda::MainLoop qw( :GIOCondition ); -use Amanda::Util qw( :constants ); +use Amanda::Util qw( :constants match_disk match_host ); use Amanda::Feature; use Amanda::Config qw( :init :getconf ); use Amanda::Changer; @@ -130,7 +130,6 @@ use Amanda::Recovery::Planner; use Amanda::Recovery::Scan; use Amanda::DB::Catalog; use Amanda::Disklist; -use Amanda::Logfile qw( match_disk match_host ); # Note that this class performs its control IO synchronously. This is adequate # for this service, as it never receives unsolicited input from the remote @@ -602,6 +601,10 @@ sub send_header { # filter out some things the remote might not be able to process if (!$self->{'their_features'}->has($Amanda::Feature::fe_amrecover_dle_in_header)) { $header->{'dle_str'} = undef; + } else { + $header->{'dle_str'} = + Amanda::Disklist::clean_dle_str_for_client($header->{'dle_str'}, + Amanda::Feature::am_features($self->{'their_features'})); } if (!$self->{'their_features'}->has($Amanda::Feature::fe_amrecover_origsize_in_header)) { $header->{'orig_size'} = 0; diff --git a/server-src/amindex.c b/server-src/amindex.c index 7c52bd3..e71fc01 100644 --- a/server-src/amindex.c +++ b/server-src/amindex.c @@ -91,6 +91,63 @@ getindexfname( return buf; } +char * +getheaderfname( + char * host, + char * disk, + char * date, + int level) +{ + char *conf_indexdir; + char *buf; + char level_str[NUM_STR_SIZE]; + char datebuf[14 + 1]; + char *dc = NULL; + char *pc; + int ch; + + if (date != NULL) { + dc = date; + pc = datebuf; + while (pc < datebuf + sizeof(datebuf)) { + ch = *dc++; + *pc++ = (char)ch; + if (ch == '\0') { + break; + } else if (! isdigit (ch)) { + pc--; + } + } + datebuf[sizeof(datebuf)-1] = '\0'; + dc = datebuf; + + g_snprintf(level_str, sizeof(level_str), "%d", level); + } + + host = sanitise_filename(host); + if (disk != NULL) { + disk = sanitise_filename(disk); + } + + conf_indexdir = config_dir_relative(getconf_str(CNF_INDEXDIR)); + /* + * Note: g_strjoin(NULL, ) will stop at the first NULL, which might be + * "disk" or "dc" (datebuf) rather than the full file name. + */ + buf = g_strjoin(NULL, conf_indexdir, "/", + host, "/", + disk, "/", + dc, "_", + level_str, ".header", + NULL); + + amfree(conf_indexdir); + amfree(host); + amfree(disk); + + return buf; +} + char * getoldindexfname( char * host, diff --git a/server-src/amindex.h b/server-src/amindex.h index 2233996..1356910 100644 --- a/server-src/amindex.h +++ b/server-src/amindex.h @@ -36,6 +36,7 @@ #include "conffile.h" char *getindexfname(char *host, char *disk, char *date, int level); +char *getheaderfname(char *host, char *disk, char *date, int level); char *getoldindexfname(char *host, char *disk, char *date, int level); #endif /* AMINDEX_H */ diff --git a/server-src/amindexd.c b/server-src/amindexd.c index 2e09bfe..bc56ed4 100644 --- a/server-src/amindexd.c +++ b/server-src/amindexd.c @@ -1291,6 +1291,11 @@ main( char his_hostname[MAX_HOSTNAME_LENGTH]; char *cfg_opt = NULL; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("amindexd-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. diff --git a/server-src/amlabel.pl b/server-src/amlabel.pl index 77a5115..98c5c78 100644 --- a/server-src/amlabel.pl +++ b/server-src/amlabel.pl @@ -57,8 +57,11 @@ $opt_force = 0; $opt_barcode = undef; $opt_meta = undef; $opt_assign = undef; + +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'help|usage|?' => \&usage, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, 'f' => \$opt_force, @@ -68,7 +71,7 @@ GetOptions( 'version' => \&Amanda::Util::version_opt, ) or usage(); -if ($opt_assign && (!$opt_meta || !$opt_barcode)) { +if ($opt_assign && (!$opt_meta and !$opt_barcode)) { print STDERR "--assign require --barcode or --meta\n"; usage(); } @@ -297,7 +300,7 @@ sub main { # update the tapelist $tl->reload(1); $tl->remove_tapelabel($label); - $tl->add_tapelabel("0", $label, undef, 1, $meta, $res->{'barcode'}); + $tl->add_tapelabel("0", $label, undef, 1, $meta, $res->{'barcode'}, $dev->block_size/1024); $tl->write(); print "Success!\n"; diff --git a/server-src/amlogroll.pl b/server-src/amlogroll.pl index 7d93747..9611a8a 100644 --- a/server-src/amlogroll.pl +++ b/server-src/amlogroll.pl @@ -24,14 +24,17 @@ use warnings; use Amanda::Util qw( :constants ); use Amanda::Config qw( :init ); use Amanda::Logfile qw( log_rename get_current_log_timestamp $amanda_log_trace_log ); -use Amanda::Debug; +use Amanda::Debug qw( debug ); use Getopt::Long; Amanda::Util::setup_application("amlogroll", "server", $CONTEXT_CMDLINE); my $config_overrides = new_config_overrides($#ARGV+1); + +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw{bundling}); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, ) or usage(); diff --git a/server-src/amoverview.pl b/server-src/amoverview.pl index d1c599b..f5e5b31 100644 --- a/server-src/amoverview.pl +++ b/server-src/amoverview.pl @@ -45,6 +45,7 @@ END } # overrideable defaults +my $opt_version; my $opt_config = undef; my $opt_hostwidth = 8; my $opt_diskwidth = 20; @@ -54,7 +55,8 @@ my $opt_num0 = 0; my $opt_togo0 = 0; my $opt_verbose = 0; -GetOptions('config=s' => \$opt_config, +GetOptions('version' => \$opt_version, + 'config=s' => \$opt_config, 'hostwidth=i' => \$opt_hostwidth, 'diskwidth=i' => \$opt_diskwidth, 'skipmissed' => \$opt_skipmissed, @@ -64,6 +66,11 @@ GetOptions('config=s' => \$opt_config, 'verbose' => \$opt_verbose) or Usage(); +if (defined $opt_version) { + print "amoverview-" . $Amanda::Constants::VERSION , "\n"; + exit 0; +} + unless(defined($opt_config)) { if (@ARGV == 1) { $opt_config = $ARGV[0]; diff --git a/server-src/amreport.pl b/server-src/amreport.pl index cb31275..ae73bab 100755 --- a/server-src/amreport.pl +++ b/server-src/amreport.pl @@ -347,8 +347,29 @@ sub open_printer_output debug("invoking printer: " . join(" ", @cmd)); # redirect stdout/stderr to stderr, which is usually the amdump log - my $pid = open3( my $fh, ">&2", ">&2", @cmd) - or error("cannot start $cmd[0]: $!", 1); + my ($pid, $fh); + if (!-f $Amanda::Constants::LPR || !-x $Amanda::Constants::LPR) { + my $errstr = "error: the mailer '$Amanda::Constants::LPR' is not an executable program."; + print STDERR "$errstr\n"; + if ($mode == MODE_SCRIPT) { + debug($errstr); + } else { + error($errstr, 1); + } + } else { + eval { $pid = open3($fh, ">&2", ">&2", @cmd); } or do { + ($pid, $fh) = (0, undef); + chomp $@; + my $errstr = "error: $@: $!"; + + print STDERR "$errstr\n"; + if ($mode == MODE_SCRIPT) { + debug($errstr); + } else { + error($errstr, 1); + } + }; + } return ($pid, $fh); } @@ -398,18 +419,29 @@ sub open_mail_output my ($pid, $fh); - eval { $pid = open3($fh, ">&2", ">&2", @cmd); 1; } or do { - - ($pid, $fh) = (0, undef); - my $errstr = - "error: could not run command: " . join(" ", @cmd) . ": $@"; - + if (!-f $cfg_mailer || !-x $cfg_mailer) { + my $errstr = "error: the mailer '$cfg_mailer' is not an executable program."; + print STDERR "$errstr\n"; if ($mode == MODE_SCRIPT) { debug($errstr); } else { error($errstr, 1); } - }; + + } else { + eval { $pid = open3($fh, ">&2", ">&2", @cmd) } or do { + ($pid, $fh) = (0, undef); + chomp $@; + my $errstr = "error: $@: $!"; + + print STDERR "$errstr\n"; + if ($mode == MODE_SCRIPT) { + debug($errstr); + } else { + error($errstr, 1); + } + }; + } return ($pid, $fh); } @@ -431,21 +463,23 @@ sub run_output { # TODO: add some generic error handling here. must be compatible # with legacy behavior. - # TODO: modularize these better - if ($reportspec->[0] eq 'xml') { - print $fh $report->xml_output("" . getconf($CNF_ORG), $config_name); - } elsif ($reportspec->[0] eq 'human') { - my $hr = - Amanda::Report::human->new( $report, $fh, $config_name, $opt_logfname ); - $hr->print_human_amreport(); - } elsif ($reportspec->[0] eq 'postscript') { - use Amanda::Report::postscript; - my $rep = - Amanda::Report::postscript->new( $report, $config_name, $opt_logfname ); - $rep->write_report($fh); - } + if (defined $fh) { + # TODO: modularize these better + if ($reportspec->[0] eq 'xml') { + print $fh $report->xml_output("" . getconf($CNF_ORG), $config_name); + } elsif ($reportspec->[0] eq 'human') { + my $hr = Amanda::Report::human->new($report, $fh, $config_name, + $opt_logfname ); + $hr->print_human_amreport(); + } elsif ($reportspec->[0] eq 'postscript') { + use Amanda::Report::postscript; + my $rep = Amanda::Report::postscript->new($report, $config_name, + $opt_logfname ); + $rep->write_report($fh); + } - close $fh; + close $fh; + } # clean up any subprocess if (defined $pid) { @@ -464,6 +498,7 @@ Amanda::Util::setup_application("amreport", "server", $CONTEXT_CMDLINE); my $config_overrides = new_config_overrides( scalar(@ARGV) + 1 ); +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw/bundling/); GetOptions( diff --git a/server-src/amrestore.pl b/server-src/amrestore.pl index d7f2421..362ee65 100644 --- a/server-src/amrestore.pl +++ b/server-src/amrestore.pl @@ -58,6 +58,8 @@ my $config_overrides = new_config_overrides($#ARGV+1); my ($opt_config, $opt_blocksize, $opt_raw, $opt_compress, $opt_compress_best, $opt_pipe, $opt_header, $opt_filenum, $opt_label, $opt_holding, $opt_restore_src); + +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( 'version' => \&Amanda::Util::version_opt, diff --git a/server-src/amrmtape.pl b/server-src/amrmtape.pl index 392228f..7c052a5 100644 --- a/server-src/amrmtape.pl +++ b/server-src/amrmtape.pl @@ -107,7 +107,10 @@ Amanda::Util::setup_application("amrmtape", "server", $CONTEXT_CMDLINE); my $config_overrides = new_config_overrides( scalar(@ARGV) + 1 ); +debug("Arguments: " . join(' ', @ARGV)); +Getopt::Long::Configure(qw{ bundling }); my $opts_ok = GetOptions( + 'version' => \&Amanda::Util::version_opt, "changer=s" => \$changer_name, "cleanup" => \$cleanup, "dryrun|n" => \$dry_run, @@ -239,7 +242,7 @@ my $scrub_db = sub { } my $level = $parts[1]; my $cur_label = $parts[7]; - if ($cur_label eq $label) { + if (defined $cur_label and $cur_label eq $label) { $dead_level = $level; vlog "Discarding Host: $host, Disk: $disk, Level: $level\n"; } elsif ( $level > $dead_level ) { @@ -306,26 +309,36 @@ my $erase_volume = make_cb('erase_volume' => sub { my $dev = $resv->{'device'}; die "Can not erase $label because the device doesn't support this feature" unless $dev->property_get('full_deletion'); - if (!$dry_run) { - $dev->erase() - or die "Failed to erase volume"; - $dev->finish(); - # label the tape with the same label it had - if ($keep_label) { - $dev->start($ACCESS_WRITE, $label, undef) - or die "Failed to write tape label"; - } - } + my $rel_cb = make_cb('rel_cb' => sub { + $resv->release(finished_cb => sub { + my ($err) = @_; - $resv->release(finished_cb => sub { - my ($err) = @_; + $chg->quit(); + die $err if $err; - $chg->quit(); - die $err if $err; - - $scrub_db->(); + $scrub_db->(); + }); }); + + if (!$dry_run) { + $dev->erase() + or die "Failed to erase volume"; + $resv->set_label(finished_cb => sub { + $dev->finish(); + + # label the tape with the same label it had + if ($keep_label) { + $dev->start($ACCESS_WRITE, $label, undef) + or die "Failed to write tape label"; + return $resv->set_label(label => $label, finished_cb => $rel_cb); + } + $rel_cb->(); + }); + } else { + $rel_cb->(); + } + }); } else { $scrub_db->(); diff --git a/server-src/amserverconfig.pl b/server-src/amserverconfig.pl index b03edd6..3c53a88 100755 --- a/server-src/amserverconfig.pl +++ b/server-src/amserverconfig.pl @@ -229,11 +229,10 @@ sub create_vtape { if ($template_only==0){ # check $template mode $mylabelprefix=$labelstr; #set labelstr if ($tapedev eq "$def_tapedev/$config"){ - &create_deftapedir; + &create_deftapedir; } else { - $tapedev=~/^(file:\/)/; - $parentdir=$'; + $parentdir=$tapedev; } } else { @@ -274,11 +273,11 @@ sub create_vtape { for $i (1..$tp_cyclelimit) { unless ( -e "slot$i"){ - mkpath ("slot$i", $def_perm) || - ( &mprint ("WARNING: mkpath $parentdir/slot$i failed: $!\n"), $vtape_err++, return); + mkpath ("slot$i", $def_perm) || + ( &mprint ("WARNING: mkpath $parentdir/slot$i failed: $!\n"), $vtape_err++, return); } ( @amlabel_out = `$sbindir/amlabel -f $config $mylabelprefix-$i slot $i`) || - ( &mprint ("WARNING: amlabel vtapes failed at slot $i: $!\n"), $vtape_err++, return); + ( &mprint ("WARNING: amlabel vtapes failed at slot $i: $!\n"), $vtape_err++, return); } foreach (@amlabel_out) { print LOG; @@ -310,57 +309,63 @@ sub create_customconf{ $labelstr="^$config-[0-9][0-9]*\$"; } } + + open (CONF, ">$confdir/$config/amanda.conf") || + &log_and_die ("ERROR: Cannot create amanda.conf file: $!\n", 1); + chmod ($amanda_conf_perm, "$confdir/$config/amanda.conf") || + &log_and_die ("ERROR: Cannot set amanda.conf file access permission: $!\n", 1); + + print CONF "org \"$config\"\t\t# your organization name for reports\n"; + print CONF "dumpuser \"$dumpuser\"\t# the user to run dumps under\n"; + print CONF "mailto \"$mailto\"\t# space separated list of operators at your site\n"; + print CONF "dumpcycle $dumpcycle\t\t# the number of days in the normal dump cycle\n"; + print CONF "runspercycle $runspercycle\t\t# the number of amdump runs in dumpcycle days\n"; + print CONF "tapecycle $tapecycle\t# the number of tapes in rotation\n"; + print CONF "runtapes $runtapes\t\t# number of tapes to be used in a single run of amdump\n"; + if ((!(defined($template)))||($template eq "harddisk")) { - if (defined $tapedev){ - $tapedev="file:/".$tapedev; - } - unless ( $tpchanger ) { $tpchanger="chg-disk"; } - unless ( $tapedev ) { $tapedev="$def_tapedev/$config"; } - unless ( $changerfile ) { $changerfile="$confdir/$config/changer.conf"; } - unless ( $changerdev ) { $changerdev="/dev/null";} + print CONF "\n"; + print CONF "define changer my_vtapes {\n"; + print CONF " tpchanger \"chg-disk:$tapedev\"\n"; + print CONF " property \"num-slot\" \"10\"\n"; + print CONF " property \"auto-create-slot\" \"yes\"\n"; + print CONF "}\n"; + print CONF "tpchanger \"my_vtapes\"\n\n"; unless ( $tapetype ) { $tapetype="HARDDISK"; } } elsif ($template eq "single-tape") { - unless ($tpchanger) {$tpchanger="chg-manual";} - unless ($tapedev) {$tapedev="/dev/nst0";} - unless ($changerfile) {$changerfile="$confdir/$config/chg-manual.conf";} - unless ($changerdev) {$changerdev="/dev/null";} + print CONF "\n"; + print CONF "define changer my_single {\n"; + print CONF " tpchanger \"chg-single:$tapedev\"\n"; + print CONF "}\n"; + print CONF "tpchanger \"my_single\"\n\n"; unless ($tapetype) {$tapetype="HP-DAT";} } elsif ($template eq "tape-changer") { - unless ($tpchanger){$tpchanger="chg-zd-mtx";} - unless ($tapedev){ $tapedev="/dev/nst0";} - unless ($changerfile){$changerfile="$confdir/$config/changer.conf";} - unless ($changerdev) {$changerdev="/dev/sg1";} + print CONF "\n"; + print CONF "define changer my_robot {\n"; + print CONF " tpchanger \"chg-robot:$changerdev\"\n"; + print CONF " property \"tape-device\" \"0=$tapedev\"\n"; + print CONF "}\n"; + print CONF "tpchanger \"my_robot\"\n\n"; unless ($tapetype) {$tapetype="HP-DAT";} } else # S3 case { - unless ($tpchanger){$tpchanger="chg-multi";} - unless ($changerfile){$changerfile="$confdir/$config/changer.conf";} + print CONF "\n"; + print CONF "define changer my_s3 {\n"; + print CONF " tpchanger \"chg-multi:$tapedev\"\n"; + print CONF " device-property \"S3_ACCESS_KEY\" \"\"\n"; + print CONF " device-property \"S3_SECRET_KEY\" \"\"\n"; + print CONF " device-property \"NB_THREADS_BACKUP\" \"\"\n"; + print CONF "}\n"; + print CONF "tpchanger \"my_s3\"\n\n"; unless ($tapetype) {$tapetype="HP-DAT";} } - - open (CONF, ">$confdir/$config/amanda.conf") || - &log_and_die ("ERROR: Cannot create amanda.conf file: $!\n", 1); - chmod ($amanda_conf_perm, "$confdir/$config/amanda.conf") || - &log_and_die ("ERROR: Cannot set amanda.conf file access permission: $!\n", 1); - - print CONF "org \"$config\"\t\t# your organization name for reports\n"; - print CONF "dumpuser \"$dumpuser\"\t# the user to run dumps under\n"; - print CONF "mailto \"$mailto\"\t# space separated list of operators at your site\n"; - print CONF "dumpcycle $dumpcycle\t\t# the number of days in the normal dump cycle\n"; - print CONF "runspercycle $runspercycle\t\t# the number of amdump runs in dumpcycle days\n"; - print CONF "tapecycle $tapecycle\t# the number of tapes in rotation\n"; - print CONF "runtapes $runtapes\t\t# number of tapes to be used in a single run of amdump\n"; - print CONF "tpchanger \"$tpchanger\"\t# the tape-changer glue script\n"; - print CONF "tapedev \"$tapedev\"\t# the no-rewind tape device\n"; - print CONF "changerfile \"$changerfile\"\t# tape changer configuration parameter file\n"; - print CONF "changerdev \"$changerdev\"\t# tape changer configuration parameter device\n"; print CONF "tapetype $tapetype\t# what kind of tape it is\n"; print CONF "labelstr \"$labelstr\"\t# label constraint regex: all tapes must match\n"; print CONF "dtimeout $def_dtimeout\t# number of idle seconds before a dump is aborted\n"; diff --git a/server-src/amstatus.pl b/server-src/amstatus.pl index be2b8fe..7192e18 100644 --- a/server-src/amstatus.pl +++ b/server-src/amstatus.pl @@ -6,13 +6,13 @@ eval '(exit $?0)' && eval 'exec @PERL@ -S $0 ${1+"$@"}' & eval 'exec @PERL@ -S $0 $argv:q' if 0; -require "newgetopt.pl"; use warnings; use lib '@amperldir@'; use Time::Local; use Text::ParseWords; use Amanda::Util; use Amanda::Process; +use Getopt::Long; delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'}; $ENV{'PATH'} = "/bin:/usr/bin:/usr/sbin:/sbin"; # force known path @@ -33,26 +33,52 @@ $STATUS_MISSING = 8; $STATUS_TAPE = 16; $exit_status = 0; -$result = &NGetOpt ( "summary", - "stats|statistics", - "dumping|d", - "waitdumping|wdumping", - "waittaper|wtaper", - "dumpingtape|dtape", - "writingtape|wtape", - "finished", - "failed|error", - "estimate", - "gestimate|gettingestimate", - "date", - "config|c:s", - "file:s", - "locale-independent-date-format", - ); -if($result !=1 ) { - &usage(); +my $opt_summary; +my $opt_stats; +my $opt_dumping; +my $opt_waitdumping; +my $opt_waittaper; +my $opt_dumpingtape; +my $opt_writingtape; +my $opt_finished; +my $opt_failed; +my $opt_estimate; +my $opt_gestimate; +my $opt_date; +my $opt_config; +my $opt_file; +my $opt_locale_independent_date_format; + +sub usage() { + print "amstatus [--file amdump_file]\n"; + print " [--summary] [--dumping] [--waitdumping] [--waittaper]\n"; + print " [--dumpingtape] [--writingtape] [--finished] [--failed]\n"; + print " [--estimate] [--gestimate] [--stats] [--date]\n"; + print " [--locale-independent-date-format]\n"; + print " [--config] \n"; + exit 0; } +Getopt::Long::Configure(qw{ bundling }); +GetOptions( + 'summary' => \$opt_summary, + 'stats|statistics' => \$opt_stats, + 'dumping|d' => \$opt_dumping, + 'waitdumping|wdumping' => \$opt_waitdumping, + 'waittaper|wtaper' => \$opt_waittaper, + 'dumpingtape|dtape' => \$opt_dumpingtape, + 'writingtape|wtape' => \$opt_writingtape, + 'finished' => \$opt_finished, + 'failed|error' => \$opt_failed, + 'estimate' => \$opt_estimate, + 'gestimate|gettingestimate' => \$opt_gestimate, + 'date' => \$opt_date, + 'config|c:s' => \$opt_config, + 'file:s' => \$opt_file, + 'locale-independent-date-format' => \$opt_locale_independent_date_format, + ) or usage(); + + if( defined $opt_config ) { $conf = $opt_config; } @@ -1566,12 +1592,3 @@ sub busytime() { return $result; } -sub usage() { - print "amstatus [--file amdump_file]\n"; - print " [--summary] [--dumping] [--waitdumping] [--waittaper]\n"; - print " [--dumpingtape] [--writingtape] [--finished] [--failed]\n"; - print " [--estimate] [--gestimate] [--stats] [--date]\n"; - print " [--locale-independent-date-format]\n"; - print " [--config] \n"; - exit 0; -} diff --git a/server-src/amtape.pl b/server-src/amtape.pl index 4c8cd36..bb29001 100644 --- a/server-src/amtape.pl +++ b/server-src/amtape.pl @@ -148,17 +148,39 @@ sub { }); }); -subcommand("show", "show", "scan all slots in the changer, starting with the current slot", +subcommand("show", "show []", "scan all slots (or listed slots) in the changer, starting with the current slot", sub { my ($finished_cb, @args) = @_; my $last_slot; my %seen_slots; my $chg; - if (@args != 0) { + if (@args > 1) { return usage($finished_cb); } + my $what = $args[0]; + my @slots; + + if (defined $what) { + my @what1 = split /,/, $what; + foreach my $what1 (@what1) { + if ($what1 =~ /^(\d*)-(\d*)$/) { + my $begin = $1; + my $end = $2; + $end = $begin if $begin > $end; + while ($begin <= $end) { + push @slots, $begin; + $begin++; + } + } else { + push @slots, $what1; + } + } + } + + my $use_slots = @slots > 0; + $chg = load_changer($finished_cb) or return; my $steps = define_steps @@ -173,13 +195,19 @@ sub { my ($err, %info) = @_; return failure($err, $finished_cb) if $err; - print STDERR "amtape: scanning all $info{num_slots} slots in changer:\n"; + if ($use_slots) { + my $slot = shift @slots; + $chg->load(slot => $slot, + mode => "read", + res_cb => $steps->{'loaded'}); - $steps->{'load_current'}->(); - }; + } else { + print STDERR "amtape: scanning all $info{num_slots} slots in changer:\n"; - step load_current => sub { - $chg->load(relative_slot => 'current', mode => "read", res_cb => $steps->{'loaded'}); + $chg->load(relative_slot => 'current', + mode => "read", + res_cb => $steps->{'loaded'}); + } }; step loaded => sub { @@ -224,8 +252,19 @@ sub { }; step released => sub { - $chg->load(relative_slot => 'next', slot => $last_slot, - except_slots => { %seen_slots }, res_cb => $steps->{'loaded'}); + if ($use_slots) { + return $finished_cb->() if @slots == 0; + my $slot = shift @slots; + $chg->load(slot => $slot, + mode => "read", + res_cb => $steps->{'loaded'}); + + } else { + $chg->load(relative_slot => 'next', + slot => $last_slot, + except_slots => { %seen_slots }, + res_cb => $steps->{'loaded'}); + } }; }); @@ -274,7 +313,11 @@ sub { } elsif ($sl->{'device_status'} == $DEVICE_STATUS_VOLUME_UNLABELED) { $line .= " blank"; } elsif ($sl->{'device_status'} != $DEVICE_STATUS_SUCCESS) { - $line .= "device error"; + if (defined $sl->{'device_error'}) { + $line .= " " . $sl->{'device_error'}; + } else { + $line .= "device error"; + } } elsif ($sl->{'f_type'} != $Amanda::Header::F_TAPESTART) { $line .= " blank"; } else { @@ -534,13 +577,25 @@ sub { my $result_cb = make_cb(result_cb => sub { my ($err, $res, $label, $mode) = @_; if ($err) { - $taperscan->quit() if defined $taperscan; - return failure($err, $finished_cb); + if ($res) { + $res->release(finished_cb => sub { + $taperscan->quit() if defined $taperscan; + return failure($err, $finished_cb); + }); + return; + } else { + $taperscan->quit() if defined $taperscan; + return failure($err, $finished_cb); + } } my $modestr = ($mode == $ACCESS_APPEND)? "append" : "write"; my $slot = $res->{'this_slot'}; - print STDERR "Will $modestr to volume $label in slot $slot.\n"; + if (defined $res->{'device'} and defined $res->{'device'}->volume_label()) { + print STDERR "Will $modestr to volume '$label' in slot $slot.\n"; + } else { + print STDERR "Will $modestr label '$label' to new volume in slot $slot.\n"; + } $res->release(finished_cb => sub { my ($err) = @_; die "$err" if $err; @@ -572,10 +627,10 @@ sub { }, finished_cb => sub { my ($err) = @_; + $chg->quit(); return failure($err, $finished_cb) if $err; print STDERR "update complete\n"; - $chg->quit(); $finished_cb->(); }); }); @@ -620,8 +675,10 @@ Amanda::Util::setup_application("amtape", "server", $CONTEXT_CMDLINE); my $config_overrides = new_config_overrides($#ARGV+1); +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw(bundling)); GetOptions( + 'version' => \&Amanda::Util::version_opt, 'help|usage|?' => \&usage, 'o=s' => sub { add_config_override_opt($config_overrides, $_[1]); }, ) or usage(); diff --git a/server-src/amtrmidx.c b/server-src/amtrmidx.c index 25f7f3e..a2f4c8b 100644 --- a/server-src/amtrmidx.c +++ b/server-src/amtrmidx.c @@ -70,6 +70,11 @@ main( int amtrmidx_debug = 0; config_overrides_t *cfg_ovr = NULL; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("amtrmidx-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. diff --git a/server-src/amtrmlog.c b/server-src/amtrmlog.c index 9afc796..6b4e0ea 100644 --- a/server-src/amtrmlog.c +++ b/server-src/amtrmlog.c @@ -66,6 +66,11 @@ main( int dumpcycle; config_overrides_t *cfg_ovr = NULL; + if (argc > 1 && argv && argv[1] && g_str_equal(argv[1], "--version")) { + printf("amtrmlog-%s\n", VERSION); + return (0); + } + /* * Configure program for internationalization: * 1) Only set the message locale for now. diff --git a/server-src/amvault.pl b/server-src/amvault.pl index 8b2c87a..87a43fb 100644 --- a/server-src/amvault.pl +++ b/server-src/amvault.pl @@ -93,7 +93,7 @@ sub user_request { package Amvault; use Amanda::Config qw( :getconf config_dir_relative ); -use Amanda::Debug qw( :logging ); +use Amanda::Debug qw( :logging debug ); use Amanda::Xfer qw( :constants ); use Amanda::Header qw( :constants ); use Amanda::MainLoop; @@ -108,8 +108,8 @@ use Amanda::Changer qw( :constants ); use Amanda::Cmdline; use Amanda::Paths; use Amanda::Logfile qw( :logtype_t log_add log_add_full - log_rename $amanda_log_trace_log make_stats - match_datestamp match_level ); + log_rename $amanda_log_trace_log make_stats ); +use Amanda::Util qw ( match_datestamp match_level ); use base qw( Amanda::Recovery::Clerk::Feedback @@ -313,7 +313,7 @@ sub plan_cb { $dump->{'dump_timestamp'} . " " . $dump->{'level'} . "\n"; } - $total_kb += $dump->{'kb'}; + $total_kb += int $dump->{'kb'}; } print STDOUT "Total Size: $total_kb KB\n"; @@ -630,6 +630,14 @@ sub quit { }; step roll_log => sub { + if (defined $self->{'src'}->{'chg'}) { + $self->{'src'}->{'chg'}->quit(); + $self->{'src'}->{'chg'} = undef; + } + if (defined $self->{'dst'}->{'chg'}) { + $self->{'dst'}->{'chg'}->quit(); + $self->{'dst'}->{'chg'} = undef; + } if ($self->{'cleanup'}{'roll_trace_log'}) { log_add_full($L_FINISH, "driver", "fake driver finish"); log_add($L_INFO, "pid-done $$"); @@ -740,6 +748,7 @@ sub scribe_notif_log_info { my $self = shift; my %params = @_; + debug("$params{'message'}"); log_add_full($L_INFO, "taper", $params{'message'}); } @@ -942,6 +951,7 @@ sub add_autolabel { usage("unknown --autolabel value '$val'"); } +debug("Arguments: " . join(' ', @ARGV)); Getopt::Long::Configure(qw{ bundling }); GetOptions( 'o=s' => sub { diff --git a/server-src/diskfile.c b/server-src/diskfile.c index 71e2ef5..b25b749 100644 --- a/server-src/diskfile.c +++ b/server-src/diskfile.c @@ -341,6 +341,7 @@ free_disklist( while (dl->head != NULL) { dp = dequeue_disk(dl); + amfree(dp->filename); amfree(dp->name); amfree(dp->hostname); amfree(dp->device); @@ -423,6 +424,28 @@ parse_diskline( fp = s - 1; skip_non_whitespace(s, ch); s[-1] = '\0'; + if (g_str_equal(fp, "includefile")) { + char *include_name; + char *include_filename; + skip_whitespace(s, ch); + if (ch == '\0' || ch == '#') { + disk_parserror(filename, line_num, _("include filename name expected")); + return (-1); + } + fp = s - 1; + skip_quoted_string(s, ch); + s[-1] = '\0'; + include_name = unquote_string(fp); + include_filename = config_dir_relative(include_name); + read_diskfile(include_filename, lst); + g_free(include_filename); + g_free(include_name); + if (config_errors(NULL) >= CFGERR_WARNINGS) { + return -1; + } else { + return 0; + } + } host = lookup_host(fp); if (host == NULL) { hostname = stralloc(fp); @@ -540,6 +563,7 @@ parse_diskline( } if (!disk) { disk = alloc(SIZEOF(disk_t)); + disk->filename = g_strdup(filename); disk->line = line_num; disk->hostname = hostname; disk->name = diskname; @@ -1227,7 +1251,45 @@ optionstr( return result; } - +typedef struct { + am_feature_t *features; + char *result; +} xml_app_t; + +/* A GHFunc (callback for g_hash_table_foreach) */ +static void xml_property( + gpointer key_p, + gpointer value_p, + gpointer user_data_p) +{ + char *tmp; + property_t *property = value_p; + xml_app_t *xml_app = user_data_p; + GSList *value; + GString *strbuf; + + strbuf = g_string_new(xml_app->result); + + tmp = amxml_format_tag("name", (char *)key_p); + g_string_append_printf(strbuf, " \n %s\n", tmp); + g_free(tmp); + + // TODO if client have fe_xml_property_priority + if (property->priority + && am_has_feature(xml_app->features, fe_xml_property_priority)) + g_string_append(strbuf, " yes\n"); + + for (value = property->values; value != NULL; value = value->next) { + tmp = amxml_format_tag("value", value->data); + g_string_append_printf(strbuf, " %s", tmp); + g_free(tmp); + } + g_string_append_printf(strbuf, "\n \n"); + + g_free(xml_app->result); + xml_app->result = g_string_free(strbuf, FALSE); +} + char * xml_optionstr( disk_t * dp, @@ -1483,6 +1545,21 @@ xml_optionstr( return result; } +char * +xml_dumptype_properties( + disk_t *dp) +{ + xml_app_t xml_dumptype; + + xml_dumptype.result = g_strdup(""); + xml_dumptype.features = NULL; + if (dp && dp->config) { + g_hash_table_foreach(dumptype_get_property(dp->config), xml_property, + &xml_dumptype); + } + return xml_dumptype.result; +} + char * xml_estimate( estimatelist_t estimatelist, @@ -1521,10 +1598,13 @@ xml_estimate( char * clean_dle_str_for_client( - char *dle_str) + char *dle_str, + am_feature_t *their_features) { char *rval_dle_str; char *hack1, *hack2; + char *pend, *pscript, *pproperty, *eproperty; + int len; if (!dle_str) return NULL; @@ -1544,45 +1624,39 @@ clean_dle_str_for_client( #undef SC #undef SC_LEN - return rval_dle_str; -} - -typedef struct { - am_feature_t *features; - char *result; -} xml_app_t; - -/* A GHFunc (callback for g_hash_table_foreach) */ -static void xml_property( - gpointer key_p, - gpointer value_p, - gpointer user_data_p) -{ - char *property_s = key_p; - char *b64property; - property_t *property = value_p; - char *b64value_data; - xml_app_t *xml_app = user_data_p; - GSList *value; - - b64property = amxml_format_tag("name", property_s); - vstrextend(&xml_app->result, " \n", - " ", b64property, "\n", NULL); - // TODO if client have fe_xml_property_priority - if (property->priority && - am_has_feature(xml_app->features, fe_xml_property_priority)) { - vstrextend(&xml_app->result, " yes\n", NULL); - } - for(value = property->values; value != NULL; value = value->next) { - b64value_data = amxml_format_tag("value", value->data); - vstrextend(&xml_app->result, " ", b64value_data, "\n", NULL); - amfree(b64value_data); + if (!am_has_feature(their_features, fe_dumptype_property)) { +#define SC "\n" +#define SC_LEN strlen(SC) + /* remove all dle properties, they are before backup-program or script + properties */ + hack1 = rval_dle_str; + pend = strstr(rval_dle_str, ""); + pscript = strstr(rval_dle_str, "