summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMark Wielaard <mjw@redhat.com>2009-01-23 14:28:47 +0100
committerMark Wielaard <mjw@redhat.com>2009-01-23 14:28:47 +0100
commitc3bad3042df505a3470f1e20b09822a9df1d4761 (patch)
tree6842e8eaa705e406379d34cf07a85431b6d71344
parent750b1f2f5c84acaf0776de5239dc81e2e95c1dec (diff)
parentf120873cb40cfc16cc94f06fd722abc927b96227 (diff)
downloadsystemtap-steved-c3bad3042df505a3470f1e20b09822a9df1d4761.tar.gz
systemtap-steved-c3bad3042df505a3470f1e20b09822a9df1d4761.tar.xz
systemtap-steved-c3bad3042df505a3470f1e20b09822a9df1d4761.zip
Merge branch 'master' into pr6866.
-rw-r--r--ChangeLog319
-rw-r--r--Makefile.am48
-rw-r--r--Makefile.in277
-rw-r--r--aclocal.m4160
-rw-r--r--buildrun.cxx10
-rw-r--r--config.in6
-rwxr-xr-xconfigure4155
-rw-r--r--configure.ac110
-rw-r--r--doc/ChangeLog40
-rw-r--r--doc/Makefile.am1
-rw-r--r--doc/Makefile.in244
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Array-Operations.xml50
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Arrays.xml26
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Errors.xml12
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/ScriptConstructs.xml21
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Scripts.xml1059
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Understanding_How_SystemTap_Works.xml2
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-disktop.xml19
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml11
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-iotime.xml37
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-nettop.xml13
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml2
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio.xml17
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml2
-rw-r--r--doc/SystemTap_Beginners_Guide/en-US/extras/iotime-simple.stp6
-rwxr-xr-xdoc/SystemTap_Beginners_Guide/en-US/extras/para-callgraph-simple.stp36
-rw-r--r--doc/SystemTap_Tapset_Reference/Makefile.am44
-rw-r--r--doc/SystemTap_Tapset_Reference/Makefile.in134
-rw-r--r--doc/SystemTap_Tapset_Reference/tapsets.tmpl15
-rwxr-xr-xdtrace145
-rw-r--r--dwarf_wrappers.cxx4
-rw-r--r--elaborate.cxx1
-rw-r--r--runtime/ChangeLog50
-rw-r--r--runtime/autoconf-task-uid.c6
-rw-r--r--runtime/sdt.h163
-rw-r--r--runtime/sduprobes.h141
-rw-r--r--runtime/staprun/ChangeLog4
-rw-r--r--runtime/staprun/staprun.h3
-rw-r--r--runtime/task_finder.c303
-rw-r--r--runtime/transport/ChangeLog5
-rw-r--r--runtime/transport/symbols.c24
-rw-r--r--runtime/transport/transport.c7
-rw-r--r--runtime/uprobes/uprobes.c78
-rw-r--r--runtime/uprobes2/uprobes.c78
-rw-r--r--runtime/vsprintf.c19
-rw-r--r--scripts/kprobes_test/.gitignore2
-rw-r--r--scripts/kprobes_test/README57
-rw-r--r--scripts/kprobes_test/config_opts.py32
-rw-r--r--scripts/kprobes_test/default.cfg16
-rwxr-xr-xscripts/kprobes_test/gen_code.py80
-rwxr-xr-xscripts/kprobes_test/is_probed.py55
-rw-r--r--scripts/kprobes_test/kprobe_module.c65
-rwxr-xr-xscripts/kprobes_test/monitor_system.py82
-rwxr-xr-xscripts/kprobes_test/readelf.py76
-rwxr-xr-xscripts/kprobes_test/run_module.py121
-rwxr-xr-xscripts/kprobes_test/whitelist.exp162
-rwxr-xr-xscripts/kprobes_test/whitelist_lib.exp175
-rwxr-xr-xstap-add-server-cert46
-rwxr-xr-xstap-client264
-rw-r--r--stap-client-connect.c488
-rwxr-xr-xstap-find-or-start-server12
-rwxr-xr-xstap-gen-server-cert92
-rwxr-xr-xstap-server124
-rw-r--r--stap-server-connect.c771
-rwxr-xr-xstap-serverd91
-rwxr-xr-xstap-start-server22
-rw-r--r--stap.1.in9
-rw-r--r--staptree.cxx8
-rw-r--r--staptree.h1
-rw-r--r--systemtap.spec38
-rw-r--r--tapset/ChangeLog5
-rw-r--r--tapset/context.stp18
-rw-r--r--tapset/task.stp35
-rw-r--r--tapsets.cxx85
-rw-r--r--testsuite/ChangeLog46
-rw-r--r--testsuite/lib/systemtap.exp23
-rw-r--r--testsuite/systemtap.base/badkprobe.exp1
-rwxr-xr-xtestsuite/systemtap.base/bz5274.exp8
-rw-r--r--testsuite/systemtap.base/bz6850.exp9
-rw-r--r--testsuite/systemtap.base/static_uprobes.exp139
-rw-r--r--testsuite/systemtap.base/static_uprobes.stp14
-rw-r--r--testsuite/systemtap.base/uprobes.exp9
-rw-r--r--testsuite/systemtap.context/backtrace.tcl2
-rw-r--r--testsuite/systemtap.examples/ChangeLog11
-rwxr-xr-xtestsuite/systemtap.examples/io/traceio2.stp2
-rwxr-xr-xtestsuite/systemtap.examples/process/futexes.stp2
-rwxr-xr-xtestsuite/systemtap.examples/profiling/functioncallcount.stp1
-rwxr-xr-xtestsuite/systemtap.examples/profiling/thread-times.stp3
-rwxr-xr-xtestsuite/systemtap.syscall/test.tcl2
-rw-r--r--translate.cxx20
90 files changed, 8090 insertions, 3141 deletions
diff --git a/ChangeLog b/ChangeLog
index f993fd08..b8ed45fe 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -25,6 +25,324 @@
Test for STP_NEED_TASK_FINDER_VMA to enable
emit_vm_callback_probe_decl.
+2009-01-23 Mark Wielaard <mjw@redhat.com>
+
+ * configure.ac: Use make -k install-data for elfutils.
+ * configure: Regenerated.
+
+2009-01-22 David Smith <dsmith@redhat.com>
+
+ * systemtap.spec: Added 'nss-devel' buildreq so that the 'client'
+ subpackage could be built correctly. Added file-based buildreq
+ for xmlto's pdf support, which works on f8, f9, f9, and rhel5.
+
+ * configure.ac: Fixed typo.
+ * configure: Regenerated.
+
+2009-01-22 Stan Cox <scox@redhat.com>
+
+ * dtrace: Rewritten to handle dtrace -h -G
+ * runtime/sdt.h: New .probes layout. Make labels unique, args unused.
+ * tapsets.cxx (dwarf_builder::build): New .probes layout.
+ Don't reset location->components[0].
+
+2009-01-21 Mark Wielaard <mjw@redhat.com>
+
+ * configure.ac: Create PIECFLAGS and PIECXXFLAGS, like PIELDFLAGS.
+ Don't duplicate -pie in PIELDFLAGS.
+ * configure: Regenerated.
+ * Makefile.am: Add @PIECFLAGS@ and @PIECXXFLAGS@ to executable
+ flags.
+ * Makefile.in: Regenerated.
+
+2009-01-21 Mark Wielaard <mjw@redhat.com>
+
+ * Makefile.am (distclean-local): Remove build-elfutils,
+ include-elfutils and lib-elfutils here, not in clean-local.
+ * Makefile.in: Regenerated.
+ * configure.ac: Only muck with CPPFLAGS and include-elfutils when
+ actually building with bundled elfutils.
+ * configure: Regenerated.
+
+2009-01-21 Mark Wielaard <mjw@redhat.com>
+
+ * Makefile.am (clean-local): Remove build-elfutils, include-elfutils
+ and lib-elfutils.
+ * Makefile.in: Regenerated.
+ * aclocal.m4: Regenerated.
+ * configure: Regenerated.
+
+2009-01-20 Frank Ch. Eigler <fche@elastic.org>
+
+ * tapsets.cxx (dwarf..:visit_target_symbol): Print more data
+ for failed $$vars fields to help explain printed "var=?".
+
+2009-01-20 Frank Ch. Eigler <fche@elastic.org>
+
+ * dwarf_wrappers.cxx (dwfl_assert): Tolerate rc==-1, for which
+ dwfl_errmsg(-1)=>NULL.
+
+2009-01-19 Dave Brolley <brolley@redhat.com>
+
+ * stap-serverd (initialization): Call stap-add-server-cert only if
+ it has been installed.
+
+2009-01-13 Stan Cox <scox@redhat.com>
+
+ * systemtap.spec (sdt-devel): New subpackage.
+ * Makefile.am (oldincludedir): New.
+ (oldinclude_HEADERS): New.
+ (bin_SCRIPTS): Add dtrace
+ * Makefile.in: Regenerated.
+ * runtime/sduprobes.h: Renamed to sdt.h
+
+2009-01-13 Dave Brolley <brolley@redhat.com>
+
+ * stap-find-or-start-server,stap-start-server,stap-serverd,stap-server:
+ Ensure we call other systemtap tools from the installed location.
+ * stap-client: Likewise. Also, use SYSTEMTAP_STAPRUN if it is set.
+
+2009-01-13 Dave Brolley <brolley@redhat.com>
+
+ * stap-add-server-cert: Failure to make the client database readable
+ is now only a warning. Directory argument now refers to the location
+ of the 'client' directory.
+ * stap-gen-server-cert: Ensure that the certificate is readable by
+ all. Warn if unsuccessful. Don't add the certificate to the local
+ client-side database.
+ * stap-serverd: Call stap-add-server-cert after stap-gen-server-cert.
+
+2009-01-11 Wenji Huang <wenji.huang@oracle.com>
+
+ * tapsets.cxx (dwarf_derived_probe_group::emit_module_decls): Fix too
+ large number on 32-bits machines.
+ (uprobe_derived_probe_group::emit_module_decls): Ditto.
+
+2009-01-11 Mark Wielaard <mjw@redhat.com>
+
+ * configure.ac: Add prefix as STAP_PREFIX for config.h.
+ * config.in: Regenerated.
+ * configure: Regenerated.
+
+2009-01-09 Elliott Baron <ebaron@redhat.com>
+
+ * stap.1.in: Added %M info.
+
+2009-01-09 Dave Brolley <brolley@redhat.com>
+
+ * Makefile.am (stamp-ssl): Removed.
+ (ssl/server/stap-server.cert): Removed.
+ (install-data-local): Don't install $(builddir)/ssl.
+ (stap-add-server-cert): Create database directory if it does not
+ exist. Ensure the database is readable by others.
+ * stap-client (initialization): Initialize local_ssl_dbs and
+ public_ssl_dbs. Don't initialize ssl_db.
+ (parse_options): Concatenate additional_local_ssl_dbs with
+ local_ssl_dbs.
+ (process_ssl): Build up additional_local_ssl_dbs in the order
+ specified on the command line.
+ (choose_server): Set server for non-local domains. Print
+ $tmpdir_client/connect to stderr if we can't connect.
+ (send_receive): Try connecting to the given server using all of the
+ databases in $local_ssl_dbs and $public_ssl_dbs. Keep log in
+ $tmpdir_client/connect.
+ (interrupt): Use SIGTERM to kill stap-client-connect.
+ * stap-client-connect.c (prerror.h,secerror.h): #include them.
+ (errWarn): Try to the the error text from NSPR. Handle specific errors
+ manually otherwise.
+ (handle_connection): Stop processing on write error of the local file.
+ (do_connect): Cleanup on error. Call SSL_ForceHandshake to catch
+ authentication errors here.
+ * stap-gen-server-cert: Don't create the client's database directory.
+ * stap-server: Redirect the output of signtool to /dev/null.
+ * stap-server-connect.c (handle_connect): Call SSL_ForceHandshake to catch
+ authentication errors here. Clean up temp files on error.
+ (accept_connection): Don't close the socket on error.
+ stap-serverd (initialization): Print a message if the given socket is busy.
+ Search for a local certificate database. Create and initialize one if not
+ found.
+ (listen): Don't discard stderr fomr stap-server-connect.
+ * stap-start-server: Check for existence of local certificate database as
+ evidence that the server is listening.
+ * Makefile.in: Regenerated.
+
+2009-01-08 William Cohen <wcohen@redhat.com>
+
+ * configure.ac: Check for xmlto that generates pdf.
+ * configure: Regenerated.
+
+2009-01-07 William Cohen <wcohen@redhat.com>
+
+ * configure.ac: Add --enable-refdocs configure option and
+ set check for xmlto
+ * Makefile.in: Regenerated.
+ * aclocal.m4: Likewise.
+ * configure: Likewise.
+
+2009-01-07 Mark Wielaard <mjw@redhat.com>
+
+ * configure.ac: Warn when not building docs because tools not found.
+ * configure: Regenerated.
+
+2009-01-07 Mark Wielaard <mjw@redhat.com>
+
+ * configure.ac: Add --enable-server configure option and
+ set BUILD_SERVER appropriately.
+ * Makefile.am (man_MANS, bin_PROGRAMS, bin_SCRIPTS): Only add
+ stap-server and friends when BUILD_SERVER set.A
+ * Makefile.in: Regenerated.
+ * aclocal.m4: Likewise.
+ * configure: Likewise.
+
+2009-01-06 Frank Ch. Eigler <fche@elastic.org>
+
+ PR9699.
+ * buildrun.cxx (compile_pass): Add $(LINUXINCLUDES) to autoconf
+ trial builds. Add new autoconf test for task_struct uid->cred switch.
+
+2009-01-06 Dave Brolley <brolley@redhat.com>
+
+ * systemtap.spec (stap-client): Add stap-add-server-cert,
+ stap-client-connect.
+ (stap-server): Add stap-server-connect.
+
+2009-01-05 Dave Brolley <brolley@redhat.com>
+
+ PR9702
+ * stap-gen-server-cert: Try mkpasswd, apg and then user_enter_password
+ when generating the password for the server certificate/key
+ database.
+ (user_enter_password): New function.
+
+2008-12-31 Frank Ch. Eigler <fche@elastic.org>
+
+ * translate.cxx (dump_unwindsyms): Adapt to elfutils build-id
+ bug that was fixed in 0.138.
+ * configure.ac: Look for elfutils/version.h.
+ * config.in, configure: Regenerated.
+
+2008-12-30 Dave Brolley <brolley@redhat.com>
+
+ PR9692
+ From Eugeniy Meshcheryakov <eugen@debian.org>
+ * Makefile.am (stap_client_connect_CFLAGS): Use $(nss_CFLAGS) and
+ $(nspr_CFLAGS).
+ (stap_server_connect_CFLAGS): Likewise.
+ * configure.ac: Use PKG_CHECK_MODULES to configure nss and nspr.
+ * Makefile.in: Regenerated.
+ * aclocal.m4: Regenerated.
+ * configure: Regenerated.
+
+2008-12-30 Dave Brolley <brolley@redhat.com>
+
+ * Makefile.am (install-data-local): Test for existence of $(builddir)/ssl
+ before installing it.
+ * Makefile.in: Regenerated.
+
+2008-12-29 Frank Ch. Eigler <fche@elastic.org>
+
+ * Makefile.am (install-data, uninstall-data): Use
+ $(DESTDIR)$(sysconfdir) instead of hard-coded /etc paths.
+
+2008-12-26 Dave Brolley <brolley@redhat.com>
+
+ * Makefile.am (stamp-ssl): Disable automatic building of this target.
+ * Makefile.in: Regenerated.
+
+2008-12-24 Dave Brolley <brolley@redhat.com>
+
+ * stap-client (netcat): Removed.
+ (initialization): Initialize ssl_db.
+ (parse_options): Handle the --ssl option.
+ (process_ssl): New function.
+ (send_request): Removed.
+ (receive_response): Removed.
+ (unpack_response): Use signtool to verify the contents of the
+ server's response against a local copy of the server's
+ certificate.
+ (find_and_connect_to_server): Make sure the server is referred to
+ as localhost if it is running on the local host. Call send_receive
+ in order to contact the server and perform the transaction.
+ (connect_to_server): Removed.
+ (disconnect_from_server): Removed.
+ (send_receive): New function.
+ (process_response): Work in $tmpdir_server.
+ (terminate, interrupt): Kill any running stap-client-connect.
+ * stap-find-or-start-server: Pass arguments to stap-start-server.
+ * stap-start-server: Pass arguments to stap-serverd.
+ * stap-server (port): Removed.
+ (netcat): Removed.
+ (receive_request): Removed.
+ (unpack_request): Use unzip.
+ (package_response): Use signtool to sign the response into a .jar
+ archive.
+ (send_response): Removed.
+ * stap-serverd (netcat): Removed.
+ (port1): Removed.
+ (initialize): Don't call recursively. Use a loop to select a port.
+ (listen): Call stap-server-connect.
+ (process_request): Removed.
+ (terminate): Kill any running stap-server-connect job.
+ * systemtap.spec: client and server sub packages require nss and nss-tools,
+ and no longer require nc or net-tools.
+ * Makefile.am (bin_PROGRAMS): Add stap-client-connect and
+ stap-server-connect.
+ (bin_SCRIPTS): Add stap-gen-server-cert.
+ (stap_client_connect_LDFLAGS, stap_server_connect_LDFLAGS): New.
+ (stamp-ssl): New target.
+ (ssl/server/stap-server.cert): New target.
+ (stap_client_connect_*): New.
+ (stap_server_connect_*): New.
+ (install-data-local): Install /etc/systemtap/ssl.
+ (uninstall-local): Remove /etc/systemtap.
+ * Makefile.in: Regenerated.
+ * aclocal.m4: Regenerated.
+
+2008-12-22 Masami Hiramatsu <mhiramat@redhat.com>
+
+ PR7090
+ * buildrun.cxx (compile_pass): Use flags macro to expand KBUILD_CFLAGS
+ for support kernels built with O= option.
+
+2008-12-21 Will Cohen <wcohen@redhat.com>
+
+ * systemtap.spec: Add generations of tapset reference manual material.
+
+2008-12-21 Stan Cox <scox@redhat.com>
+
+ * tapsets.cxx (dwflpp::die_has_pc): Don't abort if dwarf_ranges fails.
+ (dwflpp::find_variable_and_frame_base): A pc requires dwarf_nscopes
+
+2008-12-19 Elliott Baron <ebaron@redhat.com>
+
+ PR3668
+ * elaborate.cxx: Handling for %M.
+ * runtime/vsprintf.c: Likewise.
+ * staptree.cxx: Likewise.
+ * translate.cxx: Likewise.
+ * staptree.h: Added %M converter, conv_memory_hex, to enum
+
+2008-12-16 Roland McGrath <roland@redhat.com>
+
+ * systemtap.spec (Requires): Add kernel-devel, is correct virtual
+ provide in kernel-*-devel rpms.
+ (with_sqlite): Typo fix in default defn check.
+ [%{with_sqlite}] (Requires): Remove. BuildRequires causes the correct
+ automatic dependency.
+
+2008-12-16 Stan Cox <scox@redhat.com>
+
+ * tapsets.cxx (dwarf_builder::build): Consider alignment when
+ fetching .probes values. Convert .mark to .statement(0x) instead
+ of .statement(foo.c:N)
+
+2008-12-11 Dave Brolley <brolley@redhat.com>
+
+ PR7087
+ * stap-client: Don't use -d on netcat. Redirect from /dev/null instead.
+ * stap-server: Likewise.
+ * stap-serverd: Likewise.
+
2008-12-09 Frank Ch. Eigler <fche@elastic.org>
PR6961
@@ -37,6 +355,7 @@
2008-12-09 Dave Brolley <brolley@redhat.com>
+ PR7087
* stap-client: Use netcat or nc, whichever is available.
* stap-server: Likewise.
* stap-serverd: Likewise.
diff --git a/Makefile.am b/Makefile.am
index db77456c..90c90550 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -4,17 +4,27 @@
AUTOMAKE_OPTIONS = no-dist
pkglibexecdir = ${libexecdir}/${PACKAGE}
+oldincludedir = ${includedir}/sys
AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DPKGDATADIR='"${pkgdatadir}"' -DPKGLIBDIR='"$(pkglibexecdir)"'
AM_CFLAGS = -D_GNU_SOURCE -fexceptions -Wall -Werror -Wunused -Wformat=2 -W
AM_CXXFLAGS = -Wall -Werror
-man_MANS = stap.1 stapprobes.5 stapfuncs.5 stapvars.5 stapex.5 staprun.8 stap-server.8 man/stapprobes.iosched.5 man/stapprobes.netdev.5 man/stapprobes.nfs.5 man/stapprobes.nfsd.5 man/stapprobes.pagefault.5 man/stapprobes.process.5 man/stapprobes.rpc.5 man/stapprobes.scsi.5 man/stapprobes.signal.5 man/stapprobes.socket.5 man/stapprobes.tcp.5 man/stapprobes.udp.5
+man_MANS = stap.1 stapprobes.5 stapfuncs.5 stapvars.5 stapex.5 staprun.8 man/stapprobes.iosched.5 man/stapprobes.netdev.5 man/stapprobes.nfs.5 man/stapprobes.nfsd.5 man/stapprobes.pagefault.5 man/stapprobes.process.5 man/stapprobes.rpc.5 man/stapprobes.scsi.5 man/stapprobes.signal.5 man/stapprobes.socket.5 man/stapprobes.tcp.5 man/stapprobes.udp.5
# see also configure.ac
bin_PROGRAMS = stap staprun
-bin_SCRIPTS = stap-client stap-server stap-serverd stap-find-servers stap-start-server stap-find-or-start-server stap-stop-server stap-report
+bin_SCRIPTS = stap-report
+oldinclude_HEADERS = runtime/sdt.h
+if BUILD_SERVER
+man_MANS += stap-server.8
+bin_PROGRAMS += stap-client-connect stap-server-connect
+bin_SCRIPTS += stap-client stap-serverd stap-server stap-find-servers \
+ stap-start-server stap-find-or-start-server stap-stop-server \
+ stap-gen-server-cert stap-add-server-cert
+endif
+bin_SCRIPTS += dtrace
stap_SOURCES = main.cxx \
parse.cxx staptree.cxx elaborate.cxx translate.cxx \
tapsets.cxx buildrun.cxx loc2c.c hash.cxx mdfour.c \
@@ -23,6 +33,7 @@ stap_LDADD = @stap_LIBS@ @sqlite3_LIBS@
BUILT_SOURCES =
CLEANFILES =
+stap_DEPENDENCIES =
# Arrange for git_version.h to be regenerated at every "make".
# Code fragment is based upon RadeonHD.am.
@@ -61,13 +72,15 @@ cscope:
cscope -b -q
-stap_CXXFLAGS = $(AM_CXXFLAGS)
+stap_CFLAGS = $(AM_CFLAGS) @PIECFLAGS@
+stap_CXXFLAGS = $(AM_CXXFLAGS) @PIECXXFLAGS@
stap_CPPFLAGS = $(AM_CPPFLAGS)
stap_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
-staprun_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
-stapio_CPPFLAGS = $(AM_CPPFLAGS)
-stapio_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
+if BUILD_SERVER
+stap_client_connect_LDFLAGS = $(AM_LDFLAGS)
+stap_server_connect_LDFLAGS = $(AM_LDFLAGS)
+endif
PHONIES =
if BUILD_ELFUTILS
@@ -84,7 +97,7 @@ stamp-elfutils: config.status
$(MAKE) $(AM_MAKEFLAGS) -C build-elfutils/$$dir bin_PROGRAMS= install; \
done
touch $@
-stap_DEPENDENCIES = lib-elfutils/libdw.so
+stap_DEPENDENCIES += lib-elfutils/libdw.so
lib-elfutils/libdw.so: stamp-elfutils ;
pkglib_LIBRARIES = libsduprobes.a
@@ -105,16 +118,28 @@ staprun_SOURCES = runtime/staprun/staprun.c runtime/staprun/staprun_funcs.c\
runtime/staprun/ctl.c runtime/staprun/common.c
staprun_CPPFLAGS = $(AM_CPPFLAGS)
-staprun_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) -DSINGLE_THREADED -fno-strict-aliasing
+staprun_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) @PIECFLAGS@ -DSINGLE_THREADED -fno-strict-aliasing
+staprun_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
staprun_LDADD = @PROCFLAGS@
stapio_SOURCES = runtime/staprun/stapio.c \
runtime/staprun/mainloop.c runtime/staprun/common.c \
runtime/staprun/ctl.c \
runtime/staprun/relay.c runtime/staprun/relay_old.c
-stapio_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) -fno-strict-aliasing
+stapio_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) @PIECFLAGS@ -fno-strict-aliasing
+stapio_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
stapio_LDADD = @PROCFLAGS@ -lpthread
+if BUILD_SERVER
+stap_client_connect_SOURCES = stap-client-connect.c
+stap_client_connect_CFLAGS = -Wall -Werror $(nss_CFLAGS) $(nspr_CFLAGS)
+stap_client_connect_LDADD = -lssl3
+
+stap_server_connect_SOURCES = stap-server-connect.c
+stap_server_connect_CFLAGS = -Wall -Werror $(nss_CFLAGS) $(nspr_CFLAGS)
+stap_server_connect_LDADD = -lssl3
+endif
+
install-exec-hook:
if [ `id -u` -eq 0 ]; then chmod 04111 "$(DESTDIR)$(bindir)/staprun"; fi
@@ -127,6 +152,7 @@ CLEANFILES += $(pkglibexec_PROGRAMS)
noinst_PROGRAMS = loc2c-test
loc2c_test_SOURCES = loc2c-test.c loc2c.c
+loc2c_test_CFLAGS = $(stap_CFLAGS)
loc2c_test_CPPFLAGS = $(stap_CPPFLAGS)
loc2c_test_LDFLAGS = $(stap_LDFLAGS)
loc2c_test_LDADD = $(stap_LDADD)
@@ -200,6 +226,9 @@ clean-local:
rm -rf stap.info
rm -rf staplog.so
+distclean-local:
+ rm -rf build-elfutils include-elfutils lib-elfutils
+
uninstall-local:
rm -rf $(DESTDIR)$(pkgdatadir)
rm -rf $(DESTDIR)$(libexecdir)/$(PACKAGE)
@@ -217,6 +246,7 @@ uninstall-local:
echo " rm -f '$(SAMPLE_INSTALL_DIR)/$$p'"; \
rm -f "$(SAMPLE_INSTALL_DIR)/$$p"; \
done
+ rm -rf $(DESTDIR)$(sysconfdir)/systemtap
# XXX: leaves behind man pages
SUBDIRS = testsuite doc
diff --git a/Makefile.in b/Makefile.in
index de6d48e1..b768c3cb 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -18,6 +18,7 @@
+
VPATH = @srcdir@
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
@@ -34,15 +35,21 @@ POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
-bin_PROGRAMS = stap$(EXEEXT) staprun$(EXEEXT)
-@BUILD_ELFUTILS_TRUE@am__append_1 = -Iinclude-elfutils
-@BUILD_ELFUTILS_TRUE@am__append_2 = -Llib-elfutils -Wl,-rpath-link,lib-elfutils \
+bin_PROGRAMS = stap$(EXEEXT) staprun$(EXEEXT) $(am__EXEEXT_1)
+@BUILD_SERVER_TRUE@am__append_1 = stap-server.8
+@BUILD_SERVER_TRUE@am__append_2 = stap-client-connect stap-server-connect
+@BUILD_SERVER_TRUE@am__append_3 = stap-client stap-serverd stap-server stap-find-servers \
+@BUILD_SERVER_TRUE@ stap-start-server stap-find-or-start-server stap-stop-server \
+@BUILD_SERVER_TRUE@ stap-gen-server-cert stap-add-server-cert
+
+@BUILD_ELFUTILS_TRUE@am__append_4 = -Iinclude-elfutils
+@BUILD_ELFUTILS_TRUE@am__append_5 = -Llib-elfutils -Wl,-rpath-link,lib-elfutils \
@BUILD_ELFUTILS_TRUE@ -Wl,--enable-new-dtags,-rpath,$(pkglibdir)
-@BUILD_ELFUTILS_TRUE@am__append_3 = stamp-elfutils
-@BUILD_ELFUTILS_TRUE@am__append_4 = stamp-elfutils
-@BUILD_ELFUTILS_FALSE@stap_DEPENDENCIES =
-@BUILD_ELFUTILS_TRUE@am__append_5 = install-elfutils
+@BUILD_ELFUTILS_TRUE@am__append_6 = stamp-elfutils
+@BUILD_ELFUTILS_TRUE@am__append_7 = stamp-elfutils
+@BUILD_ELFUTILS_TRUE@am__append_8 = lib-elfutils/libdw.so
+@BUILD_ELFUTILS_TRUE@am__append_9 = install-elfutils
pkglibexec_PROGRAMS = stapio$(EXEEXT)
noinst_PROGRAMS = loc2c-test$(EXEEXT)
subdir = .
@@ -64,7 +71,8 @@ DIST_COMMON = INSTALL NEWS README AUTHORS ChangeLog \
$(top_srcdir)/man/stapprobes.signal.5.in \
$(top_srcdir)/man/stapprobes.socket.5.in \
$(top_srcdir)/man/stapprobes.tcp.5.in \
- $(top_srcdir)/man/stapprobes.udp.5.in depcomp
+ $(top_srcdir)/man/stapprobes.udp.5.in $(srcdir)/run-stap.in \
+ depcomp $(oldinclude_HEADERS)
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
@@ -80,7 +88,7 @@ CONFIG_CLEAN_FILES = stap.1 stapprobes.5 stapfuncs.5 stapvars.5 \
man/stapprobes.process.5 man/stapprobes.rpc.5 \
man/stapprobes.scsi.5 man/stapprobes.signal.5 \
man/stapprobes.socket.5 man/stapprobes.tcp.5 \
- man/stapprobes.udp.5
+ man/stapprobes.udp.5 run-stap
am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
am__vpath_adj = case $$p in \
$(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
@@ -90,7 +98,7 @@ am__strip_dir = `echo $$p | sed -e 's|^.*/||'`;
am__installdirs = "$(DESTDIR)$(pkglibdir)" "$(DESTDIR)$(bindir)" \
"$(DESTDIR)$(pkglibexecdir)" "$(DESTDIR)$(bindir)" \
"$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" \
- "$(DESTDIR)$(man8dir)"
+ "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(oldincludedir)"
pkglibLIBRARIES_INSTALL = $(INSTALL_DATA)
LIBRARIES = $(pkglib_LIBRARIES)
AR = ar
@@ -99,6 +107,8 @@ libsduprobes_a_AR = $(AR) $(ARFLAGS)
libsduprobes_a_LIBADD =
@BUILD_ELFUTILS_TRUE@am_libsduprobes_a_OBJECTS = sduprobes.$(OBJEXT)
libsduprobes_a_OBJECTS = $(am_libsduprobes_a_OBJECTS)
+@BUILD_SERVER_TRUE@am__EXEEXT_1 = stap-client-connect$(EXEEXT) \
+@BUILD_SERVER_TRUE@ stap-server-connect$(EXEEXT)
binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
pkglibexecPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
PROGRAMS = $(bin_PROGRAMS) $(noinst_PROGRAMS) $(pkglibexec_PROGRAMS)
@@ -107,8 +117,8 @@ am_loc2c_test_OBJECTS = loc2c_test-loc2c-test.$(OBJEXT) \
loc2c_test_OBJECTS = $(am_loc2c_test_OBJECTS)
am__DEPENDENCIES_1 =
loc2c_test_DEPENDENCIES = $(am__DEPENDENCIES_1)
-loc2c_test_LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(loc2c_test_LDFLAGS) \
- $(LDFLAGS) -o $@
+loc2c_test_LINK = $(CCLD) $(loc2c_test_CFLAGS) $(CFLAGS) \
+ $(loc2c_test_LDFLAGS) $(LDFLAGS) -o $@
am_stap_OBJECTS = stap-main.$(OBJEXT) stap-parse.$(OBJEXT) \
stap-staptree.$(OBJEXT) stap-elaborate.$(OBJEXT) \
stap-translate.$(OBJEXT) stap-tapsets.$(OBJEXT) \
@@ -119,6 +129,16 @@ am_stap_OBJECTS = stap-main.$(OBJEXT) stap-parse.$(OBJEXT) \
stap_OBJECTS = $(am_stap_OBJECTS)
stap_LINK = $(CXXLD) $(stap_CXXFLAGS) $(CXXFLAGS) $(stap_LDFLAGS) \
$(LDFLAGS) -o $@
+@BUILD_SERVER_TRUE@am_stap_client_connect_OBJECTS = stap_client_connect-stap-client-connect.$(OBJEXT)
+stap_client_connect_OBJECTS = $(am_stap_client_connect_OBJECTS)
+stap_client_connect_DEPENDENCIES =
+stap_client_connect_LINK = $(CCLD) $(stap_client_connect_CFLAGS) \
+ $(CFLAGS) $(stap_client_connect_LDFLAGS) $(LDFLAGS) -o $@
+@BUILD_SERVER_TRUE@am_stap_server_connect_OBJECTS = stap_server_connect-stap-server-connect.$(OBJEXT)
+stap_server_connect_OBJECTS = $(am_stap_server_connect_OBJECTS)
+stap_server_connect_DEPENDENCIES =
+stap_server_connect_LINK = $(CCLD) $(stap_server_connect_CFLAGS) \
+ $(CFLAGS) $(stap_server_connect_LDFLAGS) $(LDFLAGS) -o $@
am_stapio_OBJECTS = stapio-stapio.$(OBJEXT) stapio-mainloop.$(OBJEXT) \
stapio-common.$(OBJEXT) stapio-ctl.$(OBJEXT) \
stapio-relay.$(OBJEXT) stapio-relay_old.$(OBJEXT)
@@ -148,7 +168,9 @@ CXXLD = $(CXX)
CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
-o $@
SOURCES = $(libsduprobes_a_SOURCES) $(loc2c_test_SOURCES) \
- $(stap_SOURCES) $(stapio_SOURCES) $(staprun_SOURCES)
+ $(stap_SOURCES) $(stap_client_connect_SOURCES) \
+ $(stap_server_connect_SOURCES) $(stapio_SOURCES) \
+ $(staprun_SOURCES)
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
html-recursive info-recursive install-data-recursive \
install-dvi-recursive install-exec-recursive \
@@ -161,6 +183,8 @@ man5dir = $(mandir)/man5
man8dir = $(mandir)/man8
NROFF = nroff
MANS = $(man_MANS)
+oldincludeHEADERS_INSTALL = $(INSTALL_HEADER)
+HEADERS = $(oldinclude_HEADERS)
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
ETAGS = etags
@@ -212,7 +236,10 @@ PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
+PIECFLAGS = @PIECFLAGS@
+PIECXXFLAGS = @PIECXXFLAGS@
PIELDFLAGS = @PIELDFLAGS@
+PKG_CONFIG = @PKG_CONFIG@
PROCFLAGS = @PROCFLAGS@
RANLIB = @RANLIB@
SET_MAKE = @SET_MAKE@
@@ -244,6 +271,7 @@ have_dvips = @have_dvips@
have_latex = @have_latex@
have_latex2html = @have_latex2html@
have_ps2pdf = @have_ps2pdf@
+have_xmlto = @have_xmlto@
host_alias = @host_alias@
htmldir = @htmldir@
includedir = @includedir@
@@ -255,7 +283,11 @@ localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
-oldincludedir = @oldincludedir@
+nspr_CFLAGS = @nspr_CFLAGS@
+nspr_LIBS = @nspr_LIBS@
+nss_CFLAGS = @nss_CFLAGS@
+nss_LIBS = @nss_LIBS@
+oldincludedir = ${includedir}/sys
pdfdir = @pdfdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
@@ -269,6 +301,7 @@ staplog_CPPFLAGS = @staplog_CPPFLAGS@
subdirs = @subdirs@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AUTOMAKE_OPTIONS = no-dist
@@ -276,8 +309,15 @@ pkglibexecdir = ${libexecdir}/${PACKAGE}
AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DPKGDATADIR='"${pkgdatadir}"' -DPKGLIBDIR='"$(pkglibexecdir)"'
AM_CFLAGS = -D_GNU_SOURCE -fexceptions -Wall -Werror -Wunused -Wformat=2 -W
AM_CXXFLAGS = -Wall -Werror
-man_MANS = stap.1 stapprobes.5 stapfuncs.5 stapvars.5 stapex.5 staprun.8 stap-server.8 man/stapprobes.iosched.5 man/stapprobes.netdev.5 man/stapprobes.nfs.5 man/stapprobes.nfsd.5 man/stapprobes.pagefault.5 man/stapprobes.process.5 man/stapprobes.rpc.5 man/stapprobes.scsi.5 man/stapprobes.signal.5 man/stapprobes.socket.5 man/stapprobes.tcp.5 man/stapprobes.udp.5
-bin_SCRIPTS = stap-client stap-server stap-serverd stap-find-servers stap-start-server stap-find-or-start-server stap-stop-server stap-report
+man_MANS = stap.1 stapprobes.5 stapfuncs.5 stapvars.5 stapex.5 \
+ staprun.8 man/stapprobes.iosched.5 man/stapprobes.netdev.5 \
+ man/stapprobes.nfs.5 man/stapprobes.nfsd.5 \
+ man/stapprobes.pagefault.5 man/stapprobes.process.5 \
+ man/stapprobes.rpc.5 man/stapprobes.scsi.5 \
+ man/stapprobes.signal.5 man/stapprobes.socket.5 \
+ man/stapprobes.tcp.5 man/stapprobes.udp.5 $(am__append_1)
+bin_SCRIPTS = stap-report $(am__append_3) dtrace
+oldinclude_HEADERS = runtime/sdt.h
stap_SOURCES = main.cxx \
parse.cxx staptree.cxx elaborate.cxx translate.cxx \
tapsets.cxx buildrun.cxx loc2c.c hash.cxx mdfour.c \
@@ -293,33 +333,42 @@ stap_LDADD = @stap_LIBS@ @sqlite3_LIBS@
# of foo-bar.c if it is newer than the foo-bar.o file. Using noinst_foo_SOURCES
# instead of foo_SOURCES prevents shipping git_version.h in dist tarballs,
# which may cause false GIT_FOO readings.
-BUILT_SOURCES = git_version.stamp $(am__append_3)
-CLEANFILES = git_version.h $(am__append_4) $(pkglibexec_PROGRAMS)
+BUILT_SOURCES = git_version.stamp $(am__append_6)
+CLEANFILES = git_version.h $(am__append_7) $(pkglibexec_PROGRAMS)
+stap_DEPENDENCIES = $(am__append_8)
GIT_VERSION_CMD = $(SHELL) $(top_srcdir)/git_version.sh
-stap_CXXFLAGS = $(AM_CXXFLAGS)
-stap_CPPFLAGS = $(AM_CPPFLAGS) $(am__append_1)
-stap_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@ $(am__append_2)
-staprun_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
-stapio_CPPFLAGS = $(AM_CPPFLAGS)
-stapio_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
-PHONIES = $(am__append_5) dist-gzip
-@BUILD_ELFUTILS_TRUE@stap_DEPENDENCIES = lib-elfutils/libdw.so
+stap_CFLAGS = $(AM_CFLAGS) @PIECFLAGS@
+stap_CXXFLAGS = $(AM_CXXFLAGS) @PIECXXFLAGS@
+stap_CPPFLAGS = $(AM_CPPFLAGS) $(am__append_4)
+stap_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@ $(am__append_5)
+@BUILD_SERVER_TRUE@stap_client_connect_LDFLAGS = $(AM_LDFLAGS)
+@BUILD_SERVER_TRUE@stap_server_connect_LDFLAGS = $(AM_LDFLAGS)
+PHONIES = $(am__append_9) dist-gzip
@BUILD_ELFUTILS_TRUE@pkglib_LIBRARIES = libsduprobes.a
@BUILD_ELFUTILS_TRUE@libsduprobes_a_SOURCES = runtime/sduprobes.c
staprun_SOURCES = runtime/staprun/staprun.c runtime/staprun/staprun_funcs.c\
runtime/staprun/ctl.c runtime/staprun/common.c
staprun_CPPFLAGS = $(AM_CPPFLAGS)
-staprun_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) -DSINGLE_THREADED -fno-strict-aliasing
+staprun_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) @PIECFLAGS@ -DSINGLE_THREADED -fno-strict-aliasing
+staprun_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
staprun_LDADD = @PROCFLAGS@
stapio_SOURCES = runtime/staprun/stapio.c \
runtime/staprun/mainloop.c runtime/staprun/common.c \
runtime/staprun/ctl.c \
runtime/staprun/relay.c runtime/staprun/relay_old.c
-stapio_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) -fno-strict-aliasing
+stapio_CFLAGS = @PROCFLAGS@ $(AM_CFLAGS) @PIECFLAGS@ -fno-strict-aliasing
+stapio_LDFLAGS = $(AM_LDFLAGS) @PIELDFLAGS@
stapio_LDADD = @PROCFLAGS@ -lpthread
+@BUILD_SERVER_TRUE@stap_client_connect_SOURCES = stap-client-connect.c
+@BUILD_SERVER_TRUE@stap_client_connect_CFLAGS = -Wall -Werror $(nss_CFLAGS) $(nspr_CFLAGS)
+@BUILD_SERVER_TRUE@stap_client_connect_LDADD = -lssl3
+@BUILD_SERVER_TRUE@stap_server_connect_SOURCES = stap-server-connect.c
+@BUILD_SERVER_TRUE@stap_server_connect_CFLAGS = -Wall -Werror $(nss_CFLAGS) $(nspr_CFLAGS)
+@BUILD_SERVER_TRUE@stap_server_connect_LDADD = -lssl3
loc2c_test_SOURCES = loc2c-test.c loc2c.c
+loc2c_test_CFLAGS = $(stap_CFLAGS)
loc2c_test_CPPFLAGS = $(stap_CPPFLAGS)
loc2c_test_LDFLAGS = $(stap_LDFLAGS)
loc2c_test_LDADD = $(stap_LDADD)
@@ -432,6 +481,8 @@ man/stapprobes.tcp.5: $(top_builddir)/config.status $(top_srcdir)/man/stapprobes
cd $(top_builddir) && $(SHELL) ./config.status $@
man/stapprobes.udp.5: $(top_builddir)/config.status $(top_srcdir)/man/stapprobes.udp.5.in
cd $(top_builddir) && $(SHELL) ./config.status $@
+run-stap: $(top_builddir)/config.status $(srcdir)/run-stap.in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
install-pkglibLIBRARIES: $(pkglib_LIBRARIES)
@$(NORMAL_INSTALL)
test -z "$(pkglibdir)" || $(MKDIR_P) "$(DESTDIR)$(pkglibdir)"
@@ -520,6 +571,12 @@ loc2c-test$(EXEEXT): $(loc2c_test_OBJECTS) $(loc2c_test_DEPENDENCIES)
stap$(EXEEXT): $(stap_OBJECTS) $(stap_DEPENDENCIES)
@rm -f stap$(EXEEXT)
$(stap_LINK) $(stap_OBJECTS) $(stap_LDADD) $(LIBS)
+stap-client-connect$(EXEEXT): $(stap_client_connect_OBJECTS) $(stap_client_connect_DEPENDENCIES)
+ @rm -f stap-client-connect$(EXEEXT)
+ $(stap_client_connect_LINK) $(stap_client_connect_OBJECTS) $(stap_client_connect_LDADD) $(LIBS)
+stap-server-connect$(EXEEXT): $(stap_server_connect_OBJECTS) $(stap_server_connect_DEPENDENCIES)
+ @rm -f stap-server-connect$(EXEEXT)
+ $(stap_server_connect_LINK) $(stap_server_connect_OBJECTS) $(stap_server_connect_LDADD) $(LIBS)
stapio$(EXEEXT): $(stapio_OBJECTS) $(stapio_DEPENDENCIES)
@rm -f stapio$(EXEEXT)
$(stapio_LINK) $(stapio_OBJECTS) $(stapio_LDADD) $(LIBS)
@@ -569,6 +626,8 @@ distclean-compile:
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stap-tapsets.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stap-translate.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stap-util.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stap_client_connect-stap-client-connect.Po@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stap_server_connect-stap-server-connect.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stapio-common.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stapio-ctl.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stapio-mainloop.Po@am__quote@
@@ -609,144 +668,172 @@ sduprobes.obj: runtime/sduprobes.c
@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o sduprobes.obj `if test -f 'runtime/sduprobes.c'; then $(CYGPATH_W) 'runtime/sduprobes.c'; else $(CYGPATH_W) '$(srcdir)/runtime/sduprobes.c'; fi`
loc2c_test-loc2c-test.o: loc2c-test.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c-test.o -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c-test.Tpo -c -o loc2c_test-loc2c-test.o `test -f 'loc2c-test.c' || echo '$(srcdir)/'`loc2c-test.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c-test.o -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c-test.Tpo -c -o loc2c_test-loc2c-test.o `test -f 'loc2c-test.c' || echo '$(srcdir)/'`loc2c-test.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/loc2c_test-loc2c-test.Tpo $(DEPDIR)/loc2c_test-loc2c-test.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='loc2c-test.c' object='loc2c_test-loc2c-test.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c-test.o `test -f 'loc2c-test.c' || echo '$(srcdir)/'`loc2c-test.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c-test.o `test -f 'loc2c-test.c' || echo '$(srcdir)/'`loc2c-test.c
loc2c_test-loc2c-test.obj: loc2c-test.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c-test.obj -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c-test.Tpo -c -o loc2c_test-loc2c-test.obj `if test -f 'loc2c-test.c'; then $(CYGPATH_W) 'loc2c-test.c'; else $(CYGPATH_W) '$(srcdir)/loc2c-test.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c-test.obj -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c-test.Tpo -c -o loc2c_test-loc2c-test.obj `if test -f 'loc2c-test.c'; then $(CYGPATH_W) 'loc2c-test.c'; else $(CYGPATH_W) '$(srcdir)/loc2c-test.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/loc2c_test-loc2c-test.Tpo $(DEPDIR)/loc2c_test-loc2c-test.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='loc2c-test.c' object='loc2c_test-loc2c-test.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c-test.obj `if test -f 'loc2c-test.c'; then $(CYGPATH_W) 'loc2c-test.c'; else $(CYGPATH_W) '$(srcdir)/loc2c-test.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c-test.obj `if test -f 'loc2c-test.c'; then $(CYGPATH_W) 'loc2c-test.c'; else $(CYGPATH_W) '$(srcdir)/loc2c-test.c'; fi`
loc2c_test-loc2c.o: loc2c.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c.o -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c.Tpo -c -o loc2c_test-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c.o -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c.Tpo -c -o loc2c_test-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/loc2c_test-loc2c.Tpo $(DEPDIR)/loc2c_test-loc2c.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='loc2c.c' object='loc2c_test-loc2c.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
loc2c_test-loc2c.obj: loc2c.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c.obj -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c.Tpo -c -o loc2c_test-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -MT loc2c_test-loc2c.obj -MD -MP -MF $(DEPDIR)/loc2c_test-loc2c.Tpo -c -o loc2c_test-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/loc2c_test-loc2c.Tpo $(DEPDIR)/loc2c_test-loc2c.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='loc2c.c' object='loc2c_test-loc2c.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(loc2c_test_CPPFLAGS) $(CPPFLAGS) $(loc2c_test_CFLAGS) $(CFLAGS) -c -o loc2c_test-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
stap-loc2c.o: loc2c.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stap-loc2c.o -MD -MP -MF $(DEPDIR)/stap-loc2c.Tpo -c -o stap-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -MT stap-loc2c.o -MD -MP -MF $(DEPDIR)/stap-loc2c.Tpo -c -o stap-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap-loc2c.Tpo $(DEPDIR)/stap-loc2c.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='loc2c.c' object='stap-loc2c.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stap-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -c -o stap-loc2c.o `test -f 'loc2c.c' || echo '$(srcdir)/'`loc2c.c
stap-loc2c.obj: loc2c.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stap-loc2c.obj -MD -MP -MF $(DEPDIR)/stap-loc2c.Tpo -c -o stap-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -MT stap-loc2c.obj -MD -MP -MF $(DEPDIR)/stap-loc2c.Tpo -c -o stap-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap-loc2c.Tpo $(DEPDIR)/stap-loc2c.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='loc2c.c' object='stap-loc2c.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stap-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -c -o stap-loc2c.obj `if test -f 'loc2c.c'; then $(CYGPATH_W) 'loc2c.c'; else $(CYGPATH_W) '$(srcdir)/loc2c.c'; fi`
stap-mdfour.o: mdfour.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stap-mdfour.o -MD -MP -MF $(DEPDIR)/stap-mdfour.Tpo -c -o stap-mdfour.o `test -f 'mdfour.c' || echo '$(srcdir)/'`mdfour.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -MT stap-mdfour.o -MD -MP -MF $(DEPDIR)/stap-mdfour.Tpo -c -o stap-mdfour.o `test -f 'mdfour.c' || echo '$(srcdir)/'`mdfour.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap-mdfour.Tpo $(DEPDIR)/stap-mdfour.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mdfour.c' object='stap-mdfour.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stap-mdfour.o `test -f 'mdfour.c' || echo '$(srcdir)/'`mdfour.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -c -o stap-mdfour.o `test -f 'mdfour.c' || echo '$(srcdir)/'`mdfour.c
stap-mdfour.obj: mdfour.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT stap-mdfour.obj -MD -MP -MF $(DEPDIR)/stap-mdfour.Tpo -c -o stap-mdfour.obj `if test -f 'mdfour.c'; then $(CYGPATH_W) 'mdfour.c'; else $(CYGPATH_W) '$(srcdir)/mdfour.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -MT stap-mdfour.obj -MD -MP -MF $(DEPDIR)/stap-mdfour.Tpo -c -o stap-mdfour.obj `if test -f 'mdfour.c'; then $(CYGPATH_W) 'mdfour.c'; else $(CYGPATH_W) '$(srcdir)/mdfour.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap-mdfour.Tpo $(DEPDIR)/stap-mdfour.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mdfour.c' object='stap-mdfour.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o stap-mdfour.obj `if test -f 'mdfour.c'; then $(CYGPATH_W) 'mdfour.c'; else $(CYGPATH_W) '$(srcdir)/mdfour.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stap_CPPFLAGS) $(CPPFLAGS) $(stap_CFLAGS) $(CFLAGS) -c -o stap-mdfour.obj `if test -f 'mdfour.c'; then $(CYGPATH_W) 'mdfour.c'; else $(CYGPATH_W) '$(srcdir)/mdfour.c'; fi`
+
+stap_client_connect-stap-client-connect.o: stap-client-connect.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_client_connect_CFLAGS) $(CFLAGS) -MT stap_client_connect-stap-client-connect.o -MD -MP -MF $(DEPDIR)/stap_client_connect-stap-client-connect.Tpo -c -o stap_client_connect-stap-client-connect.o `test -f 'stap-client-connect.c' || echo '$(srcdir)/'`stap-client-connect.c
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap_client_connect-stap-client-connect.Tpo $(DEPDIR)/stap_client_connect-stap-client-connect.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='stap-client-connect.c' object='stap_client_connect-stap-client-connect.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_client_connect_CFLAGS) $(CFLAGS) -c -o stap_client_connect-stap-client-connect.o `test -f 'stap-client-connect.c' || echo '$(srcdir)/'`stap-client-connect.c
+
+stap_client_connect-stap-client-connect.obj: stap-client-connect.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_client_connect_CFLAGS) $(CFLAGS) -MT stap_client_connect-stap-client-connect.obj -MD -MP -MF $(DEPDIR)/stap_client_connect-stap-client-connect.Tpo -c -o stap_client_connect-stap-client-connect.obj `if test -f 'stap-client-connect.c'; then $(CYGPATH_W) 'stap-client-connect.c'; else $(CYGPATH_W) '$(srcdir)/stap-client-connect.c'; fi`
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap_client_connect-stap-client-connect.Tpo $(DEPDIR)/stap_client_connect-stap-client-connect.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='stap-client-connect.c' object='stap_client_connect-stap-client-connect.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_client_connect_CFLAGS) $(CFLAGS) -c -o stap_client_connect-stap-client-connect.obj `if test -f 'stap-client-connect.c'; then $(CYGPATH_W) 'stap-client-connect.c'; else $(CYGPATH_W) '$(srcdir)/stap-client-connect.c'; fi`
+
+stap_server_connect-stap-server-connect.o: stap-server-connect.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_server_connect_CFLAGS) $(CFLAGS) -MT stap_server_connect-stap-server-connect.o -MD -MP -MF $(DEPDIR)/stap_server_connect-stap-server-connect.Tpo -c -o stap_server_connect-stap-server-connect.o `test -f 'stap-server-connect.c' || echo '$(srcdir)/'`stap-server-connect.c
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap_server_connect-stap-server-connect.Tpo $(DEPDIR)/stap_server_connect-stap-server-connect.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='stap-server-connect.c' object='stap_server_connect-stap-server-connect.o' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_server_connect_CFLAGS) $(CFLAGS) -c -o stap_server_connect-stap-server-connect.o `test -f 'stap-server-connect.c' || echo '$(srcdir)/'`stap-server-connect.c
+
+stap_server_connect-stap-server-connect.obj: stap-server-connect.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_server_connect_CFLAGS) $(CFLAGS) -MT stap_server_connect-stap-server-connect.obj -MD -MP -MF $(DEPDIR)/stap_server_connect-stap-server-connect.Tpo -c -o stap_server_connect-stap-server-connect.obj `if test -f 'stap-server-connect.c'; then $(CYGPATH_W) 'stap-server-connect.c'; else $(CYGPATH_W) '$(srcdir)/stap-server-connect.c'; fi`
+@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stap_server_connect-stap-server-connect.Tpo $(DEPDIR)/stap_server_connect-stap-server-connect.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='stap-server-connect.c' object='stap_server_connect-stap-server-connect.obj' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stap_server_connect_CFLAGS) $(CFLAGS) -c -o stap_server_connect-stap-server-connect.obj `if test -f 'stap-server-connect.c'; then $(CYGPATH_W) 'stap-server-connect.c'; else $(CYGPATH_W) '$(srcdir)/stap-server-connect.c'; fi`
stapio-stapio.o: runtime/staprun/stapio.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-stapio.o -MD -MP -MF $(DEPDIR)/stapio-stapio.Tpo -c -o stapio-stapio.o `test -f 'runtime/staprun/stapio.c' || echo '$(srcdir)/'`runtime/staprun/stapio.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-stapio.o -MD -MP -MF $(DEPDIR)/stapio-stapio.Tpo -c -o stapio-stapio.o `test -f 'runtime/staprun/stapio.c' || echo '$(srcdir)/'`runtime/staprun/stapio.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-stapio.Tpo $(DEPDIR)/stapio-stapio.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/stapio.c' object='stapio-stapio.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-stapio.o `test -f 'runtime/staprun/stapio.c' || echo '$(srcdir)/'`runtime/staprun/stapio.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-stapio.o `test -f 'runtime/staprun/stapio.c' || echo '$(srcdir)/'`runtime/staprun/stapio.c
stapio-stapio.obj: runtime/staprun/stapio.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-stapio.obj -MD -MP -MF $(DEPDIR)/stapio-stapio.Tpo -c -o stapio-stapio.obj `if test -f 'runtime/staprun/stapio.c'; then $(CYGPATH_W) 'runtime/staprun/stapio.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/stapio.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-stapio.obj -MD -MP -MF $(DEPDIR)/stapio-stapio.Tpo -c -o stapio-stapio.obj `if test -f 'runtime/staprun/stapio.c'; then $(CYGPATH_W) 'runtime/staprun/stapio.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/stapio.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-stapio.Tpo $(DEPDIR)/stapio-stapio.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/stapio.c' object='stapio-stapio.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-stapio.obj `if test -f 'runtime/staprun/stapio.c'; then $(CYGPATH_W) 'runtime/staprun/stapio.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/stapio.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-stapio.obj `if test -f 'runtime/staprun/stapio.c'; then $(CYGPATH_W) 'runtime/staprun/stapio.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/stapio.c'; fi`
stapio-mainloop.o: runtime/staprun/mainloop.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-mainloop.o -MD -MP -MF $(DEPDIR)/stapio-mainloop.Tpo -c -o stapio-mainloop.o `test -f 'runtime/staprun/mainloop.c' || echo '$(srcdir)/'`runtime/staprun/mainloop.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-mainloop.o -MD -MP -MF $(DEPDIR)/stapio-mainloop.Tpo -c -o stapio-mainloop.o `test -f 'runtime/staprun/mainloop.c' || echo '$(srcdir)/'`runtime/staprun/mainloop.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-mainloop.Tpo $(DEPDIR)/stapio-mainloop.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/mainloop.c' object='stapio-mainloop.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-mainloop.o `test -f 'runtime/staprun/mainloop.c' || echo '$(srcdir)/'`runtime/staprun/mainloop.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-mainloop.o `test -f 'runtime/staprun/mainloop.c' || echo '$(srcdir)/'`runtime/staprun/mainloop.c
stapio-mainloop.obj: runtime/staprun/mainloop.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-mainloop.obj -MD -MP -MF $(DEPDIR)/stapio-mainloop.Tpo -c -o stapio-mainloop.obj `if test -f 'runtime/staprun/mainloop.c'; then $(CYGPATH_W) 'runtime/staprun/mainloop.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/mainloop.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-mainloop.obj -MD -MP -MF $(DEPDIR)/stapio-mainloop.Tpo -c -o stapio-mainloop.obj `if test -f 'runtime/staprun/mainloop.c'; then $(CYGPATH_W) 'runtime/staprun/mainloop.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/mainloop.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-mainloop.Tpo $(DEPDIR)/stapio-mainloop.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/mainloop.c' object='stapio-mainloop.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-mainloop.obj `if test -f 'runtime/staprun/mainloop.c'; then $(CYGPATH_W) 'runtime/staprun/mainloop.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/mainloop.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-mainloop.obj `if test -f 'runtime/staprun/mainloop.c'; then $(CYGPATH_W) 'runtime/staprun/mainloop.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/mainloop.c'; fi`
stapio-common.o: runtime/staprun/common.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-common.o -MD -MP -MF $(DEPDIR)/stapio-common.Tpo -c -o stapio-common.o `test -f 'runtime/staprun/common.c' || echo '$(srcdir)/'`runtime/staprun/common.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-common.o -MD -MP -MF $(DEPDIR)/stapio-common.Tpo -c -o stapio-common.o `test -f 'runtime/staprun/common.c' || echo '$(srcdir)/'`runtime/staprun/common.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-common.Tpo $(DEPDIR)/stapio-common.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/common.c' object='stapio-common.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-common.o `test -f 'runtime/staprun/common.c' || echo '$(srcdir)/'`runtime/staprun/common.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-common.o `test -f 'runtime/staprun/common.c' || echo '$(srcdir)/'`runtime/staprun/common.c
stapio-common.obj: runtime/staprun/common.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-common.obj -MD -MP -MF $(DEPDIR)/stapio-common.Tpo -c -o stapio-common.obj `if test -f 'runtime/staprun/common.c'; then $(CYGPATH_W) 'runtime/staprun/common.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/common.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-common.obj -MD -MP -MF $(DEPDIR)/stapio-common.Tpo -c -o stapio-common.obj `if test -f 'runtime/staprun/common.c'; then $(CYGPATH_W) 'runtime/staprun/common.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/common.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-common.Tpo $(DEPDIR)/stapio-common.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/common.c' object='stapio-common.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-common.obj `if test -f 'runtime/staprun/common.c'; then $(CYGPATH_W) 'runtime/staprun/common.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/common.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-common.obj `if test -f 'runtime/staprun/common.c'; then $(CYGPATH_W) 'runtime/staprun/common.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/common.c'; fi`
stapio-ctl.o: runtime/staprun/ctl.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-ctl.o -MD -MP -MF $(DEPDIR)/stapio-ctl.Tpo -c -o stapio-ctl.o `test -f 'runtime/staprun/ctl.c' || echo '$(srcdir)/'`runtime/staprun/ctl.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-ctl.o -MD -MP -MF $(DEPDIR)/stapio-ctl.Tpo -c -o stapio-ctl.o `test -f 'runtime/staprun/ctl.c' || echo '$(srcdir)/'`runtime/staprun/ctl.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-ctl.Tpo $(DEPDIR)/stapio-ctl.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/ctl.c' object='stapio-ctl.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-ctl.o `test -f 'runtime/staprun/ctl.c' || echo '$(srcdir)/'`runtime/staprun/ctl.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-ctl.o `test -f 'runtime/staprun/ctl.c' || echo '$(srcdir)/'`runtime/staprun/ctl.c
stapio-ctl.obj: runtime/staprun/ctl.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-ctl.obj -MD -MP -MF $(DEPDIR)/stapio-ctl.Tpo -c -o stapio-ctl.obj `if test -f 'runtime/staprun/ctl.c'; then $(CYGPATH_W) 'runtime/staprun/ctl.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/ctl.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-ctl.obj -MD -MP -MF $(DEPDIR)/stapio-ctl.Tpo -c -o stapio-ctl.obj `if test -f 'runtime/staprun/ctl.c'; then $(CYGPATH_W) 'runtime/staprun/ctl.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/ctl.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-ctl.Tpo $(DEPDIR)/stapio-ctl.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/ctl.c' object='stapio-ctl.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-ctl.obj `if test -f 'runtime/staprun/ctl.c'; then $(CYGPATH_W) 'runtime/staprun/ctl.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/ctl.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-ctl.obj `if test -f 'runtime/staprun/ctl.c'; then $(CYGPATH_W) 'runtime/staprun/ctl.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/ctl.c'; fi`
stapio-relay.o: runtime/staprun/relay.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay.o -MD -MP -MF $(DEPDIR)/stapio-relay.Tpo -c -o stapio-relay.o `test -f 'runtime/staprun/relay.c' || echo '$(srcdir)/'`runtime/staprun/relay.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay.o -MD -MP -MF $(DEPDIR)/stapio-relay.Tpo -c -o stapio-relay.o `test -f 'runtime/staprun/relay.c' || echo '$(srcdir)/'`runtime/staprun/relay.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-relay.Tpo $(DEPDIR)/stapio-relay.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/relay.c' object='stapio-relay.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay.o `test -f 'runtime/staprun/relay.c' || echo '$(srcdir)/'`runtime/staprun/relay.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay.o `test -f 'runtime/staprun/relay.c' || echo '$(srcdir)/'`runtime/staprun/relay.c
stapio-relay.obj: runtime/staprun/relay.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay.obj -MD -MP -MF $(DEPDIR)/stapio-relay.Tpo -c -o stapio-relay.obj `if test -f 'runtime/staprun/relay.c'; then $(CYGPATH_W) 'runtime/staprun/relay.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay.obj -MD -MP -MF $(DEPDIR)/stapio-relay.Tpo -c -o stapio-relay.obj `if test -f 'runtime/staprun/relay.c'; then $(CYGPATH_W) 'runtime/staprun/relay.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-relay.Tpo $(DEPDIR)/stapio-relay.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/relay.c' object='stapio-relay.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay.obj `if test -f 'runtime/staprun/relay.c'; then $(CYGPATH_W) 'runtime/staprun/relay.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay.obj `if test -f 'runtime/staprun/relay.c'; then $(CYGPATH_W) 'runtime/staprun/relay.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay.c'; fi`
stapio-relay_old.o: runtime/staprun/relay_old.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay_old.o -MD -MP -MF $(DEPDIR)/stapio-relay_old.Tpo -c -o stapio-relay_old.o `test -f 'runtime/staprun/relay_old.c' || echo '$(srcdir)/'`runtime/staprun/relay_old.c
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay_old.o -MD -MP -MF $(DEPDIR)/stapio-relay_old.Tpo -c -o stapio-relay_old.o `test -f 'runtime/staprun/relay_old.c' || echo '$(srcdir)/'`runtime/staprun/relay_old.c
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-relay_old.Tpo $(DEPDIR)/stapio-relay_old.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/relay_old.c' object='stapio-relay_old.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay_old.o `test -f 'runtime/staprun/relay_old.c' || echo '$(srcdir)/'`runtime/staprun/relay_old.c
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay_old.o `test -f 'runtime/staprun/relay_old.c' || echo '$(srcdir)/'`runtime/staprun/relay_old.c
stapio-relay_old.obj: runtime/staprun/relay_old.c
-@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay_old.obj -MD -MP -MF $(DEPDIR)/stapio-relay_old.Tpo -c -o stapio-relay_old.obj `if test -f 'runtime/staprun/relay_old.c'; then $(CYGPATH_W) 'runtime/staprun/relay_old.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay_old.c'; fi`
+@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -MT stapio-relay_old.obj -MD -MP -MF $(DEPDIR)/stapio-relay_old.Tpo -c -o stapio-relay_old.obj `if test -f 'runtime/staprun/relay_old.c'; then $(CYGPATH_W) 'runtime/staprun/relay_old.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay_old.c'; fi`
@am__fastdepCC_TRUE@ mv -f $(DEPDIR)/stapio-relay_old.Tpo $(DEPDIR)/stapio-relay_old.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='runtime/staprun/relay_old.c' object='stapio-relay_old.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(stapio_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay_old.obj `if test -f 'runtime/staprun/relay_old.c'; then $(CYGPATH_W) 'runtime/staprun/relay_old.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay_old.c'; fi`
+@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(stapio_CFLAGS) $(CFLAGS) -c -o stapio-relay_old.obj `if test -f 'runtime/staprun/relay_old.c'; then $(CYGPATH_W) 'runtime/staprun/relay_old.c'; else $(CYGPATH_W) '$(srcdir)/runtime/staprun/relay_old.c'; fi`
staprun-staprun.o: runtime/staprun/staprun.c
@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(staprun_CPPFLAGS) $(CPPFLAGS) $(staprun_CFLAGS) $(CFLAGS) -MT staprun-staprun.o -MD -MP -MF $(DEPDIR)/staprun-staprun.Tpo -c -o staprun-staprun.o `test -f 'runtime/staprun/staprun.c' || echo '$(srcdir)/'`runtime/staprun/staprun.c
@@ -1120,6 +1207,23 @@ uninstall-man8:
echo " rm -f '$(DESTDIR)$(man8dir)/$$inst'"; \
rm -f "$(DESTDIR)$(man8dir)/$$inst"; \
done
+install-oldincludeHEADERS: $(oldinclude_HEADERS)
+ @$(NORMAL_INSTALL)
+ test -z "$(oldincludedir)" || $(MKDIR_P) "$(DESTDIR)$(oldincludedir)"
+ @list='$(oldinclude_HEADERS)'; for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ f=$(am__strip_dir) \
+ echo " $(oldincludeHEADERS_INSTALL) '$$d$$p' '$(DESTDIR)$(oldincludedir)/$$f'"; \
+ $(oldincludeHEADERS_INSTALL) "$$d$$p" "$(DESTDIR)$(oldincludedir)/$$f"; \
+ done
+
+uninstall-oldincludeHEADERS:
+ @$(NORMAL_UNINSTALL)
+ @list='$(oldinclude_HEADERS)'; for p in $$list; do \
+ f=$(am__strip_dir) \
+ echo " rm -f '$(DESTDIR)$(oldincludedir)/$$f'"; \
+ rm -f "$(DESTDIR)$(oldincludedir)/$$f"; \
+ done
# This directory's subdirectories are mostly independent; you can cd
# into them and run `make' without going through this Makefile.
@@ -1253,11 +1357,11 @@ distclean-tags:
check-am: all-am
check: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) check-recursive
-all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(SCRIPTS) $(MANS) config.h \
- all-local
+all-am: Makefile $(LIBRARIES) $(PROGRAMS) $(SCRIPTS) $(MANS) \
+ $(HEADERS) config.h all-local
installdirs: installdirs-recursive
installdirs-am:
- for dir in "$(DESTDIR)$(pkglibdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(pkglibexecdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)"; do \
+ for dir in "$(DESTDIR)$(pkglibdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(pkglibexecdir)" "$(DESTDIR)$(bindir)" "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(man5dir)" "$(DESTDIR)$(man8dir)" "$(DESTDIR)$(oldincludedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: $(BUILT_SOURCES)
@@ -1297,7 +1401,7 @@ distclean: distclean-recursive
-rm -rf ./$(DEPDIR)
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
- distclean-hdr distclean-tags
+ distclean-hdr distclean-local distclean-tags
dvi: dvi-recursive
@@ -1309,7 +1413,8 @@ info: info-recursive
info-am:
-install-data-am: install-data-local install-man
+install-data-am: install-data-local install-man \
+ install-oldincludeHEADERS
install-dvi: install-dvi-recursive
@@ -1351,8 +1456,8 @@ ps: ps-recursive
ps-am:
uninstall-am: uninstall-binPROGRAMS uninstall-binSCRIPTS \
- uninstall-local uninstall-man uninstall-pkglibLIBRARIES \
- uninstall-pkglibexecPROGRAMS
+ uninstall-local uninstall-man uninstall-oldincludeHEADERS \
+ uninstall-pkglibLIBRARIES uninstall-pkglibexecPROGRAMS
uninstall-man: uninstall-man1 uninstall-man5 uninstall-man8
@@ -1365,13 +1470,14 @@ uninstall-man: uninstall-man1 uninstall-man5 uninstall-man8
clean-noinstPROGRAMS clean-pkglibLIBRARIES \
clean-pkglibexecPROGRAMS ctags ctags-recursive distclean \
distclean-compile distclean-generic distclean-hdr \
- distclean-tags dvi dvi-am html html-am info info-am install \
- install-am install-binPROGRAMS install-binSCRIPTS install-data \
- install-data-am install-data-local install-dvi install-dvi-am \
- install-exec install-exec-am install-exec-hook \
- install-exec-local install-html install-html-am install-info \
- install-info-am install-man install-man1 install-man5 \
- install-man8 install-pdf install-pdf-am \
+ distclean-local distclean-tags dvi dvi-am html html-am info \
+ info-am install install-am install-binPROGRAMS \
+ install-binSCRIPTS install-data install-data-am \
+ install-data-local install-dvi install-dvi-am install-exec \
+ install-exec-am install-exec-hook install-exec-local \
+ install-html install-html-am install-info install-info-am \
+ install-man install-man1 install-man5 install-man8 \
+ install-oldincludeHEADERS install-pdf install-pdf-am \
install-pkglibLIBRARIES install-pkglibexecPROGRAMS install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs installdirs-am maintainer-clean \
@@ -1380,7 +1486,8 @@ uninstall-man: uninstall-man1 uninstall-man5 uninstall-man8
uninstall uninstall-am uninstall-binPROGRAMS \
uninstall-binSCRIPTS uninstall-local uninstall-man \
uninstall-man1 uninstall-man5 uninstall-man8 \
- uninstall-pkglibLIBRARIES uninstall-pkglibexecPROGRAMS
+ uninstall-oldincludeHEADERS uninstall-pkglibLIBRARIES \
+ uninstall-pkglibexecPROGRAMS
git_version.stamp:
@if test -f "$(srcdir)/git_version.h"; then \
@@ -1480,6 +1587,9 @@ clean-local:
rm -rf stap.info
rm -rf staplog.so
+distclean-local:
+ rm -rf build-elfutils include-elfutils lib-elfutils
+
uninstall-local:
rm -rf $(DESTDIR)$(pkgdatadir)
rm -rf $(DESTDIR)$(libexecdir)/$(PACKAGE)
@@ -1497,6 +1607,7 @@ uninstall-local:
echo " rm -f '$(SAMPLE_INSTALL_DIR)/$$p'"; \
rm -f "$(SAMPLE_INSTALL_DIR)/$$p"; \
done
+ rm -rf $(DESTDIR)$(sysconfdir)/systemtap
check:
SRCDIR=`cd $(srcdir); pwd`; \
diff --git a/aclocal.m4 b/aclocal.m4
index 0e2027cd..e726a5cc 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -13,12 +13,168 @@
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
-m4_if(AC_AUTOCONF_VERSION, [2.61],,
-[m4_warning([this file was generated for autoconf 2.61.
+m4_if(AC_AUTOCONF_VERSION, [2.63],,
+[m4_warning([this file was generated for autoconf 2.63.
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'.])])
+# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
+#
+# Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
+# PKG_PROG_PKG_CONFIG([MIN-VERSION])
+# ----------------------------------
+AC_DEFUN([PKG_PROG_PKG_CONFIG],
+[m4_pattern_forbid([^_?PKG_[A-Z_]+$])
+m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
+AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl
+if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
+ AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
+fi
+if test -n "$PKG_CONFIG"; then
+ _pkg_min_version=m4_default([$1], [0.9.0])
+ AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
+ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ PKG_CONFIG=""
+ fi
+
+fi[]dnl
+])# PKG_PROG_PKG_CONFIG
+
+# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
+#
+# Check to see whether a particular set of modules exists. Similar
+# to PKG_CHECK_MODULES(), but does not set variables or print errors.
+#
+#
+# Similar to PKG_CHECK_MODULES, make sure that the first instance of
+# this or PKG_CHECK_MODULES is called, or make sure to call
+# PKG_CHECK_EXISTS manually
+# --------------------------------------------------------------
+AC_DEFUN([PKG_CHECK_EXISTS],
+[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
+if test -n "$PKG_CONFIG" && \
+ AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
+ m4_ifval([$2], [$2], [:])
+m4_ifvaln([$3], [else
+ $3])dnl
+fi])
+
+
+# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
+# ---------------------------------------------
+m4_define([_PKG_CONFIG],
+[if test -n "$$1"; then
+ pkg_cv_[]$1="$$1"
+ elif test -n "$PKG_CONFIG"; then
+ PKG_CHECK_EXISTS([$3],
+ [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
+ [pkg_failed=yes])
+ else
+ pkg_failed=untried
+fi[]dnl
+])# _PKG_CONFIG
+
+# _PKG_SHORT_ERRORS_SUPPORTED
+# -----------------------------
+AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED],
+[AC_REQUIRE([PKG_PROG_PKG_CONFIG])
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi[]dnl
+])# _PKG_SHORT_ERRORS_SUPPORTED
+
+
+# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
+# [ACTION-IF-NOT-FOUND])
+#
+#
+# Note that if there is a possibility the first call to
+# PKG_CHECK_MODULES might not happen, you should be sure to include an
+# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
+#
+#
+# --------------------------------------------------------------
+AC_DEFUN([PKG_CHECK_MODULES],
+[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
+AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
+AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
+
+pkg_failed=no
+AC_MSG_CHECKING([for $1])
+
+_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
+_PKG_CONFIG([$1][_LIBS], [libs], [$2])
+
+m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS
+and $1[]_LIBS to avoid the need to call pkg-config.
+See the pkg-config man page for more details.])
+
+if test $pkg_failed = yes; then
+ _PKG_SHORT_ERRORS_SUPPORTED
+ if test $_pkg_short_errors_supported = yes; then
+ $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1`
+ else
+ $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
+
+ ifelse([$4], , [AC_MSG_ERROR(dnl
+[Package requirements ($2) were not met:
+
+$$1_PKG_ERRORS
+
+Consider adjusting the PKG_CONFIG_PATH environment variable if you
+installed software in a non-standard prefix.
+
+_PKG_TEXT
+])],
+ [AC_MSG_RESULT([no])
+ $4])
+elif test $pkg_failed = untried; then
+ ifelse([$4], , [AC_MSG_FAILURE(dnl
+[The pkg-config script could not be found or is too old. Make sure it
+is in your PATH or set the PKG_CONFIG environment variable to the full
+path to pkg-config.
+
+_PKG_TEXT
+
+To get pkg-config, see <http://pkg-config.freedesktop.org/>.])],
+ [$4])
+else
+ $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
+ $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
+ AC_MSG_RESULT([yes])
+ ifelse([$3], , :, [$3])
+fi[]dnl
+])# PKG_CHECK_MODULES
+
# Copyright (C) 2002, 2003, 2005, 2006, 2007 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
diff --git a/buildrun.cxx b/buildrun.cxx
index ece9eda4..c626cf2a 100644
--- a/buildrun.cxx
+++ b/buildrun.cxx
@@ -82,8 +82,11 @@ compile_pass (systemtap_session& s)
if (s.verbose > 6)
redirecterrors = "";
+ // Support O= (or KBUILD_OUTPUT) option
+ o << "_KBUILD_CFLAGS := $(call flags,KBUILD_CFLAGS)" << endl;
+
o << "stap_check_gcc = $(shell " << superverbose << " if $(CC) $(1) -S -o /dev/null -xc /dev/null > /dev/null 2>&1; then echo \"$(1)\"; else echo \"$(2)\"; fi)" << endl;
- o << "stap_check_build = $(shell " << superverbose << " if $(CC) $(KBUILD_CPPFLAGS) $(CPPFLAGS) $(KBUILD_CFLAGS) $(CFLAGS_KERNEL) $(EXTRA_CFLAGS) $(CFLAGS) -DKBUILD_BASENAME=\\\"" << s.module_name << "\\\" -Werror -S -o /dev/null -xc $(1) " << redirecterrors << " ; then echo \"$(2)\"; else echo \"$(3)\"; fi)" << endl;
+ o << "stap_check_build = $(shell " << superverbose << " if $(CC) $(KBUILD_CPPFLAGS) $(CPPFLAGS) $(LINUXINCLUDE) $(_KBUILD_CFLAGS) $(CFLAGS_KERNEL) $(EXTRA_CFLAGS) $(CFLAGS) -DKBUILD_BASENAME=\\\"" << s.module_name << "\\\" -Werror -S -o /dev/null -xc $(1) " << redirecterrors << " ; then echo \"$(2)\"; else echo \"$(3)\"; fi)" << endl;
o << "SYSTEMTAP_RUNTIME = \"" << s.runtime_path << "\"" << endl;
@@ -99,6 +102,10 @@ compile_pass (systemtap_session& s)
// but that path does not exist in an O= build tree.
o << module_cflags << " += -Iinclude2/asm/mach-default" << endl;
+ // NB: don't try
+ // o << module_cflags << " += -Iusr/include" << endl;
+ // since such headers are cleansed of _KERNEL_ pieces that we need
+
o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-hrtimer-rel.c, -DSTAPCONF_HRTIMER_REL,)" << endl;
o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-hrtimer-getset-expires.c, -DSTAPCONF_HRTIMER_GETSET_EXPIRES,)" << endl;
o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-inode-private.c, -DSTAPCONF_INODE_PRIVATE,)" << endl;
@@ -113,6 +120,7 @@ compile_pass (systemtap_session& s)
o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-oneachcpu-retry.c, -DSTAPCONF_ONEACHCPU_RETRY,)" << endl;
o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-dpath-path.c, -DSTAPCONF_DPATH_PATH,)" << endl;
o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-synchronize-sched.c, -DSTAPCONF_SYNCHRONIZE_SCHED,)" << endl;
+ o << module_cflags << " += $(call stap_check_build, $(SYSTEMTAP_RUNTIME)/autoconf-task-uid.c, -DSTAPCONF_TASK_UID,)" << endl;
#if 0
/* NB: For now, the performance hit of probe_kernel_read/write (vs. our
diff --git a/config.in b/config.in
index 0f5677e9..74b5a738 100644
--- a/config.in
+++ b/config.in
@@ -9,6 +9,9 @@
/* Define to 1 if you have the <crash/defs.h> header file. */
#undef HAVE_CRASH_DEFS_H
+/* Define to 1 if you have the <elfutils/version.h> header file. */
+#undef HAVE_ELFUTILS_VERSION_H
+
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
@@ -72,6 +75,9 @@
/* Define to 1 if the C compiler supports function prototypes. */
#undef PROTOTYPES
+/* configure prefix location */
+#undef STAP_PREFIX
+
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
diff --git a/configure b/configure
index 8fe89282..6a4aff50 100755
--- a/configure
+++ b/configure
@@ -1,11 +1,11 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for systemtap 0.8.
+# Generated by GNU Autoconf 2.63 for systemtap 0.8.
#
# Report bugs to <systemtap@sources.redhat.com>.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+# 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
## --------------------- ##
@@ -17,7 +17,7 @@ DUALCASE=1; export DUALCASE # for MKS sh
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
NULLCMD=:
- # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # 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
@@ -39,17 +39,45 @@ as_cr_Letters=$as_cr_letters$as_cr_LETTERS
as_cr_digits='0123456789'
as_cr_alnum=$as_cr_Letters$as_cr_digits
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
+as_nl='
+'
+export as_nl
+# Printing a long string crashes Solaris 7 /usr/bin/printf.
+as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
+if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
+ as_echo='printf %s\n'
+ as_echo_n='printf %s'
+else
+ if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
+ as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
+ as_echo_n='/usr/ucb/echo -n'
else
- PATH_SEPARATOR=:
+ as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
+ as_echo_n_body='eval
+ arg=$1;
+ case $arg in
+ *"$as_nl"*)
+ expr "X$arg" : "X\\(.*\\)$as_nl";
+ arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
+ esac;
+ expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
+ '
+ export as_echo_n_body
+ as_echo_n='sh -c $as_echo_n_body as_echo'
fi
- rm -f conf$$.sh
+ export as_echo_body
+ as_echo='sh -c $as_echo_body as_echo'
+fi
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+ PATH_SEPARATOR=:
+ (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
+ (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
+ PATH_SEPARATOR=';'
+ }
fi
# Support unset when possible.
@@ -65,8 +93,6 @@ fi
# there to prevent editors from complaining about space-tab.
# (If _AS_PATH_WALK were called with IFS unset, it would disable word
# splitting by setting IFS to empty value.)
-as_nl='
-'
IFS=" "" $as_nl"
# Find who we are. Look in the path if we contain no directory separator.
@@ -89,7 +115,7 @@ if test "x$as_myself" = x; then
as_myself=$0
fi
if test ! -f "$as_myself"; then
- echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+ $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
{ (exit 1); exit 1; }
fi
@@ -102,17 +128,10 @@ PS2='> '
PS4='+ '
# NLS nuisances.
-for as_var in \
- LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
- LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
- LC_TELEPHONE LC_TIME
-do
- if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
- eval $as_var=C; export $as_var
- else
- ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
- fi
-done
+LC_ALL=C
+export LC_ALL
+LANGUAGE=C
+export LANGUAGE
# Required to use basename.
if expr a : '\(a\)' >/dev/null 2>&1 &&
@@ -134,7 +153,7 @@ as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
X"$0" : 'X\(//\)$' \| \
X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X/"$0" |
+$as_echo X/"$0" |
sed '/^.*\/\([^/][^/]*\)\/*$/{
s//\1/
q
@@ -160,7 +179,7 @@ else
as_have_required=no
fi
- if test $as_have_required = yes && (eval ":
+ if test $as_have_required = yes && (eval ":
(as_func_return () {
(exit \$1)
}
@@ -242,7 +261,7 @@ IFS=$as_save_IFS
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
NULLCMD=:
- # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # 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
@@ -263,7 +282,7 @@ _ASEOF
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
NULLCMD=:
- # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # 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
@@ -343,10 +362,10 @@ fi
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+"$@"}
+ do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
+ done
+ export CONFIG_SHELL
+ exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
fi
@@ -415,9 +434,10 @@ fi
test \$exitcode = 0") || {
echo No shell found that supports shell functions.
- echo Please tell autoconf@gnu.org about your system,
- echo including any error possibly output before this
- echo message
+ 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.
}
@@ -453,7 +473,7 @@ test \$exitcode = 0") || {
s/-\n.*//
' >$as_me.lineno &&
chmod +x "$as_me.lineno" ||
- { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
+ { $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
@@ -481,7 +501,6 @@ case `echo -n x` in
*)
ECHO_N='-n';;
esac
-
if expr a : '\(a\)' >/dev/null 2>&1 &&
test "X`expr 00001 : '.*\(...\)'`" = X001; then
as_expr=expr
@@ -494,19 +513,22 @@ if test -d conf$$.dir; then
rm -f conf$$.dir/conf$$.file
else
rm -f conf$$.dir
- mkdir conf$$.dir
-fi
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -p'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+ mkdir conf$$.dir 2>/dev/null
+fi
+if (echo >conf$$.file) 2>/dev/null; then
+ if ln -s conf$$.file conf$$ 2>/dev/null; then
+ as_ln_s='ln -s'
+ # ... but there are two gotchas:
+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+ # In both cases, we have to default to `cp -p'.
+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+ as_ln_s='cp -p'
+ elif ln conf$$.file conf$$ 2>/dev/null; then
+ as_ln_s=ln
+ else
as_ln_s='cp -p'
-elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
+ fi
else
as_ln_s='cp -p'
fi
@@ -531,10 +553,10 @@ else
as_test_x='
eval sh -c '\''
if test -d "$1"; then
- test -d "$1/.";
+ test -d "$1/.";
else
case $1 in
- -*)set "./$1";;
+ -*)set "./$1";;
esac;
case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
???[sx]*):;;*)false;;esac;fi
@@ -614,119 +636,148 @@ ac_includes_default="\
# include <unistd.h>
#endif"
-ac_subst_vars='SHELL
-PATH_SEPARATOR
-PACKAGE_NAME
-PACKAGE_TARNAME
-PACKAGE_VERSION
-PACKAGE_STRING
-PACKAGE_BUGREPORT
-exec_prefix
-prefix
-program_transform_name
-bindir
-sbindir
-libexecdir
-datarootdir
-datadir
-sysconfdir
-sharedstatedir
-localstatedir
-includedir
-oldincludedir
-docdir
-infodir
-htmldir
-dvidir
-pdfdir
-psdir
-libdir
-localedir
-mandir
-DEFS
-ECHO_C
-ECHO_N
-ECHO_T
-LIBS
-build_alias
-host_alias
-target_alias
-INSTALL_PROGRAM
-INSTALL_SCRIPT
-INSTALL_DATA
-am__isrc
-CYGPATH_W
-PACKAGE
-VERSION
-ACLOCAL
-AUTOCONF
-AUTOMAKE
-AUTOHEADER
-MAKEINFO
-install_sh
-STRIP
-INSTALL_STRIP_PROGRAM
-mkdir_p
-AWK
-SET_MAKE
-am__leading_dot
-AMTAR
-am__tar
-am__untar
-MAINTAINER_MODE_TRUE
-MAINTAINER_MODE_FALSE
-MAINT
-LN_S
-CC
-CFLAGS
-LDFLAGS
-CPPFLAGS
-ac_ct_CC
-EXEEXT
-OBJEXT
-DEPDIR
-am__include
-am__quote
-AMDEP_TRUE
-AMDEP_FALSE
-AMDEPBACKSLASH
-CCDEPMODE
-am__fastdepCC_TRUE
-am__fastdepCC_FALSE
-CXX
-CXXFLAGS
-ac_ct_CXX
-CXXDEPMODE
-am__fastdepCXX_TRUE
-am__fastdepCXX_FALSE
-CPP
-GREP
-EGREP
-U
-ANSI2KNR
-RANLIB
-PIELDFLAGS
-sqlite3_LIBS
-staplog_CPPFLAGS
-BUILD_CRASHMOD_TRUE
-BUILD_CRASHMOD_FALSE
-have_latex
-have_dvips
-have_ps2pdf
-have_latex2html
-BUILD_DOCS_TRUE
-BUILD_DOCS_FALSE
-BUILD_ELFUTILS_TRUE
-BUILD_ELFUTILS_FALSE
-elfutils_abs_srcdir
-stap_LIBS
-DATE
-PROCFLAGS
-CXXCPP
-subdirs
+enable_option_checking=no
+ac_subst_vars='LTLIBOBJS
LIBOBJS
-LTLIBOBJS'
+subdirs
+CXXCPP
+PROCFLAGS
+DATE
+stap_LIBS
+elfutils_abs_srcdir
+BUILD_ELFUTILS_FALSE
+BUILD_ELFUTILS_TRUE
+BUILD_SERVER_FALSE
+BUILD_SERVER_TRUE
+nspr_LIBS
+nspr_CFLAGS
+nss_LIBS
+nss_CFLAGS
+PKG_CONFIG
+BUILD_REFDOCS_FALSE
+BUILD_REFDOCS_TRUE
+have_xmlto
+BUILD_DOCS_FALSE
+BUILD_DOCS_TRUE
+have_latex2html
+have_ps2pdf
+have_dvips
+have_latex
+BUILD_CRASHMOD_FALSE
+BUILD_CRASHMOD_TRUE
+staplog_CPPFLAGS
+sqlite3_LIBS
+PIECXXFLAGS
+PIECFLAGS
+PIELDFLAGS
+RANLIB
+ANSI2KNR
+U
+EGREP
+GREP
+CPP
+am__fastdepCXX_FALSE
+am__fastdepCXX_TRUE
+CXXDEPMODE
+ac_ct_CXX
+CXXFLAGS
+CXX
+am__fastdepCC_FALSE
+am__fastdepCC_TRUE
+CCDEPMODE
+AMDEPBACKSLASH
+AMDEP_FALSE
+AMDEP_TRUE
+am__quote
+am__include
+DEPDIR
+OBJEXT
+EXEEXT
+ac_ct_CC
+CPPFLAGS
+LDFLAGS
+CFLAGS
+CC
+LN_S
+MAINT
+MAINTAINER_MODE_FALSE
+MAINTAINER_MODE_TRUE
+am__untar
+am__tar
+AMTAR
+am__leading_dot
+SET_MAKE
+AWK
+mkdir_p
+MKDIR_P
+INSTALL_STRIP_PROGRAM
+STRIP
+install_sh
+MAKEINFO
+AUTOHEADER
+AUTOMAKE
+AUTOCONF
+ACLOCAL
+VERSION
+PACKAGE
+CYGPATH_W
+am__isrc
+INSTALL_DATA
+INSTALL_SCRIPT
+INSTALL_PROGRAM
+target_alias
+host_alias
+build_alias
+LIBS
+ECHO_T
+ECHO_N
+ECHO_C
+DEFS
+mandir
+localedir
+libdir
+psdir
+pdfdir
+dvidir
+htmldir
+infodir
+docdir
+oldincludedir
+includedir
+localstatedir
+sharedstatedir
+sysconfdir
+datadir
+datarootdir
+libexecdir
+sbindir
+bindir
+program_transform_name
+prefix
+exec_prefix
+PACKAGE_BUGREPORT
+PACKAGE_STRING
+PACKAGE_VERSION
+PACKAGE_TARNAME
+PACKAGE_NAME
+PATH_SEPARATOR
+SHELL'
ac_subst_files=''
+ac_user_opts='
+enable_option_checking
+enable_maintainer_mode
+enable_dependency_tracking
+enable_perfmon
+enable_prologues
+enable_ssp
+enable_pie
+enable_sqlite
+enable_crash
+enable_docs
+enable_refdocs
+enable_server
+with_elfutils
+'
ac_precious_vars='build_alias
host_alias
target_alias
@@ -739,12 +790,19 @@ CXX
CXXFLAGS
CCC
CPP
+PKG_CONFIG
+nss_CFLAGS
+nss_LIBS
+nspr_CFLAGS
+nspr_LIBS
CXXCPP'
ac_subdirs_all='testsuite'
# Initialize some variables set by options.
ac_init_help=
ac_init_version=false
+ac_unrecognized_opts=
+ac_unrecognized_sep=
# The variables have the same names as the options, with
# dashes changed to underlines.
cache_file=/dev/null
@@ -843,13 +901,21 @@ do
datarootdir=$ac_optarg ;;
-disable-* | --disable-*)
- ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
+ ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid feature name: $ac_feature" >&2
+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+ { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
{ (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
- eval enable_$ac_feature=no ;;
+ ac_useropt_orig=$ac_useropt
+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ case $ac_user_opts in
+ *"
+"enable_$ac_useropt"
+"*) ;;
+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
+ ac_unrecognized_sep=', ';;
+ esac
+ eval enable_$ac_useropt=no ;;
-docdir | --docdir | --docdi | --doc | --do)
ac_prev=docdir ;;
@@ -862,13 +928,21 @@ do
dvidir=$ac_optarg ;;
-enable-* | --enable-*)
- ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
+ ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid feature name: $ac_feature" >&2
+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+ { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
{ (exit 1); exit 1; }; }
- ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
- eval enable_$ac_feature=\$ac_optarg ;;
+ ac_useropt_orig=$ac_useropt
+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ case $ac_user_opts in
+ *"
+"enable_$ac_useropt"
+"*) ;;
+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
+ ac_unrecognized_sep=', ';;
+ esac
+ eval enable_$ac_useropt=\$ac_optarg ;;
-exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
| --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
@@ -1059,22 +1133,38 @@ do
ac_init_version=: ;;
-with-* | --with-*)
- ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
+ ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid package name: $ac_package" >&2
+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+ { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
{ (exit 1); exit 1; }; }
- ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
- eval with_$ac_package=\$ac_optarg ;;
+ ac_useropt_orig=$ac_useropt
+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ case $ac_user_opts in
+ *"
+"with_$ac_useropt"
+"*) ;;
+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
+ ac_unrecognized_sep=', ';;
+ esac
+ eval with_$ac_useropt=\$ac_optarg ;;
-without-* | --without-*)
- ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
+ ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
# Reject names that are not valid shell variable names.
- expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid package name: $ac_package" >&2
+ expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+ { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
{ (exit 1); exit 1; }; }
- ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
- eval with_$ac_package=no ;;
+ ac_useropt_orig=$ac_useropt
+ ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+ case $ac_user_opts in
+ *"
+"with_$ac_useropt"
+"*) ;;
+ *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
+ ac_unrecognized_sep=', ';;
+ esac
+ eval with_$ac_useropt=no ;;
--x)
# Obsolete; use --with-x.
@@ -1094,7 +1184,7 @@ do
| --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
x_libraries=$ac_optarg ;;
- -*) { echo "$as_me: error: unrecognized option: $ac_option
+ -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
Try \`$0 --help' for more information." >&2
{ (exit 1); exit 1; }; }
;;
@@ -1103,16 +1193,16 @@ Try \`$0 --help' for more information." >&2
ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
# Reject names that are not valid shell variable names.
expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
- { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
+ { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
{ (exit 1); exit 1; }; }
eval $ac_envvar=\$ac_optarg
export $ac_envvar ;;
*)
# FIXME: should be removed in autoconf 3.0.
- echo "$as_me: WARNING: you should use --build, --host, --target" >&2
+ $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- echo "$as_me: WARNING: invalid host type: $ac_option" >&2
+ $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
: ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
;;
@@ -1121,22 +1211,38 @@ done
if test -n "$ac_prev"; then
ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- { echo "$as_me: error: missing argument to $ac_option" >&2
+ { $as_echo "$as_me: error: missing argument to $ac_option" >&2
{ (exit 1); exit 1; }; }
fi
-# Be sure to have absolute directory names.
+if test -n "$ac_unrecognized_opts"; then
+ case $enable_option_checking in
+ no) ;;
+ fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
+ { (exit 1); exit 1; }; } ;;
+ *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
+ esac
+fi
+
+# Check all directory arguments for consistency.
for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
datadir sysconfdir sharedstatedir localstatedir includedir \
oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
libdir localedir mandir
do
eval ac_val=\$$ac_var
+ # Remove trailing slashes.
+ case $ac_val in
+ */ )
+ ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
+ eval $ac_var=\$ac_val;;
+ esac
+ # Be sure to have absolute directory names.
case $ac_val in
[\\/$]* | ?:[\\/]* ) continue;;
NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
esac
- { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
+ { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
{ (exit 1); exit 1; }; }
done
@@ -1151,7 +1257,7 @@ target=$target_alias
if test "x$host_alias" != x; then
if test "x$build_alias" = x; then
cross_compiling=maybe
- echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
+ $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
@@ -1167,10 +1273,10 @@ 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 .` ||
- { echo "$as_me: error: Working directory cannot be determined" >&2
+ { $as_echo "$as_me: error: working directory cannot be determined" >&2
{ (exit 1); exit 1; }; }
test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- { echo "$as_me: error: pwd does not report name of working directory" >&2
+ { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
{ (exit 1); exit 1; }; }
@@ -1178,12 +1284,12 @@ test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
if test -z "$srcdir"; then
ac_srcdir_defaulted=yes
# Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$0" ||
-$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$0" : 'X\(//\)[^/]' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$0" |
+ ac_confdir=`$as_dirname -- "$as_myself" ||
+$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+ X"$as_myself" : 'X\(//\)[^/]' \| \
+ X"$as_myself" : 'X\(//\)$' \| \
+ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X"$as_myself" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -1210,12 +1316,12 @@ else
fi
if test ! -r "$srcdir/$ac_unique_file"; then
test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
+ { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
{ (exit 1); exit 1; }; }
fi
ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
+ cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
{ (exit 1); exit 1; }; }
pwd)`
# When building in place, set srcdir=.
@@ -1264,9 +1370,9 @@ Configuration:
Installation directories:
--prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
+ [$ac_default_prefix]
--exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
+ [PREFIX]
By default, \`make install' will install all the files in
\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
@@ -1276,25 +1382,25 @@ for instance \`--prefix=\$HOME'.
For better control, use the options below.
Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/systemtap]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
+ --bindir=DIR user executables [EPREFIX/bin]
+ --sbindir=DIR system admin executables [EPREFIX/sbin]
+ --libexecdir=DIR program executables [EPREFIX/libexec]
+ --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
+ --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
+ --localstatedir=DIR modifiable single-machine data [PREFIX/var]
+ --libdir=DIR object code libraries [EPREFIX/lib]
+ --includedir=DIR C header files [PREFIX/include]
+ --oldincludedir=DIR C header files for non-gcc [/usr/include]
+ --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
+ --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
+ --infodir=DIR info documentation [DATAROOTDIR/info]
+ --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
+ --mandir=DIR man documentation [DATAROOTDIR/man]
+ --docdir=DIR documentation root [DATAROOTDIR/doc/systemtap]
+ --htmldir=DIR html documentation [DOCDIR]
+ --dvidir=DIR dvi documentation [DOCDIR]
+ --pdfdir=DIR pdf documentation [DOCDIR]
+ --psdir=DIR ps documentation [DOCDIR]
_ACEOF
cat <<\_ACEOF
@@ -1313,6 +1419,7 @@ if test -n "$ac_init_help"; then
cat <<\_ACEOF
Optional Features:
+ --disable-option-checking ignore unrecognized --enable/--with options
--disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
--enable-FEATURE[=ARG] include FEATURE [ARG=yes]
--enable-maintainer-mode enable make rules and dependencies not useful
@@ -1335,6 +1442,10 @@ Optional Features:
location).
--enable-docs enable building documentation (default on if latex
etc. found).
+ --enable-refdocs enable building reference documentation (default on
+ if xmlto etc. found and other documentation built).
+ --enable-server enable building of stap-server/client (default on if
+ nss etc. found).
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
@@ -1353,6 +1464,11 @@ Some influential environment variables:
CXX C++ compiler command
CXXFLAGS C++ compiler flags
CPP C preprocessor
+ PKG_CONFIG path to pkg-config utility
+ nss_CFLAGS C compiler flags for nss, overriding pkg-config
+ nss_LIBS linker flags for nss, overriding pkg-config
+ nspr_CFLAGS C compiler flags for nspr, overriding pkg-config
+ nspr_LIBS linker flags for nspr, overriding pkg-config
CXXCPP C++ preprocessor
Use these variables to override the choices made by `configure' or to help
@@ -1366,15 +1482,17 @@ fi
if test "$ac_init_help" = "recursive"; then
# If there are subdirs, report their specific --help.
for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" || continue
+ test -d "$ac_dir" ||
+ { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
+ continue
ac_builddir=.
case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
- ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
# A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
case $ac_top_builddir_sub in
"") ac_top_builddir_sub=. ac_top_build_prefix= ;;
*) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
@@ -1410,7 +1528,7 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
echo &&
$SHELL "$ac_srcdir/configure" --help=recursive
else
- echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
+ $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
fi || ac_status=$?
cd "$ac_pwd" || { ac_status=$?; break; }
done
@@ -1420,10 +1538,10 @@ test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
systemtap configure 0.8
-generated by GNU Autoconf 2.61
+generated by GNU Autoconf 2.63
Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
-2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
@@ -1434,7 +1552,7 @@ This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by systemtap $as_me 0.8, which was
-generated by GNU Autoconf 2.61. Invocation command line was
+generated by GNU Autoconf 2.63. Invocation command line was
$ $0 $@
@@ -1470,7 +1588,7 @@ for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
- echo "PATH: $as_dir"
+ $as_echo "PATH: $as_dir"
done
IFS=$as_save_IFS
@@ -1505,7 +1623,7 @@ do
| -silent | --silent | --silen | --sile | --sil)
continue ;;
*\'*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
esac
case $ac_pass in
1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
@@ -1557,11 +1675,12 @@ _ASBOX
case $ac_val in #(
*${as_nl}*)
case $ac_var in #(
- *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
-echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
+ *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
esac
case $ac_var in #(
_ | IFS | as_nl) ;; #(
+ BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
*) $as_unset $ac_var ;;
esac ;;
esac
@@ -1591,9 +1710,9 @@ _ASBOX
do
eval ac_val=\$$ac_var
case $ac_val in
- *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+ *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
esac
- echo "$ac_var='\''$ac_val'\''"
+ $as_echo "$ac_var='\''$ac_val'\''"
done | sort
echo
@@ -1608,9 +1727,9 @@ _ASBOX
do
eval ac_val=\$$ac_var
case $ac_val in
- *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+ *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
esac
- echo "$ac_var='\''$ac_val'\''"
+ $as_echo "$ac_var='\''$ac_val'\''"
done | sort
echo
fi
@@ -1626,8 +1745,8 @@ _ASBOX
echo
fi
test "$ac_signal" != 0 &&
- echo "$as_me: caught signal $ac_signal"
- echo "$as_me: exit $exit_status"
+ $as_echo "$as_me: caught signal $ac_signal"
+ $as_echo "$as_me: exit $exit_status"
} >&5
rm -f core *.core core.conftest.* &&
rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
@@ -1669,21 +1788,24 @@ _ACEOF
# Let the site file select an alternate cache file if it wants to.
-# Prefer explicitly selected file to automatically selected ones.
+# Prefer an explicitly selected file to automatically selected ones.
+ac_site_file1=NONE
+ac_site_file2=NONE
if test -n "$CONFIG_SITE"; then
- set x "$CONFIG_SITE"
+ ac_site_file1=$CONFIG_SITE
elif test "x$prefix" != xNONE; then
- set x "$prefix/share/config.site" "$prefix/etc/config.site"
+ ac_site_file1=$prefix/share/config.site
+ ac_site_file2=$prefix/etc/config.site
else
- set x "$ac_default_prefix/share/config.site" \
- "$ac_default_prefix/etc/config.site"
+ ac_site_file1=$ac_default_prefix/share/config.site
+ ac_site_file2=$ac_default_prefix/etc/config.site
fi
-shift
-for ac_site_file
+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
- { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
-echo "$as_me: loading site script $ac_site_file" >&6;}
+ { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
+$as_echo "$as_me: loading site script $ac_site_file" >&6;}
sed 's/^/| /' "$ac_site_file" >&5
. "$ac_site_file"
fi
@@ -1693,16 +1815,16 @@ if test -r "$cache_file"; then
# Some versions of bash will fail to source /dev/null (special
# files actually), so we avoid doing that.
if test -f "$cache_file"; then
- { echo "$as_me:$LINENO: loading cache $cache_file" >&5
-echo "$as_me: loading cache $cache_file" >&6;}
+ { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
+$as_echo "$as_me: loading cache $cache_file" >&6;}
case $cache_file in
[\\/]* | ?:[\\/]* ) . "$cache_file";;
*) . "./$cache_file";;
esac
fi
else
- { echo "$as_me:$LINENO: creating cache $cache_file" >&5
-echo "$as_me: creating cache $cache_file" >&6;}
+ { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
+$as_echo "$as_me: creating cache $cache_file" >&6;}
>$cache_file
fi
@@ -1716,29 +1838,38 @@ 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,)
- { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
+ { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
+$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
ac_cache_corrupted=: ;;
,set)
- { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
+ { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
+$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
ac_cache_corrupted=: ;;
,);;
*)
if test "x$ac_old_val" != "x$ac_new_val"; then
- { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
-echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
-echo "$as_me: former value: $ac_old_val" >&2;}
- { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
-echo "$as_me: current value: $ac_new_val" >&2;}
- ac_cache_corrupted=:
+ # differences in whitespace do not lead to failure.
+ ac_old_val_w=`echo x $ac_old_val`
+ ac_new_val_w=`echo x $ac_new_val`
+ if test "$ac_old_val_w" != "$ac_new_val_w"; then
+ { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
+$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
+ ac_cache_corrupted=:
+ else
+ { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
+$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
+ eval $ac_var=\$ac_old_val
+ fi
+ { $as_echo "$as_me:$LINENO: former value: \`$ac_old_val'" >&5
+$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
+ { $as_echo "$as_me:$LINENO: current value: \`$ac_new_val'" >&5
+$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
fi;;
esac
# Pass precious variables to config.status.
if test "$ac_new_set" = set; then
case $ac_new_val in
- *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
+ *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
*) ac_arg=$ac_var=$ac_new_val ;;
esac
case " $ac_configure_args " in
@@ -1748,10 +1879,12 @@ echo "$as_me: current value: $ac_new_val" >&2;}
fi
done
if $ac_cache_corrupted; then
- { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
-echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
-echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
+ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+ { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
+$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
+$as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -1807,8 +1940,8 @@ for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
fi
done
if test -z "$ac_aux_dir"; then
- { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
-echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
+$as_echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -1834,11 +1967,12 @@ ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# OS/2's system install, which has a completely different semantic
# ./install, which can be erroneously created by make from ./install.sh.
-{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
-echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
+# Reject install programs that cannot install multiple files.
+{ $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
+$as_echo_n "checking for a BSD-compatible install... " >&6; }
if test -z "$INSTALL"; then
if test "${ac_cv_path_install+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
@@ -1867,17 +2001,29 @@ case $as_dir/ in
# program-specific install script used by HP pwplus--don't use.
:
else
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
+ rm -rf conftest.one conftest.two conftest.dir
+ echo one > conftest.one
+ echo two > conftest.two
+ mkdir conftest.dir
+ if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
+ test -s conftest.one && test -s conftest.two &&
+ test -s conftest.dir/conftest.one &&
+ test -s conftest.dir/conftest.two
+ then
+ ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
+ break 3
+ fi
fi
fi
done
done
;;
esac
+
done
IFS=$as_save_IFS
+rm -rf conftest.one conftest.two conftest.dir
fi
if test "${ac_cv_path_install+set}" = set; then
@@ -1890,8 +2036,8 @@ fi
INSTALL=$ac_install_sh
fi
fi
-{ echo "$as_me:$LINENO: result: $INSTALL" >&5
-echo "${ECHO_T}$INSTALL" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
+$as_echo "$INSTALL" >&6; }
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
@@ -1901,8 +2047,8 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-{ echo "$as_me:$LINENO: checking whether build environment is sane" >&5
-echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether build environment is sane" >&5
+$as_echo_n "checking whether build environment is sane... " >&6; }
# Just in case
sleep 1
echo timestamp > conftest.file
@@ -1925,9 +2071,9 @@ 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".
- { { echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken
+ { { $as_echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken
alias in your environment" >&5
-echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken
+$as_echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken
alias in your environment" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -1938,26 +2084,23 @@ then
# Ok.
:
else
- { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
+ { { $as_echo "$as_me:$LINENO: error: newly created file is older than distributed files!
Check your system clock" >&5
-echo "$as_me: error: newly created file is older than distributed files!
+$as_echo "$as_me: error: newly created file is older than distributed files!
Check your system clock" >&2;}
{ (exit 1); exit 1; }; }
fi
-{ echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+{ $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
test "$program_prefix" != NONE &&
program_transform_name="s&^&$program_prefix&;$program_transform_name"
# Use a double $ so make ignores it.
test "$program_suffix" != NONE &&
program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $. echo might interpret backslashes.
+# Double any \ or $.
# By default was `s,x,x', remove it if useless.
-cat <<\_ACEOF >conftest.sed
-s/[\\$]/&&/g;s/;s,x,x,$//
-_ACEOF
-program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
-rm -f conftest.sed
+ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
+program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
# expand $ac_aux_dir to an absolute path
am_aux_dir=`cd $ac_aux_dir && pwd`
@@ -1968,15 +2111,15 @@ if eval "$MISSING --run true"; then
am_missing_run="$MISSING --run "
else
am_missing_run=
- { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
-echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
+$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
fi
-{ echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
-echo $ECHO_N "checking for a thread-safe mkdir -p... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
@@ -2011,8 +2154,8 @@ fi
MKDIR_P="$ac_install_sh -d"
fi
fi
-{ echo "$as_me:$LINENO: result: $MKDIR_P" >&5
-echo "${ECHO_T}$MKDIR_P" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
+$as_echo "$MKDIR_P" >&6; }
mkdir_p="$MKDIR_P"
case $mkdir_p in
@@ -2024,10 +2167,10 @@ for ac_prog in gawk mawk nawk awk
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$AWK"; then
ac_cv_prog_AWK="$AWK" # Let the user override the test.
@@ -2040,7 +2183,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2051,22 +2194,23 @@ fi
fi
AWK=$ac_cv_prog_AWK
if test -n "$AWK"; then
- { echo "$as_me:$LINENO: result: $AWK" >&5
-echo "${ECHO_T}$AWK" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $AWK" >&5
+$as_echo "$AWK" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
test -n "$AWK" && break
done
-{ echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; }
-set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
+{ $as_echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
+$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
+set x ${MAKE-make}
+ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.make <<\_ACEOF
SHELL = /bin/sh
@@ -2083,12 +2227,12 @@ esac
rm -f conftest.make
fi
if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
SET_MAKE=
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
SET_MAKE="MAKE=${MAKE-make}"
fi
@@ -2107,8 +2251,8 @@ 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
- { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
-echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
+$as_echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
{ (exit 1); exit 1; }; }
fi
fi
@@ -2163,10 +2307,10 @@ if test "$cross_compiling" != no; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$STRIP"; then
ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
@@ -2179,7 +2323,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2190,11 +2334,11 @@ fi
fi
STRIP=$ac_cv_prog_STRIP
if test -n "$STRIP"; then
- { echo "$as_me:$LINENO: result: $STRIP" >&5
-echo "${ECHO_T}$STRIP" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
+$as_echo "$STRIP" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -2203,10 +2347,10 @@ if test -z "$ac_cv_prog_STRIP"; then
ac_ct_STRIP=$STRIP
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $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.
@@ -2219,7 +2363,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2230,11 +2374,11 @@ fi
fi
ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
if test -n "$ac_ct_STRIP"; then
- { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
-echo "${ECHO_T}$ac_ct_STRIP" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
+$as_echo "$ac_ct_STRIP" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
if test "x$ac_ct_STRIP" = x; then
@@ -2242,12 +2386,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+{ $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
@@ -2271,8 +2411,8 @@ am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
-{ echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
-echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
+$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
# Check whether --enable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
@@ -2280,8 +2420,8 @@ else
USE_MAINTAINER_MODE=no
fi
- { echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
-echo "${ECHO_T}$USE_MAINTAINER_MODE" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
+$as_echo "$USE_MAINTAINER_MODE" >&6; }
if test $USE_MAINTAINER_MODE = yes; then
MAINTAINER_MODE_TRUE=
MAINTAINER_MODE_FALSE='#'
@@ -2300,15 +2440,15 @@ case $mkdir_p in
*/*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
esac
-{ echo "$as_me:$LINENO: checking whether ln -s works" >&5
-echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&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
- { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
else
- { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
-echo "${ECHO_T}no, using $LN_S" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
+$as_echo "no, using $LN_S" >&6; }
fi
ac_ext=c
@@ -2319,10 +2459,10 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -2335,7 +2475,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2346,11 +2486,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -2359,10 +2499,10 @@ if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
@@ -2375,7 +2515,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2386,11 +2526,11 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+$as_echo "$ac_ct_CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
if test "x$ac_ct_CC" = x; then
@@ -2398,12 +2538,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
@@ -2416,10 +2552,10 @@ if test -z "$CC"; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -2432,7 +2568,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2443,11 +2579,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -2456,10 +2592,10 @@ fi
if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -2477,7 +2613,7 @@ do
continue
fi
ac_cv_prog_CC="cc"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2500,11 +2636,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -2515,10 +2651,10 @@ 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
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -2531,7 +2667,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2542,11 +2678,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -2559,10 +2695,10 @@ 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
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
@@ -2575,7 +2711,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -2586,11 +2722,11 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+$as_echo "$ac_ct_CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -2602,12 +2738,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
@@ -2617,44 +2749,50 @@ fi
fi
-test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
+test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
See \`config.log' for more details." >&5
-echo "$as_me: error: no acceptable C compiler found in \$PATH
+$as_echo "$as_me: error: no acceptable C compiler found in \$PATH
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ { (exit 1); exit 1; }; }; }
# Provide some information about the compiler.
-echo "$as_me:$LINENO: checking for C compiler version" >&5
-ac_compiler=`set X $ac_compile; echo $2`
+$as_echo "$as_me:$LINENO: checking for C compiler version" >&5
+set X $ac_compile
+ac_compiler=$2
{ (ac_try="$ac_compiler --version >&5"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
cat >conftest.$ac_ext <<_ACEOF
@@ -2673,27 +2811,22 @@ main ()
}
_ACEOF
ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.exe b.out"
+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.
-{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
-echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
-ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-#
-# List of possible output files, starting from the most likely.
-# The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
-# only as a last resort. b.out is created by i960 compilers.
-ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
-#
-# The IRIX 6 linker writes into existing files which may not be
-# executable, retaining their permissions. Remove them first so a
-# subsequent execution test works.
+{ $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
+$as_echo_n "checking for C compiler default output file name... " >&6; }
+ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
+
+# The possible output files:
+ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
+
ac_rmfiles=
for ac_file in $ac_files
do
case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
* ) ac_rmfiles="$ac_rmfiles $ac_file";;
esac
done
@@ -2704,10 +2837,11 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link_default") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; then
# Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
@@ -2718,7 +2852,7 @@ for ac_file in $ac_files ''
do
test -f "$ac_file" || continue
case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
;;
[ab].out )
# We found the default executable, but exeext='' is most
@@ -2745,25 +2879,27 @@ else
ac_file=''
fi
-{ echo "$as_me:$LINENO: result: $ac_file" >&5
-echo "${ECHO_T}$ac_file" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_file" >&5
+$as_echo "$ac_file" >&6; }
if test -z "$ac_file"; then
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
+{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
See \`config.log' for more details." >&5
-echo "$as_me: error: C compiler cannot create executables
+$as_echo "$as_me: error: C compiler cannot create executables
See \`config.log' for more details." >&2;}
- { (exit 77); exit 77; }; }
+ { (exit 77); exit 77; }; }; }
fi
ac_exeext=$ac_cv_exeext
# Check that the compiler produces executables we can run. If not, either
# the compiler is broken, or we cross compile.
-{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5
-echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
+{ $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
@@ -2772,49 +2908,53 @@ if test "$cross_compiling" != yes; then
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_try") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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
- { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
+ { { $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
-echo "$as_me: error: cannot run C compiled programs.
+$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; }; }
+ { (exit 1); exit 1; }; }; }
fi
fi
fi
-{ echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+{ $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
-rm -f a.out a.exe conftest$ac_cv_exeext b.out
+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.
-{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
-echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
-{ echo "$as_me:$LINENO: result: $cross_compiling" >&5
-echo "${ECHO_T}$cross_compiling" >&6; }
+{ $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; }
-{ echo "$as_me:$LINENO: checking for suffix of executables" >&5
-echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
+$as_echo_n "checking for suffix of executables... " >&6; }
if { (ac_try="$ac_link"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; then
# If both `conftest.exe' and `conftest' are `present' (well, observable)
# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
@@ -2823,31 +2963,33 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
for ac_file in conftest.exe conftest conftest.*; do
test -f "$ac_file" || continue
case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
*.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
break;;
* ) break;;
esac
done
else
- { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
+ { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
+$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; }; }
+ { (exit 1); exit 1; }; }; }
fi
rm -f conftest$ac_cv_exeext
-{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
-echo "${ECHO_T}$ac_cv_exeext" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
+$as_echo "$ac_cv_exeext" >&6; }
rm -f conftest.$ac_ext
EXEEXT=$ac_cv_exeext
ac_exeext=$EXEEXT
-{ echo "$as_me:$LINENO: checking for suffix of object files" >&5
-echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
+$as_echo_n "checking for suffix of object files... " >&6; }
if test "${ac_cv_objext+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -2870,40 +3012,43 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; then
for ac_file in conftest.o conftest.obj conftest.*; do
test -f "$ac_file" || continue;
case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
*) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
break;;
esac
done
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
-{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
+{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of object files: cannot compile
+$as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ { (exit 1); exit 1; }; }; }
fi
rm -f conftest.$ac_cv_objext conftest.$ac_ext
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
-echo "${ECHO_T}$ac_cv_objext" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
+$as_echo "$ac_cv_objext" >&6; }
OBJEXT=$ac_cv_objext
ac_objext=$OBJEXT
-{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
+$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
if test "${ac_cv_c_compiler_gnu+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -2929,20 +3074,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_compiler_gnu=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_compiler_gnu=no
@@ -2952,15 +3098,19 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
-GCC=`test $ac_compiler_gnu = yes && echo yes`
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
+$as_echo "$ac_cv_c_compiler_gnu" >&6; }
+if test $ac_compiler_gnu = yes; then
+ GCC=yes
+else
+ GCC=
+fi
ac_test_CFLAGS=${CFLAGS+set}
ac_save_CFLAGS=$CFLAGS
-{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
+$as_echo_n "checking whether $CC accepts -g... " >&6; }
if test "${ac_cv_prog_cc_g+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_save_c_werror_flag=$ac_c_werror_flag
ac_c_werror_flag=yes
@@ -2987,20 +3137,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cc_g=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
CFLAGS=""
@@ -3025,20 +3176,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_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
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_c_werror_flag=$ac_save_c_werror_flag
@@ -3064,20 +3216,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cc_g=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -3092,8 +3245,8 @@ fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_c_werror_flag=$ac_save_c_werror_flag
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
+$as_echo "$ac_cv_prog_cc_g" >&6; }
if test "$ac_test_CFLAGS" = set; then
CFLAGS=$ac_save_CFLAGS
elif test $ac_cv_prog_cc_g = yes; then
@@ -3109,10 +3262,10 @@ else
CFLAGS=
fi
fi
-{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
-echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
+$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
if test "${ac_cv_prog_cc_c89+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_cv_prog_cc_c89=no
ac_save_CC=$CC
@@ -3183,20 +3336,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cc_c89=$ac_arg
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -3212,15 +3366,15 @@ fi
# AC_CACHE_VAL
case "x$ac_cv_prog_cc_c89" in
x)
- { echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6; } ;;
+ { $as_echo "$as_me:$LINENO: result: none needed" >&5
+$as_echo "none needed" >&6; } ;;
xno)
- { echo "$as_me:$LINENO: result: unsupported" >&5
-echo "${ECHO_T}unsupported" >&6; } ;;
+ { $as_echo "$as_me:$LINENO: result: unsupported" >&5
+$as_echo "unsupported" >&6; } ;;
*)
CC="$CC $ac_cv_prog_cc_c89"
- { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
+ { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
+$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
esac
@@ -3241,8 +3395,8 @@ am__doit:
.PHONY: am__doit
END
# If we don't find an include directive, just comment out the code.
-{ echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
-echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
+$as_echo_n "checking for style of include used by $am_make... " >&6; }
am__include="#"
am__quote=
_am_result=none
@@ -3269,8 +3423,8 @@ if test "$am__include" = "#"; then
fi
-{ echo "$as_me:$LINENO: result: $_am_result" >&5
-echo "${ECHO_T}$_am_result" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $_am_result" >&5
+$as_echo "$_am_result" >&6; }
rm -f confinc confmf
# Check whether --enable-dependency-tracking was given.
@@ -3294,10 +3448,10 @@ fi
depcc="$CC" am_compiler_list=
-{ echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
-echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
+$as_echo_n "checking dependency style of $depcc... " >&6; }
if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
# We make a subdir and do the tests there. Otherwise we can end up
@@ -3385,8 +3539,8 @@ else
fi
fi
-{ echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
-echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
+$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
if
@@ -3414,10 +3568,10 @@ if test -z "$CXX"; 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
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CXX+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CXX"; then
ac_cv_prog_CXX="$CXX" # Let the user override the test.
@@ -3430,7 +3584,7 @@ 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_CXX="$ac_tool_prefix$ac_prog"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3441,11 +3595,11 @@ fi
fi
CXX=$ac_cv_prog_CXX
if test -n "$CXX"; then
- { echo "$as_me:$LINENO: result: $CXX" >&5
-echo "${ECHO_T}$CXX" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CXX" >&5
+$as_echo "$CXX" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -3458,10 +3612,10 @@ if test -z "$CXX"; 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
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $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_CXX+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_CXX"; then
ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
@@ -3474,7 +3628,7 @@ 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_CXX="$ac_prog"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -3485,11 +3639,11 @@ fi
fi
ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
if test -n "$ac_ct_CXX"; then
- { echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
-echo "${ECHO_T}$ac_ct_CXX" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
+$as_echo "$ac_ct_CXX" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -3501,12 +3655,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+{ $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
CXX=$ac_ct_CXX
@@ -3516,43 +3666,47 @@ fi
fi
fi
# Provide some information about the compiler.
-echo "$as_me:$LINENO: checking for C++ compiler version" >&5
-ac_compiler=`set X $ac_compile; echo $2`
+$as_echo "$as_me:$LINENO: checking for C++ compiler version" >&5
+set X $ac_compile
+ac_compiler=$2
{ (ac_try="$ac_compiler --version >&5"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
-{ echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
+$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -3578,20 +3732,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_cxx_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_compiler_gnu=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_compiler_gnu=no
@@ -3601,15 +3756,19 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6; }
-GXX=`test $ac_compiler_gnu = yes && echo yes`
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
+$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
+if test $ac_compiler_gnu = yes; then
+ GXX=yes
+else
+ GXX=
+fi
ac_test_CXXFLAGS=${CXXFLAGS+set}
ac_save_CXXFLAGS=$CXXFLAGS
-{ echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
-echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
+$as_echo_n "checking whether $CXX accepts -g... " >&6; }
if test "${ac_cv_prog_cxx_g+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_save_cxx_werror_flag=$ac_cxx_werror_flag
ac_cxx_werror_flag=yes
@@ -3636,20 +3795,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_cxx_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cxx_g=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
CXXFLAGS=""
@@ -3674,20 +3834,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_cxx_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
:
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cxx_werror_flag=$ac_save_cxx_werror_flag
@@ -3713,20 +3874,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_cxx_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cxx_g=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -3741,8 +3903,8 @@ fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_cxx_werror_flag=$ac_save_cxx_werror_flag
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
+$as_echo "$ac_cv_prog_cxx_g" >&6; }
if test "$ac_test_CXXFLAGS" = set; then
CXXFLAGS=$ac_save_CXXFLAGS
elif test $ac_cv_prog_cxx_g = yes; then
@@ -3766,10 +3928,10 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
depcc="$CXX" am_compiler_list=
-{ echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
-echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
+$as_echo_n "checking dependency style of $depcc... " >&6; }
if test "${am_cv_CXX_dependencies_compiler_type+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
# We make a subdir and do the tests there. Otherwise we can end up
@@ -3857,8 +4019,8 @@ else
fi
fi
-{ echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5
-echo "${ECHO_T}$am_cv_CXX_dependencies_compiler_type" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5
+$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; }
CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
if
@@ -3877,15 +4039,15 @@ ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
-echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
+$as_echo_n "checking how to run the C preprocessor... " >&6; }
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
fi
if test -z "$CPP"; then
if test "${ac_cv_prog_CPP+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
# Double quotes because CPP needs to be expanded
for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
@@ -3917,20 +4079,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&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
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Broken: fails on valid input.
@@ -3954,13 +4117,14 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&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
@@ -3968,7 +4132,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
# Broken: success on invalid input.
continue
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Passes both tests.
@@ -3993,8 +4157,8 @@ fi
else
ac_cv_prog_CPP=$CPP
fi
-{ echo "$as_me:$LINENO: result: $CPP" >&5
-echo "${ECHO_T}$CPP" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $CPP" >&5
+$as_echo "$CPP" >&6; }
ac_preproc_ok=false
for ac_c_preproc_warn_flag in '' yes
do
@@ -4022,20 +4186,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&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
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Broken: fails on valid input.
@@ -4059,13 +4224,14 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&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
@@ -4073,7 +4239,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
# Broken: success on invalid input.
continue
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Passes both tests.
@@ -4089,11 +4255,13 @@ rm -f conftest.err conftest.$ac_ext
if $ac_preproc_ok; then
:
else
- { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
+ { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
See \`config.log' for more details." >&5
-echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
+$as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ { (exit 1); exit 1; }; }; }
fi
ac_ext=c
@@ -4110,10 +4278,10 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -4126,7 +4294,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4137,11 +4305,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -4150,10 +4318,10 @@ if test -z "$ac_cv_prog_CC"; then
ac_ct_CC=$CC
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
@@ -4166,7 +4334,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4177,11 +4345,11 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+$as_echo "$ac_ct_CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
if test "x$ac_ct_CC" = x; then
@@ -4189,12 +4357,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
@@ -4207,10 +4371,10 @@ if test -z "$CC"; then
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -4223,7 +4387,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4234,11 +4398,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -4247,10 +4411,10 @@ fi
if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -4268,7 +4432,7 @@ do
continue
fi
ac_cv_prog_CC="cc"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4291,11 +4455,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -4306,10 +4470,10 @@ 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
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -4322,7 +4486,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4333,11 +4497,11 @@ fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
- { echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $CC" >&5
+$as_echo "$CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -4350,10 +4514,10 @@ 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
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_CC"; then
ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
@@ -4366,7 +4530,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -4377,11 +4541,11 @@ fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
- { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+$as_echo "$ac_ct_CC" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -4393,12 +4557,8 @@ done
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
CC=$ac_ct_CC
@@ -4408,50 +4568,56 @@ fi
fi
-test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
+test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
See \`config.log' for more details." >&5
-echo "$as_me: error: no acceptable C compiler found in \$PATH
+$as_echo "$as_me: error: no acceptable C compiler found in \$PATH
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ { (exit 1); exit 1; }; }; }
# Provide some information about the compiler.
-echo "$as_me:$LINENO: checking for C compiler version" >&5
-ac_compiler=`set X $ac_compile; echo $2`
+$as_echo "$as_me:$LINENO: checking for C compiler version" >&5
+set X $ac_compile
+ac_compiler=$2
{ (ac_try="$ac_compiler --version >&5"
case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }
-{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
+$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
if test "${ac_cv_c_compiler_gnu+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -4477,20 +4643,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_compiler_gnu=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_compiler_gnu=no
@@ -4500,15 +4667,19 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
-GCC=`test $ac_compiler_gnu = yes && echo yes`
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
+$as_echo "$ac_cv_c_compiler_gnu" >&6; }
+if test $ac_compiler_gnu = yes; then
+ GCC=yes
+else
+ GCC=
+fi
ac_test_CFLAGS=${CFLAGS+set}
ac_save_CFLAGS=$CFLAGS
-{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
+$as_echo_n "checking whether $CC accepts -g... " >&6; }
if test "${ac_cv_prog_cc_g+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_save_c_werror_flag=$ac_c_werror_flag
ac_c_werror_flag=yes
@@ -4535,20 +4706,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cc_g=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
CFLAGS=""
@@ -4573,20 +4745,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_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
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_c_werror_flag=$ac_save_c_werror_flag
@@ -4612,20 +4785,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cc_g=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -4640,8 +4814,8 @@ fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_c_werror_flag=$ac_save_c_werror_flag
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
+$as_echo "$ac_cv_prog_cc_g" >&6; }
if test "$ac_test_CFLAGS" = set; then
CFLAGS=$ac_save_CFLAGS
elif test $ac_cv_prog_cc_g = yes; then
@@ -4657,10 +4831,10 @@ else
CFLAGS=
fi
fi
-{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
-echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
+$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
if test "${ac_cv_prog_cc_c89+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_cv_prog_cc_c89=no
ac_save_CC=$CC
@@ -4731,20 +4905,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_cv_prog_cc_c89=$ac_arg
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
@@ -4760,15 +4935,15 @@ fi
# AC_CACHE_VAL
case "x$ac_cv_prog_cc_c89" in
x)
- { echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6; } ;;
+ { $as_echo "$as_me:$LINENO: result: none needed" >&5
+$as_echo "none needed" >&6; } ;;
xno)
- { echo "$as_me:$LINENO: result: unsupported" >&5
-echo "${ECHO_T}unsupported" >&6; } ;;
+ { $as_echo "$as_me:$LINENO: result: unsupported" >&5
+$as_echo "unsupported" >&6; } ;;
*)
CC="$CC $ac_cv_prog_cc_c89"
- { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
+ { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
+$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
esac
@@ -4780,10 +4955,10 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
depcc="$CC" am_compiler_list=
-{ echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
-echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
+$as_echo_n "checking dependency style of $depcc... " >&6; }
if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
# We make a subdir and do the tests there. Otherwise we can end up
@@ -4871,8 +5046,8 @@ else
fi
fi
-{ echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
-echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
+$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
if
@@ -4890,16 +5065,16 @@ fi
am_cv_prog_cc_stdc=$ac_cv_prog_cc_stdc
if test "x$CC" != xcc; then
- { echo "$as_me:$LINENO: checking whether $CC and cc understand -c and -o together" >&5
-echo $ECHO_N "checking whether $CC and cc understand -c and -o together... $ECHO_C" >&6; }
+ { $as_echo "$as_me:$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
- { echo "$as_me:$LINENO: checking whether cc understands -c and -o together" >&5
-echo $ECHO_N "checking whether cc understands -c and -o together... $ECHO_C" >&6; }
+ { $as_echo "$as_me:$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=`echo $2 |
+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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -4925,19 +5100,21 @@ if { (case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_try") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } &&
test -f conftest2.$ac_objext && { (case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_try") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); };
then
eval ac_cv_prog_cc_${ac_cc}_c_o=yes
@@ -4948,10 +5125,11 @@ then
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_try") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
rm -f conftest2.*
@@ -4959,19 +5137,21 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_try") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } &&
test -f conftest2.$ac_objext && { (case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_try") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); };
then
# cc works too.
@@ -4989,11 +5169,11 @@ rm -f core conftest*
fi
if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
- { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
cat >>confdefs.h <<\_ACEOF
#define NO_MINUS_C_MINUS_O 1
@@ -5015,11 +5195,11 @@ if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" != yes"; then
fi
-{ echo "$as_me:$LINENO: checking for function prototypes" >&5
-echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for function prototypes" >&5
+$as_echo_n "checking for function prototypes... " >&6; }
if test "$ac_cv_prog_cc_c89" != no; then
- { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
cat >>confdefs.h <<\_ACEOF
#define PROTOTYPES 1
@@ -5031,48 +5211,43 @@ cat >>confdefs.h <<\_ACEOF
_ACEOF
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
-{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
-echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
-if test "${ac_cv_path_GREP+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- # Extract the first word of "grep ggrep" to use in msg output
-if test -z "$GREP"; then
-set dummy grep ggrep; ac_prog_name=$2
+{ $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
+$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
if test "${ac_cv_path_GREP+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
+ if test -z "$GREP"; then
ac_path_GREP_found=false
-# Loop through the user's path and test for each of PROGNAME-LIST
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+ # Loop through the user's path and test for each of PROGNAME-LIST
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
- # Check for GNU ac_path_GREP and select it if it is found.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
+ { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
+# Check for GNU ac_path_GREP and select it if it is found.
# Check for GNU $ac_path_GREP
case `"$ac_path_GREP" --version 2>&1` in
*GNU*)
ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
*)
ac_count=0
- echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
+ $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"
- echo 'GREP' >> "conftest.nl"
+ $as_echo 'GREP' >> "conftest.nl"
"$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
ac_count=`expr $ac_count + 1`
@@ -5087,74 +5262,60 @@ case `"$ac_path_GREP" --version 2>&1` in
rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
esac
-
- $ac_path_GREP_found && break 3
+ $ac_path_GREP_found && break 3
+ done
done
done
-
-done
IFS=$as_save_IFS
-
-
-fi
-
-GREP="$ac_cv_path_GREP"
-if test -z "$GREP"; then
- { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
-echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
+ if test -z "$ac_cv_path_GREP"; then
+ { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
+$as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
{ (exit 1); exit 1; }; }
-fi
-
+ fi
else
ac_cv_path_GREP=$GREP
fi
-
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
-echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
+$as_echo "$ac_cv_path_GREP" >&6; }
GREP="$ac_cv_path_GREP"
-{ echo "$as_me:$LINENO: checking for egrep" >&5
-echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $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
- # Extract the first word of "egrep" to use in msg output
-if test -z "$EGREP"; then
-set dummy egrep; ac_prog_name=$2
-if test "${ac_cv_path_EGREP+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-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
+ # 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.
+ 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
- echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
+ $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"
- echo 'EGREP' >> "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`
@@ -5169,40 +5330,31 @@ case `"$ac_path_EGREP" --version 2>&1` in
rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
esac
-
- $ac_path_EGREP_found && break 3
+ $ac_path_EGREP_found && break 3
+ done
done
done
-
-done
IFS=$as_save_IFS
-
-
-fi
-
-EGREP="$ac_cv_path_EGREP"
-if test -z "$EGREP"; then
- { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
-echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
+ 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
else
ac_cv_path_EGREP=$EGREP
fi
-
fi
fi
-{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
-echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
+$as_echo "$ac_cv_path_EGREP" >&6; }
EGREP="$ac_cv_path_EGREP"
-{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
-echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -5229,20 +5381,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_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
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_header_stdc=no
@@ -5334,37 +5487,40 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $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 "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_try") 2>&5
ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
:
else
- echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
+ $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
-{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
-echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
+{ $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
@@ -5386,11 +5542,11 @@ fi
for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
inttypes.h stdint.h unistd.h
do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -5408,20 +5564,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_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
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_Header=no"
@@ -5429,12 +5586,15 @@ fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
- { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+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 `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
fi
@@ -5453,20 +5613,21 @@ fi
for ac_header in string.h
do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+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
- { echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+ { $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
- { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
+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?
-{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
+{ $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
@@ -5482,32 +5643,33 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_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
- echo "$as_me: failed program was:" >&5
+ $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
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+$as_echo "$ac_header_compiler" >&6; }
# Is the header present?
-{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
+{ $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
@@ -5521,51 +5683,52 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&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
- echo "$as_me: failed program was:" >&5
+ $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
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
+{ $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: )
- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+ { $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:* )
- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
+$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
( cat <<\_ASBOX
## ------------------------------------------- ##
## Report this to systemtap@sources.redhat.com ##
@@ -5574,21 +5737,24 @@ _ASBOX
) | sed "s/^/$as_me: WARNING: /" >&2
;;
esac
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
eval "$as_ac_Header=\$ac_header_preproc"
fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
- { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
+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
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+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 `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
fi
@@ -5599,10 +5765,10 @@ done
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$RANLIB"; then
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
@@ -5615,7 +5781,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5626,11 +5792,11 @@ fi
fi
RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
- { echo "$as_me:$LINENO: result: $RANLIB" >&5
-echo "${ECHO_T}$RANLIB" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
+$as_echo "$RANLIB" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
@@ -5639,10 +5805,10 @@ if test -z "$ac_cv_prog_RANLIB"; then
ac_ct_RANLIB=$RANLIB
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$ac_ct_RANLIB"; then
ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
@@ -5655,7 +5821,7 @@ 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"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -5666,11 +5832,11 @@ fi
fi
ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
if test -n "$ac_ct_RANLIB"; then
- { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
-echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
+$as_echo "$ac_ct_RANLIB" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
if test "x$ac_ct_RANLIB" = x; then
@@ -5678,12 +5844,8 @@ fi
else
case $cross_compiling:$ac_tool_warned in
yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet. If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
RANLIB=$ac_ct_RANLIB
@@ -5707,11 +5869,12 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# OS/2's system install, which has a completely different semantic
# ./install, which can be erroneously created by make from ./install.sh.
-{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
-echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
+# Reject install programs that cannot install multiple files.
+{ $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
+$as_echo_n "checking for a BSD-compatible install... " >&6; }
if test -z "$INSTALL"; then
if test "${ac_cv_path_install+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
@@ -5740,17 +5903,29 @@ case $as_dir/ in
# program-specific install script used by HP pwplus--don't use.
:
else
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
+ rm -rf conftest.one conftest.two conftest.dir
+ echo one > conftest.one
+ echo two > conftest.two
+ mkdir conftest.dir
+ if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
+ test -s conftest.one && test -s conftest.two &&
+ test -s conftest.dir/conftest.one &&
+ test -s conftest.dir/conftest.two
+ then
+ ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
+ break 3
+ fi
fi
fi
done
done
;;
esac
+
done
IFS=$as_save_IFS
+rm -rf conftest.one conftest.two conftest.dir
fi
if test "${ac_cv_path_install+set}" = set; then
@@ -5763,8 +5938,8 @@ fi
INSTALL=$ac_install_sh
fi
fi
-{ echo "$as_me:$LINENO: result: $INSTALL" >&5
-echo "${ECHO_T}$INSTALL" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
+$as_echo "$INSTALL" >&6; }
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
@@ -5774,11 +5949,12 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-{ echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; }
-set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
+{ $as_echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
+$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
+set x ${MAKE-make}
+ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.make <<\_ACEOF
SHELL = /bin/sh
@@ -5795,12 +5971,12 @@ esac
rm -f conftest.make
fi
if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
SET_MAKE=
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
SET_MAKE="MAKE=${MAKE-make}"
fi
@@ -5818,10 +5994,10 @@ if test "${enable_perfmon+set}" = set; then
LDFLAGS="$LDFLAGS -L$enable_perfmon/lib"
fi
-{ echo "$as_me:$LINENO: checking for pfm_start in -lpfm" >&5
-echo $ECHO_N "checking for pfm_start in -lpfm... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for pfm_start in -lpfm" >&5
+$as_echo_n "checking for pfm_start in -lpfm... " >&6; }
if test "${ac_cv_lib_pfm_pfm_start+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lpfm $LIBS"
@@ -5853,33 +6029,37 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
- } && test -s conftest$ac_exeext &&
- $as_test_x conftest$ac_exeext; then
+ } && test -s conftest$ac_exeext && {
+ test "$cross_compiling" = yes ||
+ $as_test_x conftest$ac_exeext
+ }; then
ac_cv_lib_pfm_pfm_start=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_pfm_pfm_start=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
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_pfm_pfm_start" >&5
-echo "${ECHO_T}$ac_cv_lib_pfm_pfm_start" >&6; }
-if test $ac_cv_lib_pfm_pfm_start = yes; then
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pfm_pfm_start" >&5
+$as_echo "$ac_cv_lib_pfm_pfm_start" >&6; }
+if test "x$ac_cv_lib_pfm_pfm_start" = x""yes; then
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBPFM 1
_ACEOF
@@ -5888,8 +6068,8 @@ _ACEOF
else
- { { echo "$as_me:$LINENO: error: systemtap cannot find required perfmon libs (libpfm-devel may need to be installed" >&5
-echo "$as_me: error: systemtap cannot find required perfmon libs (libpfm-devel may need to be installed" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: systemtap cannot find required perfmon libs (libpfm-devel may need to be installed" >&5
+$as_echo "$as_me: error: systemtap cannot find required perfmon libs (libpfm-devel may need to be installed" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -5898,17 +6078,17 @@ fi
if test "${enable_prologues+set}" != set; then
- { echo "$as_me:$LINENO: checking to see if prologue searching should be the default" >&5
-echo $ECHO_N "checking to see if prologue searching should be the default... $ECHO_C" >&6; }
+ { $as_echo "$as_me:$LINENO: checking to see if prologue searching should be the default" >&5
+$as_echo_n "checking to see if prologue searching should be the default... " >&6; }
if { echo '#if __i386__ == 1 && __GNUC__ < 4'
echo ' yes '
echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
enable_prologues=yes
- { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
fi
# Check whether --enable-prologues was given.
@@ -5917,7 +6097,7 @@ if test "${enable_prologues+set}" = set; then
if test "$enable_prologues" = yes; then
cat >>confdefs.h <<\_ACEOF
-#define ENABLE_PROLOGUES
+#define ENABLE_PROLOGUES /**/
_ACEOF
fi
@@ -5944,29 +6124,30 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
- { echo "$as_me:$LINENO: Compiling with gcc -fstack-protector-all et al." >&5
-echo "$as_me: Compiling with gcc -fstack-protector-all et al." >&6;}
+ { $as_echo "$as_me:$LINENO: Compiling with gcc -fstack-protector-all et al." >&5
+$as_echo "$as_me: Compiling with gcc -fstack-protector-all et al." >&6;}
CFLAGS="$save_CFLAGS -fstack-protector-all -D_FORTIFY_SOURCE=2"
CXFXLAGS="$save_CXXFLAGS -fstack-protector-all -D_FORTIFY_SOURCE=2"
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
- { echo "$as_me:$LINENO: Compiler does not support -fstack-protector-all et al." >&5
-echo "$as_me: Compiler does not support -fstack-protector-all et al." >&6;}
+ { $as_echo "$as_me:$LINENO: Compiler does not support -fstack-protector-all et al." >&5
+$as_echo "$as_me: Compiler does not support -fstack-protector-all et al." >&6;}
CFLAGS="$save_CFLAGS"
CXXFLAGS="$save_CXXFLAGS"
fi
@@ -5997,45 +6178,57 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
- } && test -s conftest$ac_exeext &&
- $as_test_x conftest$ac_exeext; then
+ } && test -s conftest$ac_exeext && {
+ test "$cross_compiling" = yes ||
+ $as_test_x conftest$ac_exeext
+ }; then
- { echo "$as_me:$LINENO: Compiling with gcc pie et al." >&5
-echo "$as_me: Compiling with gcc pie et al." >&6;}
+ { $as_echo "$as_me:$LINENO: Compiling with gcc pie et al." >&5
+$as_echo "$as_me: Compiling with gcc pie et al." >&6;}
# LDFLAGS is special since it may be passed down to bundled-elfutils,
# and interfere with the .so's built therein
- PIELDFLAGS="$LDFLAGS -pie -Wl,-z,relro -Wl,-z,now"
+ PIELDFLAGS="$LDFLAGS"
LDFLAGS="$save_LDFLAGS"
+ PIECFLAGS="$CFLAGS"
+ CFLAGS="$save_CFLAGS"
+ PIECXXFLAGS="$CXXFLAGS"
+ CXXFLAGS="$save_CXXFLAGS"
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
- { echo "$as_me:$LINENO: Compiler does not support -pie et al." >&5
-echo "$as_me: Compiler does not support -pie et al." >&6;}
+ { $as_echo "$as_me:$LINENO: Compiler does not support -pie et al." >&5
+$as_echo "$as_me: Compiler does not support -pie et al." >&6;}
+ PIECFLAGS=""
CFLAGS="$save_CFLAGS"
+ PIECXXFLAGS=""
CXXFLAGS="$save_CXXFLAGS"
PIELDFLAGS=""
LDFLAGS="$save_LDFLAGS"
fi
+rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
conftest$ac_exeext conftest.$ac_ext
fi
+
+
# Check whether --enable-sqlite was given.
if test "${enable_sqlite+set}" = set; then
enableval=$enable_sqlite;
@@ -6044,10 +6237,10 @@ else
fi
sqlite3_LIBS=
if test "x$enable_sqlite" != xno; then
- { echo "$as_me:$LINENO: checking for sqlite3_open in -lsqlite3" >&5
-echo $ECHO_N "checking for sqlite3_open in -lsqlite3... $ECHO_C" >&6; }
+ { $as_echo "$as_me:$LINENO: checking for sqlite3_open in -lsqlite3" >&5
+$as_echo_n "checking for sqlite3_open in -lsqlite3... " >&6; }
if test "${ac_cv_lib_sqlite3_sqlite3_open+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lsqlite3 $LIBS"
@@ -6079,33 +6272,37 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
- } && test -s conftest$ac_exeext &&
- $as_test_x conftest$ac_exeext; then
+ } && test -s conftest$ac_exeext && {
+ test "$cross_compiling" = yes ||
+ $as_test_x conftest$ac_exeext
+ }; then
ac_cv_lib_sqlite3_sqlite3_open=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_sqlite3_sqlite3_open=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
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_sqlite3_sqlite3_open" >&5
-echo "${ECHO_T}$ac_cv_lib_sqlite3_sqlite3_open" >&6; }
-if test $ac_cv_lib_sqlite3_sqlite3_open = yes; then
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_sqlite3_sqlite3_open" >&5
+$as_echo "$ac_cv_lib_sqlite3_sqlite3_open" >&6; }
+if test "x$ac_cv_lib_sqlite3_sqlite3_open" = x""yes; then
sqlite3_LIBS=-lsqlite3
@@ -6115,11 +6312,13 @@ _ACEOF
else
if test "x$enable_sqlite" != xcheck; then
- { { echo "$as_me:$LINENO: error: --enable-sqlite was given, but test for sqlite failed
+ { { $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: --enable-sqlite was given, but test for sqlite failed
See \`config.log' for more details." >&5
-echo "$as_me: error: --enable-sqlite was given, but test for sqlite failed
+$as_echo "$as_me: error: --enable-sqlite was given, but test for sqlite failed
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ { (exit 1); exit 1; }; }; }
fi
fi
@@ -6138,11 +6337,11 @@ if test "${enable_crash+set}" = set; then
for ac_header in crash/defs.h
do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
@@ -6162,20 +6361,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_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
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
eval "$as_ac_Header=no"
@@ -6183,17 +6383,20 @@ fi
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
- { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+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 `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
else
- { { echo "$as_me:$LINENO: error: cannot find required crash header (crash-devel may need to be installed)" >&5
-echo "$as_me: error: cannot find required crash header (crash-devel may need to be installed)" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: cannot find required crash header (crash-devel may need to be installed)" >&5
+$as_echo "$as_me: error: cannot find required crash header (crash-devel may need to be installed)" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -6214,6 +6417,7 @@ else
fi
+building_docs="no"
# Check whether --enable-docs was given.
if test "${enable_docs+set}" = set; then
enableval=$enable_docs; enable_docs=$enableval
@@ -6223,10 +6427,10 @@ fi
# Extract the first word of "latex", so it can be a program name with args.
set dummy latex; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_have_latex+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$have_latex"; then
ac_cv_prog_have_latex="$have_latex" # Let the user override the test.
@@ -6239,7 +6443,7 @@ 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_have_latex="yes"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -6251,20 +6455,20 @@ fi
fi
have_latex=$ac_cv_prog_have_latex
if test -n "$have_latex"; then
- { echo "$as_me:$LINENO: result: $have_latex" >&5
-echo "${ECHO_T}$have_latex" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $have_latex" >&5
+$as_echo "$have_latex" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
# Extract the first word of "dvips", so it can be a program name with args.
set dummy dvips; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_have_dvips+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$have_dvips"; then
ac_cv_prog_have_dvips="$have_dvips" # Let the user override the test.
@@ -6277,7 +6481,7 @@ 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_have_dvips="yes"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -6289,20 +6493,20 @@ fi
fi
have_dvips=$ac_cv_prog_have_dvips
if test -n "$have_dvips"; then
- { echo "$as_me:$LINENO: result: $have_dvips" >&5
-echo "${ECHO_T}$have_dvips" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $have_dvips" >&5
+$as_echo "$have_dvips" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
# Extract the first word of "ps2pdf", so it can be a program name with args.
set dummy ps2pdf; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_have_ps2pdf+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$have_ps2pdf"; then
ac_cv_prog_have_ps2pdf="$have_ps2pdf" # Let the user override the test.
@@ -6315,7 +6519,7 @@ 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_have_ps2pdf="yes"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -6327,20 +6531,20 @@ fi
fi
have_ps2pdf=$ac_cv_prog_have_ps2pdf
if test -n "$have_ps2pdf"; then
- { echo "$as_me:$LINENO: result: $have_ps2pdf" >&5
-echo "${ECHO_T}$have_ps2pdf" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $have_ps2pdf" >&5
+$as_echo "$have_ps2pdf" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
# Extract the first word of "latex2html", so it can be a program name with args.
set dummy latex2html; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_have_latex2html+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
if test -n "$have_latex2html"; then
ac_cv_prog_have_latex2html="$have_latex2html" # Let the user override the test.
@@ -6353,7 +6557,7 @@ 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_have_latex2html="yes"
- echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
break 2
fi
done
@@ -6365,22 +6569,29 @@ fi
fi
have_latex2html=$ac_cv_prog_have_latex2html
if test -n "$have_latex2html"; then
- { echo "$as_me:$LINENO: result: $have_latex2html" >&5
-echo "${ECHO_T}$have_latex2html" >&6; }
+ { $as_echo "$as_me:$LINENO: result: $have_latex2html" >&5
+$as_echo "$have_latex2html" >&6; }
else
- { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
fi
-if test "$enable_docs" == "yes"; then
- if test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" != "xyesyesyesyes"; then
- { { echo "$as_me:$LINENO: error: cannot find all tools for building documentation" >&5
-echo "$as_me: error: cannot find all tools for building documentation" >&2;}
+if test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" != "xyesyesyesyes"; then
+ if test "$enable_docs" == "yes"; then
+ { { $as_echo "$as_me:$LINENO: error: cannot find all tools for building documentation" >&5
+$as_echo "$as_me: error: cannot find all tools for building documentation" >&2;}
{ (exit 1); exit 1; }; }
fi
+ if test "$enable_docs" == "check"; then
+ { $as_echo "$as_me:$LINENO: WARNING: will not build documentation, cannot find all tools" >&5
+$as_echo "$as_me: WARNING: will not build documentation, cannot find all tools" >&2;}
+ fi
+fi
+if test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" == "xyesyesyesyes" -a "$enable_docs" != "no"; then
+ building_docs="yes"
fi
- if test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" == "xyesyesyesyes" -a "$enable_docs" != "no"; then
+ if test "$building_docs" == "yes"; then
BUILD_DOCS_TRUE=
BUILD_DOCS_FALSE='#'
else
@@ -6389,14 +6600,381 @@ else
fi
+building_refdocs="no"
+# Check whether --enable-refdocs was given.
+if test "${enable_refdocs+set}" = set; then
+ enableval=$enable_refdocs; enable_refdocs=$enableval
+else
+ enable_refdocs="check"
+fi
+
+if test "$building_docs" == "no" -a "$enable_refdocs" == "yes" ; then
+ { { $as_echo "$as_me:$LINENO: error: must use --enable-docs with --enable-refdocs" >&5
+$as_echo "$as_me: error: must use --enable-docs with --enable-refdocs" >&2;}
+ { (exit 1); exit 1; }; }
+fi
+# Extract the first word of "xmlto", so it can be a program name with args.
+set dummy xmlto; ac_word=$2
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_have_xmlto+set}" = set; then
+ $as_echo_n "(cached) " >&6
+else
+ if test -n "$have_xmlto"; then
+ ac_cv_prog_have_xmlto="$have_xmlto" # 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_have_xmlto="yes"
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+IFS=$as_save_IFS
+
+ test -z "$ac_cv_prog_have_xmlto" && ac_cv_prog_have_xmlto="no"
+fi
+fi
+have_xmlto=$ac_cv_prog_have_xmlto
+if test -n "$have_xmlto"; then
+ { $as_echo "$as_me:$LINENO: result: $have_xmlto" >&5
+$as_echo "$have_xmlto" >&6; }
+else
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+if test "x${have_xmlto}" == "xyes"; then
+{ $as_echo "$as_me:$LINENO: checking for xmlto pdf support" >&5
+$as_echo_n "checking for xmlto pdf support... " >&6; }
+cat > conftest.$ac_ext << EOF
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
+"http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" >
+ <book id="pdffromxml">
+ </book>
+EOF
+ xmlto pdf conftest.$ac_ext >& /dev/null
+ if test $? == 0; then
+ have_xmlto_pdf="yes"
+ { $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
+fi
+if test "$enable_refdocs" == "yes"; then
+ if test "x${have_xmlto}${have_xmlto_pdf}" != "xyesyes"; then
+ { { $as_echo "$as_me:$LINENO: error: cannot find proper yxmlto for building reference documentation" >&5
+$as_echo "$as_me: error: cannot find proper yxmlto for building reference documentation" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+fi
+if test "x${have_xmlto}${have_xmlto_pdf}" == "xyesyes" -a "$enable_refdocs" != "no" -a "${building_docs}" == "yes"; then
+ building_refdocs="yes"
+fi
+ if test "$building_refdocs" == "yes"; then
+ BUILD_REFDOCS_TRUE=
+ BUILD_REFDOCS_FALSE='#'
+else
+ BUILD_REFDOCS_TRUE='#'
+ BUILD_REFDOCS_FALSE=
+fi
+
+
+# Check whether --enable-server was given.
+if test "${enable_server+set}" = set; then
+ enableval=$enable_server; enable_server=$enableval
+else
+ enable_server="check"
+fi
+
+
+
+if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
+ if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
+set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
+ $as_echo_n "(cached) " >&6
+else
+ case $PKG_CONFIG in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+IFS=$as_save_IFS
+
+ ;;
+esac
+fi
+PKG_CONFIG=$ac_cv_path_PKG_CONFIG
+if test -n "$PKG_CONFIG"; then
+ { $as_echo "$as_me:$LINENO: result: $PKG_CONFIG" >&5
+$as_echo "$PKG_CONFIG" >&6; }
+else
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+fi
+if test -z "$ac_cv_path_PKG_CONFIG"; then
+ ac_pt_PKG_CONFIG=$PKG_CONFIG
+ # Extract the first word of "pkg-config", so it can be a program name with args.
+set dummy pkg-config; ac_word=$2
+{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then
+ $as_echo_n "(cached) " >&6
+else
+ case $ac_pt_PKG_CONFIG in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+ ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
+ $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+IFS=$as_save_IFS
+
+ ;;
+esac
+fi
+ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
+if test -n "$ac_pt_PKG_CONFIG"; then
+ { $as_echo "$as_me:$LINENO: result: $ac_pt_PKG_CONFIG" >&5
+$as_echo "$ac_pt_PKG_CONFIG" >&6; }
+else
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+ if test "x$ac_pt_PKG_CONFIG" = x; then
+ PKG_CONFIG=""
+ else
+ case $cross_compiling:$ac_tool_warned in
+yes:)
+{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+ PKG_CONFIG=$ac_pt_PKG_CONFIG
+ fi
+else
+ PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
+fi
+
+fi
+if test -n "$PKG_CONFIG"; then
+ _pkg_min_version=0.9.0
+ { $as_echo "$as_me:$LINENO: checking pkg-config is at least version $_pkg_min_version" >&5
+$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
+ if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+ else
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+ PKG_CONFIG=""
+ fi
+
+fi
+
+pkg_failed=no
+{ $as_echo "$as_me:$LINENO: checking for nss" >&5
+$as_echo_n "checking for nss... " >&6; }
+
+if test -n "$nss_CFLAGS"; then
+ pkg_cv_nss_CFLAGS="$nss_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"nss >= 3\"") >&5
+ ($PKG_CONFIG --exists --print-errors "nss >= 3") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ pkg_cv_nss_CFLAGS=`$PKG_CONFIG --cflags "nss >= 3" 2>/dev/null`
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$nss_LIBS"; then
+ pkg_cv_nss_LIBS="$nss_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"nss >= 3\"") >&5
+ ($PKG_CONFIG --exists --print-errors "nss >= 3") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ pkg_cv_nss_LIBS=`$PKG_CONFIG --libs "nss >= 3" 2>/dev/null`
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ nss_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "nss >= 3" 2>&1`
+ else
+ nss_PKG_ERRORS=`$PKG_CONFIG --print-errors "nss >= 3" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$nss_PKG_ERRORS" >&5
+
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+ have_nss=no
+elif test $pkg_failed = untried; then
+ have_nss=no
+else
+ nss_CFLAGS=$pkg_cv_nss_CFLAGS
+ nss_LIBS=$pkg_cv_nss_LIBS
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+ have_nss=yes
+fi
+
+pkg_failed=no
+{ $as_echo "$as_me:$LINENO: checking for nspr" >&5
+$as_echo_n "checking for nspr... " >&6; }
+
+if test -n "$nspr_CFLAGS"; then
+ pkg_cv_nspr_CFLAGS="$nspr_CFLAGS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"nspr >= 4\"") >&5
+ ($PKG_CONFIG --exists --print-errors "nspr >= 4") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ pkg_cv_nspr_CFLAGS=`$PKG_CONFIG --cflags "nspr >= 4" 2>/dev/null`
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+if test -n "$nspr_LIBS"; then
+ pkg_cv_nspr_LIBS="$nspr_LIBS"
+ elif test -n "$PKG_CONFIG"; then
+ if test -n "$PKG_CONFIG" && \
+ { ($as_echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"nspr >= 4\"") >&5
+ ($PKG_CONFIG --exists --print-errors "nspr >= 4") 2>&5
+ ac_status=$?
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ pkg_cv_nspr_LIBS=`$PKG_CONFIG --libs "nspr >= 4" 2>/dev/null`
+else
+ pkg_failed=yes
+fi
+ else
+ pkg_failed=untried
+fi
+
+
+
+if test $pkg_failed = yes; then
+
+if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
+ _pkg_short_errors_supported=yes
+else
+ _pkg_short_errors_supported=no
+fi
+ if test $_pkg_short_errors_supported = yes; then
+ nspr_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "nspr >= 4" 2>&1`
+ else
+ nspr_PKG_ERRORS=`$PKG_CONFIG --print-errors "nspr >= 4" 2>&1`
+ fi
+ # Put the nasty error message in config.log where it belongs
+ echo "$nspr_PKG_ERRORS" >&5
+
+ { $as_echo "$as_me:$LINENO: result: no" >&5
+$as_echo "no" >&6; }
+ have_nspr=no
+elif test $pkg_failed = untried; then
+ have_nspr=no
+else
+ nspr_CFLAGS=$pkg_cv_nspr_CFLAGS
+ nspr_LIBS=$pkg_cv_nspr_LIBS
+ { $as_echo "$as_me:$LINENO: result: yes" >&5
+$as_echo "yes" >&6; }
+ have_nspr=yes
+fi
+if test "x${have_nss}${have_nspr}" != "xyesyes"; then
+ if test "$enable_server" == "yes"; then
+ { { $as_echo "$as_me:$LINENO: error: cannot find all libraries for stap-server" >&5
+$as_echo "$as_me: error: cannot find all libraries for stap-server" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+ if test "$enable_server" == "check"; then
+ { $as_echo "$as_me:$LINENO: WARNING: will not build stap-server, cannot find all libraries" >&5
+$as_echo "$as_me: WARNING: will not build stap-server, cannot find all libraries" >&2;}
+ fi
+fi
+ if test "x${have_nss}${have_nspr}" == "xyesyes" -a "$enable_server" != "no"; then
+ BUILD_SERVER_TRUE=
+ BUILD_SERVER_FALSE='#'
+else
+ BUILD_SERVER_TRUE='#'
+ BUILD_SERVER_FALSE=
+fi
+
+
build_elfutils=no
# Check whether --with-elfutils was given.
if test "${with_elfutils+set}" = set; then
withval=$with_elfutils;
case "$with_elfutils" in
-yes) { { echo "$as_me:$LINENO: error: --with-elfutils requires an argument" >&5
-echo "$as_me: error: --with-elfutils requires an argument" >&2;}
+yes) { { $as_echo "$as_me:$LINENO: error: --with-elfutils requires an argument" >&5
+$as_echo "$as_me: error: --with-elfutils requires an argument" >&2;}
{ (exit 1); exit 1; }; } ;;
''|no) ;;
*) build_elfutils=yes ;;
@@ -6421,10 +6999,10 @@ if test $build_elfutils = no; then
# Need libdwfl-capable recent elfutils http://elfutils.fedorahosted.org/
save_LIBS="$LIBS"
-{ echo "$as_me:$LINENO: checking for dwfl_module_getsym in -ldw" >&5
-echo $ECHO_N "checking for dwfl_module_getsym in -ldw... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for dwfl_module_getsym in -ldw" >&5
+$as_echo_n "checking for dwfl_module_getsym in -ldw... " >&6; }
if test "${ac_cv_lib_dw_dwfl_module_getsym+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldw -Wl,--start-group -ldw -lebl -Wl,--end-group -lelf $LIBS"
@@ -6456,33 +7034,37 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
- } && test -s conftest$ac_exeext &&
- $as_test_x conftest$ac_exeext; then
+ } && test -s conftest$ac_exeext && {
+ test "$cross_compiling" = yes ||
+ $as_test_x conftest$ac_exeext
+ }; then
ac_cv_lib_dw_dwfl_module_getsym=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_dw_dwfl_module_getsym=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
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dw_dwfl_module_getsym" >&5
-echo "${ECHO_T}$ac_cv_lib_dw_dwfl_module_getsym" >&6; }
-if test $ac_cv_lib_dw_dwfl_module_getsym = yes; then
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dw_dwfl_module_getsym" >&5
+$as_echo "$ac_cv_lib_dw_dwfl_module_getsym" >&6; }
+if test "x$ac_cv_lib_dw_dwfl_module_getsym" = x""yes; then
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBDW 1
_ACEOF
@@ -6491,16 +7073,16 @@ _ACEOF
else
- { { echo "$as_me:$LINENO: error: missing elfutils development headers/libraries (install elfutils-devel, libebl-dev, libdw-dev and/or libebl-devel)" >&5
-echo "$as_me: error: missing elfutils development headers/libraries (install elfutils-devel, libebl-dev, libdw-dev and/or libebl-devel)" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: missing elfutils development headers/libraries (install elfutils-devel, libebl-dev, libdw-dev and/or libebl-devel)" >&5
+$as_echo "$as_me: error: missing elfutils development headers/libraries (install elfutils-devel, libebl-dev, libdw-dev and/or libebl-devel)" >&2;}
{ (exit 1); exit 1; }; }
fi
-{ echo "$as_me:$LINENO: checking for dwarf_getelf in -ldw" >&5
-echo $ECHO_N "checking for dwarf_getelf in -ldw... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking for dwarf_getelf in -ldw" >&5
+$as_echo_n "checking for dwarf_getelf in -ldw... " >&6; }
if test "${ac_cv_lib_dw_dwarf_getelf+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-ldw -Wl,--start-group -ldw -lebl -Wl,--end-group -lelf $LIBS"
@@ -6532,33 +7114,37 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_link") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_c_werror_flag" ||
test ! -s conftest.err
- } && test -s conftest$ac_exeext &&
- $as_test_x conftest$ac_exeext; then
+ } && test -s conftest$ac_exeext && {
+ test "$cross_compiling" = yes ||
+ $as_test_x conftest$ac_exeext
+ }; then
ac_cv_lib_dw_dwarf_getelf=yes
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
ac_cv_lib_dw_dwarf_getelf=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
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dw_dwarf_getelf" >&5
-echo "${ECHO_T}$ac_cv_lib_dw_dwarf_getelf" >&6; }
-if test $ac_cv_lib_dw_dwarf_getelf = yes; then
+{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dw_dwarf_getelf" >&5
+$as_echo "$ac_cv_lib_dw_dwarf_getelf" >&6; }
+if test "x$ac_cv_lib_dw_dwarf_getelf" = x""yes; then
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBDW 1
_ACEOF
@@ -6567,8 +7153,8 @@ _ACEOF
else
- { { echo "$as_me:$LINENO: error: elfutils, libdw too old, need 0.126+" >&5
-echo "$as_me: error: elfutils, libdw too old, need 0.126+" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: elfutils, libdw too old, need 0.126+" >&5
+$as_echo "$as_me: error: elfutils, libdw too old, need 0.126+" >&2;}
{ (exit 1); exit 1; }; }
fi
@@ -6580,8 +7166,8 @@ else
fi
-{ echo "$as_me:$LINENO: stap will link $stap_LIBS" >&5
-echo "$as_me: stap will link $stap_LIBS" >&6;}
+{ $as_echo "$as_me:$LINENO: stap will link $stap_LIBS" >&5
+$as_echo "$as_me: stap will link $stap_LIBS" >&6;}
date=`date +%Y-%m-%d`
@@ -6619,11 +7205,11 @@ ac_cpp='$CXXCPP $CPPFLAGS'
ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-{ echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5
-echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6; }
+{ $as_echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5
+$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
if test -z "$CXXCPP"; then
if test "${ac_cv_prog_CXXCPP+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
# Double quotes because CXXCPP needs to be expanded
for CXXCPP in "$CXX -E" "/lib/cpp"
@@ -6655,20 +7241,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
test ! -s conftest.err
}; then
:
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Broken: fails on valid input.
@@ -6692,13 +7279,14 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
test ! -s conftest.err
@@ -6706,7 +7294,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
# Broken: success on invalid input.
continue
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Passes both tests.
@@ -6731,8 +7319,8 @@ fi
else
ac_cv_prog_CXXCPP=$CXXCPP
fi
-{ echo "$as_me:$LINENO: result: $CXXCPP" >&5
-echo "${ECHO_T}$CXXCPP" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $CXXCPP" >&5
+$as_echo "$CXXCPP" >&6; }
ac_preproc_ok=false
for ac_cxx_preproc_warn_flag in '' yes
do
@@ -6760,20 +7348,21 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
test ! -s conftest.err
}; then
:
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Broken: fails on valid input.
@@ -6797,13 +7386,14 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
test ! -s conftest.err
@@ -6811,7 +7401,7 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
# Broken: success on invalid input.
continue
else
- echo "$as_me: failed program was:" >&5
+ $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5
# Passes both tests.
@@ -6827,11 +7417,13 @@ rm -f conftest.err conftest.$ac_ext
if $ac_preproc_ok; then
:
else
- { { echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check
+ { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+{ { $as_echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check
See \`config.log' for more details." >&5
-echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check
+$as_echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check
See \`config.log' for more details." >&2;}
- { (exit 1); exit 1; }; }
+ { (exit 1); exit 1; }; }; }
fi
ac_ext=cpp
@@ -6844,20 +7436,21 @@ ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
for ac_header in tr1/unordered_map
do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+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
- { echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+ { $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
- { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
+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?
-{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
+{ $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
@@ -6873,32 +7466,33 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
(eval "$ac_compile") 2>conftest.er1
ac_status=$?
grep -v '^ *+' conftest.er1 >conftest.err
rm -f conftest.er1
cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } && {
test -z "$ac_cxx_werror_flag" ||
test ! -s conftest.err
} && test -s conftest.$ac_objext; then
ac_header_compiler=yes
else
- echo "$as_me: failed program was:" >&5
+ $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
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
+{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+$as_echo "$ac_header_compiler" >&6; }
# Is the header present?
-{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
+{ $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
@@ -6912,51 +7506,52 @@ case "(($ac_try" in
*\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
*) ac_try_echo=$ac_try;;
esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+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
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } >/dev/null && {
test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
test ! -s conftest.err
}; then
ac_header_preproc=yes
else
- echo "$as_me: failed program was:" >&5
+ $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
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
+{ $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_cxx_preproc_warn_flag in
yes:no: )
- { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+ { $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:* )
- { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
- { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
+$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
( cat <<\_ASBOX
## ------------------------------------------- ##
## Report this to systemtap@sources.redhat.com ##
@@ -6965,21 +7560,24 @@ _ASBOX
) | sed "s/^/$as_me: WARNING: /" >&2
;;
esac
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+{ $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
- echo $ECHO_N "(cached) $ECHO_C" >&6
+ $as_echo_n "(cached) " >&6
else
eval "$as_ac_Header=\$ac_header_preproc"
fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
- { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
+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
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
+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 `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
fi
@@ -6993,15 +7591,356 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+if test $build_elfutils = yes; then
+ case "$with_elfutils" in
+ /*) elfutils_srcdir="$with_elfutils" ;;
+ *) elfutils_srcdir="../$with_elfutils" ;;
+ esac
+ { $as_echo "$as_me:$LINENO: running ${elfutils_srcdir}/configure" >&5
+$as_echo "$as_me: running ${elfutils_srcdir}/configure" >&6;}
+ # Our libdw.so's libebl will look in $ORIGIN/../lib/... but that
+ # $ORIGIN is where libdw.so resides, which is not where there is a ../lib.
+ # Note that $libdir might be using a quoted use of $exec_prefix or $prefix.
+ # So we must make sure to pass those settings to elfutils configure.
+ elfutils_rpath="-Wl,--enable-new-dtags,-rpath,${libdir}/${PACKAGE_NAME}"
+ here=`pwd`
+ (mkdir -p build-elfutils && cd build-elfutils &&
+ ${elfutils_srcdir}/configure --enable-libebl-subdir=${PACKAGE_NAME} \
+ --includedir="${here}/include-elfutils" \
+ --libdir="${here}/lib-elfutils" \
+ --exec-prefix="$exec_prefix" \
+ --prefix="$prefix" \
+ CFLAGS="${CFLAGS/-Wall/}" \
+ LDFLAGS="$LDFLAGS $elfutils_rpath" &&
+ make -k install-data # so that elfutils/version.h - if any - may be found.
+ # Note, we need -k because parts (like to po files) might fail,
+ # since those fo to $prefix to which we might not be able to write.
+ # We are only really interested in the include-elfutils files anyway here.
+ )
+ save_CPPFLAGS=${CPPFLAGS}
+ CPPFLAGS="${CPPFLAGS} -Iinclude-elfutils" # in case bundled elfutils
+
+for ac_header in elfutils/version.h
+do
+as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+ { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
+$as_echo_n "checking for $ac_header... " >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+ $as_echo_n "(cached) " >&6
+fi
+ac_res=`eval 'as_val=${'$as_ac_Header'}
+ $as_echo "$as_val"'`
+ { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+else
+ # Is the header compilable?
+{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
+$as_echo_n "checking $ac_header usability... " >&6; }
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+$ac_includes_default
+#include <$ac_header>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
+ (eval "$ac_compile") 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+ ac_header_compiler=yes
+else
+ $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_header_compiler=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+$as_echo "$ac_header_compiler" >&6; }
+
+# Is the header present?
+{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
+$as_echo_n "checking $ac_header presence... " >&6; }
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null && {
+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ }; then
+ ac_header_preproc=yes
+else
+ $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_header_preproc=no
+fi
+
+rm -f conftest.err conftest.$ac_ext
+{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+$as_echo "$ac_header_preproc" >&6; }
+
+# So? What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+ yes:no: )
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+ ac_header_preproc=yes
+ ;;
+ no:yes:* )
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
+$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+ ( cat <<\_ASBOX
+## ------------------------------------------- ##
+## Report this to systemtap@sources.redhat.com ##
+## ------------------------------------------- ##
+_ASBOX
+ ) | sed "s/^/$as_me: WARNING: /" >&2
+ ;;
+esac
+{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
+$as_echo_n "checking for $ac_header... " >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+ $as_echo_n "(cached) " >&6
+else
+ eval "$as_ac_Header=\$ac_header_preproc"
+fi
+ac_res=`eval 'as_val=${'$as_ac_Header'}
+ $as_echo "$as_val"'`
+ { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+
+fi
+as_val=`eval 'as_val=${'$as_ac_Header'}
+ $as_echo "$as_val"'`
+ if test "x$as_val" = x""yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+
+done
+
+ CPPFLAGS="$save_CPPFLAGS"
+else
+
+for ac_header in elfutils/version.h
+do
+as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+ { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
+$as_echo_n "checking for $ac_header... " >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+ $as_echo_n "(cached) " >&6
+fi
+ac_res=`eval 'as_val=${'$as_ac_Header'}
+ $as_echo "$as_val"'`
+ { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+else
+ # Is the header compilable?
+{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
+$as_echo_n "checking $ac_header usability... " >&6; }
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+$ac_includes_default
+#include <$ac_header>
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
+ (eval "$ac_compile") 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && {
+ test -z "$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ } && test -s conftest.$ac_objext; then
+ ac_header_compiler=yes
+else
+ $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_header_compiler=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+$as_echo "$ac_header_compiler" >&6; }
+
+# Is the header present?
+{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
+$as_echo_n "checking $ac_header presence... " >&6; }
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+ *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+ *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
+$as_echo "$ac_try_echo") >&5
+ (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null && {
+ test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+ test ! -s conftest.err
+ }; then
+ ac_header_preproc=yes
+else
+ $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ ac_header_preproc=no
+fi
+
+rm -f conftest.err conftest.$ac_ext
+{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+$as_echo "$ac_header_preproc" >&6; }
+
+# So? What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+ yes:no: )
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+ ac_header_preproc=yes
+ ;;
+ no:yes:* )
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
+$as_echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
+$as_echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+ ( cat <<\_ASBOX
+## ------------------------------------------- ##
+## Report this to systemtap@sources.redhat.com ##
+## ------------------------------------------- ##
+_ASBOX
+ ) | sed "s/^/$as_me: WARNING: /" >&2
+ ;;
+esac
+{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
+$as_echo_n "checking for $ac_header... " >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+ $as_echo_n "(cached) " >&6
+else
+ eval "$as_ac_Header=\$ac_header_preproc"
+fi
+ac_res=`eval 'as_val=${'$as_ac_Header'}
+ $as_echo "$as_val"'`
+ { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+
+fi
+as_val=`eval 'as_val=${'$as_ac_Header'}
+ $as_echo "$as_val"'`
+ if test "x$as_val" = x""yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+
+done
+
+fi
+
+
+cat >>confdefs.h <<_ACEOF
+#define STAP_PREFIX "$prefix"
+_ACEOF
+
+
ac_config_headers="$ac_config_headers config.h:config.in"
ac_config_files="$ac_config_files Makefile doc/Makefile doc/SystemTap_Tapset_Reference/Makefile stap.1 stapprobes.5 stapfuncs.5 stapvars.5 stapex.5 staprun.8 stap-server.8 man/stapprobes.iosched.5 man/stapprobes.netdev.5 man/stapprobes.nfs.5 man/stapprobes.nfsd.5 man/stapprobes.pagefault.5 man/stapprobes.process.5 man/stapprobes.rpc.5 man/stapprobes.scsi.5 man/stapprobes.signal.5 man/stapprobes.socket.5 man/stapprobes.tcp.5 man/stapprobes.udp.5"
-subdirs="$subdirs testsuite"
-ac_config_files="$ac_config_files run-stap"
+subdirs="$subdirs testsuite"
+ac_config_files="$ac_config_files run-stap"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
@@ -7030,11 +7969,12 @@ _ACEOF
case $ac_val in #(
*${as_nl}*)
case $ac_var in #(
- *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
-echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
+ *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
esac
case $ac_var in #(
_ | IFS | as_nl) ;; #(
+ BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
*) $as_unset $ac_var ;;
esac ;;
esac
@@ -7067,12 +8007,12 @@ echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
if test -w "$cache_file"; then
test "x$cache_file" != "x/dev/null" &&
- { echo "$as_me:$LINENO: updating cache $cache_file" >&5
-echo "$as_me: updating cache $cache_file" >&6;}
+ { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
+$as_echo "$as_me: updating cache $cache_file" >&6;}
cat confcache >$cache_file
else
- { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
-echo "$as_me: not updating unwritable cache $cache_file" >&6;}
+ { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
+$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
fi
fi
rm -f confcache
@@ -7088,7 +8028,7 @@ ac_ltlibobjs=
for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
# 1. Remove the extension, and $U if already installed.
ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`echo "$ac_i" | sed "$ac_script"`
+ 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"
@@ -7100,68 +8040,83 @@ LTLIBOBJS=$ac_ltlibobjs
if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined.
+$as_echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"AMDEP\" was never defined.
+$as_echo "$as_me: error: conditional \"AMDEP\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
+$as_echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCXX\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCXX\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"am__fastdepCXX\" was never defined.
+$as_echo "$as_me: error: conditional \"am__fastdepCXX\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
+$as_echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "${BUILD_CRASHMOD_TRUE}" && test -z "${BUILD_CRASHMOD_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"BUILD_CRASHMOD\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_CRASHMOD\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"BUILD_CRASHMOD\" was never defined.
+$as_echo "$as_me: error: conditional \"BUILD_CRASHMOD\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "${BUILD_DOCS_TRUE}" && test -z "${BUILD_DOCS_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"BUILD_DOCS\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_DOCS\" was never defined.
+Usually this means the macro was only invoked conditionally." >&5
+$as_echo "$as_me: error: conditional \"BUILD_DOCS\" was never defined.
+Usually this means the macro was only invoked conditionally." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+if test -z "${BUILD_REFDOCS_TRUE}" && test -z "${BUILD_REFDOCS_FALSE}"; then
+ { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_REFDOCS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"BUILD_DOCS\" was never defined.
+$as_echo "$as_me: error: conditional \"BUILD_REFDOCS\" was never defined.
+Usually this means the macro was only invoked conditionally." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+if test -z "${BUILD_SERVER_TRUE}" && test -z "${BUILD_SERVER_FALSE}"; then
+ { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_SERVER\" was never defined.
+Usually this means the macro was only invoked conditionally." >&5
+$as_echo "$as_me: error: conditional \"BUILD_SERVER\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
if test -z "${BUILD_ELFUTILS_TRUE}" && test -z "${BUILD_ELFUTILS_FALSE}"; then
- { { echo "$as_me:$LINENO: error: conditional \"BUILD_ELFUTILS\" was never defined.
+ { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_ELFUTILS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
-echo "$as_me: error: conditional \"BUILD_ELFUTILS\" was never defined.
+$as_echo "$as_me: error: conditional \"BUILD_ELFUTILS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
{ (exit 1); exit 1; }; }
fi
: ${CONFIG_STATUS=./config.status}
+ac_write_fail=0
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
-echo "$as_me: creating $CONFIG_STATUS" >&6;}
-cat >$CONFIG_STATUS <<_ACEOF
+{ $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
+$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
+cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
#! $SHELL
# Generated by $as_me.
# Run this file to recreate the current configuration.
@@ -7174,7 +8129,7 @@ ac_cs_silent=false
SHELL=\${CONFIG_SHELL-$SHELL}
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
## --------------------- ##
## M4sh Initialization. ##
## --------------------- ##
@@ -7184,7 +8139,7 @@ DUALCASE=1; export DUALCASE # for MKS sh
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
emulate sh
NULLCMD=:
- # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # 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
@@ -7206,17 +8161,45 @@ as_cr_Letters=$as_cr_letters$as_cr_LETTERS
as_cr_digits='0123456789'
as_cr_alnum=$as_cr_Letters$as_cr_digits
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
+as_nl='
+'
+export as_nl
+# Printing a long string crashes Solaris 7 /usr/bin/printf.
+as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
+as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
+if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
+ as_echo='printf %s\n'
+ as_echo_n='printf %s'
+else
+ if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
+ as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
+ as_echo_n='/usr/ucb/echo -n'
else
- PATH_SEPARATOR=:
+ as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
+ as_echo_n_body='eval
+ arg=$1;
+ case $arg in
+ *"$as_nl"*)
+ expr "X$arg" : "X\\(.*\\)$as_nl";
+ arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
+ esac;
+ expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
+ '
+ export as_echo_n_body
+ as_echo_n='sh -c $as_echo_n_body as_echo'
fi
- rm -f conf$$.sh
+ export as_echo_body
+ as_echo='sh -c $as_echo_body as_echo'
+fi
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+ PATH_SEPARATOR=:
+ (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
+ (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
+ PATH_SEPARATOR=';'
+ }
fi
# Support unset when possible.
@@ -7232,8 +8215,6 @@ fi
# there to prevent editors from complaining about space-tab.
# (If _AS_PATH_WALK were called with IFS unset, it would disable word
# splitting by setting IFS to empty value.)
-as_nl='
-'
IFS=" "" $as_nl"
# Find who we are. Look in the path if we contain no directory separator.
@@ -7256,7 +8237,7 @@ if test "x$as_myself" = x; then
as_myself=$0
fi
if test ! -f "$as_myself"; then
- echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+ $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
{ (exit 1); exit 1; }
fi
@@ -7269,17 +8250,10 @@ PS2='> '
PS4='+ '
# NLS nuisances.
-for as_var in \
- LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
- LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
- LC_TELEPHONE LC_TIME
-do
- if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
- eval $as_var=C; export $as_var
- else
- ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
- fi
-done
+LC_ALL=C
+export LC_ALL
+LANGUAGE=C
+export LANGUAGE
# Required to use basename.
if expr a : '\(a\)' >/dev/null 2>&1 &&
@@ -7301,7 +8275,7 @@ as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
X"$0" : 'X\(//\)$' \| \
X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-echo X/"$0" |
+$as_echo X/"$0" |
sed '/^.*\/\([^/][^/]*\)\/*$/{
s//\1/
q
@@ -7352,7 +8326,7 @@ $as_unset CDPATH
s/-\n.*//
' >$as_me.lineno &&
chmod +x "$as_me.lineno" ||
- { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
+ { $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
@@ -7380,7 +8354,6 @@ case `echo -n x` in
*)
ECHO_N='-n';;
esac
-
if expr a : '\(a\)' >/dev/null 2>&1 &&
test "X`expr 00001 : '.*\(...\)'`" = X001; then
as_expr=expr
@@ -7393,19 +8366,22 @@ if test -d conf$$.dir; then
rm -f conf$$.dir/conf$$.file
else
rm -f conf$$.dir
- mkdir conf$$.dir
-fi
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -p'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+ mkdir conf$$.dir 2>/dev/null
+fi
+if (echo >conf$$.file) 2>/dev/null; then
+ if ln -s conf$$.file conf$$ 2>/dev/null; then
+ as_ln_s='ln -s'
+ # ... but there are two gotchas:
+ # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+ # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+ # In both cases, we have to default to `cp -p'.
+ ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+ as_ln_s='cp -p'
+ elif ln conf$$.file conf$$ 2>/dev/null; then
+ as_ln_s=ln
+ else
as_ln_s='cp -p'
-elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
+ fi
else
as_ln_s='cp -p'
fi
@@ -7430,10 +8406,10 @@ else
as_test_x='
eval sh -c '\''
if test -d "$1"; then
- test -d "$1/.";
+ test -d "$1/.";
else
case $1 in
- -*)set "./$1";;
+ -*)set "./$1";;
esac;
case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
???[sx]*):;;*)false;;esac;fi
@@ -7456,7 +8432,7 @@ exec 6>&1
# values after options handling.
ac_log="
This file was extended by systemtap $as_me 0.8, which was
-generated by GNU Autoconf 2.61. Invocation command line was
+generated by GNU Autoconf 2.63. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
CONFIG_HEADERS = $CONFIG_HEADERS
@@ -7469,7 +8445,16 @@ on `(hostname || uname -n) 2>/dev/null | sed 1q`
_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
+case $ac_config_files in *"
+"*) set x $ac_config_files; shift; ac_config_files=$*;;
+esac
+
+case $ac_config_headers in *"
+"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
+esac
+
+
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
# Files that config.status was made for.
config_files="$ac_config_files"
config_headers="$ac_config_headers"
@@ -7477,22 +8462,23 @@ config_commands="$ac_config_commands"
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
ac_cs_usage="\
\`$as_me' instantiates files from templates according to the
current configuration.
-Usage: $0 [OPTIONS] [FILE]...
+Usage: $0 [OPTION]... [FILE]...
-h, --help print this help, then exit
-V, --version print version number and configuration settings, then exit
- -q, --quiet do not print progress messages
+ -q, --quiet, --silent
+ do not print progress messages
-d, --debug don't remove temporary files
--recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
+ --file=FILE[:TEMPLATE]
+ instantiate the configuration file FILE
+ --header=FILE[:TEMPLATE]
+ instantiate the configuration header FILE
Configuration files:
$config_files
@@ -7506,13 +8492,13 @@ $config_commands
Report bugs to <bug-autoconf@gnu.org>."
_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
systemtap config.status 0.8
-configured by $0, generated by GNU Autoconf 2.61,
- with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
+configured by $0, generated by GNU Autoconf 2.63,
+ with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
-Copyright (C) 2006 Free Software Foundation, Inc.
+Copyright (C) 2008 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."
@@ -7520,11 +8506,12 @@ ac_pwd='$ac_pwd'
srcdir='$srcdir'
INSTALL='$INSTALL'
MKDIR_P='$MKDIR_P'
+AWK='$AWK'
+test -n "\$AWK" || AWK=awk
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-# If no file are specified by the user, then we need to provide default
-# value. By we need to know if files were specified by the user.
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+# The default lists apply if the user does not specify any file.
ac_need_defaults=:
while test $# != 0
do
@@ -7546,30 +8533,36 @@ do
-recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
ac_cs_recheck=: ;;
--version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- echo "$ac_cs_version"; exit ;;
+ $as_echo "$ac_cs_version"; exit ;;
--debug | --debu | --deb | --de | --d | -d )
debug=: ;;
--file | --fil | --fi | --f )
$ac_shift
- CONFIG_FILES="$CONFIG_FILES $ac_optarg"
+ case $ac_optarg in
+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ esac
+ CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
ac_need_defaults=false;;
--header | --heade | --head | --hea )
$ac_shift
- CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
+ case $ac_optarg in
+ *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ esac
+ CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
ac_need_defaults=false;;
--he | --h)
# Conflict between --help and --header
- { echo "$as_me: error: ambiguous option: $1
+ { $as_echo "$as_me: error: ambiguous option: $1
Try \`$0 --help' for more information." >&2
{ (exit 1); exit 1; }; };;
--help | --hel | -h )
- echo "$ac_cs_usage"; exit ;;
+ $as_echo "$ac_cs_usage"; exit ;;
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
| -silent | --silent | --silen | --sile | --sil | --si | --s)
ac_cs_silent=: ;;
# This is an error.
- -*) { echo "$as_me: error: unrecognized option: $1
+ -*) { $as_echo "$as_me: error: unrecognized option: $1
Try \`$0 --help' for more information." >&2
{ (exit 1); exit 1; }; } ;;
@@ -7588,27 +8581,29 @@ if $ac_cs_silent; then
fi
_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
if \$ac_cs_recheck; then
- echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
- CONFIG_SHELL=$SHELL
+ set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+ shift
+ \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
+ CONFIG_SHELL='$SHELL'
export CONFIG_SHELL
- exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+ exec "\$@"
fi
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
exec 5>>config.log
{
echo
sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
## Running $as_me. ##
_ASBOX
- echo "$ac_log"
+ $as_echo "$ac_log"
} >&5
_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
#
# INIT-COMMANDS
#
@@ -7616,7 +8611,7 @@ AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# Handling of arguments.
for ac_config_target in $ac_config_targets
@@ -7648,8 +8643,8 @@ do
"man/stapprobes.udp.5") CONFIG_FILES="$CONFIG_FILES man/stapprobes.udp.5" ;;
"run-stap") CONFIG_FILES="$CONFIG_FILES run-stap" ;;
- *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
-echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
+ *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
+$as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
{ (exit 1); exit 1; }; };;
esac
done
@@ -7690,218 +8685,144 @@ $debug ||
(umask 077 && mkdir "$tmp")
} ||
{
- echo "$me: cannot create a temporary directory in ." >&2
+ $as_echo "$as_me: cannot create a temporary directory in ." >&2
{ (exit 1); exit 1; }
}
-#
-# Set up the sed scripts for CONFIG_FILES section.
-#
-
-# No need to generate the scripts if there are no CONFIG_FILES.
-# This happens for instance when ./config.status config.h
+# Set up the scripts for CONFIG_FILES section.
+# No need to generate them if there are no CONFIG_FILES.
+# This happens for instance with `./config.status config.h'.
if test -n "$CONFIG_FILES"; then
-_ACEOF
-
-
-
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- cat >conf$$subs.sed <<_ACEOF
-SHELL!$SHELL$ac_delim
-PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
-PACKAGE_NAME!$PACKAGE_NAME$ac_delim
-PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
-PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
-PACKAGE_STRING!$PACKAGE_STRING$ac_delim
-PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
-exec_prefix!$exec_prefix$ac_delim
-prefix!$prefix$ac_delim
-program_transform_name!$program_transform_name$ac_delim
-bindir!$bindir$ac_delim
-sbindir!$sbindir$ac_delim
-libexecdir!$libexecdir$ac_delim
-datarootdir!$datarootdir$ac_delim
-datadir!$datadir$ac_delim
-sysconfdir!$sysconfdir$ac_delim
-sharedstatedir!$sharedstatedir$ac_delim
-localstatedir!$localstatedir$ac_delim
-includedir!$includedir$ac_delim
-oldincludedir!$oldincludedir$ac_delim
-docdir!$docdir$ac_delim
-infodir!$infodir$ac_delim
-htmldir!$htmldir$ac_delim
-dvidir!$dvidir$ac_delim
-pdfdir!$pdfdir$ac_delim
-psdir!$psdir$ac_delim
-libdir!$libdir$ac_delim
-localedir!$localedir$ac_delim
-mandir!$mandir$ac_delim
-DEFS!$DEFS$ac_delim
-ECHO_C!$ECHO_C$ac_delim
-ECHO_N!$ECHO_N$ac_delim
-ECHO_T!$ECHO_T$ac_delim
-LIBS!$LIBS$ac_delim
-build_alias!$build_alias$ac_delim
-host_alias!$host_alias$ac_delim
-target_alias!$target_alias$ac_delim
-INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
-INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
-INSTALL_DATA!$INSTALL_DATA$ac_delim
-am__isrc!$am__isrc$ac_delim
-CYGPATH_W!$CYGPATH_W$ac_delim
-PACKAGE!$PACKAGE$ac_delim
-VERSION!$VERSION$ac_delim
-ACLOCAL!$ACLOCAL$ac_delim
-AUTOCONF!$AUTOCONF$ac_delim
-AUTOMAKE!$AUTOMAKE$ac_delim
-AUTOHEADER!$AUTOHEADER$ac_delim
-MAKEINFO!$MAKEINFO$ac_delim
-install_sh!$install_sh$ac_delim
-STRIP!$STRIP$ac_delim
-INSTALL_STRIP_PROGRAM!$INSTALL_STRIP_PROGRAM$ac_delim
-mkdir_p!$mkdir_p$ac_delim
-AWK!$AWK$ac_delim
-SET_MAKE!$SET_MAKE$ac_delim
-am__leading_dot!$am__leading_dot$ac_delim
-AMTAR!$AMTAR$ac_delim
-am__tar!$am__tar$ac_delim
-am__untar!$am__untar$ac_delim
-MAINTAINER_MODE_TRUE!$MAINTAINER_MODE_TRUE$ac_delim
-MAINTAINER_MODE_FALSE!$MAINTAINER_MODE_FALSE$ac_delim
-MAINT!$MAINT$ac_delim
-LN_S!$LN_S$ac_delim
-CC!$CC$ac_delim
-CFLAGS!$CFLAGS$ac_delim
-LDFLAGS!$LDFLAGS$ac_delim
-CPPFLAGS!$CPPFLAGS$ac_delim
-ac_ct_CC!$ac_ct_CC$ac_delim
-EXEEXT!$EXEEXT$ac_delim
-OBJEXT!$OBJEXT$ac_delim
-DEPDIR!$DEPDIR$ac_delim
-am__include!$am__include$ac_delim
-am__quote!$am__quote$ac_delim
-AMDEP_TRUE!$AMDEP_TRUE$ac_delim
-AMDEP_FALSE!$AMDEP_FALSE$ac_delim
-AMDEPBACKSLASH!$AMDEPBACKSLASH$ac_delim
-CCDEPMODE!$CCDEPMODE$ac_delim
-am__fastdepCC_TRUE!$am__fastdepCC_TRUE$ac_delim
-am__fastdepCC_FALSE!$am__fastdepCC_FALSE$ac_delim
-CXX!$CXX$ac_delim
-CXXFLAGS!$CXXFLAGS$ac_delim
-ac_ct_CXX!$ac_ct_CXX$ac_delim
-CXXDEPMODE!$CXXDEPMODE$ac_delim
-am__fastdepCXX_TRUE!$am__fastdepCXX_TRUE$ac_delim
-am__fastdepCXX_FALSE!$am__fastdepCXX_FALSE$ac_delim
-CPP!$CPP$ac_delim
-GREP!$GREP$ac_delim
-EGREP!$EGREP$ac_delim
-U!$U$ac_delim
-ANSI2KNR!$ANSI2KNR$ac_delim
-RANLIB!$RANLIB$ac_delim
-PIELDFLAGS!$PIELDFLAGS$ac_delim
-sqlite3_LIBS!$sqlite3_LIBS$ac_delim
-staplog_CPPFLAGS!$staplog_CPPFLAGS$ac_delim
-BUILD_CRASHMOD_TRUE!$BUILD_CRASHMOD_TRUE$ac_delim
-BUILD_CRASHMOD_FALSE!$BUILD_CRASHMOD_FALSE$ac_delim
-have_latex!$have_latex$ac_delim
-_ACEOF
-
- if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
- break
- elif $ac_last_try; then
- { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
-echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
- { (exit 1); exit 1; }; }
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
-if test -n "$ac_eof"; then
- ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
- ac_eof=`expr $ac_eof + 1`
+ac_cr=' '
+ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
+if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
+ ac_cs_awk_cr='\\r'
+else
+ ac_cs_awk_cr=$ac_cr
fi
-cat >>$CONFIG_STATUS <<_ACEOF
-cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-_ACEOF
-sed '
-s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
-s/^/s,@/; s/!/@,|#_!!_#|/
-:n
-t n
-s/'"$ac_delim"'$/,g/; t
-s/$/\\/; p
-N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
-' >>$CONFIG_STATUS <conf$$subs.sed
-rm -f conf$$subs.sed
-cat >>$CONFIG_STATUS <<_ACEOF
-CEOF$ac_eof
+echo 'BEGIN {' >"$tmp/subs1.awk" &&
_ACEOF
+{
+ echo "cat >conf$$subs.awk <<_ACEOF" &&
+ echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
+ echo "_ACEOF"
+} >conf$$subs.sh ||
+ { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
+$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
+ { (exit 1); exit 1; }; }
+ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
ac_delim='%!_!# '
for ac_last_try in false false false false false :; do
- cat >conf$$subs.sed <<_ACEOF
-have_dvips!$have_dvips$ac_delim
-have_ps2pdf!$have_ps2pdf$ac_delim
-have_latex2html!$have_latex2html$ac_delim
-BUILD_DOCS_TRUE!$BUILD_DOCS_TRUE$ac_delim
-BUILD_DOCS_FALSE!$BUILD_DOCS_FALSE$ac_delim
-BUILD_ELFUTILS_TRUE!$BUILD_ELFUTILS_TRUE$ac_delim
-BUILD_ELFUTILS_FALSE!$BUILD_ELFUTILS_FALSE$ac_delim
-elfutils_abs_srcdir!$elfutils_abs_srcdir$ac_delim
-stap_LIBS!$stap_LIBS$ac_delim
-DATE!$DATE$ac_delim
-PROCFLAGS!$PROCFLAGS$ac_delim
-CXXCPP!$CXXCPP$ac_delim
-subdirs!$subdirs$ac_delim
-LIBOBJS!$LIBOBJS$ac_delim
-LTLIBOBJS!$LTLIBOBJS$ac_delim
-_ACEOF
-
- if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 15; then
+ . ./conf$$subs.sh ||
+ { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
+$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
+ { (exit 1); exit 1; }; }
+
+ ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
+ if test $ac_delim_n = $ac_delim_num; then
break
elif $ac_last_try; then
- { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
-echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
+$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
{ (exit 1); exit 1; }; }
else
ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
fi
done
+rm -f conf$$subs.sh
+
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
+_ACEOF
+sed -n '
+h
+s/^/S["/; s/!.*/"]=/
+p
+g
+s/^[^!]*!//
+:repl
+t repl
+s/'"$ac_delim"'$//
+t delim
+:nl
+h
+s/\(.\{148\}\).*/\1/
+t more1
+s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
+p
+n
+b repl
+:more1
+s/["\\]/\\&/g; s/^/"/; s/$/"\\/
+p
+g
+s/.\{148\}//
+t nl
+:delim
+h
+s/\(.\{148\}\).*/\1/
+t more2
+s/["\\]/\\&/g; s/^/"/; s/$/"/
+p
+b
+:more2
+s/["\\]/\\&/g; s/^/"/; s/$/"\\/
+p
+g
+s/.\{148\}//
+t delim
+' <conf$$subs.awk | sed '
+/^[^""]/{
+ N
+ s/\n//
+}
+' >>$CONFIG_STATUS || ac_write_fail=1
+rm -f conf$$subs.awk
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+_ACAWK
+cat >>"\$tmp/subs1.awk" <<_ACAWK &&
+ for (key in S) S_is_set[key] = 1
+ FS = ""
-ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
-if test -n "$ac_eof"; then
- ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
- ac_eof=`expr $ac_eof + 1`
-fi
+}
+{
+ line = $ 0
+ nfields = split(line, field, "@")
+ substed = 0
+ len = length(field[1])
+ for (i = 2; i < nfields; i++) {
+ key = field[i]
+ keylen = length(key)
+ if (S_is_set[key]) {
+ value = S[key]
+ line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
+ len += length(value) + length(field[++i])
+ substed = 1
+ } else
+ len += 1 + keylen
+ }
+
+ print line
+}
-cat >>$CONFIG_STATUS <<_ACEOF
-cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
+_ACAWK
_ACEOF
-sed '
-s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
-s/^/s,@/; s/!/@,|#_!!_#|/
-:n
-t n
-s/'"$ac_delim"'$/,g/; t
-s/$/\\/; p
-N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
-' >>$CONFIG_STATUS <conf$$subs.sed
-rm -f conf$$subs.sed
-cat >>$CONFIG_STATUS <<_ACEOF
-:end
-s/|#_!!_#|//g
-CEOF$ac_eof
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
+ sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
+else
+ cat
+fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
+ || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
+$as_echo "$as_me: error: could not setup config files machinery" >&2;}
+ { (exit 1); exit 1; }; }
_ACEOF
-
# VPATH may cause trouble with some makes, so we remove $(srcdir),
# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
# trailing colons and then remove the whole line if VPATH becomes empty
@@ -7917,19 +8838,133 @@ s/^[^=]*=[ ]*$//
}'
fi
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
fi # test -n "$CONFIG_FILES"
+# Set up the scripts for CONFIG_HEADERS section.
+# No need to generate them if there are no CONFIG_HEADERS.
+# This happens for instance with `./config.status Makefile'.
+if test -n "$CONFIG_HEADERS"; then
+cat >"$tmp/defines.awk" <<\_ACAWK ||
+BEGIN {
+_ACEOF
+
+# Transform confdefs.h into an awk script `defines.awk', embedded as
+# here-document in config.status, that substitutes the proper values into
+# config.h.in to produce config.h.
+
+# Create a delimiter string that does not exist in confdefs.h, to ease
+# handling of long lines.
+ac_delim='%!_!# '
+for ac_last_try in false false :; do
+ ac_t=`sed -n "/$ac_delim/p" confdefs.h`
+ if test -z "$ac_t"; then
+ break
+ elif $ac_last_try; then
+ { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
+$as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
+ { (exit 1); exit 1; }; }
+ else
+ ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
+ fi
+done
+
+# For the awk script, D is an array of macro values keyed by name,
+# likewise P contains macro parameters if any. Preserve backslash
+# newline sequences.
+
+ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
+sed -n '
+s/.\{148\}/&'"$ac_delim"'/g
+t rset
+:rset
+s/^[ ]*#[ ]*define[ ][ ]*/ /
+t def
+d
+:def
+s/\\$//
+t bsnl
+s/["\\]/\\&/g
+s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
+D["\1"]=" \3"/p
+s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
+d
+:bsnl
+s/["\\]/\\&/g
+s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
+D["\1"]=" \3\\\\\\n"\\/p
+t cont
+s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
+t cont
+d
+:cont
+n
+s/.\{148\}/&'"$ac_delim"'/g
+t clear
+:clear
+s/\\$//
+t bsnlc
+s/["\\]/\\&/g; s/^/"/; s/$/"/p
+d
+:bsnlc
+s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
+b cont
+' <confdefs.h | sed '
+s/'"$ac_delim"'/"\\\
+"/g' >>$CONFIG_STATUS || ac_write_fail=1
+
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+ for (key in D) D_is_set[key] = 1
+ FS = ""
+}
+/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
+ line = \$ 0
+ split(line, arg, " ")
+ if (arg[1] == "#") {
+ defundef = arg[2]
+ mac1 = arg[3]
+ } else {
+ defundef = substr(arg[1], 2)
+ mac1 = arg[2]
+ }
+ split(mac1, mac2, "(") #)
+ macro = mac2[1]
+ prefix = substr(line, 1, index(line, defundef) - 1)
+ if (D_is_set[macro]) {
+ # Preserve the white space surrounding the "#".
+ print prefix "define", macro P[macro] D[macro]
+ next
+ } else {
+ # Replace #undef with comments. This is necessary, for example,
+ # in the case of _POSIX_SOURCE, which is predefined and required
+ # on some systems where configure will not decide to define it.
+ if (defundef == "undef") {
+ print "/*", prefix defundef, macro, "*/"
+ next
+ }
+ }
+}
+{ print }
+_ACAWK
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+ { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
+$as_echo "$as_me: error: could not setup config headers machinery" >&2;}
+ { (exit 1); exit 1; }; }
+fi # test -n "$CONFIG_HEADERS"
+
-for ac_tag in :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS
+eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
+shift
+for ac_tag
do
case $ac_tag in
:[FHLC]) ac_mode=$ac_tag; continue;;
esac
case $ac_mode$ac_tag in
:[FHL]*:*);;
- :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
-echo "$as_me: error: Invalid tag $ac_tag." >&2;}
+ :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
+$as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
{ (exit 1); exit 1; }; };;
:[FH]-) ac_tag=-:-;;
:[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
@@ -7958,26 +8993,38 @@ echo "$as_me: error: Invalid tag $ac_tag." >&2;}
[\\/$]*) false;;
*) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
esac ||
- { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
-echo "$as_me: error: cannot find input file: $ac_f" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
+$as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
{ (exit 1); exit 1; }; };;
esac
- ac_file_inputs="$ac_file_inputs $ac_f"
+ case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
+ ac_file_inputs="$ac_file_inputs '$ac_f'"
done
# Let's still pretend it is `configure' which instantiates (i.e., don't
# use $as_me), people would be surprised to read:
# /* config.h. Generated by config.status. */
- configure_input="Generated from "`IFS=:
- echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
+ configure_input='Generated from '`
+ $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
+ `' by configure.'
if test x"$ac_file" != x-; then
configure_input="$ac_file. $configure_input"
- { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
+ { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
+$as_echo "$as_me: creating $ac_file" >&6;}
fi
+ # Neutralize special characters interpreted by sed in replacement strings.
+ case $configure_input in #(
+ *\&* | *\|* | *\\* )
+ ac_sed_conf_input=`$as_echo "$configure_input" |
+ sed 's/[\\\\&|]/\\\\&/g'`;; #(
+ *) ac_sed_conf_input=$configure_input;;
+ esac
case $ac_tag in
- *:-:* | *:-) cat >"$tmp/stdin";;
+ *:-:* | *:-) cat >"$tmp/stdin" \
+ || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
+$as_echo "$as_me: error: could not create $ac_file" >&2;}
+ { (exit 1); exit 1; }; } ;;
esac
;;
esac
@@ -7987,7 +9034,7 @@ $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$ac_file" : 'X\(//\)[^/]' \| \
X"$ac_file" : 'X\(//\)$' \| \
X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$ac_file" |
+$as_echo X"$ac_file" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -8013,7 +9060,7 @@ echo X"$ac_file" |
as_dirs=
while :; do
case $as_dir in #(
- *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
*) as_qdir=$as_dir;;
esac
as_dirs="'$as_qdir' $as_dirs"
@@ -8022,7 +9069,7 @@ $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_dir" : 'X\(//\)[^/]' \| \
X"$as_dir" : 'X\(//\)$' \| \
X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$as_dir" |
+$as_echo X"$as_dir" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -8043,17 +9090,17 @@ echo X"$as_dir" |
test -d "$as_dir" && break
done
test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
-echo "$as_me: error: cannot create directory $as_dir" >&2;}
+ } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
+$as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
{ (exit 1); exit 1; }; }; }
ac_builddir=.
case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
- ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
# A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
case $ac_top_builddir_sub in
"") ac_top_builddir_sub=. ac_top_build_prefix= ;;
*) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
@@ -8098,12 +9145,13 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
esac
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# If the template does not know about datarootdir, expand it.
# FIXME: This hack should be removed a few years after 2.60.
ac_datarootdir_hack=; ac_datarootdir_seen=
-case `sed -n '/datarootdir/ {
+ac_sed_dataroot='
+/datarootdir/ {
p
q
}
@@ -8112,13 +9160,14 @@ case `sed -n '/datarootdir/ {
/@infodir@/p
/@localedir@/p
/@mandir@/p
-' $ac_file_inputs` in
+'
+case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
*datarootdir*) ac_datarootdir_seen=yes;;
*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
+$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_datarootdir_hack='
s&@datadir@&$datadir&g
s&@docdir@&$docdir&g
@@ -8132,15 +9181,16 @@ _ACEOF
# Neutralize VPATH when `$srcdir' = `.'.
# Shell code in configure.ac might set extrasub.
# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF
- sed "$ac_vpsub
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+ac_sed_extra="$ac_vpsub
$extrasub
_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
:t
/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s&@configure_input@&$configure_input&;t t
+s|@configure_input@|$ac_sed_conf_input|;t t
s&@top_builddir@&$ac_top_builddir_sub&;t t
+s&@top_build_prefix@&$ac_top_build_prefix&;t t
s&@srcdir@&$ac_srcdir&;t t
s&@abs_srcdir@&$ac_abs_srcdir&;t t
s&@top_srcdir@&$ac_top_srcdir&;t t
@@ -8151,121 +9201,60 @@ s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
s&@INSTALL@&$ac_INSTALL&;t t
s&@MKDIR_P@&$ac_MKDIR_P&;t t
$ac_datarootdir_hack
-" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
+"
+eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
+ || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
+$as_echo "$as_me: error: could not create $ac_file" >&2;}
+ { (exit 1); exit 1; }; }
test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
{ ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
{ ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
- { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+ { $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
-echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined. Please make sure it is defined." >&2;}
rm -f "$tmp/stdin"
case $ac_file in
- -) cat "$tmp/out"; rm -f "$tmp/out";;
- *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
- esac
+ -) cat "$tmp/out" && rm -f "$tmp/out";;
+ *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
+ esac \
+ || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
+$as_echo "$as_me: error: could not create $ac_file" >&2;}
+ { (exit 1); exit 1; }; }
;;
:H)
#
# CONFIG_HEADER
#
-_ACEOF
-
-# Transform confdefs.h into a sed script `conftest.defines', that
-# substitutes the proper values into config.h.in to produce config.h.
-rm -f conftest.defines conftest.tail
-# First, append a space to every undef/define line, to ease matching.
-echo 's/$/ /' >conftest.defines
-# Then, protect against being on the right side of a sed subst, or in
-# an unquoted here document, in config.status. If some macros were
-# called several times there might be several #defines for the same
-# symbol, which is useless. But do not sort them, since the last
-# AC_DEFINE must be honored.
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-# These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
-# NAME is the cpp macro being defined, VALUE is the value it is being given.
-# PARAMS is the parameter list in the macro definition--in most cases, it's
-# just an empty string.
-ac_dA='s,^\\([ #]*\\)[^ ]*\\([ ]*'
-ac_dB='\\)[ (].*,\\1define\\2'
-ac_dC=' '
-ac_dD=' ,'
-
-uniq confdefs.h |
- sed -n '
- t rset
- :rset
- s/^[ ]*#[ ]*define[ ][ ]*//
- t ok
- d
- :ok
- s/[\\&,]/\\&/g
- s/^\('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
- s/^\('"$ac_word_re"'\)[ ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
- ' >>conftest.defines
-
-# Remove the space that was appended to ease matching.
-# Then replace #undef with comments. This is necessary, for
-# example, in the case of _POSIX_SOURCE, which is predefined and required
-# on some systems where configure will not decide to define it.
-# (The regexp can be short, since the line contains either #define or #undef.)
-echo 's/ $//
-s,^[ #]*u.*,/* & */,' >>conftest.defines
-
-# Break up conftest.defines:
-ac_max_sed_lines=50
-
-# First sed command is: sed -f defines.sed $ac_file_inputs >"$tmp/out1"
-# Second one is: sed -f defines.sed "$tmp/out1" >"$tmp/out2"
-# Third one will be: sed -f defines.sed "$tmp/out2" >"$tmp/out1"
-# et cetera.
-ac_in='$ac_file_inputs'
-ac_out='"$tmp/out1"'
-ac_nxt='"$tmp/out2"'
-
-while :
-do
- # Write a here document:
- cat >>$CONFIG_STATUS <<_ACEOF
- # First, check the format of the line:
- cat >"\$tmp/defines.sed" <<\\CEOF
-/^[ ]*#[ ]*undef[ ][ ]*$ac_word_re[ ]*\$/b def
-/^[ ]*#[ ]*define[ ][ ]*$ac_word_re[( ]/b def
-b
-:def
-_ACEOF
- sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
- echo 'CEOF
- sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
- ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
- sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
- grep . conftest.tail >/dev/null || break
- rm -f conftest.defines
- mv conftest.tail conftest.defines
-done
-rm -f conftest.defines conftest.tail
-
-echo "ac_result=$ac_in" >>$CONFIG_STATUS
-cat >>$CONFIG_STATUS <<\_ACEOF
if test x"$ac_file" != x-; then
- echo "/* $configure_input */" >"$tmp/config.h"
- cat "$ac_result" >>"$tmp/config.h"
- if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
- { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
-echo "$as_me: $ac_file is unchanged" >&6;}
+ {
+ $as_echo "/* $configure_input */" \
+ && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
+ } >"$tmp/config.h" \
+ || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
+$as_echo "$as_me: error: could not create $ac_file" >&2;}
+ { (exit 1); exit 1; }; }
+ if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
+ { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
+$as_echo "$as_me: $ac_file is unchanged" >&6;}
else
- rm -f $ac_file
- mv "$tmp/config.h" $ac_file
+ rm -f "$ac_file"
+ mv "$tmp/config.h" "$ac_file" \
+ || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
+$as_echo "$as_me: error: could not create $ac_file" >&2;}
+ { (exit 1); exit 1; }; }
fi
else
- echo "/* $configure_input */"
- cat "$ac_result"
+ $as_echo "/* $configure_input */" \
+ && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
+ || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
+$as_echo "$as_me: error: could not create -" >&2;}
+ { (exit 1); exit 1; }; }
fi
- rm -f "$tmp/out12"
-# Compute $ac_file's index in $config_headers.
-_am_arg=$ac_file
+# Compute "$ac_file"'s index in $config_headers.
+_am_arg="$ac_file"
_am_stamp_count=1
for _am_header in $config_headers :; do
case $_am_header in
@@ -8280,7 +9269,7 @@ $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$_am_arg" : 'X\(//\)[^/]' \| \
X"$_am_arg" : 'X\(//\)$' \| \
X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$_am_arg" |
+$as_echo X"$_am_arg" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -8300,8 +9289,8 @@ echo X"$_am_arg" |
s/.*/./; q'`/stamp-h$_am_stamp_count
;;
- :C) { echo "$as_me:$LINENO: executing $ac_file commands" >&5
-echo "$as_me: executing $ac_file commands" >&6;}
+ :C) { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
+$as_echo "$as_me: executing $ac_file commands" >&6;}
;;
esac
@@ -8323,7 +9312,7 @@ $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$mf" : 'X\(//\)[^/]' \| \
X"$mf" : 'X\(//\)$' \| \
X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$mf" |
+$as_echo X"$mf" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -8367,7 +9356,7 @@ $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$file" : 'X\(//\)[^/]' \| \
X"$file" : 'X\(//\)$' \| \
X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$file" |
+$as_echo X"$file" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -8393,7 +9382,7 @@ echo X"$file" |
as_dirs=
while :; do
case $as_dir in #(
- *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
*) as_qdir=$as_dir;;
esac
as_dirs="'$as_qdir' $as_dirs"
@@ -8402,7 +9391,7 @@ $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_dir" : 'X\(//\)[^/]' \| \
X"$as_dir" : 'X\(//\)$' \| \
X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$as_dir" |
+$as_echo X"$as_dir" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -8423,8 +9412,8 @@ echo X"$as_dir" |
test -d "$as_dir" && break
done
test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
-echo "$as_me: error: cannot create directory $as_dir" >&2;}
+ } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
+$as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
{ (exit 1); exit 1; }; }; }
# echo "creating $dirpart/$file"
echo '# dummy' > "$dirpart/$file"
@@ -8442,6 +9431,11 @@ _ACEOF
chmod +x $CONFIG_STATUS
ac_clean_files=$ac_clean_files_save
+test $ac_write_fail = 0 ||
+ { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
+$as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
+ { (exit 1); exit 1; }; }
+
# configure is writing to config.log, and then calls config.status.
# config.status does its own redirection, appending to config.log.
@@ -8469,7 +9463,8 @@ fi
#
if test "$no_recursion" != yes; then
- # Remove --cache-file and --srcdir arguments so they do not pile up.
+ # Remove --cache-file, --srcdir, and --disable-option-checking arguments
+ # so they do not pile up.
ac_sub_configure_args=
ac_prev=
eval "set x $ac_configure_args"
@@ -8498,9 +9493,11 @@ if test "$no_recursion" != yes; then
ac_prev=prefix ;;
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
;;
+ --disable-option-checking)
+ ;;
*)
case $ac_arg in
- *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
esac
ac_sub_configure_args="$ac_sub_configure_args '$ac_arg'" ;;
esac
@@ -8510,7 +9507,7 @@ if test "$no_recursion" != yes; then
# in subdir configurations.
ac_arg="--prefix=$prefix"
case $ac_arg in
- *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
esac
ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
@@ -8519,6 +9516,10 @@ if test "$no_recursion" != yes; then
ac_sub_configure_args="--silent $ac_sub_configure_args"
fi
+ # Always prepend --disable-option-checking to silence warnings, since
+ # different subdirs can have different --enable and --with options.
+ ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
+
ac_popdir=`pwd`
for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
@@ -8527,8 +9528,8 @@ if test "$no_recursion" != yes; then
test -d "$srcdir/$ac_dir" || continue
ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
- echo "$as_me:$LINENO: $ac_msg" >&5
- echo "$ac_msg" >&6
+ $as_echo "$as_me:$LINENO: $ac_msg" >&5
+ $as_echo "$ac_msg" >&6
{ as_dir="$ac_dir"
case $as_dir in #(
-*) as_dir=./$as_dir;;
@@ -8537,7 +9538,7 @@ if test "$no_recursion" != yes; then
as_dirs=
while :; do
case $as_dir in #(
- *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
+ *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
*) as_qdir=$as_dir;;
esac
as_dirs="'$as_qdir' $as_dirs"
@@ -8546,7 +9547,7 @@ $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
X"$as_dir" : 'X\(//\)[^/]' \| \
X"$as_dir" : 'X\(//\)$' \| \
X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-echo X"$as_dir" |
+$as_echo X"$as_dir" |
sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
s//\1/
q
@@ -8567,17 +9568,17 @@ echo X"$as_dir" |
test -d "$as_dir" && break
done
test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
-echo "$as_me: error: cannot create directory $as_dir" >&2;}
+ } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
+$as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
{ (exit 1); exit 1; }; }; }
ac_builddir=.
case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
- ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
+ ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
# A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
+ ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
case $ac_top_builddir_sub in
"") ac_top_builddir_sub=. ac_top_build_prefix= ;;
*) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
@@ -8616,8 +9617,8 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
# This should be Cygnus configure.
ac_sub_configure=$ac_aux_dir/configure
else
- { echo "$as_me:$LINENO: WARNING: no configuration information is in $ac_dir" >&5
-echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
+ { $as_echo "$as_me:$LINENO: WARNING: no configuration information is in $ac_dir" >&5
+$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
ac_sub_configure=
fi
@@ -8630,56 +9631,36 @@ echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
esac
- { echo "$as_me:$LINENO: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
-echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
+ { $as_echo "$as_me:$LINENO: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
+$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
# The eval makes quoting arguments work.
eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
--cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
- { { echo "$as_me:$LINENO: error: $ac_sub_configure failed for $ac_dir" >&5
-echo "$as_me: error: $ac_sub_configure failed for $ac_dir" >&2;}
+ { { $as_echo "$as_me:$LINENO: error: $ac_sub_configure failed for $ac_dir" >&5
+$as_echo "$as_me: error: $ac_sub_configure failed for $ac_dir" >&2;}
{ (exit 1); exit 1; }; }
fi
cd "$ac_popdir"
done
fi
-
-
-if test $build_elfutils = yes; then
- case "$with_elfutils" in
- /*) elfutils_srcdir="$with_elfutils" ;;
- *) elfutils_srcdir="../$with_elfutils" ;;
- esac
- { echo "$as_me:$LINENO: running ${elfutils_srcdir}/configure" >&5
-echo "$as_me: running ${elfutils_srcdir}/configure" >&6;}
- # Our libdw.so's libebl will look in $ORIGIN/../lib/... but that
- # $ORIGIN is where libdw.so resides, which is not where there is a ../lib.
- # Note that $libdir might be using a quoted use of $exec_prefix or $prefix.
- # So we must make sure to pass those settings to elfutils configure.
- elfutils_rpath="-Wl,--enable-new-dtags,-rpath,${libdir}/${PACKAGE_NAME}"
- here=`pwd`
- (mkdir -p build-elfutils && cd build-elfutils &&
- ${elfutils_srcdir}/configure --enable-libebl-subdir=${PACKAGE_NAME} \
- --includedir="${here}/include-elfutils" \
- --libdir="${here}/lib-elfutils" \
- --exec-prefix="$exec_prefix" \
- --prefix="$prefix" \
- CFLAGS="${CFLAGS/-Wall/}" \
- LDFLAGS="$LDFLAGS $elfutils_rpath"
- )
+if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
+ { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
+$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
fi
+
if test "${prefix}" = "/usr/local"; then
- { echo "$as_me:$LINENO: " >&5
-echo "$as_me: " >&6;}
- { echo "$as_me:$LINENO: For a private or temporary build of systemtap, we recommend" >&5
-echo "$as_me: For a private or temporary build of systemtap, we recommend" >&6;}
- { echo "$as_me:$LINENO: configuring with a prefix. For example, try" >&5
-echo "$as_me: configuring with a prefix. For example, try" >&6;}
- { echo "$as_me:$LINENO: $0 $ac_configure_args --prefix=$HOME/systemtap-${PACKAGE_VERSION}-$$" >&5
-echo "$as_me: $0 $ac_configure_args --prefix=$HOME/systemtap-${PACKAGE_VERSION}-$$" >&6;}
- { echo "$as_me:$LINENO: Running systemtap uninstalled, entirely out of the build tree," >&5
-echo "$as_me: Running systemtap uninstalled, entirely out of the build tree," >&6;}
- { echo "$as_me:$LINENO: is not supported." >&5
-echo "$as_me: is not supported." >&6;}
+ { $as_echo "$as_me:$LINENO: " >&5
+$as_echo "$as_me: " >&6;}
+ { $as_echo "$as_me:$LINENO: For a private or temporary build of systemtap, we recommend" >&5
+$as_echo "$as_me: For a private or temporary build of systemtap, we recommend" >&6;}
+ { $as_echo "$as_me:$LINENO: configuring with a prefix. For example, try" >&5
+$as_echo "$as_me: configuring with a prefix. For example, try" >&6;}
+ { $as_echo "$as_me:$LINENO: $0 $ac_configure_args --prefix=$HOME/systemtap-${PACKAGE_VERSION}-$$" >&5
+$as_echo "$as_me: $0 $ac_configure_args --prefix=$HOME/systemtap-${PACKAGE_VERSION}-$$" >&6;}
+ { $as_echo "$as_me:$LINENO: Running systemtap uninstalled, entirely out of the build tree," >&5
+$as_echo "$as_me: Running systemtap uninstalled, entirely out of the build tree," >&6;}
+ { $as_echo "$as_me:$LINENO: is not supported." >&5
+$as_echo "$as_me: is not supported." >&6;}
fi
diff --git a/configure.ac b/configure.ac
index 7b413293..3e0efc95 100644
--- a/configure.ac
+++ b/configure.ac
@@ -94,15 +94,23 @@ AS_IF([test "x$enable_pie" != xno],[
AC_MSG_NOTICE([Compiling with gcc pie et al.])
# LDFLAGS is special since it may be passed down to bundled-elfutils,
# and interfere with the .so's built therein
- PIELDFLAGS="$LDFLAGS -pie -Wl,-z,relro -Wl,-z,now"
+ PIELDFLAGS="$LDFLAGS"
LDFLAGS="$save_LDFLAGS"
+ PIECFLAGS="$CFLAGS"
+ CFLAGS="$save_CFLAGS"
+ PIECXXFLAGS="$CXXFLAGS"
+ CXXFLAGS="$save_CXXFLAGS"
],[
AC_MSG_NOTICE([Compiler does not support -pie et al.])
+ PIECFLAGS=""
CFLAGS="$save_CFLAGS"
+ PIECXXFLAGS=""
CXXFLAGS="$save_CXXFLAGS"
PIELDFLAGS=""
LDFLAGS="$save_LDFLAGS"])])
AC_SUBST(PIELDFLAGS)
+AC_SUBST(PIECFLAGS)
+AC_SUBST(PIECXXFLAGS)
dnl Handle optional sqlite support. If enabled/disabled by the user,
dnl do the right thing. If not specified by the user, use it if
@@ -145,6 +153,7 @@ AC_ARG_ENABLE([crash],
AM_CONDITIONAL([BUILD_CRASHMOD], [test "$enable_crash" != "no"])
dnl Handle the option to build the documentation
+building_docs="no"
AC_ARG_ENABLE([docs],
AS_HELP_STRING([--enable-docs],
[enable building documentation (default on if latex etc. found).]),
@@ -154,12 +163,74 @@ AC_CHECK_PROG(have_latex, latex, yes, no)
AC_CHECK_PROG(have_dvips, dvips, yes, no)
AC_CHECK_PROG(have_ps2pdf, ps2pdf, yes, no)
AC_CHECK_PROG(have_latex2html, latex2html, yes, no)
-if test "$enable_docs" == "yes"; then
- if test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" != "xyesyesyesyes"; then
+if test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" != "xyesyesyesyes"; then
+ if test "$enable_docs" == "yes"; then
AC_MSG_ERROR([cannot find all tools for building documentation])
fi
+ if test "$enable_docs" == "check"; then
+ AC_MSG_WARN([will not build documentation, cannot find all tools])
+ fi
+fi
+if test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" == "xyesyesyesyes" -a "$enable_docs" != "no"; then
+ building_docs="yes"
+fi
+AM_CONDITIONAL([BUILD_DOCS], [test "$building_docs" == "yes"])
+
+dnl Handle the option to build the reference documentation
+building_refdocs="no"
+AC_ARG_ENABLE([refdocs],
+ AS_HELP_STRING([--enable-refdocs],
+ [enable building reference documentation (default on if xmlto etc. found and other documentation built).]),
+ [enable_refdocs=$enableval],
+ [enable_refdocs="check"])
+if test "$building_docs" == "no" -a "$enable_refdocs" == "yes" ; then
+ AC_MSG_ERROR([must use --enable-docs with --enable-refdocs])
+fi
+AC_CHECK_PROG(have_xmlto, xmlto, yes, no)
+if test "x${have_xmlto}" == "xyes"; then
+AC_MSG_CHECKING([for xmlto pdf support])
+cat > conftest.$ac_ext << EOF
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
+"http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" []>
+ <book id="pdffromxml">
+ </book>
+EOF
+ xmlto pdf conftest.$ac_ext >& /dev/null
+ if test $? == 0; then
+ have_xmlto_pdf="yes"
+ AC_MSG_RESULT([yes])
+ else
+ AC_MSG_RESULT([no])
+ fi
+fi
+if test "$enable_refdocs" == "yes"; then
+ if test "x${have_xmlto}${have_xmlto_pdf}" != "xyesyes"; then
+ AC_MSG_ERROR([cannot find proper yxmlto for building reference documentation])
+ fi
+fi
+if test "x${have_xmlto}${have_xmlto_pdf}" == "xyesyes" -a "$enable_refdocs" != "no" -a "${building_docs}" == "yes"; then
+ building_refdocs="yes"
fi
-AM_CONDITIONAL([BUILD_DOCS], [test "x${have_latex}${have_dvips}${have_ps2pdf}${have_latex2html}" == "xyesyesyesyes" -a "$enable_docs" != "no"])
+AM_CONDITIONAL([BUILD_REFDOCS], [test "$building_refdocs" == "yes"])
+
+dnl Handle the option to build the server setup.
+AC_ARG_ENABLE([server],
+ AS_HELP_STRING([--enable-server],
+ [enable building of stap-server/client (default on if nss etc. found).]),
+ [enable_server=$enableval],
+ [enable_server="check"])
+PKG_CHECK_MODULES([nss],[nss >= 3], have_nss=yes, have_nss=no)
+PKG_CHECK_MODULES([nspr],[nspr >= 4], have_nspr=yes, have_nspr=no)
+if test "x${have_nss}${have_nspr}" != "xyesyes"; then
+ if test "$enable_server" == "yes"; then
+ AC_MSG_ERROR([cannot find all libraries for stap-server])
+ fi
+ if test "$enable_server" == "check"; then
+ AC_MSG_WARN([will not build stap-server, cannot find all libraries])
+ fi
+fi
+AM_CONDITIONAL([BUILD_SERVER], [test "x${have_nss}${have_nspr}" == "xyesyes" -a "$enable_server" != "no"])
dnl Handle elfutils. If '--with-elfutils=DIR' wasn't specified, used
dnl the system's elfutils.
@@ -220,13 +291,6 @@ AC_LANG_PUSH(C++)
AC_CHECK_HEADERS([tr1/unordered_map])
AC_LANG_POP(C++)
-AC_CONFIG_HEADERS([config.h:config.in])
-AC_CONFIG_FILES(Makefile doc/Makefile doc/SystemTap_Tapset_Reference/Makefile stap.1 stapprobes.5 stapfuncs.5 stapvars.5 stapex.5 staprun.8 stap-server.8 man/stapprobes.iosched.5 man/stapprobes.netdev.5 man/stapprobes.nfs.5 man/stapprobes.nfsd.5 man/stapprobes.pagefault.5 man/stapprobes.process.5 man/stapprobes.rpc.5 man/stapprobes.scsi.5 man/stapprobes.signal.5 man/stapprobes.socket.5 man/stapprobes.tcp.5 man/stapprobes.udp.5)
-AC_CONFIG_SUBDIRS(testsuite)
-
-AC_CONFIG_FILES([run-stap], [chmod +x run-stap])
-
-AC_OUTPUT
if test $build_elfutils = yes; then
case "$with_elfutils" in
@@ -247,10 +311,32 @@ if test $build_elfutils = yes; then
--exec-prefix="$exec_prefix" \
--prefix="$prefix" \
CFLAGS="${CFLAGS/-Wall/}" \
- LDFLAGS="$LDFLAGS $elfutils_rpath"
+ LDFLAGS="$LDFLAGS $elfutils_rpath" &&
+ make -k install-data # so that elfutils/version.h - if any - may be found.
+ # Note, we need -k because parts (like to po files) might fail,
+ # since those fo to $prefix to which we might not be able to write.
+ # We are only really interested in the include-elfutils files anyway here.
)
+ save_CPPFLAGS=${CPPFLAGS}
+ CPPFLAGS="${CPPFLAGS} -Iinclude-elfutils" # in case bundled elfutils
+ AC_CHECK_HEADERS([elfutils/version.h])
+ CPPFLAGS="$save_CPPFLAGS"
+else
+ AC_CHECK_HEADERS([elfutils/version.h])
fi
+dnl This is here mainly to make sure that configure --prefix=... changes
+dnl the config.h files so files depending on it are recompiled
+dnl prefix is passed through indirectly in the Makefile.am AM_CPPFLAGS.
+dnl Don't use this directly (when not given it is set to NONE).
+AC_DEFINE_UNQUOTED(STAP_PREFIX, "$prefix", [configure prefix location])
+
+AC_CONFIG_HEADERS([config.h:config.in])
+AC_CONFIG_FILES(Makefile doc/Makefile doc/SystemTap_Tapset_Reference/Makefile stap.1 stapprobes.5 stapfuncs.5 stapvars.5 stapex.5 staprun.8 stap-server.8 man/stapprobes.iosched.5 man/stapprobes.netdev.5 man/stapprobes.nfs.5 man/stapprobes.nfsd.5 man/stapprobes.pagefault.5 man/stapprobes.process.5 man/stapprobes.rpc.5 man/stapprobes.scsi.5 man/stapprobes.signal.5 man/stapprobes.socket.5 man/stapprobes.tcp.5 man/stapprobes.udp.5)
+AC_CONFIG_SUBDIRS(testsuite)
+AC_CONFIG_FILES([run-stap], [chmod +x run-stap])
+AC_OUTPUT
+
if test "${prefix}" = "/usr/local"; then
AC_MSG_NOTICE([])
AC_MSG_NOTICE([For a private or temporary build of systemtap, we recommend])
diff --git a/doc/ChangeLog b/doc/ChangeLog
index 9f992132..b3fd1d78 100644
--- a/doc/ChangeLog
+++ b/doc/ChangeLog
@@ -1,3 +1,43 @@
+2009-01-21 William Cohen <wcohen@redhat.com>
+
+ * S_T_R/tapsets.tmpl: Use context-symbols.stp and context-unwind.stp.
+
+2009-01-21 William Cohen <wcohen@redhat.com>
+
+ * S_T_R/tapsets.tmpl: Update copyright date and correct paragraph.
+
+2009-01-12 William Cohen <wcohen@redhat.com>
+
+ * S_T_R/tapsets.tmpl: Correct author's name.
+
+2009-01-07 William Cohen <wcohen@redhat.com>
+
+ * S_T_R/Makefile.am: Use BUILD_REFDOCS.
+ * S_T_R/Makefile.in: Regenerated.
+
+2009-01-06 Frank Ch. Eigler <fche@elastic.org>
+
+ * S_T_R/Makefile.am: Regenerate docs only as necessary, via
+ stamp-* files for html/man, and cmp for tapsets.xml.
+ * S_T_R/Makefile.in: Regenerated.
+
+2008-12-30 Dave Brolley <brolley@redhat.com>
+
+ PR9692
+ * Makefile.in: Regenerated.
+ * SystemTap_Tapset_Reference/Makefile.in: Regenerated.
+
+2008-12-24 Dave Brolley <brolley@redhat.com>
+
+ * Makefile.in: Regenerated.
+ * SystemTap_Tapset_Reference/Makefile.in: Regenerated.
+
+2008-12-21 Will Cohen <wcohen@redhat.com>
+
+ * Makefile.am: Add generations of tapset reference manual material.
+ * SystemTap_Tapset_Reference/Makefile.am: Install tapset reference man.
+ * Makfile.am, SystemTap_Tapset_Reference/Makefile.in: Regenerated.
+
2008-11-26 Will Cohen <wcohen@redhat.com>
* SystemTap_Tapset_Reference/tapsets.tmpl: Add scsi.
diff --git a/doc/Makefile.am b/doc/Makefile.am
index fb228897..55291f7f 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -3,6 +3,7 @@
PDF_FILES = tutorial.pdf langref.pdf
DOC_INSTALL_DIR = $(DESTDIR)$(datadir)/doc/systemtap
+SUBDIRS = SystemTap_Tapset_Reference
if BUILD_DOCS
all-local: $(PDF_FILES)
diff --git a/doc/Makefile.in b/doc/Makefile.in
index c003c742..776381d8 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -1,8 +1,8 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.10 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -42,6 +42,18 @@ CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
SOURCES =
DIST_SOURCES =
+RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
+ html-recursive info-recursive install-data-recursive \
+ install-dvi-recursive install-exec-recursive \
+ install-html-recursive install-info-recursive \
+ install-pdf-recursive install-ps-recursive install-recursive \
+ installcheck-recursive installdirs-recursive pdf-recursive \
+ ps-recursive uninstall-recursive
+RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
+ distclean-recursive maintainer-clean-recursive
+ETAGS = etags
+CTAGS = ctags
+DIST_SUBDIRS = $(SUBDIRS)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
ACLOCAL = @ACLOCAL@
AMTAR = @AMTAR@
@@ -90,6 +102,7 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PIELDFLAGS = @PIELDFLAGS@
+PKG_CONFIG = @PKG_CONFIG@
PROCFLAGS = @PROCFLAGS@
RANLIB = @RANLIB@
SET_MAKE = @SET_MAKE@
@@ -121,6 +134,7 @@ have_dvips = @have_dvips@
have_latex = @have_latex@
have_latex2html = @have_latex2html@
have_ps2pdf = @have_ps2pdf@
+have_xmlto = @have_xmlto@
host_alias = @host_alias@
htmldir = @htmldir@
includedir = @includedir@
@@ -132,6 +146,10 @@ localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
+nspr_CFLAGS = @nspr_CFLAGS@
+nspr_LIBS = @nspr_LIBS@
+nss_CFLAGS = @nss_CFLAGS@
+nss_LIBS = @nss_LIBS@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@
@@ -150,8 +168,9 @@ top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
PDF_FILES = tutorial.pdf langref.pdf
DOC_INSTALL_DIR = $(DESTDIR)$(datadir)/doc/systemtap
+SUBDIRS = SystemTap_Tapset_Reference
SUFFIXES = ps pdf dvi ps tex
-all: all-am
+all: all-recursive
.SUFFIXES:
.SUFFIXES: ps pdf dvi ps tex .dvi .pdf .ps .tex
@@ -184,12 +203,137 @@ $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+# This directory's subdirectories are mostly independent; you can cd
+# into them and run `make' without going through this Makefile.
+# To change the values of `make' variables: instead of editing Makefiles,
+# (1) if the variable is set in `config.status', edit `config.status'
+# (which will cause the Makefiles to be regenerated when you run `make');
+# (2) otherwise, pass the desired values on the `make' command line.
+$(RECURSIVE_TARGETS):
+ @failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ dot_seen=no; \
+ target=`echo $@ | sed s/-recursive//`; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ dot_seen=yes; \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done; \
+ if test "$$dot_seen" = "no"; then \
+ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
+ fi; test -z "$$fail"
+
+$(RECURSIVE_CLEAN_TARGETS):
+ @failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ dot_seen=no; \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ rev=''; for subdir in $$list; do \
+ if test "$$subdir" = "."; then :; else \
+ rev="$$subdir $$rev"; \
+ fi; \
+ done; \
+ rev="$$rev ."; \
+ target=`echo $@ | sed s/-recursive//`; \
+ for subdir in $$rev; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done && test -z "$$fail"
+tags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
+ done
+ctags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+ done
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ mkid -fID $$unique
tags: TAGS
-TAGS:
+TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
+ include_option=--etags-include; \
+ empty_fix=.; \
+ else \
+ include_option=--include; \
+ empty_fix=; \
+ fi; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test ! -f $$subdir/TAGS || \
+ tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+ fi; \
+ done; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$tags $$unique; \
+ fi
ctags: CTAGS
-CTAGS:
-
+CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ test -z "$(CTAGS_ARGS)$$tags$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$tags $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && cd $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) $$here
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -217,20 +361,38 @@ distdir: $(DISTFILES)
|| exit 1; \
fi; \
done
+ list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test -d "$(distdir)/$$subdir" \
+ || $(MKDIR_P) "$(distdir)/$$subdir" \
+ || exit 1; \
+ distdir=`$(am__cd) $(distdir) && pwd`; \
+ top_distdir=`$(am__cd) $(top_distdir) && pwd`; \
+ (cd $$subdir && \
+ $(MAKE) $(AM_MAKEFLAGS) \
+ top_distdir="$$top_distdir" \
+ distdir="$$distdir/$$subdir" \
+ am__remove_distdir=: \
+ am__skip_length_check=: \
+ distdir) \
+ || exit 1; \
+ fi; \
+ done
check-am: all-am
-check: check-am
+check: check-recursive
@BUILD_DOCS_FALSE@all-local:
all-am: Makefile all-local
-installdirs:
-install: install-am
-install-exec: install-exec-am
-install-data: install-data-am
-uninstall: uninstall-am
+installdirs: installdirs-recursive
+installdirs-am:
+install: install-recursive
+install-exec: install-exec-recursive
+install-data: install-data-recursive
+uninstall: uninstall-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-installcheck: installcheck-am
+installcheck: installcheck-recursive
install-strip:
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
@@ -249,21 +411,21 @@ maintainer-clean-generic:
@BUILD_DOCS_FALSE@uninstall-local:
@BUILD_DOCS_FALSE@clean-local:
@BUILD_DOCS_FALSE@install-data-hook:
-clean: clean-am
+clean: clean-recursive
clean-am: clean-generic clean-local mostlyclean-am
-distclean: distclean-am
+distclean: distclean-recursive
-rm -f Makefile
-distclean-am: clean-am distclean-generic
+distclean-am: clean-am distclean-generic distclean-tags
-dvi: dvi-am
+dvi: dvi-recursive
dvi-am:
-html: html-am
+html: html-recursive
-info: info-am
+info: info-recursive
info-am:
@@ -271,52 +433,56 @@ install-data-am:
@$(NORMAL_INSTALL)
$(MAKE) $(AM_MAKEFLAGS) install-data-hook
-install-dvi: install-dvi-am
+install-dvi: install-dvi-recursive
install-exec-am:
-install-html: install-html-am
+install-html: install-html-recursive
-install-info: install-info-am
+install-info: install-info-recursive
install-man:
-install-pdf: install-pdf-am
+install-pdf: install-pdf-recursive
-install-ps: install-ps-am
+install-ps: install-ps-recursive
installcheck-am:
-maintainer-clean: maintainer-clean-am
+maintainer-clean: maintainer-clean-recursive
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
-mostlyclean: mostlyclean-am
+mostlyclean: mostlyclean-recursive
mostlyclean-am: mostlyclean-generic
-pdf: pdf-am
+pdf: pdf-recursive
pdf-am:
-ps: ps-am
+ps: ps-recursive
ps-am:
uninstall-am: uninstall-local
-.MAKE: install-am install-data-am install-strip
-
-.PHONY: all all-am all-local check check-am clean clean-generic \
- clean-local distclean distclean-generic distdir dvi dvi-am \
- html html-am info info-am install install-am install-data \
- install-data-am install-data-hook install-dvi install-dvi-am \
- install-exec install-exec-am install-html install-html-am \
- install-info install-info-am install-man install-pdf \
- install-pdf-am install-ps install-ps-am install-strip \
- installcheck installcheck-am installdirs maintainer-clean \
+.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \
+ install-data-am install-strip
+
+.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
+ all all-am all-local check check-am clean clean-generic \
+ clean-local ctags ctags-recursive distclean distclean-generic \
+ distclean-tags distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am \
+ install-data-hook install-dvi install-dvi-am install-exec \
+ install-exec-am install-html install-html-am install-info \
+ install-info-am install-man install-pdf install-pdf-am \
+ install-ps install-ps-am install-strip installcheck \
+ installcheck-am installdirs installdirs-am maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
- pdf-am ps ps-am uninstall uninstall-am uninstall-local
+ pdf-am ps ps-am tags tags-recursive uninstall uninstall-am \
+ uninstall-local
@BUILD_DOCS_TRUE@all-local: $(PDF_FILES)
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Array-Operations.xml b/doc/SystemTap_Beginners_Guide/en-US/Array-Operations.xml
index 789bf607..00a8673c 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Array-Operations.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Array-Operations.xml
@@ -505,7 +505,7 @@ probe timer.s(3)
}
</screen>
-<para>This <command>foreach</command> statement instructs the script to process the elements in the array <command>reads</command> in descending order (of associated value). The <command>limit 10</command> option instructs the script to only process the first ten elements in the array (i.e. the first 10, starting with the highest value).</para>
+<para>This <command>foreach</command> statement instructs the script to process the elements in the array <command>reads</command> in descending order (of associated value). The <command>limit 10</command> option instructs the <command>foreach</command> to only process the first ten iterations (i.e. print the first 10, starting with the highest value).</para>
</section>
<section id="arrayops-deleting">
@@ -665,7 +665,7 @@ probe vfs.read
probe timer.s(3)
{
printf("=======\n")
- foreach (count in reads+)
+ foreach (count in reads-)
printf("%s : %d \n", count, reads[count])
delete reads
}
@@ -673,7 +673,7 @@ probe timer.s(3)
probe end
{
printf("TOTALS\n")
- foreach (total in totalreads+)
+ foreach (total in totalreads-)
printf("%s : %d \n", total, totalreads[total])
}
</screen>
@@ -788,7 +788,7 @@ probe timer.s(3)
</formalpara>
<screen>
-if([<replaceable>index_expression</replaceable>] in <replaceable>array_name</replaceable>)
+if([<replaceable>index_expression</replaceable>] in <replaceable>array_name</replaceable>) <replaceable>statement</replaceable>
</screen>
<para>To illustrate this, consider the following example:</para>
@@ -962,23 +962,23 @@ probe vfs.read
<indexterm>
<primary>array operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>count (integer extractor)</tertiary>
+<tertiary>@count (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>count (integer extractor)</tertiary>
+<tertiary>@count (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>computing for statistical aggregates</primary>
<secondary>array operations</secondary>
-<tertiary>count (integer extractor)</tertiary>
+<tertiary>@count (integer extractor)</tertiary>
</indexterm>
<indexterm>
-<primary>count (integer extractor)</primary>
+ <primary>@count (integer extractor)</primary>
<secondary>computing for statistical aggregates</secondary>
<tertiary>array operations</tertiary>
</indexterm>
@@ -997,23 +997,23 @@ probe vfs.read
<indexterm>
<primary>array operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>sum (integer extractor)</tertiary>
+<tertiary>@sum (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>sum (integer extractor)</tertiary>
+<tertiary>@sum (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>computing for statistical aggregates</primary>
<secondary>array operations</secondary>
-<tertiary>sum (integer extractor)</tertiary>
+<tertiary>@sum (integer extractor)</tertiary>
</indexterm>
<indexterm>
-<primary>sum (integer extractor)</primary>
+ <primary>@sum (integer extractor)</primary>
<secondary>computing for statistical aggregates</secondary>
<tertiary>array operations</tertiary>
</indexterm>
@@ -1033,23 +1033,23 @@ probe vfs.read
<indexterm>
<primary>array operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>min (integer extractor)</tertiary>
+<tertiary>@min (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>min (integer extractor)</tertiary>
+<tertiary>@min (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>computing for statistical aggregates</primary>
<secondary>array operations</secondary>
-<tertiary>min (integer extractor)</tertiary>
+<tertiary>@min (integer extractor)</tertiary>
</indexterm>
<indexterm>
-<primary>min (integer extractor)</primary>
+ <primary>@min (integer extractor)</primary>
<secondary>computing for statistical aggregates</secondary>
<tertiary>array operations</tertiary>
</indexterm>
@@ -1069,23 +1069,23 @@ probe vfs.read
<indexterm>
<primary>array operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>max (integer extractor)</tertiary>
+<tertiary>@max (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>max (integer extractor)</tertiary>
+<tertiary>@max (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>computing for statistical aggregates</primary>
<secondary>array operations</secondary>
-<tertiary>max (integer extractor)</tertiary>
+<tertiary>@max (integer extractor)</tertiary>
</indexterm>
<indexterm>
-<primary>max (integer extractor)</primary>
+ <primary>@max (integer extractor)</primary>
<secondary>computing for statistical aggregates</secondary>
<tertiary>array operations</tertiary>
</indexterm>
@@ -1105,23 +1105,23 @@ probe vfs.read
<indexterm>
<primary>array operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>avg (integer extractor)</tertiary>
+<tertiary>@avg (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>operations</primary>
<secondary>computing for statistical aggregates</secondary>
-<tertiary>avg (integer extractor)</tertiary>
+<tertiary>@avg (integer extractor)</tertiary>
</indexterm>
<indexterm>
<primary>computing for statistical aggregates</primary>
<secondary>array operations</secondary>
-<tertiary>avg (integer extractor)</tertiary>
+<tertiary>@avg (integer extractor)</tertiary>
</indexterm>
<indexterm>
-<primary>avg (integer extractor)</primary>
+ <primary>@avg (integer extractor)</primary>
<secondary>computing for statistical aggregates</secondary>
<tertiary>array operations</tertiary>
</indexterm>
@@ -1163,7 +1163,7 @@ probe vfs.read
}
probe timer.s(3)
{
- foreach([var1,var2] in reads)
+ foreach([var1,var2] in reads)
printf("%s (%d) : %d \n", var1, var2, @count(reads[var1,var2]))
}
</programlisting>
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Arrays.xml b/doc/SystemTap_Beginners_Guide/en-US/Arrays.xml
index 63c3df04..3d3dec01 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Arrays.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Arrays.xml
@@ -6,7 +6,7 @@
<title>Associative Arrays</title>
<indexterm>
<primary>arrays</primary>
-<secondary>introduction</secondary>
+<seealso>associative arrays</seealso>
</indexterm>
<indexterm>
@@ -20,11 +20,13 @@
<!-- next 2 indexterms for key pairs -->
+<!--
<indexterm>
<primary>arrays</primary>
<secondary>introduction</secondary>
<tertiary>key pairs</tertiary>
</indexterm>
+-->
<indexterm>
<primary>associative arrays</primary>
@@ -38,14 +40,14 @@
<tertiary>arrays</tertiary>
</indexterm>
-<!-- next 2 indexterms for unique keys -->
+<!-- next 2 indexterms for unique keys
<indexterm>
<primary>arrays</primary>
<secondary>introduction</secondary>
<tertiary>unique keys</tertiary>
</indexterm>
-
+-->
<indexterm>
<primary>associative arrays</primary>
<secondary>introduction</secondary>
@@ -58,14 +60,14 @@
<tertiary>arrays</tertiary>
</indexterm>
-<!-- next 2 indexterms for associated values -->
+<!-- next 2 indexterms for associated values
<indexterm>
<primary>arrays</primary>
<secondary>introduction</secondary>
<tertiary>associated values</tertiary>
</indexterm>
-
+-->
<indexterm>
<primary>associative arrays</primary>
<secondary>introduction</secondary>
@@ -78,14 +80,14 @@
<tertiary>arrays</tertiary>
</indexterm>
-<!-- next 2 indexterms for index expression -->
+<!-- next 2 indexterms for index expression
<indexterm>
<primary>arrays</primary>
<secondary>introduction</secondary>
<tertiary>index expression</tertiary>
</indexterm>
-
+-->
<indexterm>
<primary>associative arrays</primary>
<secondary>introduction</secondary>
@@ -99,13 +101,13 @@
</indexterm>
<para>Since associative arrays are normally processed in multiple probes (as we will demonstrate later), they are declared as <command>global</command> variables in the SystemTap script. The syntax for accessing an element in an associative array is similar to that of <command>awk</command>, and is as follows:</para>
-<!-- next 3 indexterms for syntax -->
+<!-- next 3 indexterms for syntax
<indexterm>
<primary>arrays</primary>
<secondary>introduction</secondary>
<tertiary>syntax</tertiary>
</indexterm>
-
+-->
<indexterm>
<primary>associative arrays</primary>
<secondary>introduction</secondary>
@@ -131,14 +133,14 @@
<para>Here, the <command><replaceable>array_name</replaceable></command> is any arbitrary name the array uses. The <command><replaceable>index_expression</replaceable></command> is used to refer to a specific unique key in the array. To illustrate, let us try to build an array named <command>foo</command> that specifies the ages of three people (i.e. the unique keys): <command>tom</command>, <command>dick</command>, and <command>harry</command>. To assign them the ages (i.e. associated values) of 23, 24, and 25 respectively, we'd use the following array statements:</para>
-<!-- next 2 indexterms for example -->
+<!-- next 2 indexterms for example
<indexterm>
<primary>arrays</primary>
<secondary>introduction</secondary>
<tertiary>example</tertiary>
</indexterm>
-
+-->
<indexterm>
<primary>associative arrays</primary>
<secondary>introduction</secondary>
@@ -159,7 +161,7 @@ foo["harry"] = 25
</screen>
</example>
-<para>You can specify up to 5 index expressons in an array statement, each one delimited by a comma (<command>,</command>). This is useful if you wish to have a key that contains multiple pieces of information. The following line from <xref linkend="scriptdisktop"/> uses 5 elements for the key: process ID, executable name, user ID, parent ID, and string "W". It associates the value of <command>devname</command> with that key.</para>
+<para>You can specify up to 5 index expressons in an array statement, each one delimited by a comma (<command>,</command>). This is useful if you wish to have a key that contains multiple pieces of information. The following line from <xref linkend="scriptdisktop"/> uses 5 elements for the key: process ID, executable name, user ID, parent process ID, and string "W". It associates the value of <command>devname</command> with that key.</para>
<screen>
device[pid(),execname(),uid(),ppid(),"W"] = devname
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Errors.xml b/doc/SystemTap_Beginners_Guide/en-US/Errors.xml
index ffb70470..62e89580 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Errors.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Errors.xml
@@ -101,7 +101,7 @@
replicate?</remark>
<para>
- The following invalid SystemTap script is missing the its probe
+ The following invalid SystemTap script is missing its probe
handlers:
</para>
@@ -473,8 +473,9 @@ probe syscall.open
<computeroutput><replaceable>foo</replaceable></computeroutput> refers
to. This usually means that SystemTap could not find a match for
<computeroutput><replaceable>foo</replaceable></computeroutput> in the
- tapset library. The <replaceable>N</replaceable> refers to the column
- the error occurred in.</para>
+ tapset library. The <replaceable>N</replaceable> refers to the
+ line and column of
+ the error.</para>
</formalpara>
<remark>how to explain N in previous? "The divergence from the “tree” of probe point namespace is at position N (starting with zero at left)." (from tutorial) </remark>
@@ -807,6 +808,7 @@ An array containing aggregate values contains too many distinct key pairs at thi
<para>
Too many levels of function call nesting were attempted.
+ The default nesting of function calls allowed is 10.
</para>
</formalpara>
@@ -843,7 +845,9 @@ An array containing aggregate values contains too many distinct key pairs at thi
<tertiary>understainding SystemTap errors</tertiary>
</indexterm>
<para>
- The probe handler attempted to execute too many statements in the probe handler.
+ The probe handler attempted to execute too many statements in the
+ probe handler. The default number of actions allow in a probe handler
+ is 1000.
</para>
</formalpara>
diff --git a/doc/SystemTap_Beginners_Guide/en-US/ScriptConstructs.xml b/doc/SystemTap_Beginners_Guide/en-US/ScriptConstructs.xml
index a139015d..89334eff 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/ScriptConstructs.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/ScriptConstructs.xml
@@ -45,7 +45,7 @@
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>SystemTap handler constructs</secondary>
<tertiary>variables</tertiary>
</indexterm>
@@ -73,7 +73,7 @@ name, assign a value from a function or expression to it, and use it in an expre
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>SystemTap handler constructs</secondary>
<tertiary><command>global</command></tertiary>
</indexterm>
@@ -130,7 +130,7 @@ probe timer.jiffies(100) { count_jiffies ++ }
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>conditional statements</secondary>
</indexterm>
<para>
@@ -153,7 +153,7 @@ You can do this by using <emphasis>conditionals</emphasis> in handlers. SystemTa
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>conditional statements</secondary>
<tertiary>if/else</tertiary>
</indexterm>
@@ -177,7 +177,8 @@ The <command><replaceable>statement1</replaceable></command> is executed if the
<command><replaceable>condition</replaceable></command> expression is
non-zero. The <command><replaceable>statement2</replaceable></command> is
executed if the <command><replaceable>condition</replaceable></command>
-expression is zero. The <command>else</command> is optional. Both
+expression is zero. The <command>else</command> clause
+(<command>else</command> <replaceable>statement2</replaceable>)is optional. Both
<command><replaceable>statement1</replaceable></command> and
<command><replaceable>statement2</replaceable></command> can be statement
blocks.
@@ -219,7 +220,7 @@ probe end
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>conditional statements</secondary>
<tertiary>while loops</tertiary>
</indexterm>
@@ -271,7 +272,7 @@ printf("goodbye world\n")
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>conditional statements</secondary>
<tertiary>for loops</tertiary>
</indexterm>
@@ -326,7 +327,7 @@ while (<replaceable>conditional</replaceable>) {
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>conditional statements</secondary>
<tertiary>conditional operators</tertiary>
</indexterm>
@@ -374,7 +375,7 @@ while (<replaceable>conditional</replaceable>) {
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>SystemTap handler constructs</secondary>
<tertiary>command-line arguments</tertiary>
</indexterm>
@@ -407,7 +408,7 @@ probe kernel.function(@1).return { }
</indexterm>
<indexterm>
-<primary>SystemTap handlers</primary>
+ <primary>SystemTap statements</primary>
<secondary>SystemTap handler constructs</secondary>
<tertiary>variable notations</tertiary>
</indexterm>
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Scripts.xml b/doc/SystemTap_Beginners_Guide/en-US/Scripts.xml
index a0fc7d52..88aa42ab 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Scripts.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Scripts.xml
@@ -129,7 +129,7 @@
</indexterm>
<para>
SystemTap scripts use the file extension <filename>.stp</filename>, and
- are conatains probes written in the following format:
+ contains probes written in the following format:
</para>
</formalpara>
<screen>
@@ -547,14 +547,14 @@ probe timer.s(4)
</section>
<!-- stophere -->
- <section id="systemtapscript-handler">
- <title>Systemtap Handler/Body</title>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>introduction</secondary>
-</indexterm>
- <para> Consider the following sample script: </para>
-
+<section id="systemtapscript-handler">
+ <title>Systemtap Handler/Body</title>
+ <indexterm>
+ <primary>handlers</primary>
+ <secondary>introduction</secondary>
+ </indexterm>
+ <para> Consider the following sample script: </para>
+
<example id="helloworld"><title>helloworld.stp</title>
<programlisting>
probe begin
@@ -564,108 +564,108 @@ probe begin
}
</programlisting>
</example>
-
- <para>
- In <xref linkend="helloworld"/>, the event <command>begin</command>
- (i.e. the start of the session) triggers the handler enclosed in
- <command>{ }</command>, which simply prints <command>hello
- world</command>, then exits.
- </para>
-
- <note>
- <title>Note</title>
-<indexterm>
-<primary>Handlers</primary>
-<secondary><command>exit()</command></secondary>
-</indexterm>
-
-<indexterm>
-<primary><command>exit()</command></primary>
-<secondary>Handlers</secondary>
-</indexterm>
- <para>
- SystemTap scripts continue to run until the
- <command>exit()</command> function executes. If the users wants to stop
- the execution of the script, it can interrupted manually with
- <keycombo><keycap>Ctrl</keycap><keycap>C</keycap></keycombo>.
- </para>
- </note>
-
- <formalpara id="printf">
- <title>printf ( ) Statements</title>
-<indexterm>
- <primary><command>printf()</command></primary>
- <secondary>format strings</secondary>
- </indexterm>
-
- <para>
- The <command>printf ()</command> statement is one of the simplest
- functions for printing data. <command>printf ()</command> can also be
- used to display data using a wide variety of SystemTap functions in the
- following format:
- </para>
- </formalpara>
-
-
-<programlisting>
-printf ("<replaceable>format string</replaceable>\n", <replaceable>arguments</replaceable>)
-</programlisting>
-<indexterm>
-<primary><command>printf()</command></primary>
-<secondary>format strings</secondary>
-</indexterm>
-
-<indexterm>
-<primary>format strings</primary>
-<secondary><command>printf()</command></secondary>
-</indexterm>
- <para>
- The <replaceable>format string</replaceable> specifies how
- <replaceable>arguments</replaceable> should be printed. The format string
- of <xref linkend="helloworld"/> simply instructs SystemTap to print
- <command>hello world</command>, and contains no format specifiers.
- </para>
-<indexterm>
-<primary><command>printf()</command></primary>
-<secondary>format specifiers</secondary>
-</indexterm>
-
-<indexterm>
-<primary>format specifiers</primary>
-<secondary><command>printf()</command></secondary>
-</indexterm>
- <para>
- You can use the format specifiers <command>%s</command> (for strings)
- and <command>%d</command> (for numbers) in format strings, depending on
- your list of arguments. Format strings can have multiple format
- specifiers, each matching a corresponding argument; multiple arguments
- are delimited by a comma (<command>,</command>).
- </para>
-
- <note>
- <title>Note</title>
-<indexterm>
-<primary><command>printf()</command></primary>
-<secondary>syntax and format</secondary>
-</indexterm>
-
-<indexterm>
-<primary>syntax and format</primary>
-<secondary><command>printf()</command></secondary>
-</indexterm>
-<indexterm>
-<primary>format and syntax</primary>
-<secondary><command>printf()</command></secondary>
-</indexterm>
- <para>Semantically, the SystemTap <command>printf</command> function is
- very similar to its C language counterpart. The aforementioned syntax
- and format for SystemTap's <command>printf</command> function is
- identical to that of the C-style <command>printf</command>.
- </para>
- </note>
-
- <para> To illustrate this, consider the following probe example: </para>
-
+
+ <para>
+ In <xref linkend="helloworld"/>, the event <command>begin</command>
+ (i.e. the start of the session) triggers the handler enclosed in
+ <command>{ }</command>, which simply prints <command>hello
+ world</command> followed by a new-line, then exits.
+ </para>
+
+ <note>
+ <title>Note</title>
+ <indexterm>
+ <primary>functions (used in handlers)</primary>
+ <secondary><command>exit()</command></secondary>
+ </indexterm>
+
+ <indexterm>
+ <primary><command>exit()</command></primary>
+ <secondary>functions</secondary>
+ </indexterm>
+ <para>
+ SystemTap scripts continue to run until the
+ <command>exit()</command> function executes. If the users wants to stop
+ the execution of the script, it can interrupted manually with
+ <keycombo><keycap>Ctrl</keycap><keycap>C</keycap></keycombo>.
+ </para>
+ </note>
+
+ <formalpara id="printf">
+ <title>printf ( ) Statements</title>
+ <indexterm>
+ <primary><command>printf()</command></primary>
+ <secondary>format strings</secondary>
+ </indexterm>
+
+ <para>
+ The <command>printf ()</command> statement is one of the simplest
+ functions for printing data. <command>printf ()</command> can also be
+ used to display data using a wide variety of SystemTap functions in the
+ following format:
+ </para>
+ </formalpara>
+
+
+ <programlisting>
+ printf ("<replaceable>format string</replaceable>\n", <replaceable>arguments</replaceable>)
+ </programlisting>
+ <indexterm>
+ <primary><command>printf()</command></primary>
+ <secondary>format strings</secondary>
+ </indexterm>
+
+ <indexterm>
+ <primary>format strings</primary>
+ <secondary><command>printf()</command></secondary>
+ </indexterm>
+ <para>
+ The <replaceable>format string</replaceable> specifies how
+ <replaceable>arguments</replaceable> should be printed. The format string
+ of <xref linkend="helloworld"/> simply instructs SystemTap to print
+ <command>hello world</command>, and contains no format specifiers.
+ </para>
+ <indexterm>
+ <primary><command>printf()</command></primary>
+ <secondary>format specifiers</secondary>
+ </indexterm>
+
+ <indexterm>
+ <primary>format specifiers</primary>
+ <secondary><command>printf()</command></secondary>
+ </indexterm>
+ <para>
+ You can use the format specifiers <command>%s</command> (for strings)
+ and <command>%d</command> (for numbers) in format strings, depending on
+ your list of arguments. Format strings can have multiple format
+ specifiers, each matching a corresponding argument; multiple arguments
+ are delimited by a comma (<command>,</command>).
+ </para>
+
+ <note>
+ <title>Note</title>
+ <indexterm>
+ <primary><command>printf()</command></primary>
+ <secondary>syntax and format</secondary>
+ </indexterm>
+
+ <indexterm>
+ <primary>syntax and format</primary>
+ <secondary><command>printf()</command></secondary>
+ </indexterm>
+ <indexterm>
+ <primary>format and syntax</primary>
+ <secondary><command>printf()</command></secondary>
+ </indexterm>
+ <para>Semantically, the SystemTap <command>printf</command> function is
+ very similar to its C language counterpart. The aforementioned syntax
+ and format for SystemTap's <command>printf</command> function is
+ identical to that of the C-style <command>printf</command>.
+ </para>
+ </note>
+
+ <para> To illustrate this, consider the following probe example: </para>
+
<example id="syscall-open">
<title>variables-in-printf-statements.stp</title>
<programlisting>
@@ -675,19 +675,19 @@ probe syscall.open
}
</programlisting>
</example>
-
- <para>
- <xref linkend="syscall-open"/> instructs SystemTap to probe all entries to
- the system call <command>open</command>; for each event, it prints the
- current <command>execname()</command> (a string with the executable name) and
- <command>pid()</command> (the current process ID number), followed by the word
- <command>open</command>. A snippet of this probe's output would look like:
- </para>
-
- <remark>editorial review: does a clarification that "format specifier1" is
- to "argument1", "format specifier2" is to "argument2", or is this clear
- enough? </remark>
-
+
+ <para>
+ <xref linkend="syscall-open"/> instructs SystemTap to probe all entries to
+ the system call <command>open</command>; for each event, it prints the
+ current <command>execname()</command> (a string with the executable name) and
+ <command>pid()</command> (the current process ID number), followed by the word
+ <command>open</command>. A snippet of this probe's output would look like:
+ </para>
+
+ <remark>editorial review: does a clarification that "format specifier1" is
+ to "argument1", "format specifier2" is to "argument2", or is this clear
+ enough? </remark>
+
<screen>
vmware-guestd(2206) open
hald(2360) open
@@ -698,245 +698,253 @@ df(3433) open
df(3433) open
hald(2360) open
</screen>
-
- <formalpara id="systemtapscript-functions">
- <title>SystemTap Functions</title>
-<indexterm>
-<primary>functions</primary>
-</indexterm>
-
-<indexterm>
-<primary>SystemTap script functions</primary>
-</indexterm>
-
-<indexterm>
- <primary>Handlers</primary>
- <secondary>handler functions</secondary>
-</indexterm>
-
-<indexterm>
- <primary>handler functions</primary>
- <secondary>Handlers</secondary>
-</indexterm>
-
- <para>
- SystemTap supports a wide variety of functions that can be used as
- <command>printf ()</command> arguments. <xref linkend="syscall-open"/>
- uses the SystemTap functions <command>execname()</command> (name of the
- process that called a kernel function/performed a system call) and
- <command>pid()</command> (current process ID).
- </para>
- </formalpara>
-
- <remark>is "handler function" an appropriate term? wcohen: use "SystemTap functions" to match up language in man pages</remark>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-</indexterm>
-
- <para>The following is a list of commonly-used SystemTap functions:</para>
-<variablelist>
-
-<varlistentry>
- <term>tid()</term>
- <listitem>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>tid()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>tid()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>tid()</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
-
- <para>The ID of the current thread.</para>
- </listitem>
-</varlistentry>
-
-<varlistentry>
- <term>uid()</term>
- <listitem>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>uid()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>uid()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>uid()</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
- <para>The ID of the current user.</para>
- </listitem>
-</varlistentry>
-
-<varlistentry>
- <term>cpu()</term>
- <listitem>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>cpu()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>cpu()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>cpu()</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
- <para>The current CPU number.</para>
- </listitem>
-</varlistentry>
-
-<varlistentry>
- <term>gettimeofday_s()</term>
- <listitem>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>gettimeofday_s()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>gettimeofday_s()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>gettimeofday_s()</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
-
- <para>The number of seconds since UNIX epoch (January 1, 1970).</para>
- </listitem>
-</varlistentry>
-
-<varlistentry>
- <term>ctime()</term>
- <listitem>
+
+ <formalpara id="systemtapscript-functions">
+ <title>SystemTap Functions</title>
+ <indexterm>
+ <primary>functions</primary>
+ </indexterm>
+
+ <indexterm>
+ <primary>SystemTap script functions</primary>
+ </indexterm>
+
+ <indexterm>
+ <primary>handler functions</primary>
+ </indexterm>
+
<para>
- Convert number of seconds since UNIX epoch to date.</para>
- </listitem>
-</varlistentry>
-
-<!--
-<varlistentry>
- <term>get_cycles()</term>
- <listitem>
- <para>A snapshot of the hardware cycle counter.</para>
- </listitem>
-</varlistentry>
--->
-
-<varlistentry>
- <term>pp()</term>
- <listitem>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>pp()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>pp()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>pp()</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
- <para>A string describing the probe point currently being handled.</para>
- </listitem>
-</varlistentry>
-<!-- removed, doesnt work as expected anymore
-<varlistentry>
- <term>probefunc()</term>
- <listitem>
- <para>If known, the name of the function in which the probe was placed.</para>
- </listitem>
-</varlistentry>
--->
-
-<varlistentry>
- <term>thread_indent()</term>
- <listitem>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>thread_indent()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>thread_indent()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>thread_indent()</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
- <para>
- This particular function is quite useful, providing you with a way
- to better organize your print results. The function takes one
- argument, an indentation delta, which indicates how many
- spaces to add or remove from a thread's "indentation counter".
- It then returns a
- string with some generic trace data along with an appropriate number
- of indentation spaces.
- </para>
+ SystemTap supports a wide variety of functions that can be used as
+ <command>printf ()</command> arguments. <xref linkend="syscall-open"/>
+ uses the SystemTap functions <command>execname()</command> (name of the
+ process that called a kernel function/performed a system call) and
+ <command>pid()</command> (current process ID).
+ </para>
+ </formalpara>
+
+ <remark>is "handler function" an appropriate term? wcohen: use "SystemTap functions" to match up language in man pages</remark>
+
+ <para>The following is a list of commonly-used SystemTap functions:</para>
+ <variablelist>
- <para>
- The generic data included in the returned string includes a
- timestamp (number of microseconds since the
- first call to <command>thread_indent()</command> by the thread),
- a process name, and the thread ID. This allows you to
- identify what functions were called, who called them, and the
- duration of each function call.
- </para>
-
- <para>
- If call entries and exits immediately precede each other, it is easy
- to match them. However, in most cases, after a first function call
- entry is made several other call entries and exits may be made
- before the first call exits. The indentation counter helps you match
- an entry with its corresponding exit by indenting the next function
- call if it is not the exit of the previous one.
- </para>
+ <varlistentry>
+ <term>tid()</term>
+ <listitem>
+ <indexterm>
+ <primary>functions</primary>
+ <secondary><command>tid()</command></secondary>
+<!-- <tertiary><command>tid()</command></tertiary> -->
+ </indexterm>
+
+ <indexterm>
+ <primary>functions</primary>
+ <secondary><command>tid()</command></secondary>
+<!-- <tertiary></tertiary> -->
+ </indexterm>
+
+ <indexterm>
+ <primary><command>tid()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler </tertiary> -->
+ </indexterm>
+
+ <para>The ID of the current thread.</para>
+ </listitem>
+ </varlistentry>
- <para>
- Consider the following example on the use of
- <command>thread_indent()</command>:
- </para>
+ <varlistentry>
+ <term>uid()</term>
+ <listitem>
+ <indexterm>
+ <primary>functions</primary>
+ <!--<secondary>handler functions</secondary>-->
+ <secondary><command>uid()</command></secondary>
+ </indexterm>
+<!--
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>uid()</command></tertiary>
+ </indexterm>
+ -->
+ <indexterm>
+ <primary><command>uid()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler functions</tertiary> -->
+ </indexterm>
+ <para>The ID of the current user.</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term>cpu()</term>
+ <listitem>
+ <indexterm>
+ <primary>functions</primary>
+ <!--<secondary>handler functions</secondary>-->
+ <secondary><command>cpu()</command></secondary>
+ </indexterm>
+<!--
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>cpu()</command></tertiary>
+ </indexterm>
+ -->
+ <indexterm>
+ <primary><command>cpu()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler functions</tertiary> -->
+ </indexterm>
+ <para>The current CPU number.</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term>gettimeofday_s()</term>
+ <listitem>
+ <indexterm>
+ <primary>functions</primary>
+ <!--<secondary>handler functions</secondary>-->
+ <secondary><command>gettimeofday_s()</command></secondary>
+ </indexterm>
+<!--
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>gettimeofday_s()</command></tertiary>
+ </indexterm>
+ -->
+ <indexterm>
+ <primary><command>gettimeofday_s()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler functions</tertiary> -->
+ </indexterm>
+
+ <para>The number of seconds since UNIX epoch (January 1, 1970).</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term>ctime()</term>
+ <listitem>
+ <indexterm>
+ <primary>functions</primary>
+ <!--<secondary>handler functions</secondary>-->
+ <secondary><command>ctime()</command></secondary>
+ </indexterm>
+<!--
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>ctime()</command></tertiary>
+ </indexterm>
+ -->
+ <indexterm>
+ <primary><command>ctime()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler functions</tertiary> -->
+ </indexterm>
+ <para>
+ Convert number of seconds since UNIX epoch to date.
+ </para>
+ </listitem>
+ </varlistentry>
+ <!--
+ <varlistentry>
+ <term>get_cycles()</term>
+ <listitem>
+ <para>A snapshot of the hardware cycle counter.</para>
+ </listitem>
+ </varlistentry>
+ -->
+
+ <varlistentry>
+ <term>pp()</term>
+ <listitem>
+ <indexterm>
+ <primary>functions</primary>
+ <!--<secondary>handler functions</secondary>-->
+ <secondary><command>pp()</command></secondary>
+ </indexterm>
+<!--
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>pp()</command></tertiary>
+ </indexterm>
+ -->
+ <indexterm>
+ <primary><command>pp()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler functions</tertiary> -->
+ </indexterm>
+ <para>A string describing the probe point currently being handled.</para>
+ </listitem>
+ </varlistentry>
+ <!-- removed, doesnt work as expected anymore
+ <varlistentry>
+ <term>probefunc()</term>
+ <listitem>
+ <para>If known, the name of the function in which the probe was placed.</para>
+ </listitem>
+ </varlistentry>
+ -->
+
+ <varlistentry>
+ <term>thread_indent()</term>
+ <listitem>
+ <indexterm>
+ <primary>functions</primary>
+ <!--<secondary>handler functions</secondary>-->
+ <secondary><command>thread_indent()</command></secondary>
+ </indexterm>
+<!--
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>thread_indent()</command></tertiary>
+ </indexterm>
+ -->
+ <indexterm>
+ <primary><command>thread_indent()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler functions</tertiary> -->
+ </indexterm>
+ <para>
+ This particular function is quite useful, providing you with a way
+ to better organize your print results. The function takes one
+ argument, an indentation delta, which indicates how many
+ spaces to add or remove from a thread's "indentation counter".
+ It then returns a
+ string with some generic trace data along with an appropriate number
+ of indentation spaces.
+ </para>
+
+ <para>
+ The generic data included in the returned string includes a
+ timestamp (number of microseconds since the
+ first call to <command>thread_indent()</command> by the thread),
+ a process name, and the thread ID. This allows you to
+ identify what functions were called, who called them, and the
+ duration of each function call.
+ </para>
+
+ <para>
+ If call entries and exits immediately precede each other, it is easy
+ to match them. However, in most cases, after a first function call
+ entry is made several other call entries and exits may be made
+ before the first call exits. The indentation counter helps you match
+ an entry with its corresponding exit by indenting the next function
+ call if it is not the exit of the previous one.
+ </para>
+
+ <para>
+ Consider the following example on the use of
+ <command>thread_indent()</command>:
+ </para>
+
<example id="thread_indent"><title>thread_indent.stp</title>
<programlisting>
probe kernel.function("*@net/socket.c")
@@ -949,108 +957,122 @@ probe kernel.function("*@net/socket.c").return
}
</programlisting>
</example>
-
- <para>
- <xref linkend="thread_indent"/> prints out the
- <command>thread_indent()</command> and probe functions at each event
- in the following format:</para>
-
+
+ <para>
+ <xref linkend="thread_indent"/> prints out the
+ <command>thread_indent()</command> and probe functions at each event
+ in the following format:</para>
+
<screen>
- 0 ftp(7223): -&gt; sys_socketcall
- 1159 ftp(7223): -&gt; sys_socket
- 2173 ftp(7223): -&gt; __sock_create
- 2286 ftp(7223): -&gt; sock_alloc_inode
- 2737 ftp(7223): &lt;- sock_alloc_inode
- 3349 ftp(7223): -&gt; sock_alloc
- 3389 ftp(7223): &lt;- sock_alloc
- 3417 ftp(7223): &lt;- __sock_create
- 4117 ftp(7223): -&gt; sock_create
- 4160 ftp(7223): &lt;- sock_create
- 4301 ftp(7223): -&gt; sock_map_fd
- 4644 ftp(7223): -&gt; sock_map_file
- 4699 ftp(7223): &lt;- sock_map_file
- 4715 ftp(7223): &lt;- sock_map_fd
- 4732 ftp(7223): &lt;- sys_socket
- 4775 ftp(7223): &lt;- sys_socketcall
+0 ftp(7223): -&gt; sys_socketcall
+1159 ftp(7223): -&gt; sys_socket
+2173 ftp(7223): -&gt; __sock_create
+2286 ftp(7223): -&gt; sock_alloc_inode
+2737 ftp(7223): &lt;- sock_alloc_inode
+3349 ftp(7223): -&gt; sock_alloc
+3389 ftp(7223): &lt;- sock_alloc
+3417 ftp(7223): &lt;- __sock_create
+4117 ftp(7223): -&gt; sock_create
+4160 ftp(7223): &lt;- sock_create
+4301 ftp(7223): -&gt; sock_map_fd
+4644 ftp(7223): -&gt; sock_map_file
+4699 ftp(7223): &lt;- sock_map_file
+4715 ftp(7223): &lt;- sock_map_fd
+4732 ftp(7223): &lt;- sys_socket
+4775 ftp(7223): &lt;- sys_socketcall
</screen>
-
-<para>This sample output contains the following information:</para>
-
-<itemizedlist>
- <listitem><para>The time (in microseconds) since the initial <command>thread_ident()</command> call for the thread (included in the string from <command>thread_ident()</command>).</para></listitem>
-
- <listitem><para>The process name (and its corresponding ID) that made the function call (included in the string from <command>thread_ident()</command>).</para></listitem>
-
- <listitem><para>An arrow signifying whether the call was an entry (<computeroutput>&lt;-</computeroutput>) or an exit (<computeroutput>-></computeroutput>); the indentations help you match specific function call entries with their corresponding exits.</para></listitem>
-
- <listitem><para>The name of the function called by the process.</para></listitem>
-</itemizedlist>
-
-<remark>remember to add a reference later to "tapsets" from here, to clarify
-that thread_indent is defined in tapsets as a special function of sorts</remark>
-
- </listitem>
- </varlistentry>
-
- <varlistentry>
- <term>name</term>
- <listitem>
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>name</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>name</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>name</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
- <para>Identifies the name of a specific system call. This variable can
- only be used in probes that use the event
- <command>syscall.<replaceable>system_call</replaceable></command>.
- </para>
- </listitem>
- </varlistentry>
-
- <varlistentry>
- <term>target()</term>
- <listitem>
-
-<indexterm>
-<primary>Handlers</primary>
-<secondary>handler functions</secondary>
-<tertiary><command>target()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary>handler functions</primary>
-<secondary>Handlers</secondary>
-<tertiary><command>target()</command></tertiary>
-</indexterm>
-
-<indexterm>
-<primary><command>target()</command></primary>
-<secondary>Handlers</secondary>
-<tertiary>handler functions</tertiary>
-</indexterm>
- <para>
- Used in conjunction with <command>stap
- <replaceable>script</replaceable> -x <replaceable>process
- ID</replaceable></command> or <command>stap
- <replaceable>script</replaceable> -c
- <replaceable>command</replaceable></command>. If you want to specify
- a script to take an argument of a process ID or command, use
- <command>target()</command> as the variable in the script to refer
- to it. For example:
- </para>
-
+
+ <para>This sample output contains the following information:</para>
+
+ <itemizedlist>
+ <listitem><para>The time (in microseconds) since the initial <command>thread_ident()</command> call for the thread (included in the string from <command>thread_ident()</command>).</para></listitem>
+
+ <listitem><para>The process name (and its corresponding ID) that made the function call (included in the string from <command>thread_ident()</command>).</para></listitem>
+
+ <listitem><para>An arrow signifying whether the call was an entry (<computeroutput>&lt;-</computeroutput>) or an exit (<computeroutput>-></computeroutput>); the indentations help you match specific function call entries with their corresponding exits.</para></listitem>
+
+ <listitem><para>The name of the function called by the process.</para></listitem>
+ </itemizedlist>
+
+ <remark>remember to add a reference later to "tapsets" from here, to clarify
+ that thread_indent is defined in tapsets as a special function of sorts</remark>
+
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term>name</term>
+ <listitem>
+<indexterm>
+<primary>local variables</primary>
+<secondary>name</secondary>
+</indexterm>
+
+<indexterm>
+<primary>variables (local)</primary>
+<secondary>name</secondary>
+</indexterm>
+
+<indexterm>
+<primary>name</primary>
+<secondary>local variables</secondary>
+</indexterm>
+<!-- <indexterm>
+ <primary>functions</primary>
+ <secondary>handler functions</secondary>
+ <tertiary><command>name</command></tertiary>
+ </indexterm>
+
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>name</command></tertiary>
+ </indexterm>
+
+ <indexterm>
+ <primary><command>name</command></primary>
+ <secondary>Handlers</secondary>
+ <tertiary>handler functions</tertiary>
+ </indexterm>-->
+ <para>Identifies the name of a specific system call. This variable can
+ only be used in probes that use the event
+ <command>syscall.<replaceable>system_call</replaceable></command>.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term>target()</term>
+ <listitem>
+
+ <indexterm>
+ <primary>functions</primary>
+<!-- <secondary>handler functions</secondary> -->
+ <secondary><command>target()</command></secondary>
+ </indexterm>
+<!--
+ <indexterm>
+ <primary>handler functions</primary>
+ <secondary>Handlers</secondary>
+ <tertiary><command>target()</command></tertiary>
+ </indexterm>
+ -->
+ <indexterm>
+ <primary><command>target()</command></primary>
+ <secondary>functions</secondary>
+<!-- <tertiary>handler functions</tertiary> -->
+ </indexterm>
+ <para>
+ Used in conjunction with <command>stap
+ <replaceable>script</replaceable> -x <replaceable>process
+ ID</replaceable></command> or <command>stap
+ <replaceable>script</replaceable> -c
+ <replaceable>command</replaceable></command>. If you want to specify
+ a script to take an argument of a process ID or command, use
+ <command>target()</command> as the variable in the script to refer
+ to it. For example:
+ </para>
+
<example id="targetexample">
<title>targetexample.stp</title>
<programlisting>
@@ -1060,65 +1082,64 @@ probe syscall.* {
}
</programlisting>
</example>
-
- <para>
- When <xref linkend="targetexample"/> is run with the argument
- <command>-x <replaceable>process ID</replaceable></command>, it
- watches all system calls (as specified by the event
- <command>syscall.*</command>) and prints out the name of all system
- calls made by the specified process.
- </para>
-
- <para>
- This has the same effect as specifying <command>if (pid() ==
- <replaceable>process ID</replaceable>)</command> each time you wish
- to target a specific process. However, using
- <command>target()</command> makes it easier for you to re-use the
- script, giving you the ability to simply pass a process ID as an
- argument each time you wish to run the script (e.g. <command>stap
- targetexample.stp -x <replaceable>process ID</replaceable></command>).
- </para>
-<!--
-<note>
- <title>Note</title>
- <para>In <xref linkend="targetexample"/>, <command>name</command> instructs SystemTap to capture the name of the process</para>
-</note> -->
-
- </listitem>
- </varlistentry>
-
-<!--
-<varlistentry>
- <term></term>
- <listitem>
- <para></para>
- </listitem>
-</varlistentry>
--->
- </variablelist>
-
- <para>For more information about supported SystemTap functions, refer to
- <command>man stapfuncs</command>.
- </para>
-
-<remark>will need a complete listing of supported handler functions? also, SystemTap function descriptions seem ambiguous, please advise.</remark>
-
-<!--
-<para>
- <replaceable>variable</replaceable> can be either <command>%s</command> for strings, or <command>%d</command> for numbers, depending on the <replaceable>handler function</replaceable> used. Each <command>printf ()</command> statement can contain multiple <replaceable>variable</replaceable>s, with each one corresponding to a matching <replaceable>handler function</replaceable>. Multiple <replaceable>handler function</replaceable>s are delimited by comma (<command>,</command>).
-</para>
-
- <command>printf ()</command> is a SystemTap-supported C statement, and can also trap data using a wide variety
-
- SystemTap supports a wide variety of handler functions that can trap data when triggered by events. One way to display these functions is to use the <command>print()</command>
-</para>
-
-
-<para>
- <xref linkend="wildcards"/> illustrates an example of a SystemTap script that contains no handlers. SystemTap will still be able to run the script, but no information will be displayed.
-</para>
--->
-
+
+ <para>
+ When <xref linkend="targetexample"/> is run with the argument
+ <command>-x <replaceable>process ID</replaceable></command>, it
+ watches all system calls (as specified by the event
+ <command>syscall.*</command>) and prints out the name of all system
+ calls made by the specified process.
+ </para>
+
+ <para>
+ This has the same effect as specifying <command>if (pid() ==
+ <replaceable>process ID</replaceable>)</command> each time you wish
+ to target a specific process. However, using
+ <command>target()</command> makes it easier for you to re-use the
+ script, giving you the ability to simply pass a process ID as an
+ argument each time you wish to run the script (e.g. <command>stap
+ targetexample.stp -x <replaceable>process ID</replaceable></command>).
+ </para>
+ <!--
+ <note>
+ <title>Note</title>
+ <para>In <xref linkend="targetexample"/>, <command>name</command> instructs SystemTap to capture the name of the process</para>
+ </note> -->
+
+ </listitem>
+ </varlistentry>
+
+ <!--
+ <varlistentry>
+ <term></term>
+ <listitem>
+ <para></para>
+ </listitem>
+ </varlistentry>
+ -->
+ </variablelist>
+
+ <para>For more information about supported SystemTap functions, refer to
+ <command>man stapfuncs</command>.
+ </para>
+
+ <remark>will need a complete listing of supported handler functions? also, SystemTap function descriptions seem ambiguous, please advise.</remark>
+
+ <!--
+ <para>
+ <replaceable>variable</replaceable> can be either <command>%s</command> for strings, or <command>%d</command> for numbers, depending on the <replaceable>handler function</replaceable> used. Each <command>printf ()</command> statement can contain multiple <replaceable>variable</replaceable>s, with each one corresponding to a matching <replaceable>handler function</replaceable>. Multiple <replaceable>handler function</replaceable>s are delimited by comma (<command>,</command>).
+ </para>
+
+ <command>printf ()</command> is a SystemTap-supported C statement, and can also trap data using a wide variety
+
+ SystemTap supports a wide variety of handler functions that can trap data when triggered by events. One way to display these functions is to use the <command>print()</command>
+ </para>
+
+
+ <para>
+ <xref linkend="wildcards"/> illustrates an example of a SystemTap script that contains no handlers. SystemTap will still be able to run the script, but no information will be displayed.
+ </para>
+ -->
+
</section>
-
</section>
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Understanding_How_SystemTap_Works.xml b/doc/SystemTap_Beginners_Guide/en-US/Understanding_How_SystemTap_Works.xml
index 4e61e247..d9fe6ab4 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Understanding_How_SystemTap_Works.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Understanding_How_SystemTap_Works.xml
@@ -53,7 +53,7 @@
expiration, session termination, etc. A handler is a series of script
language statements that specify the work to be done whenever the event
occurs. This work normally includes extracting data from the event context,
- storing them into internal variables, or printing results.
+ storing them into internal variables, and printing results.
</para>
<section id="understanding-architecture-tools">
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-disktop.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-disktop.xml
index 42f1986b..8a786d82 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-disktop.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-disktop.xml
@@ -107,7 +107,24 @@
<para>The time and date in the output of <xref linkend="scriptdisktop"/> is returned by the functions <command>ctime()</command> and <command>gettimeofday_s()</command>. <command>ctime()</command> derives calendar time in terms of seconds passed since the Unix epoch (January 1, 1970). <command>gettimeofday_s()</command> counts the <emphasis>actual</emphasis> number of seconds since Unix epoch, which gives a fairly accurate human-readable timestamp for the output.</para>
-
+<!-- next 3 indexterms for $return -->
+<indexterm>
+ <primary>local variables</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>$return</tertiary>
+</indexterm>
+
+<indexterm>
+ <primary>variables (local)</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>$return</tertiary>
+</indexterm>
+
+<indexterm>
+ <primary>$return</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>local variables</tertiary>
+</indexterm>
<para>
In this script, the <command>$return</command> is a local variable that stores the
actual number of bytes each process reads or writes from the virtual file system.
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml
index 098524ae..47cc4e16 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-inodewatch.xml
@@ -59,7 +59,8 @@ no script in examples
<remark>need to add references to sources/man pages that explain how "dev_nr = $file->f_dentry->d_inode->i_sb->s_dev" and "($1 &lt;&lt; 20 | $2)".</remark>
-<para><xref linkend="inodewatch"/> takes the following information about the file as an argument:</para>
+<para><xref linkend="inodewatch"/> takes the following information about the
+file as arguments on the command line:</para>
<indexterm>
<primary>script examples</primary>
<secondary>file device number (integer format)</secondary>
@@ -81,7 +82,9 @@ no script in examples
</indexterm>
<itemizedlist>
- <listitem><para>The file's device number, in integer format. When this is passed to the script as the first argument, be sure to replace any <computeroutput>0</computeroutput> with a space.</para></listitem>
+ <listitem><para>The file's major device number.</para></listitem>
+
+ <listitem><para>The file's minor device number.</para></listitem>
<listitem><para>The file's <command>inode</command> number.</para></listitem>
</itemizedlist>
@@ -121,9 +124,9 @@ no script in examples
<secondary>examples of SystemTap scripts</secondary>
</indexterm>
-<para><computeroutput>805</computeroutput> is the device number, while <computeroutput>1078319</computeroutput> is the <command>inode</command> number. To start monitoring <filename>/etc/crontab</filename>, run <command>stap inodewatch.stp 8 5 1078319</command>.</para>
+<para><computeroutput>805</computeroutput> is the base-16 (hexadecimal) device number. The lower two digits are the minor device number and the upper digits are the major number. <computeroutput>1078319</computeroutput> is the <command>inode</command> number. To start monitoring <filename>/etc/crontab</filename>, run <command>stap inodewatch.stp 0x8 0x05 1078319</command> (The <command>0x</command> prefixes indicate base-16 values.</para>
-<para>The output of this command contains the name and ID of any process performing a read/write, the function it is performing (i.e. <command>vfs_read</command> or <command>vfs_write</command>), the device number (in hex format), and the <command>inode</command> number. <xref linkend="inodewatchoutput"/> contains the output of <command>stap inodewatch.stp 8 5 1078319</command> (when <command>cat /etc/crontab</command> is executed while the script is running) :</para>
+<para>The output of this command contains the name and ID of any process performing a read/write, the function it is performing (i.e. <command>vfs_read</command> or <command>vfs_write</command>), the device number (in hex format), and the <command>inode</command> number. <xref linkend="inodewatchoutput"/> contains the output of <command>stap inodewatch.stp 0x8 0x05 1078319</command> (when <command>cat /etc/crontab</command> is executed while the script is running) :</para>
<example id="inodewatchoutput">
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-iotime.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-iotime.xml
index 21b6db9d..4d7d6b17 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-iotime.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-iotime.xml
@@ -52,6 +52,26 @@
of microseconds it takes for any reads or writes to finish and tracks the amount of data (in
bytes) read from or written to the file.
</para>
+<!-- next 2 indexterms for $count -->
+
+<indexterm>
+ <primary>local variables</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>$count</tertiary>
+</indexterm>
+
+<indexterm>
+ <primary>variables (local)</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>$count</tertiary>
+</indexterm>
+
+<indexterm>
+ <primary>$count</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>local variables</tertiary>
+</indexterm>
+
<para>
<xref linkend="iotime"/> also uses the local variable <command>$count</command> to track the
@@ -68,13 +88,14 @@
<title><xref linkend="iotime"/> Sample Output</title>
<screen>
[...]
-3123380 2460 (pcscd) access /dev/bus/usb/005/001 read: 0 write: 0
-825946 3364 (NetworkManager) access /sys/class/net/eth0/carrier read: 8190 write: 0
-825955 3364 (NetworkManager) iotime /sys/class/net/eth0/carrier time: 9
-117061 2460 (pcscd) access /dev/bus/usb/003/001 read: 43 write: 0
-117065 2460 (pcscd) iotime /dev/bus/usb/003/001 time: 7
-3973737 2886 (sendmail) access /proc/loadavg read: 4096 write: 0
-3973744 2886 (sendmail) iotime /proc/loadavg time: 11
+825946 3364 (NetworkManager) access /sys/class/net/eth0/carrier read: 8190 write: 0
+825955 3364 (NetworkManager) iotime /sys/class/net/eth0/carrier time: 9
+[...]
+117061 2460 (pcscd) access /dev/bus/usb/003/001 read: 43 write: 0
+117065 2460 (pcscd) iotime /dev/bus/usb/003/001 time: 7
+[...]
+3973737 2886 (sendmail) access /proc/loadavg read: 4096 write: 0
+3973744 2886 (sendmail) iotime /proc/loadavg time: 11
[...]
</screen>
</example>
@@ -137,4 +158,4 @@ print("\n")
}
-->
-</section> \ No newline at end of file
+</section>
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-nettop.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-nettop.xml
index c51d4b66..2d7e3595 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-nettop.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-nettop.xml
@@ -63,20 +63,23 @@
<primary>if/else conditionals, alternative syntax</primary>
<secondary>examples of SystemTap scripts</secondary>
</indexterm>
-<para>Note that <command>function print_activity()</command> uses the following constructs:</para>
+<para>Note that <command>function print_activity()</command> uses the following
+expressions:</para>
<screen>
-n_xmit ? @sum(ifxmit[pid, dev, exec, uid])/1024 : 0,
+n_xmit ? @sum(ifxmit[pid, dev, exec, uid])/1024 : 0
n_recv ? @sum(ifrecv[pid, dev, exec, uid])/1024 : 0
</screen>
-<para>These constructs are if/else conditionals. The first statement is simply a more concise way of writing:</para>
+<para>These expressions are if/else conditionals.
+The first statement is simply a more concise way of writing the following
+psuedo code:</para>
<screen>
if n_recv != 0 then
- @sum(ifrecv[pid, dev, exec, uid])/1024
+ @sum(ifrecv[pid, dev, exec, uid])/1024
else
- 0
+ 0
</screen>
<para><xref linkend="nettop"/> tracks which processes are generating network traffic on the system, and provides the following information about each process:</para>
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml
index 9a9e1c55..6e913b48 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-sockettrace.xml
@@ -51,7 +51,7 @@
<title>socket-trace.stp</title>
<para>
<programlisting>
- <xi:include parse="text" href="extras/testsuite/systemtap.examples/network/socket-trace.stp" xmlns:xi="http://www.w3.org/2001/XInclude" />
+<xi:include parse="text" href="extras/testsuite/systemtap.examples/network/socket-trace.stp" xmlns:xi="http://www.w3.org/2001/XInclude" />
</programlisting>
</para>
</formalpara>
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio.xml
index ab260d63..1af1475d 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio.xml
@@ -55,7 +55,24 @@
executables. This information is tracked and printed out in 1-second intervals, and in
descending order.
</para>
+<!-- next 3 indexterms for $return -->
+<indexterm>
+ <primary>local variables</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>$return</tertiary>
+</indexterm>
+<indexterm>
+ <primary>variables (local)</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>$return</tertiary>
+</indexterm>
+
+<indexterm>
+ <primary>$return</primary>
+ <secondary>sample usage</secondary>
+ <tertiary>local variables</tertiary>
+</indexterm>
<para>
Note that <xref linkend="traceio"/> also uses the local variable <command>$return</command>,
which is also used by <xref linkend="scriptdisktop"/> from <xref linkend="disktop"/>.
diff --git a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml
index 4fc7ecc2..7451de98 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml
+++ b/doc/SystemTap_Beginners_Guide/en-US/Useful_Scripts-traceio2.xml
@@ -50,7 +50,7 @@
</para>
<formalpara id="traceio2">
- <title>traceio2-simple.stp</title>
+ <title>traceio2.stp</title>
<para>
<programlisting>
<xi:include parse="text" href="extras/testsuite/systemtap.examples/io/traceio2.stp" xmlns:xi="http://www.w3.org/2001/XInclude" />
diff --git a/doc/SystemTap_Beginners_Guide/en-US/extras/iotime-simple.stp b/doc/SystemTap_Beginners_Guide/en-US/extras/iotime-simple.stp
index a14f7731..a16ee4a2 100644
--- a/doc/SystemTap_Beginners_Guide/en-US/extras/iotime-simple.stp
+++ b/doc/SystemTap_Beginners_Guide/en-US/extras/iotime-simple.stp
@@ -68,10 +68,10 @@ probe syscall.write.return {
probe syscall.close {
if (filehandles[pid(), $fd] != "") {
printf("%d %s access %s read: %d write: %d\n", timestamp(), proc(),
- filehandles[pid(), $fd], fileread[pid(), $fd], filewrite[pid(), $fd])
+ filehandles[pid(), $fd], fileread[pid(), $fd], filewrite[pid(), $fd])
if (@count(time_io[pid(), $fd]))
printf("%d %s iotime %s time: %d\n", timestamp(), proc(),
- filehandles[pid(), $fd], @sum(time_io[pid(), $fd]))
+ filehandles[pid(), $fd], @sum(time_io[pid(), $fd]))
}
delete fileread[pid(), $fd]
delete filewrite[pid(), $fd]
@@ -79,4 +79,4 @@ probe syscall.close {
delete fd_io[pid()]
delete entry_io[pid()]
delete time_io[pid(),$fd]
-} \ No newline at end of file
+}
diff --git a/doc/SystemTap_Beginners_Guide/en-US/extras/para-callgraph-simple.stp b/doc/SystemTap_Beginners_Guide/en-US/extras/para-callgraph-simple.stp
index 17cf50a5..1a3e2e03 100755
--- a/doc/SystemTap_Beginners_Guide/en-US/extras/para-callgraph-simple.stp
+++ b/doc/SystemTap_Beginners_Guide/en-US/extras/para-callgraph-simple.stp
@@ -1,39 +1,39 @@
function trace(entry_p) {
- if(tid() in trace)
- printf("%s%s%s\n",thread_indent(entry_p),
- (entry_p>0?"->":"<-"),
- probefunc())
+ if(tid() in trace)
+ printf("%s%s%s\n",thread_indent(entry_p),
+ (entry_p>0?"->":"<-"),
+ probefunc())
}
global trace
probe kernel.function(@1).call {
- if (execname() == "stapio") next # skip our own helper process
- trace[tid()] = 1
- trace(1)
+ if (execname() == "stapio") next # skip our own helper process
+ trace[tid()] = 1
+ trace(1)
}
probe kernel.function(@1).return {
- trace(-1)
- delete trace[tid()]
+ trace(-1)
+ delete trace[tid()]
}
probe kernel.function(@2).call { trace(1) }
probe kernel.function(@2).return { trace(-1) }
function trace(entry_p) {
- if(tid() in trace)
- printf("%s%s%s\n",thread_indent(entry_p),
- (entry_p>0?"->":"<-"),
- probefunc())
+ if(tid() in trace)
+ printf("%s%s%s\n",thread_indent(entry_p),
+ (entry_p>0?"->":"<-"),
+ probefunc())
}
global trace
probe kernel.function(@1).call {
- if (execname() == "stapio") next # skip our own helper process
- trace[tid()] = 1
- trace(1)
+ if (execname() == "stapio") next # skip our own helper process
+ trace[tid()] = 1
+ trace(1)
}
probe kernel.function(@1).return {
- trace(-1)
- delete trace[tid()]
+ trace(-1)
+ delete trace[tid()]
}
probe kernel.function(@2).call { trace(1) }
diff --git a/doc/SystemTap_Tapset_Reference/Makefile.am b/doc/SystemTap_Tapset_Reference/Makefile.am
index c196e977..9e7d2069 100644
--- a/doc/SystemTap_Tapset_Reference/Makefile.am
+++ b/doc/SystemTap_Tapset_Reference/Makefile.am
@@ -1,6 +1,11 @@
# Makefile.am --- automake input file for systemtap tapset reference manual
## process this file with automake to produce Makefile.in
+DOC_INSTALL_DIR = $(DESTDIR)$(datadir)/doc/systemtap
+MAN_INSTALL_DIR = $(DESTDIR)$(mandir)/man5
+HTML_INSTALL_DIR = $(DESTDIR)$(datadir)/doc/systemtap/tapsets
+
+
###
# The build process is as follows (targets):
# (xmldocs) [by docproc]
@@ -9,29 +14,38 @@
# +--> DIR=file (htmldocs) [by xmlto]
# +--> man/ (mandocs) [by xmlto]
-bin_PROGRAMS = docproc
-docproc_SOURCES = docproc.c
-
-all: pdfdocs htmldocs mandocs
-
-
+noinst_PROGRAMS = docproc
SRCTREE=$(abs_top_srcdir)/
DOCPROC=$(abs_builddir)/docproc
-xmldocs: docproc
- SRCTREE=$(SRCTREE) $(DOCPROC) doc $(abs_srcdir)/tapsets.tmpl > tapsets.xml
-
-htmldocs: xmldocs
+if BUILD_REFDOCS
+all: tapsets.pdf stamp-htmldocs stamp-mandocs
+tapsets.xml: docproc $(shell find $(SRCTREE) -name '*.stp')
+ SRCTREE=$(SRCTREE) $(DOCPROC) doc $(abs_srcdir)/tapsets.tmpl > tapsets.xml.new
+ if cmp tapsets.xml.new tapsets.xml >/dev/null ; then \
+ echo tapsets.xml unchanged; \
+ else \
+ mv tapsets.xml.new tapsets.xml; \
+ fi
+
+stamp-htmldocs: tapsets.xml
xmlto html -o tapsets tapsets.xml
+ touch stamp-htmldocs
-pdfdocs: xmldocs
+tapsets.pdf: tapsets.xml
xmlto pdf tapsets.xml
-mandocs: xmldocs
+stamp-mandocs: tapsets.xml
xmlto man -o man5 tapsets.xml
+ touch stamp-mandocs
#FIXME need to figure out where to install things appropriately
#installmandocs: mandocs
-# $(MKDIR_P) /usr/local/man/man5/
-# install Documentation/DocBook/man/*.5.gz /usr/local/man/man5/
-
+install-data-hook:
+ $(MKDIR_P) $(DOC_INSTALL_DIR)
+ $(INSTALL_DATA) tapsets.pdf $(DOC_INSTALL_DIR)
+ $(MKDIR_P) $(MAN_INSTALL_DIR)
+ $(INSTALL_DATA) man5/* $(MAN_INSTALL_DIR)
+ $(MKDIR_P) $(HTML_INSTALL_DIR)
+ $(INSTALL_DATA) tapsets/* $(HTML_INSTALL_DIR)
+endif
diff --git a/doc/SystemTap_Tapset_Reference/Makefile.in b/doc/SystemTap_Tapset_Reference/Makefile.in
index b61be1b7..f840d8c5 100644
--- a/doc/SystemTap_Tapset_Reference/Makefile.in
+++ b/doc/SystemTap_Tapset_Reference/Makefile.in
@@ -1,8 +1,8 @@
-# Makefile.in generated by automake 1.10.1 from Makefile.am.
+# Makefile.in generated by automake 1.10 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
-# 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+# 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -16,14 +16,6 @@
# Makefile.am --- automake input file for systemtap tapset reference manual
-###
-# The build process is as follows (targets):
-# (xmldocs) [by docproc]
-# file.tmpl --> file.xml +--> file.ps (psdocs) [by xmlto]
-# +--> file.pdf (pdfdocs) [by xmlto]
-# +--> DIR=file (htmldocs) [by xmlto]
-# +--> man/ (mandocs) [by xmlto]
-
VPATH = @srcdir@
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
@@ -40,7 +32,7 @@ POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
-bin_PROGRAMS = docproc$(EXEEXT)
+noinst_PROGRAMS = docproc$(EXEEXT)
subdir = doc/SystemTap_Tapset_Reference
DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -50,21 +42,19 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
-am__installdirs = "$(DESTDIR)$(bindir)"
-binPROGRAMS_INSTALL = $(INSTALL_PROGRAM)
-PROGRAMS = $(bin_PROGRAMS)
-am_docproc_OBJECTS = docproc.$(OBJEXT)
-docproc_OBJECTS = $(am_docproc_OBJECTS)
+PROGRAMS = $(noinst_PROGRAMS)
+docproc_SOURCES = docproc.c
+docproc_OBJECTS = docproc.$(OBJEXT)
docproc_LDADD = $(LDADD)
-DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
+DEFAULT_INCLUDES = -I. -I$(top_builddir)@am__isrc@
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
CCLD = $(CC)
LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
-SOURCES = $(docproc_SOURCES)
-DIST_SOURCES = $(docproc_SOURCES)
+SOURCES = docproc.c
+DIST_SOURCES = docproc.c
ETAGS = etags
CTAGS = ctags
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -115,6 +105,7 @@ PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PIELDFLAGS = @PIELDFLAGS@
+PKG_CONFIG = @PKG_CONFIG@
PROCFLAGS = @PROCFLAGS@
RANLIB = @RANLIB@
SET_MAKE = @SET_MAKE@
@@ -146,6 +137,7 @@ have_dvips = @have_dvips@
have_latex = @have_latex@
have_latex2html = @have_latex2html@
have_ps2pdf = @have_ps2pdf@
+have_xmlto = @have_xmlto@
host_alias = @host_alias@
htmldir = @htmldir@
includedir = @includedir@
@@ -157,6 +149,10 @@ localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
+nspr_CFLAGS = @nspr_CFLAGS@
+nspr_LIBS = @nspr_LIBS@
+nss_CFLAGS = @nss_CFLAGS@
+nss_LIBS = @nss_LIBS@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@
@@ -173,7 +169,9 @@ sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
-docproc_SOURCES = docproc.c
+DOC_INSTALL_DIR = $(DESTDIR)$(datadir)/doc/systemtap
+MAN_INSTALL_DIR = $(DESTDIR)$(mandir)/man5
+HTML_INSTALL_DIR = $(DESTDIR)$(datadir)/doc/systemtap/tapsets
SRCTREE = $(abs_top_srcdir)/
DOCPROC = $(abs_builddir)/docproc
all: all-am
@@ -209,29 +207,9 @@ $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
-install-binPROGRAMS: $(bin_PROGRAMS)
- @$(NORMAL_INSTALL)
- test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)"
- @list='$(bin_PROGRAMS)'; for p in $$list; do \
- p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
- if test -f $$p \
- ; then \
- f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \
- echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \
- $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \
- else :; fi; \
- done
-uninstall-binPROGRAMS:
- @$(NORMAL_UNINSTALL)
- @list='$(bin_PROGRAMS)'; for p in $$list; do \
- f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \
- echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \
- rm -f "$(DESTDIR)$(bindir)/$$f"; \
- done
-
-clean-binPROGRAMS:
- -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS)
+clean-noinstPROGRAMS:
+ -test -z "$(noinst_PROGRAMS)" || rm -f $(noinst_PROGRAMS)
docproc$(EXEEXT): $(docproc_OBJECTS) $(docproc_DEPENDENCIES)
@rm -f docproc$(EXEEXT)
$(LINK) $(docproc_OBJECTS) $(docproc_LDADD) $(LIBS)
@@ -263,8 +241,8 @@ ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
- $(AWK) '{ files[$$0] = 1; nonemtpy = 1; } \
- END { if (nonempty) { for (i in files) print i; }; }'`; \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
mkid -fID $$unique
tags: TAGS
@@ -276,8 +254,8 @@ TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
- $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
- END { if (nonempty) { for (i in files) print i; }; }'`; \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
@@ -287,12 +265,13 @@ ctags: CTAGS
CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
tags=; \
+ here=`pwd`; \
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
- $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
- END { if (nonempty) { for (i in files) print i; }; }'`; \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
test -z "$(CTAGS_ARGS)$$tags$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$tags $$unique
@@ -335,9 +314,6 @@ check-am: all-am
check: check-am
all-am: Makefile $(PROGRAMS)
installdirs:
- for dir in "$(DESTDIR)$(bindir)"; do \
- test -z "$$dir" || $(MKDIR_P) "$$dir"; \
- done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
@@ -362,9 +338,10 @@ distclean-generic:
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
+@BUILD_REFDOCS_FALSE@install-data-hook:
clean: clean-am
-clean-am: clean-binPROGRAMS clean-generic mostlyclean-am
+clean-am: clean-generic clean-noinstPROGRAMS mostlyclean-am
distclean: distclean-am
-rm -rf ./$(DEPDIR)
@@ -383,10 +360,12 @@ info: info-am
info-am:
install-data-am:
+ @$(NORMAL_INSTALL)
+ $(MAKE) $(AM_MAKEFLAGS) install-data-hook
install-dvi: install-dvi-am
-install-exec-am: install-binPROGRAMS
+install-exec-am:
install-html: install-html-am
@@ -417,42 +396,53 @@ ps: ps-am
ps-am:
-uninstall-am: uninstall-binPROGRAMS
+uninstall-am:
-.MAKE: install-am install-strip
+.MAKE: install-am install-data-am install-strip
-.PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \
- clean-generic ctags distclean distclean-compile \
+.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
+ clean-noinstPROGRAMS ctags distclean distclean-compile \
distclean-generic distclean-tags distdir dvi dvi-am html \
- html-am info info-am install install-am install-binPROGRAMS \
- install-data install-data-am install-dvi install-dvi-am \
+ html-am info info-am install install-am install-data \
+ install-data-am install-data-hook install-dvi install-dvi-am \
install-exec install-exec-am install-html install-html-am \
install-info install-info-am install-man install-pdf \
install-pdf-am install-ps install-ps-am install-strip \
installcheck installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-compile \
mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \
- uninstall-am uninstall-binPROGRAMS
-
+ uninstall-am
-all: pdfdocs htmldocs mandocs
-xmldocs: docproc
- SRCTREE=$(SRCTREE) $(DOCPROC) doc $(abs_srcdir)/tapsets.tmpl > tapsets.xml
+@BUILD_REFDOCS_TRUE@all: tapsets.pdf stamp-htmldocs stamp-mandocs
+@BUILD_REFDOCS_TRUE@tapsets.xml: docproc $(shell find $(SRCTREE) -name '*.stp')
+@BUILD_REFDOCS_TRUE@ SRCTREE=$(SRCTREE) $(DOCPROC) doc $(abs_srcdir)/tapsets.tmpl > tapsets.xml.new
+@BUILD_REFDOCS_TRUE@ if cmp tapsets.xml.new tapsets.xml >/dev/null ; then \
+@BUILD_REFDOCS_TRUE@ echo tapsets.xml unchanged; \
+@BUILD_REFDOCS_TRUE@ else \
+@BUILD_REFDOCS_TRUE@ mv tapsets.xml.new tapsets.xml; \
+@BUILD_REFDOCS_TRUE@ fi
-htmldocs: xmldocs
- xmlto html -o tapsets tapsets.xml
+@BUILD_REFDOCS_TRUE@stamp-htmldocs: tapsets.xml
+@BUILD_REFDOCS_TRUE@ xmlto html -o tapsets tapsets.xml
+@BUILD_REFDOCS_TRUE@ touch stamp-htmldocs
-pdfdocs: xmldocs
- xmlto pdf tapsets.xml
+@BUILD_REFDOCS_TRUE@tapsets.pdf: tapsets.xml
+@BUILD_REFDOCS_TRUE@ xmlto pdf tapsets.xml
-mandocs: xmldocs
- xmlto man -o man5 tapsets.xml
+@BUILD_REFDOCS_TRUE@stamp-mandocs: tapsets.xml
+@BUILD_REFDOCS_TRUE@ xmlto man -o man5 tapsets.xml
+@BUILD_REFDOCS_TRUE@ touch stamp-mandocs
#FIXME need to figure out where to install things appropriately
#installmandocs: mandocs
-# $(MKDIR_P) /usr/local/man/man5/
-# install Documentation/DocBook/man/*.5.gz /usr/local/man/man5/
+@BUILD_REFDOCS_TRUE@install-data-hook:
+@BUILD_REFDOCS_TRUE@ $(MKDIR_P) $(DOC_INSTALL_DIR)
+@BUILD_REFDOCS_TRUE@ $(INSTALL_DATA) tapsets.pdf $(DOC_INSTALL_DIR)
+@BUILD_REFDOCS_TRUE@ $(MKDIR_P) $(MAN_INSTALL_DIR)
+@BUILD_REFDOCS_TRUE@ $(INSTALL_DATA) man5/* $(MAN_INSTALL_DIR)
+@BUILD_REFDOCS_TRUE@ $(MKDIR_P) $(HTML_INSTALL_DIR)
+@BUILD_REFDOCS_TRUE@ $(INSTALL_DATA) tapsets/* $(HTML_INSTALL_DIR)
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
diff --git a/doc/SystemTap_Tapset_Reference/tapsets.tmpl b/doc/SystemTap_Tapset_Reference/tapsets.tmpl
index 00dcd92f..f1750d45 100644
--- a/doc/SystemTap_Tapset_Reference/tapsets.tmpl
+++ b/doc/SystemTap_Tapset_Reference/tapsets.tmpl
@@ -8,7 +8,7 @@
<authorgroup>
<author>
- <firstname>Willliam</firstname>
+ <firstname>William</firstname>
<surname>Cohen</surname>
<affiliation>
<address>
@@ -19,7 +19,7 @@
</authorgroup>
<copyright>
- <year>2008</year>
+ <year>2008, 2009</year>
<holder>Red Hat, Inc.</holder>
</copyright>
@@ -92,11 +92,10 @@
</para>
<para>
- In some cases, tapsets do not have a <replaceable>return</replaceable> v
-alue. This
- simply means that the tapset does not extract anything from the kernel.
-This is common among
- asynchronous events such as timers, exit functions, and print functions.
+ In some cases, tapsets do not have a <replaceable>return</replaceable>
+ value. This simply means that the tapset does not extract anything from
+ the kernel. This is common among asynchronous events such as timers,
+ exit functions, and print functions.
</para>
<!--
@@ -122,6 +121,8 @@ This is common among
and the current register values for the processor.
</para>
!Itapset/context.stp
+!Itapset/context-symbols.stp
+!Itapset/context-unwind.stp
</chapter>
<chapter id="timestamp_stp">
diff --git a/dtrace b/dtrace
new file mode 100755
index 00000000..1eb53bf9
--- /dev/null
+++ b/dtrace
@@ -0,0 +1,145 @@
+#!/usr/bin/python
+
+# This handles the systemtap equivalent of
+# $(DTRACE) $(DTRACEFLAGS) -G -s $^ -o $@
+# $(DTRACE) $(DTRACEFLAGS) -h -s $^ -o $@
+# which is a step that builds DTrace provider and probe definitions
+
+# Copyright (C) 2009 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+import os,posix,sys
+from subprocess import *
+
+class provider:
+ arglist = dict()
+ def open(self, provider, header):
+ have_provider = False
+ self.f = open(provider)
+ self.h = open(header,mode='w')
+ self.h.write("// Generated by /usr/bin/dtrace\n")
+ self.h.write("\n#include <sys/sdt.h>\n\n")
+ in_comment = False
+ while (True):
+ line = self.f.readline()
+ if (line == ""):
+ break
+ if (line.find("/*") >= 0):
+ in_comment = True
+ if (line.find("*/") >= 0):
+ in_comment = False
+ continue
+ if (in_comment):
+ continue
+ if (line.find("provider") >= 0):
+ tokens = line.split()
+ have_provider = True
+ self.provider = tokens[1]
+ elif (have_provider and line.find("probe ") > 0):
+ while (line.find(")") < 0):
+ line += self.f.readline()
+ this_probe = line[line.find("probe ")+5:line.find("(")].strip()
+ this_probe_canon = self.provider.upper() + "_" + this_probe.replace("__","_").upper()
+ args = (line[line.find("(")+1:line.find(")")])
+ new_args = ""
+ i = 0
+ c = 0
+ self.arglist[this_probe] = ""
+ while (i < len(args)):
+ if (args[i:i+1] == ","):
+ new_args = ('%s%s' % (new_args, args[i]))
+ c += 1
+ else:
+ new_args = new_args + args[i]
+ i += 1
+ if (len(new_args) > 0):
+ self.arglist[this_probe] = ('%s arg%d' % (new_args, c))
+ if (len(new_args) == 0):
+ self.h.write ('#define %s STAP_PROBE(provider,%s)\n' % (this_probe_canon, this_probe))
+ elif (c == 0):
+ self.h.write ('#define %s(arg1) STAP_PROBE%d(provider,%s,arg1)\n' % (this_probe_canon, c+1, this_probe))
+ elif (c == 1):
+ self.h.write ('#define %s(arg1,arg2) STAP_PROBE%d(provider,%s,arg1,arg2)\n' % (this_probe_canon, c+1, this_probe))
+ elif (c == 2):
+ self.h.write ('#define %s(arg1,arg2,arg3) STAP_PROBE%d(provider,%s,arg1,arg2,arg3)\n' % (this_probe_canon, c+1, this_probe))
+ elif (c == 3):
+ self.h.write ('#define %s(arg1,arg2,arg3,arg4) STAP_PROBE%d(provider,%s,arg1,arg2,arg3,arg4)\n' % (this_probe_canon, c+1, this_probe))
+ elif (c == 4):
+ self.h.write ('#define %s(arg1,arg2,arg3,arg4,arg5) STAP_PROBE%d(provider,%s,arg1,arg2,arg3,arg4,arg5)\n' % (this_probe_canon, c+1, this_probe))
+ elif (c == 5):
+ self.h.write ('#define %s(arg1,arg2,arg3,arg4,arg5,arg6) STAP_PROBE%d(provider,%s,arg1,arg2,arg3,arg4,arg5,arg6)\n' % (this_probe_canon, c+1, this_probe))
+ self.h.write ('#define %s_ENABLED() 1\n' % this_probe_canon)
+
+ def get(self, arg):
+ print arg
+ if (arg in self.arglist):
+ return self.arglist[arg]
+ else:
+ return ""
+########################################################################
+# main
+########################################################################
+
+def usage ():
+ print "Usage " + sys.argv[0] + "[-h | -G] -s File.d -o File {Files}"
+ sys.exit(1)
+
+def open_file (arg):
+ if (len (sys.argv) <= arg):
+ return False
+ try:
+ file = open(sys.argv[arg], 'r')
+ except IOError:
+ print (sys.argv[arg] + " not found")
+ sys.exit(1)
+ return file
+
+if (len (sys.argv) < 2):
+ usage()
+
+i = 1
+build_header = False
+build_source = False
+filename = ""
+while (i < len (sys.argv)):
+ if (sys.argv[i] == "-o"):
+ i += 1
+ filename = sys.argv[i]
+ elif (sys.argv[i] == "-s"):
+ i += 1
+ s_filename = sys.argv[i]
+ elif (sys.argv[i] == "-h"):
+ build_header = True
+ elif (sys.argv[i] == "-G"):
+ build_source = True
+ i += 1
+# print build_header == False and build_source == False
+if (build_header == False and build_source == False):
+ usage()
+ sys.exit(1)
+
+if (filename == ""):
+ if (s_filename != ""):
+ filename = s_filename.replace(".d","")
+ else:
+ usage
+ sys.exit(1)
+
+if (build_header):
+ providers = provider()
+ providers.open(s_filename, filename + ".h")
+elif (build_source):
+ fn = "/tmp/" + os.path.basename(s_filename).replace(".d", ".c")
+ f = open(fn,mode='w')
+ f.write("static __dtrace () {}\n")
+ f.close()
+ call("gcc -fPIC -c " + fn + " -o " + filename + ".o", shell=True)
+ f.close()
+ os.remove(fn)
+
+
+
diff --git a/dwarf_wrappers.cxx b/dwarf_wrappers.cxx
index 4fd074ed..f83c4665 100644
--- a/dwarf_wrappers.cxx
+++ b/dwarf_wrappers.cxx
@@ -1,5 +1,5 @@
// -*- C++ -*-
-// Copyright (C) 2008 Red Hat Inc.
+// Copyright (C) 2008-2009 Red Hat Inc.
//
// This file is part of systemtap, and is free software. You can
// redistribute it and/or modify it under the terms of the GNU General
@@ -21,7 +21,7 @@ void dwfl_assert(const string& desc, int rc)
return;
string msg = "libdwfl failure (" + desc + "): ";
if (rc < 0)
- msg += dwfl_errmsg (rc);
+ msg += (dwfl_errmsg (rc) ?: "?");
else
msg += std::strerror (rc);
throw semantic_error (msg);
diff --git a/elaborate.cxx b/elaborate.cxx
index ba1cb79c..db1a4d78 100644
--- a/elaborate.cxx
+++ b/elaborate.cxx
@@ -3956,6 +3956,7 @@ typeresolution_info::visit_print_format (print_format* e)
case print_format::conv_binary:
case print_format::conv_char:
case print_format::conv_memory:
+ case print_format::conv_memory_hex:
wanted = pe_long;
break;
diff --git a/runtime/ChangeLog b/runtime/ChangeLog
index b9a2a058..ca299a8c 100644
--- a/runtime/ChangeLog
+++ b/runtime/ChangeLog
@@ -16,6 +16,56 @@
task_finder_vma.c (stap_add_vma_map_info): Take an optional module.
(__stp_tf_get_vma_entry_addr): New lookup function.
+2009-01-20 David Smith <dsmith@redhat.com>
+
+ PR 9673.
+ * task_finder.c (struct stap_task_finder_target): Added
+ 'vm_events' field.
+ (stap_register_task_finder_target): Sets vm_events if a
+ vm_callback is present.
+ (__stp_task_finder_cleanup): Only detaches engines on the main
+ __stp_task_finder_list linked list.
+ (__stp_call_callbacks): New function.
+ (__stp_call_vm_callbacks): New function.
+ (__stp_utrace_attach_match_filename): Calls __stp_call_callbacks()
+ to call callbacks.
+ (__stp_utrace_task_finder_target_death): Ditto.
+ (__stp_utrace_task_finder_target_quiesce): Calls
+ __stp_call_callbacks() and __stp_call_vm_callbacks() to call
+ callbacks.
+ (__stp_call_vm_callbacks_with_vma): Renamed from
+ __stp_target_call_vm_callback.
+ (__stp_utrace_task_finder_target_syscall_exit): Calls
+ __stp_call_vm_callbacks() to call vm callbacks.
+ (stap_start_task_finder): Instead of a utrace engine for every
+ task_finder_target, there is now one utrace engine for all targets
+ with the same path or pid.
+
+2009-01-13 Jim Keniston <jkenisto@us.ibm.com>
+
+ PR 7082.
+ * uprobes2/uprobes.c: On exec, free up outstanding
+ uretprobe_instances and tick down the uproc's ref-count
+ accordingly, so the (old image's) uproc goes away as
+ desired.
+
+2009-01-12 Wenji Huang <wenji.huang@oracle.com>
+
+ * transport/symbols.c (_stp_sort): Adapt it to 2.6.29.
+
+2009-01-06 Frank Ch. Eigler <fche@elastic.org>
+
+ PR9699.
+ * autoconf-task-uid.c: New test.
+
+2008-12-21 Stan Cox <scox@redhat.com>
+
+ * sduprobes.h (STAP_PROBE): Put block around probe point.
+
+2008-12-16 Stan Cox <scox@redhat.com>
+
+ * sduprobes.h (STAP_PROBE): Add synthetic reference to probe label.
+
2008-12-09 Frank Ch. Eigler <fche@elastic.org>
* time.c (_stp_gettimeofday_ns): Protect some more against freq=0.
diff --git a/runtime/autoconf-task-uid.c b/runtime/autoconf-task-uid.c
new file mode 100644
index 00000000..8e40f831
--- /dev/null
+++ b/runtime/autoconf-task-uid.c
@@ -0,0 +1,6 @@
+#include <linux/sched.h>
+
+int bar (struct task_struct *foo) {
+ return (foo->uid = 0);
+}
+/* as opposed to linux/cred.h wrappers current_uid() etc. */
diff --git a/runtime/sdt.h b/runtime/sdt.h
new file mode 100644
index 00000000..9fe7b176
--- /dev/null
+++ b/runtime/sdt.h
@@ -0,0 +1,163 @@
+// Copyright (C) 2005-2009 Red Hat Inc.
+// Copyright (C) 2006 Intel Corporation.
+//
+// This file is part of systemtap, and is free software. You can
+// redistribute it and/or modify it under the terms of the GNU General
+// Public License (GPL); either version 2, or (at your option) any
+// later version.
+
+#include <string.h>
+
+#if _LP64
+#define STAP_PROBE_STRUCT_ARG(arg) \
+ __uint64_t arg;
+#else
+#define STAP_PROBE_STRUCT_ARG(arg) \
+ long arg __attribute__ ((aligned(8)));
+#endif
+
+#define STAP_SENTINEL 0x31425250
+
+#define STAP_PROBE_STRUCT(probe,type,argc) \
+struct _probe_ ## probe \
+{ \
+ int probe_type; \
+ char *probe_name; \
+ STAP_PROBE_STRUCT_ARG (probe_arg); \
+}; \
+static char probe_name [strlen(#probe)+1] \
+ __attribute__ ((section (".probes"))) \
+ = #probe; \
+static volatile struct _probe_ ## probe _probe_ ## probe __attribute__ ((section (".probes"))) = {STAP_SENTINEL,&probe_name[0],argc};
+
+#define STAP_CONCAT(a,b) a ## b
+#define STAP_LABEL(p,n) \
+ STAP_CONCAT(_probe_ ## p ## _, n)
+
+// The goto _probe_ prevents the label from "drifting"
+#ifdef USE_STAP_PROBE
+#define STAP_PROBE(provider,probe) \
+ STAP_PROBE_STRUCT(probe,0,0) \
+ _stap_probe_0 (_probe_ ## probe.probe_name);
+#else
+#define STAP_PROBE(provider,probe) \
+STAP_LABEL(probe,__LINE__): \
+ asm volatile ("nop"); \
+ STAP_PROBE_STRUCT(probe,1,(size_t)&& STAP_LABEL(probe,__LINE__)) \
+ if (__builtin_expect(_probe_ ## probe.probe_type < 0, 0)) \
+ goto STAP_LABEL(probe,__LINE__);
+#endif
+
+#ifdef USE_STAP_PROBE
+#define STAP_PROBE1(provider,probe,arg1) \
+ STAP_PROBE_STRUCT(probe,0,1) \
+ _stap_probe_1 (_probe_ ## probe.probe_name,(size_t)arg1);
+#else
+#define STAP_PROBE1(provider,probe,parm1) \
+ {volatile typeof((parm1)) arg1 __attribute__ ((unused)) = parm1; \
+STAP_LABEL(probe,__LINE__): \
+ asm volatile ("nop" :: "r"(arg1)); \
+ STAP_PROBE_STRUCT(probe,1,(size_t)&& STAP_LABEL(probe,__LINE__)) \
+ if (__builtin_expect(_probe_ ## probe.probe_type < 0, 0)) \
+ goto STAP_LABEL(probe,__LINE__);}
+#endif
+
+#ifdef USE_STAP_PROBE
+#define STAP_PROBE2(provider,probe,arg1,arg2) \
+ STAP_PROBE_STRUCT(probe,0,2) \
+ _stap_probe_2 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2);
+#else
+#define STAP_PROBE2(provider,probe,parm1,parm2) \
+ {volatile typeof((parm1)) arg1 __attribute__ ((unused)) = parm1; \
+ volatile typeof((parm2)) arg2 __attribute__ ((unused)) = parm2; \
+STAP_LABEL(probe,__LINE__): \
+ asm volatile ("nop" :: "r"(arg1), "r"(arg2)); \
+ STAP_PROBE_STRUCT(probe,1,(size_t)&& STAP_LABEL(probe,__LINE__)) \
+ if (__builtin_expect(_probe_ ## probe.probe_type < 0, 0)) \
+ goto STAP_LABEL(probe,__LINE__);}
+#endif
+
+#ifdef USE_STAP_PROBE
+#define STAP_PROBE3(provider,probe,arg1,arg2,arg3) \
+ STAP_PROBE_STRUCT(probe,0,3) \
+ _stap_probe_3 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2,(size_t)arg3);
+#else
+#define STAP_PROBE3(provider,probe,parm1,parm2,parm3) \
+ {volatile typeof((parm1)) arg1 __attribute__ ((unused)) = parm1; \
+ volatile typeof((parm2)) arg2 __attribute__ ((unused)) = parm2; \
+ volatile typeof((parm3)) arg3 __attribute__ ((unused)) = parm3; \
+STAP_LABEL(probe,__LINE__): \
+ asm volatile ("nop" :: "r"(arg1), "r"(arg2), "r"(arg3)); \
+ STAP_PROBE_STRUCT(probe,1,(size_t)&& STAP_LABEL(probe,__LINE__)) \
+ if (__builtin_expect(_probe_ ## probe.probe_type < 0, 0)) \
+ goto STAP_LABEL(probe,__LINE__);}
+#endif
+
+#ifdef USE_STAP_PROBE
+#define STAP_PROBE4(provider,probe,arg1,arg2,arg3,arg4) \
+ STAP_PROBE_STRUCT(probe,0,4) \
+ _stap_probe_4 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2,(size_t)arg3,(size_t)arg4);
+#else
+#define STAP_PROBE4(provider,probe,parm1,parm2,parm3,parm4) \
+ {volatile typeof((parm1)) arg1 __attribute__ ((unused)) = parm1; \
+ volatile typeof((parm2)) arg2 __attribute__ ((unused)) = parm2; \
+ volatile typeof((parm3)) arg3 __attribute__ ((unused)) = parm3; \
+ volatile typeof((parm4)) arg4 __attribute__ ((unused)) = parm4; \
+STAP_LABEL(probe,__LINE__): \
+ asm volatile ("nop" :: "r"(arg1), "r"(arg2), "r"(arg3), "r"(arg4)); \
+ STAP_PROBE_STRUCT(probe,1,(size_t)&& STAP_LABEL(probe,__LINE__)) \
+ if (__builtin_expect(_probe_ ## probe.probe_type < 0, 0)) \
+ goto STAP_LABEL(probe,__LINE__);}
+#endif
+
+#ifdef USE_STAP_PROBE
+#define STAP_PROBE5(provider,probe,arg1,arg2,arg3,arg4,arg5) \
+ STAP_PROBE_STRUCT(probe,0,5) \
+ _stap_probe_5 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2,(size_t)arg3,(size_t)arg4,(size_t)arg5);
+#else
+#define STAP_PROBE5(provider,probe,parm1,parm2,parm3,parm4,parm5) \
+ {volatile typeof((parm1)) arg1 __attribute__ ((unused)) = parm1; \
+ volatile typeof((parm2)) arg2 __attribute__ ((unused)) = parm2; \
+ volatile typeof((parm3)) arg3 __attribute__ ((unused)) = parm3; \
+ volatile typeof((parm4)) arg4 __attribute__ ((unused)) = parm4; \
+ volatile typeof((parm5)) arg5 __attribute__ ((unused)) = parm5; \
+STAP_LABEL(probe,__LINE__): \
+ asm volatile ("nop" :: "r"(arg1), "r"(arg2), "r"(arg3), "r"(arg4), "r"(arg5)); \
+ STAP_PROBE_STRUCT(probe,1,(size_t)&& STAP_LABEL(probe,__LINE__)) \
+ if (__builtin_expect(_probe_ ## probe.probe_type < 0, 0)) \
+ goto STAP_LABEL(probe,__LINE__);}
+#endif
+
+#ifdef USE_STAP_PROBE
+#define STAP_PROBE6(provider,probe,arg1,arg2,arg3,arg4,arg5,arg6) \
+ STAP_PROBE_STRUCT(probe,0,6) \
+ _stap_probe_6 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2,(size_t)arg3,(size_t)arg4,(size_t)arg5,(size_t)arg6);
+#else
+#define STAP_PROBE6(provider,probe,parm1,parm2,parm3,parm4,parm5,parm6) \
+ {volatile typeof((parm1)) arg1 __attribute__ ((unused)) = parm1; \
+ volatile typeof((parm2)) arg2 __attribute__ ((unused)) = parm2; \
+ volatile typeof((parm3)) arg3 __attribute__ ((unused)) = parm3; \
+ volatile typeof((parm4)) arg4 __attribute__ ((unused)) = parm4; \
+ volatile typeof((parm5)) arg5 __attribute__ ((unused)) = parm5; \
+ volatile typeof((parm6)) arg6 __attribute__ ((unused)) = parm6; \
+STAP_LABEL(probe,__LINE__): \
+ asm volatile ("nop" :: "r"(arg1), "r"(arg2), "r"(arg3), "r"(arg4), "r"(arg5), "r"(arg6)); \
+ STAP_PROBE_STRUCT(probe,1,(size_t)&& STAP_LABEL(probe,__LINE__)) \
+ if (__builtin_expect(_probe_ ## probe.probe_type < 0, 0)) \
+ goto STAP_LABEL(probe,__LINE__);}
+#endif
+
+#define DTRACE_PROBE(provider,probe) \
+STAP_PROBE(provider,probe)
+#define DTRACE_PROBE1(provider,probe,parm1) \
+STAP_PROBE1(provider,probe,parm1)
+#define DTRACE_PROBE2(provider,probe,parm1,parm2) \
+STAP_PROBE2(provider,probe,parm1,parm2)
+#define DTRACE_PROBE3(provider,probe,parm1,parm2,parm3) \
+STAP_PROBE3(provider,probe,parm1,parm2,parm3)
+#define DTRACE_PROBE4(provider,probe,parm1,parm2,parm3,parm4) \
+STAP_PROBE4(provider,probe,parm1,parm2,parm3,parm4)
+#define DTRACE_PROBE5(provider,probe,parm1,parm2,parm3,parm4,parm5) \
+STAP_PROBE4(provider,probe,parm1,parm2,parm3,parm4,parm5)
+#define DTRACE_PROBE6(provider,probe,parm1,parm2,parm3,parm4,parm5,parm6) \
+STAP_PROBE4(provider,probe,parm1,parm2,parm3,parm4,parm5,parm6)
diff --git a/runtime/sduprobes.h b/runtime/sduprobes.h
deleted file mode 100644
index b91dea93..00000000
--- a/runtime/sduprobes.h
+++ /dev/null
@@ -1,141 +0,0 @@
-// Copyright (C) 2005-2008 Red Hat Inc.
-// Copyright (C) 2006 Intel Corporation.
-//
-// This file is part of systemtap, and is free software. You can
-// redistribute it and/or modify it under the terms of the GNU General
-// Public License (GPL); either version 2, or (at your option) any
-// later version.
-
-#include <string.h>
-
-#if _LP64
-#define STAP_PROBE_STRUCT_ARG \
- __uint64_t probe_arg;
-#else
-#define STAP_PROBE_STRUCT_ARG \
- long probe_arg __attribute__ ((aligned(8)));
-#endif
-
-#define STAP_PROBE_STRUCT(probe,type,argc) \
-struct _probe_ ## probe \
-{ \
- char probe_name [strlen(#probe)+1]; \
- int probe_type; \
- STAP_PROBE_STRUCT_ARG \
-}; \
- static volatile struct _probe_ ## probe _probe_ ## probe __attribute__ ((section (".probes"))) = {#probe,type,argc};
-
-#ifndef USE_STAP_DEBUGINFO_PROBE
-#define STAP_PROBE(provider,probe) \
- STAP_PROBE_STRUCT(probe,0,0) \
- _stap_probe_0 (_probe_ ## probe.probe_name);
-#else
-#define STAP_PROBE(provider,probe) \
-_probe_ ## probe: \
- asm volatile ("nop"); \
- STAP_PROBE_STRUCT(probe,1,(size_t)&& _probe_ ## probe) \
- asm volatile ("# %0" :: "m" ((_probe_ ## probe.probe_type)));
-#endif
-
-
-#ifndef USE_STAP_DEBUGINFO_PROBE
-#define STAP_PROBE1(provider,probe,arg1) \
- STAP_PROBE_STRUCT(probe,0,1) \
- _stap_probe_1 (_probe_ ## probe.probe_name,(size_t)arg1);
-#else
-#define STAP_PROBE1(provider,probe,parm1) \
-_probe_ ## probe: \
- asm volatile ("nop"); \
- volatile typeof(parm1) arg1 = parm1; \
- STAP_PROBE_STRUCT(probe,1,(size_t)&& _probe_ ## probe) \
- asm volatile ("# %0" :: "r"(arg1)); \
- asm volatile ("# %0" :: "m" ((_probe_ ## probe.probe_type)));
-#endif
-
-
-#ifndef USE_STAP_DEBUGINFO_PROBE
-#define STAP_PROBE2(provider,probe,arg1,arg2) \
- STAP_PROBE_STRUCT(probe,0,2) \
- _stap_probe_2 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2);
-#else
-#define STAP_PROBE2(provider,probe,parm1,parm2) \
-_probe_ ## probe: \
- asm volatile ("nop"); \
- volatile typeof(parm1) arg1 = parm1; \
- volatile typeof(parm2) arg2 = parm2; \
- STAP_PROBE_STRUCT(probe,1,(size_t)&& _probe_ ## probe)\
- asm volatile ("# %0" :: "r"(arg1)); \
- asm volatile ("# %0" :: "r"(arg2)); \
- asm volatile ("# %0" :: "m" ((_probe_ ## probe.probe_type)));
-#endif
-
-#ifndef USE_STAP_DEBUGINFO_PROBE
-#define STAP_PROBE3(provider,probe,arg1,arg2,arg3) \
- STAP_PROBE_STRUCT(probe,0,3) \
- _stap_probe_3 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2,(size_t)arg3);
-#else
-#define STAP_PROBE3(provider,probe,parm1,parm2,parm3) \
-_probe_ ## probe: \
- asm volatile ("nop"); \
- volatile typeof(parm1) arg1 = parm1; \
- volatile typeof(parm2) arg2 = parm2; \
- volatile typeof(parm3) arg3 = parm3; \
- STAP_PROBE_STRUCT(probe,1,(size_t)&& _probe_ ## probe) \
- asm volatile ("# %0" :: "r"(arg1)); \
- asm volatile ("# %0" :: "r"(arg2)); \
- asm volatile ("# %0" :: "r"(arg3)); \
- asm volatile ("# %0" :: "m" ((_probe_ ## probe.probe_type)));
-#endif
-
-#ifndef USE_STAP_DEBUGINFO_PROBE
-#define STAP_PROBE4(provider,probe,arg1,arg2,arg3,arg4) \
- STAP_PROBE_STRUCT(probe,0,4) \
- _stap_probe_4 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2,(size_t)arg3,(size_t)arg4);
-#else
-#define STAP_PROBE4(provider,probe,parm1,parm2,parm3) \
-_probe_ ## probe: \
- asm volatile ("nop"); \
- volatile typeof(parm1) arg1 = parm1; \
- volatile typeof(parm2) arg2 = parm2; \
- volatile typeof(parm3) arg3 = parm3; \
- volatile typeof(parm4) arg4 = parm4; \
- STAP_PROBE_STRUCT(probe,1,(size_t)&& _probe_ ## probe) \
- asm volatile ("# %0" :: "r"(arg1)); \
- asm volatile ("# %0" :: "r"(arg2)); \
- asm volatile ("# %0" :: "r"(arg3)); \
- asm volatile ("# %0" :: "r"(arg4)); \
- asm volatile ("# %0" :: "m" ((_probe_ ## probe.probe_type)));
-#endif
-
-#ifndef USE_STAP_DEBUGINFO_PROBE
-#define STAP_PROBE5(provider,probe,arg1,arg2,arg3,arg4,arg5) \
- STAP_PROBE_STRUCT(probe,0,5) \
- _stap_probe_5 (_probe_ ## probe.probe_name,(size_t)arg1,(size_t)arg2,(size_t)arg3,(size_t)arg4,(size_t)arg5);
-#else
-#define STAP_PROBE5(provider,probe,parm1,parm2,parm3,parm4,parm5) \
-_probe_ ## probe: \
- asm volatile ("nop"); \
- volatile typeof(parm1) arg1 = parm1; \
- volatile typeof(parm2) arg2 = parm2; \
- volatile typeof(parm3) arg3 = parm3; \
- volatile typeof(parm4) arg4 = parm4; \
- volatile typeof(parm5) arg5 = parm5; \
- STAP_PROBE_STRUCT(probe,1,(size_t)&& _probe_ ## probe) \
- asm volatile ("# %0" :: "r"(arg1)); \
- asm volatile ("# %0" :: "r"(arg2)); \
- asm volatile ("# %0" :: "r"(arg3)); \
- asm volatile ("# %0" :: "r"(arg4)); \
- asm volatile ("# %0" :: "r"(arg5)); \
- asm volatile ("# %0" :: "m" ((_probe_ ## probe.probe_type)));
-#endif
-
-#define DTRACE_PROBE1(provider,probe,parm1,parm2,parm3,parm4,parm5) \
-STAP_PROBE1(provider,probe,parm1,parm2,parm3,parm4,parm5)
-#define DTRACE_PROBE2(provider,probe,parm1,parm2,parm3,parm4,parm5) \
-STAP_PROBE2(provider,probe,parm1,parm2,parm3,parm4,parm5)
-#define DTRACE_PROBE3(provider,probe,parm1,parm2,parm3,parm4,parm5) \
-STAP_PROBE3(provider,probe,parm1,parm2,parm3,parm4,parm5)
-#define DTRACE_PROBE4(provider,probe,parm1,parm2,parm3,parm4,parm5) \
-STAP_PROBE4(provider,probe,parm1,parm2,parm3,parm4,parm5)
-#define DTRACE_PROBE5(provider,probe,parm1,parm2,parm3,parm4,parm5) \
-STAP_PROBE5(provider,probe,parm1,parm2,parm3,parm4,parm5)
diff --git a/runtime/staprun/ChangeLog b/runtime/staprun/ChangeLog
index 3611b55e..6c2304ce 100644
--- a/runtime/staprun/ChangeLog
+++ b/runtime/staprun/ChangeLog
@@ -1,3 +1,7 @@
+2008-01-11 Mark Wielaard <mjw@redhat.com>
+
+ * staprun.h: include config.h for dependency.
+
2008-12-08 Frank Ch. Eigler <fche@elastic.org>
PR7062
diff --git a/runtime/staprun/staprun.h b/runtime/staprun/staprun.h
index 2014ce5b..84cf63fc 100644
--- a/runtime/staprun/staprun.h
+++ b/runtime/staprun/staprun.h
@@ -34,6 +34,9 @@
#include <sys/statfs.h>
#include <linux/version.h>
+/* Include config.h to pick up dependency for --prefix usage. */
+#include "config.h"
+
#define dbug(level, args...) {if (verbose>=level) {fprintf(stderr,"%s:%s:%d ",__name__,__FUNCTION__, __LINE__); fprintf(stderr,args);}}
extern char *__name__;
diff --git a/runtime/task_finder.c b/runtime/task_finder.c
index 1e0a8474..31bccad8 100644
--- a/runtime/task_finder.c
+++ b/runtime/task_finder.c
@@ -95,7 +95,8 @@ struct stap_task_finder_target {
struct list_head callback_list_head;
struct list_head callback_list;
struct utrace_engine_ops ops;
- int engine_attached;
+ unsigned engine_attached:1;
+ unsigned vm_events:1;
size_t pathlen;
/* public: */
@@ -174,6 +175,7 @@ stap_register_task_finder_target(struct stap_task_finder_target *new_tgt)
// Make sure everything is initialized properly.
new_tgt->engine_attached = 0;
+ new_tgt->vm_events = 0;
memset(&new_tgt->ops, 0, sizeof(new_tgt->ops));
new_tgt->ops.report_death = &__stp_utrace_task_finder_target_death;
new_tgt->ops.report_quiesce = &__stp_utrace_task_finder_target_quiesce;
@@ -209,6 +211,10 @@ stap_register_task_finder_target(struct stap_task_finder_target *new_tgt)
// Add this target to the callback list for this task.
list_add_tail(&new_tgt->callback_list, &tgt->callback_list_head);
+
+ // If the new target has a vm_callback, remember this.
+ if (new_tgt->vm_callback != NULL)
+ tgt->vm_events = 1;
return 0;
}
@@ -309,7 +315,6 @@ static void
__stp_task_finder_cleanup(void)
{
struct list_head *tgt_node, *tgt_next;
- struct list_head *cb_node, *cb_next;
struct stap_task_finder_target *tgt;
// Walk the main list, cleaning up as we go.
@@ -319,22 +324,15 @@ __stp_task_finder_cleanup(void)
if (tgt == NULL)
continue;
- list_for_each_safe(cb_node, cb_next,
- &tgt->callback_list_head) {
- struct stap_task_finder_target *cb_tgt;
- cb_tgt = list_entry(cb_node,
- struct stap_task_finder_target,
- callback_list);
- if (cb_tgt == NULL)
- continue;
+ if (tgt->engine_attached) {
+ stap_utrace_detach_ops(&tgt->ops);
+ tgt->engine_attached = 0;
+ }
- if (cb_tgt->engine_attached) {
- stap_utrace_detach_ops(&cb_tgt->ops);
- cb_tgt->engine_attached = 0;
- }
+ // Notice we're not walking the callback_list here.
+ // There isn't anything to clean up and doing it would
+ // mess up callbacks in progress.
- list_del(&cb_tgt->callback_list);
- }
list_del(&tgt->list);
}
}
@@ -379,10 +377,10 @@ __stp_get_mm_path(struct mm_struct *mm, char *buf, int buflen)
/*
* __STP_TASK_BASE_EVENTS: base events for stap_task_finder_target's
- * without a vm_callback
+ * without vm_callback's
*
* __STP_TASK_VM_BASE_EVENTS: base events for
- * stap_task_finder_target's with a vm_callback
+ * stap_task_finder_target's with vm_callback's
*/
#define __STP_TASK_BASE_EVENTS (UTRACE_EVENT(DEATH))
@@ -400,8 +398,7 @@ __stp_get_mm_path(struct mm_struct *mm, char *buf, int buflen)
| UTRACE_EVENT(QUIESCE))
#define __STP_ATTACHED_TASK_BASE_EVENTS(tgt) \
- ((((tgt)->vm_callback) == NULL) ? __STP_TASK_BASE_EVENTS \
- : __STP_TASK_VM_BASE_EVENTS)
+ ((tgt)->vm_events ? __STP_TASK_VM_BASE_EVENTS : __STP_TASK_BASE_EVENTS)
static int
__stp_utrace_attach(struct task_struct *tsk,
@@ -485,6 +482,61 @@ stap_utrace_attach(struct task_struct *tsk,
}
static inline void
+__stp_call_callbacks(struct stap_task_finder_target *tgt,
+ struct task_struct *tsk, int register_p, int process_p)
+{
+ struct list_head *cb_node;
+ int rc;
+
+ if (tgt == NULL || tsk == NULL)
+ return;
+
+ list_for_each(cb_node, &tgt->callback_list_head) {
+ struct stap_task_finder_target *cb_tgt;
+
+ cb_tgt = list_entry(cb_node, struct stap_task_finder_target,
+ callback_list);
+ if (cb_tgt == NULL || cb_tgt->callback == NULL)
+ continue;
+
+ rc = cb_tgt->callback(cb_tgt, tsk, register_p, process_p);
+ if (rc != 0) {
+ _stp_error("callback for %d failed: %d",
+ (int)tsk->pid, rc);
+ }
+ }
+}
+
+static inline void
+__stp_call_vm_callbacks(struct stap_task_finder_target *tgt,
+ struct task_struct *tsk, int map_p, char *vm_path,
+ unsigned long vm_start, unsigned long vm_end,
+ unsigned long vm_pgoff)
+{
+ struct list_head *cb_node;
+ int rc;
+
+ if (tgt == NULL || tsk == NULL)
+ return;
+
+ list_for_each(cb_node, &tgt->callback_list_head) {
+ struct stap_task_finder_target *cb_tgt;
+
+ cb_tgt = list_entry(cb_node, struct stap_task_finder_target,
+ callback_list);
+ if (cb_tgt == NULL || cb_tgt->vm_callback == NULL)
+ continue;
+
+ rc = cb_tgt->vm_callback(cb_tgt, tsk, map_p, vm_path,
+ vm_start, vm_end, vm_pgoff);
+ if (rc != 0) {
+ _stp_error("vm callback for %d failed: %d",
+ (int)tsk->pid, rc);
+ }
+ }
+}
+
+static inline void
__stp_utrace_attach_match_filename(struct task_struct *tsk,
const char * const filename,
int register_p, int process_p)
@@ -495,7 +547,7 @@ __stp_utrace_attach_match_filename(struct task_struct *tsk,
filelen = strlen(filename);
list_for_each(tgt_node, &__stp_task_finder_list) {
- struct list_head *cb_node;
+ int rc;
tgt = list_entry(tgt_node, struct stap_task_finder_target,
list);
@@ -515,52 +567,31 @@ __stp_utrace_attach_match_filename(struct task_struct *tsk,
/* Notice that "pid == 0" (which means to probe all
* threads) falls through. */
- list_for_each(cb_node, &tgt->callback_list_head) {
- struct stap_task_finder_target *cb_tgt;
- int rc;
-
- cb_tgt = list_entry(cb_node,
- struct stap_task_finder_target,
- callback_list);
- if (cb_tgt == NULL)
- continue;
-
- // Set up events we need for attached tasks.
- // When register_p is set, we won't actually
- // call the callback here - we'll call it when
- // the thread gets quiesced. When register_p
- // isn't set, we can go ahead and call the
- // callback.
- if (register_p) {
- rc = __stp_utrace_attach(tsk, &cb_tgt->ops,
- cb_tgt,
- __STP_ATTACHED_TASK_EVENTS,
- UTRACE_STOP);
- if (rc != 0 && rc != EPERM)
- break;
- cb_tgt->engine_attached = 1;
- }
- else {
- if (cb_tgt->callback != NULL) {
- rc = cb_tgt->callback(cb_tgt, tsk,
- register_p,
- process_p);
- if (rc != 0) {
- _stp_error("callback for %d failed: %d",
- (int)tsk->pid, rc);
- break;
- }
- }
-
- rc = stap_utrace_detach(tsk, &cb_tgt->ops);
- if (rc != 0)
- break;
+ // Set up events we need for attached tasks. When
+ // register_p is set, we won't actually call the
+ // callbacks here - we'll call it when the thread gets
+ // quiesced. When register_p isn't set, we can go
+ // ahead and call the callbacks.
+ if (register_p) {
+ rc = __stp_utrace_attach(tsk, &tgt->ops,
+ tgt,
+ __STP_ATTACHED_TASK_EVENTS,
+ UTRACE_STOP);
+ if (rc != 0 && rc != EPERM)
+ break;
+ tgt->engine_attached = 1;
+ }
+ else {
+ // Call the callbacks, then detach.
+ __stp_call_callbacks(tgt, tsk, register_p, process_p);
+ rc = stap_utrace_detach(tsk, &tgt->ops);
+ if (rc != 0)
+ break;
- // Note that we don't want to set
- // engine_attached to 0 here - only
- // when *all* threads using this
- // engine have been detached.
- }
+ // Note that we don't want to set
+ // engine_attached to 0 here - only
+ // when *all* threads using this
+ // engine have been detached.
}
}
}
@@ -756,20 +787,14 @@ __stp_utrace_task_finder_target_death(struct utrace_attached_engine *engine,
// don't know which callback(s) to call.
//
// So, now when an "interesting" thread is found, we add a
- // separate UTRACE_EVENT(DEATH) handler for every probe.
-
- if (tgt != NULL && tgt->callback != NULL) {
- int rc;
-
- // Call the callback
- rc = tgt->callback(tgt, tsk, 0,
- ((tsk->signal == NULL)
- || (atomic_read(&tsk->signal->live) == 0)));
- if (rc != 0) {
- _stp_error("death callback for %d failed: %d",
- (int)tsk->pid, rc);
- }
+ // separate UTRACE_EVENT(DEATH) handler for each attached
+ // handler.
+ if (tgt != NULL && tsk != NULL) {
+ __stp_call_callbacks(tgt, tsk, 0,
+ ((tsk->signal == NULL)
+ || (atomic_read(&tsk->signal->live) == 0)));
}
+
__stp_tf_handler_end();
debug_task_finder_detach();
return UTRACE_DETACH;
@@ -795,7 +820,7 @@ __stp_utrace_task_finder_target_quiesce(enum utrace_resume_action action,
return UTRACE_DETACH;
}
- if (tgt == NULL) {
+ if (tgt == NULL || tsk == NULL) {
debug_task_finder_detach();
return UTRACE_DETACH;
}
@@ -825,20 +850,15 @@ __stp_utrace_task_finder_target_quiesce(enum utrace_resume_action action,
_stp_error("utrace_set_events returned error %d on pid %d",
rc, (int)tsk->pid);
- if (tgt->callback != NULL) {
- /* Call the callback. Assume that if the thread is a
- * thread group leader, it is a process. */
- rc = tgt->callback(tgt, tsk, 1, (tsk->pid == tsk->tgid));
- if (rc != 0) {
- _stp_error("callback for %d failed: %d",
- (int)tsk->pid, rc);
- }
- }
- /* If this is just a thread other than the thread group leader,
+ /* Call the callbacks. Assume that if the thread is a
+ * thread group leader, it is a process. */
+ __stp_call_callbacks(tgt, tsk, 1, (tsk->pid == tsk->tgid));
+
+ /* If this is just a thread other than the thread group leader,
don't bother inform vm_callback clients about its memory map,
since they will simply duplicate each other. */
- if (tgt->vm_callback != NULL && (tsk->tgid == tsk->pid)) {
+ if (tgt->vm_events == 1 && tsk->tgid == tsk->pid) {
struct mm_struct *mm;
char *mmpath_buf;
char *mmpath;
@@ -872,18 +892,12 @@ __stp_utrace_task_finder_target_quiesce(enum utrace_resume_action action,
mmpath_buf, PATH_MAX);
#endif
if (mmpath) {
- // Call the callback
- rc = tgt->vm_callback(tgt, tsk, 1,
- mmpath,
- vma->vm_start,
- vma->vm_end,
- (vma->vm_pgoff
- << PAGE_SHIFT));
- if (rc != 0) {
- _stp_error("vm callback for %d failed: %d",
- (int)tsk->pid, rc);
- }
-
+ __stp_call_vm_callbacks(tgt, tsk, 1,
+ mmpath,
+ vma->vm_start,
+ vma->vm_end,
+ (vma->vm_pgoff
+ << PAGE_SHIFT));
}
else {
_stp_dbug(__FUNCTION__, __LINE__,
@@ -944,7 +958,7 @@ __stp_utrace_task_finder_target_syscall_entry(enum utrace_resume_action action,
return UTRACE_DETACH;
}
- if (tgt == NULL || tgt->vm_callback == NULL)
+ if (tgt == NULL || tgt->vm_events == 0)
return UTRACE_RESUME;
// See if syscall is one we're interested in.
@@ -987,9 +1001,9 @@ __stp_utrace_task_finder_target_syscall_entry(enum utrace_resume_action action,
}
static void
-__stp_target_call_vm_callback(struct stap_task_finder_target *tgt,
- struct task_struct *tsk,
- struct vm_area_struct *vma)
+__stp_call_vm_callbacks_with_vma(struct stap_task_finder_target *tgt,
+ struct task_struct *tsk,
+ struct vm_area_struct *vma)
{
char *mmpath_buf;
char *mmpath;
@@ -1015,13 +1029,9 @@ __stp_target_call_vm_callback(struct stap_task_finder_target *tgt,
rc, (int)tsk->pid);
}
else {
- rc = tgt->vm_callback(tgt, tsk, 1, mmpath, vma->vm_start,
- vma->vm_end,
- (vma->vm_pgoff << PAGE_SHIFT));
- if (rc != 0) {
- _stp_error("vm callback for %d failed: %d",
- (int)tsk->pid, rc);
- }
+ __stp_call_vm_callbacks(tgt, tsk, 1, mmpath,
+ vma->vm_start, vma->vm_end,
+ (vma->vm_pgoff << PAGE_SHIFT));
}
_stp_kfree(mmpath_buf);
}
@@ -1056,7 +1066,7 @@ __stp_utrace_task_finder_target_syscall_exit(enum utrace_resume_action action,
return UTRACE_DETACH;
}
- if (tgt == NULL || tgt->vm_callback == NULL)
+ if (tgt == NULL || tgt->vm_events == 0)
return UTRACE_RESUME;
// See if syscall is one we're interested in.
@@ -1112,8 +1122,7 @@ __stp_utrace_task_finder_target_syscall_exit(enum utrace_resume_action action,
down_read(&mm->mmap_sem);
vma = __stp_find_file_based_vma(mm, rv);
if (vma != NULL) {
- __stp_target_call_vm_callback(tgt, tsk,
- vma);
+ __stp_call_vm_callbacks_with_vma(tgt, tsk, vma);
}
up_read(&mm->mmap_sem);
mmput(mm);
@@ -1138,15 +1147,12 @@ __stp_utrace_task_finder_target_syscall_exit(enum utrace_resume_action action,
// FIXME: We'll need to figure out to
// retrieve the path of a deleted
// vma.
- rc = tgt->vm_callback(tgt, tsk, 0, NULL,
- entry->vm_start,
- entry->vm_end,
- (entry->vm_pgoff
- << PAGE_SHIFT));
- if (rc != 0) {
- _stp_error("vm callback for %d failed: %d",
- (int)tsk->pid, rc);
- }
+
+ __stp_call_vm_callbacks(tgt, tsk, 0, NULL,
+ entry->vm_start,
+ entry->vm_end,
+ (entry->vm_pgoff
+ << PAGE_SHIFT));
}
// If nothing has changed, there is no
@@ -1172,15 +1178,11 @@ __stp_utrace_task_finder_target_syscall_exit(enum utrace_resume_action action,
// FIXME: We'll need to figure out to
// retrieve the path of a deleted
// vma.
- rc = tgt->vm_callback(tgt, tsk, 0, NULL,
- entry->vm_start,
- entry->vm_end,
- (entry->vm_pgoff
- << PAGE_SHIFT));
- if (rc != 0) {
- _stp_error("vm callback for %d failed: %d",
- (int)tsk->pid, rc);
- }
+ __stp_call_vm_callbacks(tgt, tsk, 0, NULL,
+ entry->vm_start,
+ entry->vm_end,
+ (entry->vm_pgoff
+ << PAGE_SHIFT));
// Now find all the new vma's that
// made up the original vma's address
@@ -1191,8 +1193,9 @@ __stp_utrace_task_finder_target_syscall_exit(enum utrace_resume_action action,
tmp))
!= NULL)
&& vma->vm_end <= entry->vm_end) {
- __stp_target_call_vm_callback(tgt, tsk,
- vma);
+ __stp_call_vm_callbacks_with_vma(tgt,
+ tsk,
+ vma);
if (vma->vm_end >= entry->vm_end)
break;
tmp = vma->vm_end;
@@ -1284,7 +1287,6 @@ stap_start_task_finder(void)
mmpathlen = strlen(mmpath);
list_for_each(tgt_node, &__stp_task_finder_list) {
struct stap_task_finder_target *tgt;
- struct list_head *cb_node;
tgt = list_entry(tgt_node,
struct stap_task_finder_target, list);
@@ -1301,23 +1303,13 @@ stap_start_task_finder(void)
/* Notice that "pid == 0" (which means to
* probe all threads) falls through. */
- list_for_each(cb_node, &tgt->callback_list_head) {
- struct stap_task_finder_target *cb_tgt;
- cb_tgt = list_entry(cb_node,
- struct stap_task_finder_target,
- callback_list);
- if (cb_tgt == NULL)
- continue;
-
- // Set up events we need for attached tasks.
- rc = __stp_utrace_attach(tsk, &cb_tgt->ops,
- cb_tgt,
- __STP_ATTACHED_TASK_EVENTS,
- UTRACE_STOP);
- if (rc != 0 && rc != EPERM)
- goto stf_err;
- cb_tgt->engine_attached = 1;
- }
+ // Set up events we need for attached tasks.
+ rc = __stp_utrace_attach(tsk, &tgt->ops, tgt,
+ __STP_ATTACHED_TASK_EVENTS,
+ UTRACE_STOP);
+ if (rc != 0 && rc != EPERM)
+ goto stf_err;
+ tgt->engine_attached = 1;
}
} while_each_thread(grp, tsk);
stf_err:
@@ -1354,6 +1346,7 @@ stap_stop_task_finder(void)
if (i > 0)
printk(KERN_ERR "it took %d polling loops to quit.\n", i);
#endif
+ debug_task_finder_report();
}
diff --git a/runtime/transport/ChangeLog b/runtime/transport/ChangeLog
index c6dfa005..e8e2a047 100644
--- a/runtime/transport/ChangeLog
+++ b/runtime/transport/ChangeLog
@@ -1,3 +1,8 @@
+2009-01-06 Frank Ch. Eigler <fche@elastic.org>
+
+ PR9699.
+ * transport.c (_stp_transport_init): Adapt to task_struct cred switch.
+
2008-11-28 Frank Ch. Eigler <fche@elastic.org>
PR5947: make code -Wpointer-arith clean
diff --git a/runtime/transport/symbols.c b/runtime/transport/symbols.c
index 6e3bef1b..72f9ad80 100644
--- a/runtime/transport/symbols.c
+++ b/runtime/transport/symbols.c
@@ -92,8 +92,8 @@ static void generic_swap(void *a, void *b, int size)
* @base: pointer to data to sort
* @num: number of elements
* @size: size of each element
- * @cmp: pointer to comparison function
- * @swap: pointer to swap function or NULL
+ * @cmp_func: pointer to comparison function
+ * @swap_func: pointer to swap function or NULL
*
* This function does a heapsort on the given array. You may provide a
* swap function optimized to your element type.
@@ -104,37 +104,37 @@ static void generic_swap(void *a, void *b, int size)
* it less suitable for kernel use.
*/
void _stp_sort(void *_base, size_t num, size_t size,
- int (*cmp) (const void *, const void *), void (*swap) (void *, void *, int size))
+ int (*cmp_func) (const void *, const void *), void (*swap_func) (void *, void *, int size))
{
char *base = (char*) _base;
/* pre-scale counters for performance */
int i = (num / 2 - 1) * size, n = num * size, c, r;
- if (!swap)
- swap = (size == 4 ? u32_swap : generic_swap);
+ if (!swap_func)
+ swap_func = (size == 4 ? u32_swap : generic_swap);
/* heapify */
for (; i >= 0; i -= size) {
for (r = i; r * 2 + size < n; r = c) {
c = r * 2 + size;
- if (c < n - size && cmp(base + c, base + c + size) < 0)
+ if (c < n - size && cmp_func(base + c, base + c + size) < 0)
c += size;
- if (cmp(base + r, base + c) >= 0)
+ if (cmp_func(base + r, base + c) >= 0)
break;
- swap(base + r, base + c, size);
+ swap_func(base + r, base + c, size);
}
}
/* sort */
for (i = n - size; i >= 0; i -= size) {
- swap(base, base + i, size);
+ swap_func(base, base + i, size);
for (r = 0; r * 2 + size < i; r = c) {
c = r * 2 + size;
- if (c < i - size && cmp(base + c, base + c + size) < 0)
+ if (c < i - size && cmp_func(base + c, base + c + size) < 0)
c += size;
- if (cmp(base + r, base + c) >= 0)
+ if (cmp_func(base + r, base + c) >= 0)
break;
- swap(base + r, base + c, size);
+ swap_func(base + r, base + c, size);
}
}
}
diff --git a/runtime/transport/transport.c b/runtime/transport/transport.c
index 9f7a25f2..f5ee2c36 100644
--- a/runtime/transport/transport.c
+++ b/runtime/transport/transport.c
@@ -2,7 +2,7 @@
* transport.c - stp transport functions
*
* Copyright (C) IBM Corporation, 2005
- * Copyright (C) Red Hat Inc, 2005-2008
+ * Copyright (C) Red Hat Inc, 2005-2009
* Copyright (C) Intel Corporation, 2006
*
* This file is part of systemtap, and is free software. You can
@@ -211,8 +211,13 @@ int _stp_transport_init(void)
dbug_trans(1, "transport_init\n");
_stp_init_pid = current->pid;
+#ifdef STAPCONF_TASK_UID
_stp_uid = current->uid;
_stp_gid = current->gid;
+#else
+ _stp_uid = current_uid();
+ _stp_gid = current_gid();
+#endif
#ifdef RELAY_GUEST
/* Guest scripts use relay only for reporting warnings and errors */
diff --git a/runtime/uprobes/uprobes.c b/runtime/uprobes/uprobes.c
index 22d62ecc..9dfb82b9 100644
--- a/runtime/uprobes/uprobes.c
+++ b/runtime/uprobes/uprobes.c
@@ -453,13 +453,24 @@ static int quiesce_all_threads(struct uprobe_process *uproc,
return survivors;
}
+static void utask_free_uretprobe_instances(struct uprobe_task *utask)
+{
+ struct uretprobe_instance *ri;
+ struct hlist_node *r1, *r2;
+
+ hlist_for_each_entry_safe(ri, r1, r2, &utask->uretprobe_instances,
+ hlist) {
+ hlist_del(&ri->hlist);
+ kfree(ri);
+ uprobe_decref_process(utask->uproc);
+ }
+}
+
/* Called with utask->uproc write-locked. */
static void uprobe_free_task(struct uprobe_task *utask)
{
struct deferred_registration *dr, *d;
struct delayed_signal *ds, *ds2;
- struct uretprobe_instance *ri;
- struct hlist_node *r1, *r2;
uprobe_unhash_utask(utask);
list_del(&utask->list);
@@ -473,12 +484,8 @@ static void uprobe_free_task(struct uprobe_task *utask)
kfree(ds);
}
- hlist_for_each_entry_safe(ri, r1, r2, &utask->uretprobe_instances,
- hlist) {
- hlist_del(&ri->hlist);
- kfree(ri);
- uprobe_decref_process(utask->uproc);
- }
+ utask_free_uretprobe_instances(utask);
+
kfree(utask);
}
@@ -809,6 +816,27 @@ static void purge_uprobe(struct uprobe_kimg *uk)
uprobe_free_probept(ppt);
}
+/* TODO: Avoid code duplication with uprobe_validate_vaddr(). */
+static int uprobe_validate_vma(struct task_struct *t, unsigned long vaddr)
+{
+ struct vm_area_struct *vma;
+ struct mm_struct *mm;
+ int ret = 0;
+
+ mm = get_task_mm(t);
+ if (!mm)
+ return -EINVAL;
+ down_read(&mm->mmap_sem);
+ vma = find_vma(mm, vaddr);
+ if (!vma || vaddr < vma->vm_start)
+ ret = -ENOENT;
+ else if (!(vma->vm_flags & VM_EXEC))
+ ret = -EFAULT;
+ up_read(&mm->mmap_sem);
+ mmput(mm);
+ return ret;
+}
+
/* Probed address must be in an executable VM area, outside the SSOL area. */
static int uprobe_validate_vaddr(struct task_struct *p, unsigned long vaddr,
struct uprobe_process *uproc)
@@ -1942,9 +1970,9 @@ done:
/*
* uproc's process is exiting or exec-ing, so zap all the (now irrelevant)
- * probepoints. Runs with uproc->rwsem write-locked. Caller must ref-count
- * uproc before calling this function, to ensure that uproc doesn't get
- * freed in the middle of this.
+ * probepoints and uretprobe_instances. Runs with uproc->rwsem write-locked.
+ * Caller must ref-count uproc before calling this function, to ensure that
+ * uproc doesn't get freed in the middle of this.
*/
static void uprobe_cleanup_process(struct uprobe_process *uproc)
{
@@ -1953,6 +1981,7 @@ static void uprobe_cleanup_process(struct uprobe_process *uproc)
struct hlist_node *pnode1, *pnode2;
struct hlist_head *head;
struct uprobe_kimg *uk, *unode;
+ struct uprobe_task *utask;
uproc->finished = 1;
@@ -1988,6 +2017,16 @@ static void uprobe_cleanup_process(struct uprobe_process *uproc)
}
}
}
+
+ /*
+ * Free uretprobe_instances. This is a nop on exit, since all
+ * the uprobe_tasks are already gone. We do this here on exec
+ * (as opposed to letting uprobe_free_process() take care of it)
+ * because uprobe_free_process() never gets called if we don't
+ * tick down the ref count here (PR #7082).
+ */
+ list_for_each_entry(utask, &uproc->thread_list, list)
+ utask_free_uretprobe_instances(utask);
}
/*
@@ -2134,6 +2173,23 @@ static int uprobe_fork_uproc(struct uprobe_process *parent_uproc,
BUG_ON(!parent_uproc->uretprobe_trampoline_addr ||
IS_ERR(parent_uproc->uretprobe_trampoline_addr));
+ ret = uprobe_validate_vma(child_tsk,
+ (unsigned long) parent_uproc->ssol_area.insn_area);
+ if (ret) {
+ int ret2;
+ printk(KERN_ERR "uprobes: Child %d failed to inherit"
+ " parent %d's SSOL vma at %p. Error = %d\n",
+ child_tsk->pid, parent_utask->tsk->pid,
+ parent_uproc->ssol_area.insn_area, ret);
+ ret2 = uprobe_validate_vma(parent_utask->tsk,
+ (unsigned long) parent_uproc->ssol_area.insn_area);
+ if (ret2 != 0)
+ printk(KERN_ERR "uprobes: Parent %d's SSOL vma"
+ " is no longer valid. Error = %d\n",
+ parent_utask->tsk->pid, ret2);
+ return ret;
+ }
+
if (!try_module_get(THIS_MODULE))
return -ENOSYS;
child_uproc = uprobe_mk_process(child_tsk);
diff --git a/runtime/uprobes2/uprobes.c b/runtime/uprobes2/uprobes.c
index 02496a4e..af187fc9 100644
--- a/runtime/uprobes2/uprobes.c
+++ b/runtime/uprobes2/uprobes.c
@@ -498,13 +498,24 @@ static bool quiesce_all_threads(struct uprobe_process *uproc,
return survivors;
}
+static void utask_free_uretprobe_instances(struct uprobe_task *utask)
+{
+ struct uretprobe_instance *ri;
+ struct hlist_node *r1, *r2;
+
+ hlist_for_each_entry_safe(ri, r1, r2, &utask->uretprobe_instances,
+ hlist) {
+ hlist_del(&ri->hlist);
+ kfree(ri);
+ uprobe_decref_process(utask->uproc);
+ }
+}
+
/* Called with utask->uproc write-locked. */
static void uprobe_free_task(struct uprobe_task *utask, bool in_callback)
{
struct deferred_registration *dr, *d;
struct delayed_signal *ds, *ds2;
- struct uretprobe_instance *ri;
- struct hlist_node *r1, *r2;
if (utask->engine && (utask->tsk != current || !in_callback)) {
/*
@@ -530,12 +541,8 @@ static void uprobe_free_task(struct uprobe_task *utask, bool in_callback)
kfree(ds);
}
- hlist_for_each_entry_safe(ri, r1, r2, &utask->uretprobe_instances,
- hlist) {
- hlist_del(&ri->hlist);
- kfree(ri);
- uprobe_decref_process(utask->uproc);
- }
+ utask_free_uretprobe_instances(utask);
+
kfree(utask);
}
@@ -873,6 +880,27 @@ static void purge_uprobe(struct uprobe_kimg *uk)
uprobe_free_probept(ppt);
}
+/* TODO: Avoid code duplication with uprobe_validate_vaddr(). */
+static int uprobe_validate_vma(struct task_struct *t, unsigned long vaddr)
+{
+ struct vm_area_struct *vma;
+ struct mm_struct *mm;
+ int ret = 0;
+
+ mm = get_task_mm(t);
+ if (!mm)
+ return -EINVAL;
+ down_read(&mm->mmap_sem);
+ vma = find_vma(mm, vaddr);
+ if (!vma || vaddr < vma->vm_start)
+ ret = -ENOENT;
+ else if (!(vma->vm_flags & VM_EXEC))
+ ret = -EFAULT;
+ up_read(&mm->mmap_sem);
+ mmput(mm);
+ return ret;
+}
+
/* Probed address must be in an executable VM area, outside the SSOL area. */
static int uprobe_validate_vaddr(struct pid *p, unsigned long vaddr,
struct uprobe_process *uproc)
@@ -2085,9 +2113,9 @@ static u32 uprobe_report_quiesce(enum utrace_resume_action action,
/*
* uproc's process is exiting or exec-ing, so zap all the (now irrelevant)
- * probepoints. Runs with uproc->rwsem write-locked. Caller must ref-count
- * uproc before calling this function, to ensure that uproc doesn't get
- * freed in the middle of this.
+ * probepoints and uretprobe_instances. Runs with uproc->rwsem write-locked.
+ * Caller must ref-count uproc before calling this function, to ensure that
+ * uproc doesn't get freed in the middle of this.
*/
static void uprobe_cleanup_process(struct uprobe_process *uproc)
{
@@ -2096,6 +2124,7 @@ static void uprobe_cleanup_process(struct uprobe_process *uproc)
struct hlist_node *pnode1, *pnode2;
struct hlist_head *head;
struct uprobe_kimg *uk, *unode;
+ struct uprobe_task *utask;
uproc->finished = 1;
@@ -2131,6 +2160,16 @@ static void uprobe_cleanup_process(struct uprobe_process *uproc)
}
}
}
+
+ /*
+ * Free uretprobe_instances. This is a nop on exit, since all
+ * the uprobe_tasks are already gone. We do this here on exec
+ * (as opposed to letting uprobe_free_process() take care of it)
+ * because uprobe_free_process() never gets called if we don't
+ * tick down the ref count here (PR #7082).
+ */
+ list_for_each_entry(utask, &uproc->thread_list, list)
+ utask_free_uretprobe_instances(utask);
}
/*
@@ -2280,6 +2319,23 @@ static int uprobe_fork_uproc(struct uprobe_process *parent_uproc,
BUG_ON(!parent_uproc->uretprobe_trampoline_addr ||
IS_ERR(parent_uproc->uretprobe_trampoline_addr));
+ ret = uprobe_validate_vma(child_tsk,
+ (unsigned long) parent_uproc->ssol_area.insn_area);
+ if (ret) {
+ int ret2;
+ printk(KERN_ERR "uprobes: Child %d failed to inherit"
+ " parent %d's SSOL vma at %p. Error = %d\n",
+ child_tsk->pid, parent_utask->tsk->pid,
+ parent_uproc->ssol_area.insn_area, ret);
+ ret2 = uprobe_validate_vma(parent_utask->tsk,
+ (unsigned long) parent_uproc->ssol_area.insn_area);
+ if (ret2 != 0)
+ printk(KERN_ERR "uprobes: Parent %d's SSOL vma"
+ " is no longer valid. Error = %d\n",
+ parent_utask->tsk->pid, ret2);
+ return ret;
+ }
+
if (!try_module_get(THIS_MODULE))
return -ENOSYS;
child_pid = get_pid(find_vpid(child_tsk->pid));
diff --git a/runtime/vsprintf.c b/runtime/vsprintf.c
index 831b7a2b..2c3067cf 100644
--- a/runtime/vsprintf.c
+++ b/runtime/vsprintf.c
@@ -283,6 +283,7 @@ int _stp_vsnprintf(char *buf, size_t size, const char *fmt, va_list args)
continue;
case 's':
+ case 'M':
case 'm':
s = va_arg(args, char *);
if ((unsigned long)s < PAGE_SIZE)
@@ -302,11 +303,20 @@ int _stp_vsnprintf(char *buf, size_t size, const char *fmt, va_list args)
++str;
}
}
- for (i = 0; i < len; ++i) {
- if (str <= end)
- *str = *s;
- ++str; ++s;
+ if (*fmt == 'M') {
+ str = number(str, str + len - 1 < end ? str + len - 1 : end,
+ (unsigned long) *(uint64_t *) s,
+ 16, field_width, len, flags);
+ }
+ else {
+ for (i = 0; i < len; ++i) {
+ if (str <= end) {
+ *str = *s;
+ }
+ ++str; ++s;
+ }
}
+
while (len < field_width--) {
if (str <= end)
*str = ' ';
@@ -318,7 +328,6 @@ int _stp_vsnprintf(char *buf, size_t size, const char *fmt, va_list args)
++str;
}
continue;
-
case 'X':
flags |= STP_LARGE;
case 'x':
diff --git a/scripts/kprobes_test/.gitignore b/scripts/kprobes_test/.gitignore
new file mode 100644
index 00000000..2f836aac
--- /dev/null
+++ b/scripts/kprobes_test/.gitignore
@@ -0,0 +1,2 @@
+*~
+*.pyc
diff --git a/scripts/kprobes_test/README b/scripts/kprobes_test/README
new file mode 100644
index 00000000..c2c0fcb9
--- /dev/null
+++ b/scripts/kprobes_test/README
@@ -0,0 +1,57 @@
+Here are the original instructions for 'gen_whitelist', which tested
+systemtap probe safety. This modified code tests the underlying
+kprobes themselves.
+
+To start a kprobes test run:
+ runtest whitelist.exp
+
+----
+Here is an implementation of generating whitelist for safe-mode probes
+based on the discussion in former thread
+(http://sourceware.org/ml/systemtap/2006-q3/msg00574.html).
+
+Its main idea is:
+ 1) Fetch a group of probe points from probes.pending, probe them and
+ run some workloads(e.g. runltp) parallely meanwhile.
+
+ 2) If the probe test ends without crash, those actually triggered
+ probe points are moved into probes.passed and those untriggered
+ are into probes.untriggered;
+ If the probe test crashes the system, it will be resumed
+ automatically after system reboot. Those probe points which have
+ been triggered are also moved into probes.passed, but those
+ untriggered ones are moved into probes.failed.
+
+ 3) Repeat the above until probes.pending becomes empty, then:
+ Normally, probes.pending is reinitialized from probes.failed and
+ probes.untriggered, then start the next iteration;
+ But if max running level (now 3) is reached, or probes.pending,
+ probes.failed and probes.untriggered are all empty, stop the
+ whole test.
+
+To be able to resume after a crash, this test will append its startup
+codes to the end of /etc/rc.d/rc.local at the beginning and remove
+them at the end of the test.
+
+The gen_tapset_all.sh is used to generate a "probes.all" file based
+on current tapset of systemtap.
+
+It is suggested to use a script in a remote server to restart the
+test machine automatically in case it is crashed by the probe test.
+
+Instructions:
+ 0) Please jump to 6) directly if you use all default settings
+ 1) Define your list of probe points in a file named "probes.all";
+ otherwise, it will be automatically extracted from
+ stap -p2 -e 'probe kernel.function("*"){}
+ 2) Define your own workloads by changing the "benchs" list variable;
+ otherwise, several LTP testcases will be used
+ 3) Define how may times you want the test to be iterated by changing
+ MAX_RUNNING_LEVEL variable; otherwise, 3 is the default
+ 4) Define the group size for different iteration level by changing
+ proper_current_size() function; otherwise, they will be set in
+ a decreasing order based on the length of probes.all
+ 5) Remove /stp_genwhitelist_running if you want to start a test from
+ the beginning after a system crash
+ 6) Start a test:
+ runtest whitelist.exp
diff --git a/scripts/kprobes_test/config_opts.py b/scripts/kprobes_test/config_opts.py
new file mode 100644
index 00000000..6163db50
--- /dev/null
+++ b/scripts/kprobes_test/config_opts.py
@@ -0,0 +1,32 @@
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+import os
+import sys
+
+# Here we set up the default config options. These can be overridden
+# by the config file.
+config_opts = dict()
+
+# Various file names
+config_opts['probes_result'] = 'probe.out'
+config_opts['probes_all'] = 'probes.all'
+config_opts['probes_pending'] = 'probes.pending'
+config_opts['probes_current'] = 'probes.current'
+config_opts['probes_passed'] = 'probes.passed'
+config_opts['probes_failed'] = 'probes.failed'
+config_opts['probes_untriggered'] = 'probes.untriggered'
+config_opts['probes_unregistered'] = 'probes.unregistered'
+
+# Read in the config file
+print "Reading config file..."
+cfg = os.path.join(os.getcwd(), 'default.cfg')
+if os.path.exists(cfg):
+ execfile(cfg)
+else:
+ print >>sys.stderr, ("Could not find required config file: %s" % cfg)
+ sys.exit(1)
diff --git a/scripts/kprobes_test/default.cfg b/scripts/kprobes_test/default.cfg
new file mode 100644
index 00000000..c1c8acdb
--- /dev/null
+++ b/scripts/kprobes_test/default.cfg
@@ -0,0 +1,16 @@
+# -*-python-*-
+
+# Commands to run to generate a system load
+config_opts['load_cmds'] = [
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'syscalls', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'nfs', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'rpc', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'ipc', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'dio', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'fs', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'mm', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'tcp_cmds', ],
+ # [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'ltp-aio-stress.part1', ],
+ [ '/usr/local/ltp/runltp', '-t', '600s', '-f', 'lvm.part1' ],
+ ]
+
diff --git a/scripts/kprobes_test/gen_code.py b/scripts/kprobes_test/gen_code.py
new file mode 100755
index 00000000..1361f98e
--- /dev/null
+++ b/scripts/kprobes_test/gen_code.py
@@ -0,0 +1,80 @@
+#!/usr/bin/python
+
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+import os
+import sys
+from config_opts import config_opts
+
+def gen_files(dir, subset):
+ f = open('%s/kprobe_defs.h' % dir, 'w')
+
+ # Output the array of kp_data structs
+ print >>f, "static struct kp_data kp_data[] = {"
+ i = 0
+ while i < len(subset):
+ print >>f, ("\t{ .kp={ .symbol_name=\"%s\", .pre_handler=&handler_pre, }, .use_count=ATOMIC_INIT(0) },"
+ % (subset[i]))
+ i += 1
+ print >>f, "};"
+ print >>f
+ f.close()
+
+ # Generate the Makefile
+ f = open('Makefile', 'w')
+ print >>f, """
+EXTRA_CFLAGS :=
+EXTRA_CFLAGS += -freorder-blocks
+EXTRA_CFLAGS += -Wno-unused -Werror
+obj-m := kprobe_module.o"""
+ f.close()
+
+def run_make_cmd(cmd):
+ # Before running make, fix up the environment a bit. Clean out a
+ # few variables that /lib/modules/${KVER}/build/Makefile uses.
+ os.unsetenv("ARCH")
+ os.unsetenv("KBUILD_EXTMOD")
+ os.unsetenv("CROSS_COMPILE")
+ os.unsetenv("KBUILD_IMAGE")
+ os.unsetenv("KCONFIG_CONFIG")
+ os.unsetenv("INSTALL_PATH");
+
+ print "Running", cmd
+ return os.system(cmd)
+
+def gen_module():
+ f = open(config_opts['probes_current'])
+ probes = f.readlines()
+ f.close()
+ if len(probes) == 0:
+ print >>sys.stderr, ("Error: no probe points in %s"
+ % config_opts['probes_current'])
+ return -1
+
+ # Cleanup each probe by stripping whitespace
+ i = 0
+ while i < len(probes):
+ probes[i] = probes[i].rstrip()
+ i += 1
+
+ # Generate necessary files
+ gen_files(os.getcwd(), probes)
+
+ # Try to build the module - add "V=1" at the end for more verbosity
+ os.system('rm -f ./kprobe_module.ko')
+ (sysname, nodename, release, version, machine) = os.uname()
+ cmd = ("make -C \"/lib/modules/%s/build\" M=\"%s\" modules >build.log 2>&1"
+ % (release, os.getcwd()))
+ rc = run_make_cmd(cmd)
+ if os.WEXITSTATUS(rc) != 0:
+ print >>sys.stderr, "Error: Make failed, see build.log for details"
+ return -1
+ return 0
+
+rc = gen_module()
+sys.exit(rc)
diff --git a/scripts/kprobes_test/is_probed.py b/scripts/kprobes_test/is_probed.py
new file mode 100755
index 00000000..192abd88
--- /dev/null
+++ b/scripts/kprobes_test/is_probed.py
@@ -0,0 +1,55 @@
+#!/usr/bin/python
+
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+import re
+import sys
+import os
+from config_opts import config_opts
+
+# Parse the output file, looking for probe points
+pp_re = re.compile(": (-?\d+) (\S+)$")
+f = open(config_opts['probes_result'], 'r')
+pp = dict()
+line = f.readline()
+while line:
+ match = pp_re.search(line)
+ if match:
+ pp[match.group(2)] = int(match.group(1))
+ line = f.readline()
+f.close()
+
+if len(pp.keys()) == 0:
+ print >>sys.stderr, "No data found?"
+ sys.exit(1)
+
+# Parse the list of probe points.
+f = open(config_opts['probes_current'], 'r')
+passed = open(config_opts['probes_passed'], 'a')
+failed = open(config_opts['probes_failed'], 'a')
+untriggered = open(config_opts['probes_untriggered'], 'a')
+unregistered = open(config_opts['probes_unregistered'], 'a')
+line = f.readline().strip()
+while line:
+ if pp.has_key(line):
+ if pp[line] > 0:
+ passed.write(line + '\n')
+ elif pp[line] == 0:
+ untriggered.write(line + '\n')
+ elif pp[line] == -1:
+ unregistered.write(line + '\n')
+ else:
+ failed.write(line + '\n')
+ line = f.readline().strip()
+f.close()
+passed.close()
+failed.close()
+untriggered.close()
+unregistered.close()
+
+sys.exit(0)
diff --git a/scripts/kprobes_test/kprobe_module.c b/scripts/kprobes_test/kprobe_module.c
new file mode 100644
index 00000000..0ba6c1db
--- /dev/null
+++ b/scripts/kprobes_test/kprobe_module.c
@@ -0,0 +1,65 @@
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/kprobes.h>
+
+struct kp_data {
+ struct kprobe kp;
+ atomic_t use_count;
+};
+
+static int handler_pre(struct kprobe *p, struct pt_regs *regs);
+
+#include "kprobe_defs.h"
+
+
+/* kprobe pre_handler: called just before the probed instruction is executed */
+static int handler_pre(struct kprobe *p, struct pt_regs *regs)
+{
+ struct kp_data *k = container_of(p, struct kp_data, kp);
+ atomic_inc(&k->use_count);
+ return 0;
+}
+
+static int __init kprobe_init(void)
+{
+ int ret;
+ int probes_registered = 0;
+ int i;
+
+ for (i = 0; i < ARRAY_SIZE(kp_data); i++) {
+ ret = register_kprobe(&kp_data[i].kp);
+ if (ret != 0)
+ atomic_set(&kp_data[i].use_count, -1);
+ else
+ probes_registered++;
+ }
+ if (probes_registered == 0) {
+ for (i = 0; i < ARRAY_SIZE(kp_data); i++) {
+ printk(KERN_INFO "-1 %s\n", kp_data[i].kp.symbol_name);
+ }
+ printk(KERN_INFO "kprobe_module unloaded\n");
+ return ret;
+ }
+ printk(KERN_INFO "Planted kprobes\n");
+ return 0;
+}
+
+static void __exit kprobe_exit(void)
+{
+ int i;
+
+ for (i = 0; i < ARRAY_SIZE(kp_data); i++) {
+ if (atomic_read(&kp_data[i].use_count) != -1)
+ unregister_kprobe(&kp_data[i].kp);
+ }
+ printk(KERN_INFO "kprobes unregistered\n");
+ for (i = 0; i < ARRAY_SIZE(kp_data); i++) {
+ printk(KERN_INFO "%d %s\n", atomic_read(&kp_data[i].use_count),
+ kp_data[i].kp.symbol_name);
+ }
+ printk(KERN_INFO "kprobe_module unloaded\n");
+}
+
+module_init(kprobe_init)
+module_exit(kprobe_exit)
+MODULE_LICENSE("GPL");
diff --git a/scripts/kprobes_test/monitor_system.py b/scripts/kprobes_test/monitor_system.py
new file mode 100755
index 00000000..59d49e7d
--- /dev/null
+++ b/scripts/kprobes_test/monitor_system.py
@@ -0,0 +1,82 @@
+#!/usr/bin/python
+
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+# This script monitors a remote system that is running the kprobes
+# test. If several consecutive 'ping's fail, the system is rebooted.
+#
+# This script takes as an argument a config filename, whose contents
+# should look like the following:
+#
+# config_opts['system_name'] = "SYSTEM_NAME"
+# config_opts['restart_cmds'] = [
+# 'CMD1',
+# 'CMD2',
+# ]
+#
+# As an example, here is a config file used when monitoring a kvm
+# instance:
+#
+# config_opts['system_name'] = "dhcp-148"
+# config_opts['restart_cmds'] = [
+# 'sudo virsh destroy kvm-rawhide-64-1',
+# 'sudo virsh start kvm-rawhide-64-1',
+# ]
+
+import sys
+import os
+import time
+
+if len(sys.argv) != 2:
+ print >>sys.stderr, "Usage: %s config_file" % sys.argv[0]
+ sys.exit(1)
+cfg = sys.argv[1]
+
+# Read in the config file
+if not os.path.exists(cfg):
+ print >>sys.stderr, ("Could not find required config file: %s" % cfg)
+ sys.exit(1)
+
+print "Reading config file %s..." % cfg
+config_opts = dict()
+execfile(cfg)
+if not config_opts.has_key('system_name'):
+ print >>sys.stderr, "Missing required config opt 'system_name'"
+ sys.exit(1)
+if not config_opts.has_key('restart_cmds'):
+ print >>sys.stderr, "Missing required config opt 'restart_cmds'"
+ sys.exit(1)
+
+errors = 0
+while 1:
+ rc = os.system("ping -c 1 %s" % config_opts['system_name'])
+ # If ping worked, system is still up and running. Wait a minute
+ # and try again.
+ if os.WEXITSTATUS(rc) == 0:
+ time.sleep(60)
+ errors = 0
+
+ # If the ping failed, increase the error count. If we've got 3
+ # consecutive errors, assume the machine has crashed and restart
+ # it.
+ else:
+ errors += 1
+ if errors < 3:
+ time.sleep(30)
+ else:
+ print >>sys.stderr, "Restarting %s..." % config_opts['system_name']
+ # Run each restart command
+
+ for cmd in config_opts['restart_cmds']:
+ print >>sys.stderr, "Running '%s'..." % cmd
+ os.system(cmd)
+ # Sleep for 5 minutes to give the system a chance to boot
+ print >>sys.stderr, "Sleeping for 5 minutes..."
+ time.sleep(5 * 60)
+ errors = 0
+
diff --git a/scripts/kprobes_test/readelf.py b/scripts/kprobes_test/readelf.py
new file mode 100755
index 00000000..d031625b
--- /dev/null
+++ b/scripts/kprobes_test/readelf.py
@@ -0,0 +1,76 @@
+#!/usr/bin/python
+
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+import re
+import sys
+import os
+#import pickle
+import subprocess
+from config_opts import config_opts
+
+# Read the output of eu-readelf on vmlinux
+(sysname, nodename, release, version, machine) = os.uname()
+cmd = "eu-readelf --symbols /usr/lib/debug/lib/modules/%s/vmlinux" % release
+print "Running", cmd
+p = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE)
+lines = p.stdout.readlines()
+p.wait()
+if p.returncode != 0:
+ print >>sys.stderr, "Error: eu-readelf failed."
+ sys.exit(p.returncode)
+
+# Parse the output
+kprobes_text_start = 0
+kprobes_text_end = 0
+syms = dict()
+func_re = re.compile("^\s*\d+:\s+([0-9a-f]+)\s+\d+\s+FUNC\s+\S+\s+\S+\s+\d+\s+(\S+)$")
+notype_re = re.compile("^\s*\d+:\s+([0-9a-f]+)\s+\d+\s+NOTYPE\s+\S+\s+\S+\s+\d+\s+(\S+)$")
+for line in lines:
+ match = notype_re.match(line)
+ if match:
+ addr = match.group(1)
+ name = match.group(2)
+ if name == "__kprobes_text_start":
+ kprobes_text_start = long(addr, 16)
+ elif name == "__kprobes_text_end":
+ kprobes_text_end = long(addr, 16)
+ continue
+
+ match = func_re.match(line)
+ if match:
+ addr = match.group(1)
+ name = match.group(2)
+ syms[name] = long(addr, 16)
+
+# Now we've parsed everything. Now we need to go back and remove all
+# symbols between '__kprobes_text_start' and '__kprobes_text_end',
+# since they are already protected from kprobes. We couldn't do this
+# in the loop above, since we might encounter symbols that need to be
+# removed before we found the start/end of the kprobes section.
+if kprobes_text_start == 0 or kprobes_text_end == 0:
+ print "Error - didn't find kprobes_test_start(%d) or kprobes_text_end(%d)" \
+ % (kprobes_text_start, kprobes_text_end)
+ sys.exit(1)
+
+for name in syms.keys():
+ if syms[name] >= kprobes_text_start and syms[name] < kprobes_text_end:
+ print "deleting", name
+ del syms[name]
+
+## Save data
+#f = open('%s.syms' % (release), 'w')
+#p = pickle.Pickler(f)
+#p.dump(syms)
+#f.close()
+
+# Write the data out in text format
+f = open(config_opts['probes_all'], 'w')
+for name in syms.keys():
+ print >>f, name
+f.close()
diff --git a/scripts/kprobes_test/run_module.py b/scripts/kprobes_test/run_module.py
new file mode 100755
index 00000000..74465d94
--- /dev/null
+++ b/scripts/kprobes_test/run_module.py
@@ -0,0 +1,121 @@
+#!/usr/bin/python
+
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+import sys
+import os
+import os.path
+import time
+import select
+from config_opts import config_opts
+
+def run_module():
+ # Find the current size of /var/log/messages
+ logfile = '/var/log/messages'
+ print >>sys.stderr, "Getting size of %s..." % logfile
+
+ start_pos = os.path.getsize(logfile)
+ l = open(logfile, 'r')
+ l.seek(start_pos)
+
+ # Insert the module
+ print >>sys.stderr, "Inserting module..."
+ rc = os.system("/sbin/insmod %s" % os.path.join(os.getcwd(),
+ 'kprobe_module.ko'))
+ if os.WEXITSTATUS(rc) != 0:
+ # This is actually semi-OK, which is why there is no error
+ # message here, only a notice. This might mean that every
+ # probe tried cannot be registered.
+ print >>sys.stderr, "Notice: insmod failed"
+ else:
+ # Run the load generate commands (if any). Note we ignore the
+ # return values, since we don't really care if the commands
+ # succeed or not.
+ if config_opts.has_key('load_cmds'):
+ num_waits = 0
+
+ # Redirect the output to 'run_module.log' by modifying
+ # what stdout points to.
+ old_stdout = os.dup(sys.stdout.fileno())
+ fd = os.open('run_module.log', os.O_CREAT | os.O_WRONLY)
+ os.dup2(fd, sys.stdout.fileno())
+
+ # Run the commands.
+ for cmd in config_opts['load_cmds']:
+ pid = os.spawnvp(os.P_NOWAIT, cmd[0], cmd)
+ num_waits += 1
+ while num_waits > 0:
+ (pid, status) = os.waitpid(-1, 0)
+ num_waits -= 1
+
+ # Restore old value of stdout.
+ os.close(fd)
+ os.dup2(old_stdout, sys.stdout.fileno())
+
+ # Remove the module
+ print >>sys.stderr, "Removing module..."
+ rc = os.system("/sbin/rmmod kprobe_module")
+ if os.WEXITSTATUS(rc) != 0:
+ print >>sys.stderr, "Error: rmmod failed"
+ return -1
+
+ # Now we have to wait until everything is flushed to the logfile
+ f = open(config_opts['probes_result'], 'w')
+ while 1:
+ # Find the ending size of /var/log/messages
+ end_pos = os.path.getsize(logfile)
+
+ if end_pos < start_pos:
+ # The log files have been rotated. Read any leftover data,
+ # then reopen file.
+ data = l.read()
+ if data:
+ f.write(data)
+
+ # See if we can find 'kprobe_module unloaded' in the
+ # data we just read.
+ if data.find('kprobe_module unloaded') != -1:
+ break
+
+ l.close()
+ l = open(logfile, 'r')
+ start_pos = 0
+ continue
+
+ # Try to wait until data is available
+ while 1:
+ try:
+ input, output, exc = select.select([l.fileno()], [], [], 60)
+ break
+ except select.error, err:
+ if err[0] != EINTR:
+ raise
+
+ # Get the new stuff logged to /var/log/messages
+ data = l.read(end_pos - start_pos + 1)
+ if not data:
+ # ignore EOF
+ time.sleep(2)
+ continue
+
+ # Write results data
+ f.write(data)
+
+ # See if we can find 'kprobe_module unloaded' in the data we
+ # just read.
+ if data.find('kprobe_module unloaded') == -1:
+ start_pos = end_pos
+ else:
+ break
+
+ l.close()
+ f.close()
+ return 0
+
+rc = run_module()
+sys.exit(rc)
diff --git a/scripts/kprobes_test/whitelist.exp b/scripts/kprobes_test/whitelist.exp
new file mode 100755
index 00000000..37c1502c
--- /dev/null
+++ b/scripts/kprobes_test/whitelist.exp
@@ -0,0 +1,162 @@
+# Test kernel functions for kprobe safety.
+#
+# Copyright (C) 2006 IBM Corp.
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+#
+# Based on software written by Gui Jian <guijian@cn.ibm.com>
+#
+
+load_lib "whitelist_lib.exp"
+
+set MAX_RUNNING_LEVEL 3
+
+set GENKPROBES_RUNNING "/genkprobes_running"
+set PROBES_RESULT "probe.out"
+set PROBES_ALL "probes.all"
+set PROBES_PENDING "probes.pending"
+set PROBES_CURRENT "probes.current"
+set PROBES_PASSED "probes.passed"
+set PROBES_FAILED "probes.failed"
+set PROBES_UNTRIGGERED "probes.untriggered"
+set PROBES_UNREGISTERED "probes.unregistered"
+
+proc proper_current_size {level inputfile} {
+ set totalsize [get_linesize $inputfile]
+ switch $level {
+ {1} {set currentsize [expr $totalsize/9]
+ # Use a max size of 1000
+ if {$currentsize > 1000} {
+ set currentsize 1000
+ }
+ # Use a min size of 50
+ if {$currentsize < 50} {
+ set currentsize 50
+ }
+ }
+ {2} {set currentsize [expr $totalsize/49]
+ # Use a max size of 400
+ if {$currentsize > 400} {
+ set currentsize 400
+ }
+ # Use a min size of 10
+ if {$currentsize < 10} {
+ set currentsize 10
+ }
+ }
+ {3} {set currentsize 100}
+ {4} {set currentsize 10}
+ default {
+ puts "Reached unexpected iteration level: $level"
+ set currentsize $totalsize
+ }
+ }
+ if {$currentsize <= 0} {
+ set currentsize 5
+ }
+ return $currentsize
+}
+
+#
+# Main routine of the whole test
+#
+if {[get_running_level] == 0} {
+ # Not started yet, start the whole test from the scratch
+ # Append the startup code to /etc/init.d/rc.local if not yet
+ register_service
+ # Check whether probes.all is empty or not given
+ if {[get_linesize $PROBES_ALL] == 0} {
+ init_probes_all
+ }
+ # Set current_running_level as 1 to indicate a new test started
+ init_running_level
+ # Initialize intermediate files based on probe.all
+ exec rm -f $PROBES_PENDING $PROBES_CURRENT
+ exec rm -f $PROBES_PASSED $PROBES_UNTRIGGERED $PROBES_FAILED $PROBES_UNREGISTERED
+ file copy $PROBES_ALL $PROBES_PENDING
+ exec touch $PROBES_PASSED $PROBES_UNTRIGGERED $PROBES_FAILED $PROBES_UNREGISTERED
+ sync_discs
+ puts "Start a fresh stp_genwhitelist test."
+} else {
+ # Maybe started already, so do some cleaning if necessary
+ garbage_collect $ALREADY_CRASHED
+ puts "Recovered from last maybe crashed probe test."
+}
+
+set current_size_const [proper_current_size [get_running_level] $PROBES_ALL]
+puts "current_size_const is initialized as $current_size_const"
+
+while {1} {
+ puts "Current size of probes.pending is [get_linesize $PROBES_PENDING]"
+ if {[get_linesize $PROBES_PENDING] == 0} {
+ # Check whether we need the next iteration or not
+ global MAX_RUNNING_LEVEL
+ # incr running_level for the start of a new iteration
+ set old_running_level [get_running_level]
+ incr_running_level
+ puts "Running level increased to [get_running_level]"
+ if {[get_running_level] > $MAX_RUNNING_LEVEL} {
+ puts "Reached max iteration limit: [get_running_level]"
+ break
+ } else {
+ exec cp $PROBES_PASSED $PROBES_PASSED-pass$old_running_level
+ exec cp $PROBES_FAILED $PROBES_FAILED-pass$old_running_level
+ exec cp $PROBES_UNTRIGGERED $PROBES_UNTRIGGERED-pass$old_running_level
+
+ puts "Current running level is [get_running_level]"
+ exec rm -f $PROBES_PENDING
+ if {[get_linesize $PROBES_FAILED] > 0} {
+ # Append probes.failed to probes.pending
+ exec cat $PROBES_FAILED >> $PROBES_PENDING
+ file delete $PROBES_FAILED
+ exec touch $PROBES_FAILED
+ puts "Append $PROBES_FAILED to $PROBES_PENDING, now size=[get_linesize $PROBES_PENDING]"
+ }
+ if {[get_linesize $PROBES_UNTRIGGERED] > 0} {
+ # Append probes.untriggered to probes.pending
+ exec cat $PROBES_UNTRIGGERED >> $PROBES_PENDING
+ file delete $PROBES_UNTRIGGERED
+ exec touch $PROBES_UNTRIGGERED
+ puts "Append $PROBES_UNTRIGGERED to $PROBES_PENDING, now size=[get_linesize $PROBES_PENDING]"
+ }
+ if {[get_linesize $PROBES_PENDING] == 0} {
+ # No more pending probe points
+ puts "No more iterations needed. Stopped."
+ break
+ }
+ # set new value of current_size_const for new iteration level
+ set current_size_const [proper_current_size [get_running_level] $PROBES_ALL]
+ puts "current_size_const is set as $current_size_const now"
+ continue
+ }
+ }
+ # Now, non-empty probes.pending should be ready
+ # Generate probes.current
+ exec rm -f $PROBES_CURRENT
+ exec head -n $current_size_const $PROBES_PENDING > $PROBES_CURRENT
+ exec tail -n+[expr $current_size_const+1] $PROBES_PENDING > /tmp/whitelist_tmpfile
+ exec mv /tmp/whitelist_tmpfile $PROBES_PENDING
+ sync_discs
+
+ set d [exec date]
+ puts "Ready to do current probe test at $d"
+ # Do actual probe test
+ do_current_test
+ set d [exec date]
+ puts "Completed one probe test successfully at $d"
+
+ # No crash fortunately, so do some cleaning to prepare for next test
+ garbage_collect $NO_CRASH
+}
+
+# Congratulations for arriving here
+# Remove all temporary files and unregister myself
+puts "Now removing all temporary files, unregistering the service and exit."
+exec rm -f $PROBES_PENDING $PROBES_CURRENT $GENKPROBES_RUNNING
+exec rm -f $PROBES_RESULT /tmp/whitelist_tmpfile
+unregister_service
+exit 0
diff --git a/scripts/kprobes_test/whitelist_lib.exp b/scripts/kprobes_test/whitelist_lib.exp
new file mode 100755
index 00000000..122c320b
--- /dev/null
+++ b/scripts/kprobes_test/whitelist_lib.exp
@@ -0,0 +1,175 @@
+# Defines the supporting procedures used by whitelist.exp
+#
+# Copyright (C) 2006 IBM Corp.
+# Copyright (C) 2008 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+#
+# Based on software written by Gui Jian <guijian@cn.ibm.com>
+#
+set NO_CRASH 0
+set ALREADY_CRASHED 1
+
+set startup_line_in_RCLOCAL "cd $env(PWD) && runtest whitelist.exp&"
+set RCLOCAL "/etc/rc.d/rc.local"
+
+set GROUP_NUM 1
+
+proc do_current_test {} {
+ global GROUP_NUM
+ set testname "L[get_running_level]_G$GROUP_NUM"
+ set GROUP_NUM [expr $GROUP_NUM + 1]
+
+ # Generate the C code
+ if {[catch {exec ./gen_code.py} results]} {
+ puts results
+ if {[lindex $::errorCode 0] eq "CHILDSTATUS"} {
+ set status [lindex $::errorCode 2]
+ } else {
+ # Some kind of unexpected failure
+ set status -1
+ }
+
+ if {$status != 0} {
+ return;
+ }
+ }
+ wait
+ set module_path "[pwd]/kprobe_module.ko"
+ whitelist_run $testname $module_path
+}
+
+proc get_linesize {filename} {
+ if [file readable $filename] {
+ scan [exec wc -l $filename] "%d" lines
+ if {[info exists lines] && $lines > 0} {
+ return $lines
+ }
+ }
+ return 0
+}
+
+proc get_running_level {} {
+ global GENKPROBES_RUNNING
+ if [file readable $GENKPROBES_RUNNING] {
+ scan [exec cat $GENKPROBES_RUNNING] "%d" current_running_level
+ if {[info exists current_running_level] && $current_running_level > 0} {
+ return $current_running_level
+ }
+ }
+ return 0
+}
+
+proc sync_discs {} {
+ exec sync
+ exec sync
+ exec sync
+ exec sleep 5
+ return
+}
+
+# Notice throughout garbage_collect we make sure the discs are synced
+# before we return. Otherwise, if the changes don't get flushed to
+# disk and the system crashes, we'll end up in an infinite loop of
+# crashes.
+proc garbage_collect {{already_crashed $NO_CRASH}} {
+ global PROBES_RESULT
+ global PROBES_CURRENT
+ global PROBES_PASSED
+ global PROBES_FAILED
+ global PROBES_UNTRIGGERED
+
+ if {[get_linesize $PROBES_CURRENT] == 0} {
+ puts "Empty $PROBES_CURRENT, returning"
+ exec rm -f $PROBES_CURRENT $PROBES_RESULT
+ sync_discs
+ return
+ }
+ if {[get_linesize $PROBES_RESULT] == 0} {
+ puts "Empty $PROBES_RESULT"
+ if {$already_crashed} {
+ exec cat $PROBES_CURRENT >> $PROBES_FAILED
+ } else {
+ exec cat $PROBES_CURRENT >> $PROBES_UNTRIGGERED
+ }
+ exec rm -f $PROBES_CURRENT $PROBES_RESULT
+ sync_discs
+ return
+ }
+
+ # both probes.current and probe.out are non-empty
+ if [catch {open $PROBES_CURRENT r} Infile] {
+ puts "Failed to open $PROBES_CURRENT"
+ exec rm -f $PROBES_CURRENT $PROBES_RESULT
+ sync_discs
+ return
+ }
+
+ puts "Running ./is_probed.py"
+ exec ./is_probed.py
+
+ catch {close $Infile}
+ exec rm -f $PROBES_CURRENT $PROBES_RESULT
+ sync_discs
+ return
+}
+
+proc incr_running_level {} {
+ global GENKPROBES_RUNNING
+ set newlevel [expr [get_running_level]+1]
+ if { $newlevel > 0 } {
+ exec echo $newlevel > $GENKPROBES_RUNNING
+ } else {
+ exec echo 0 > $GENKPROBES_RUNNING
+ }
+ return
+}
+
+proc init_probes_all {} {
+ exec ./readelf.py
+}
+
+proc init_running_level {} {
+ global GENKPROBES_RUNNING
+ exec echo 1 > $GENKPROBES_RUNNING
+}
+
+proc register_service {} {
+ global startup_line_in_RCLOCAL
+ global RCLOCAL
+ exec sed -i -n -e "/runtest whitelist.exp/!p" $RCLOCAL
+ exec echo $startup_line_in_RCLOCAL >> $RCLOCAL
+}
+
+proc unregister_service {} {
+ global RCLOCAL
+ exec sed -i -n -e "/runtest whitelist.exp/!p" $RCLOCAL
+}
+
+proc whitelist_run { TEST_NAME MODULE } {
+ if {[info procs installtest_p] != "" && ![installtest_p]} {
+ untested $TEST_NAME;
+ return;
+ }
+
+ set status 0
+ if {[catch {exec ./run_module.py} results]} {
+ puts $results
+ if {[lindex $::errorCode 0] eq "CHILDSTATUS"} {
+ set status [lindex $::errorCode 2]
+ } else {
+ # Some kind of unexpected failure
+ set status -1
+ }
+ }
+ if {$status != 0} {
+ fail $TEST_NAME;
+ return;
+ }
+ pass "$TEST_NAME end successfully";
+
+ wait
+}
diff --git a/stap-add-server-cert b/stap-add-server-cert
new file mode 100755
index 00000000..976f323f
--- /dev/null
+++ b/stap-add-server-cert
@@ -0,0 +1,46 @@
+#!/bin/bash
+
+# Add an existing server certificate to the
+# database of trusted servers for the client.
+#
+# Copyright (C) 2008, 2009 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+# Obtain the filename of the certificate
+if test "X$1" = "X"; then
+ echo "Certificate file must be specified" >&2
+ exit 1
+fi
+if ! test -f $1; then
+ echo "Cannot find certificate file $1" >&2
+ exit 1
+fi
+
+# Obtain the certificate database directory name.
+if test "X$2" = "X"; then
+ echo "Certificate database directory must be specified" >&2
+ exit 1
+fi
+if ! test -d $2/client; then
+ if ! mkdir -p $2/client; then
+ echo "Unable to find or create the client certificate database directory: $2/client" >&2
+ exit 1
+ fi
+fi
+
+# Add the certificate
+if ! certutil -A -n stap-server -d $2/client -i $1 -t "P,P,P" > /dev/null; then
+ echo "Unable to add $1 to the client certificate database $2" >&2
+ exit 1
+fi
+
+# Ensure that the database is readable by others
+if ! chmod +r $2/client/*.db; then
+ echo "Warning: unable to make the client certificate database $2 readable by others" >&2
+fi
+
+exit 0
diff --git a/stap-client b/stap-client
index 255551b3..09ee60bf 100755
--- a/stap-client
+++ b/stap-client
@@ -2,7 +2,7 @@
# Compile server client for systemtap
#
-# Copyright (C) 2008 Red Hat Inc.
+# Copyright (C) 2008, 2009 Red Hat Inc.
#
# This file is part of systemtap, and is free software. You can
# redistribute it and/or modify it under the terms of the GNU General
@@ -29,11 +29,6 @@ function configuration {
tmpdir_prefix_client=stap.client
tmpdir_prefix_server=stap.server
avahi_service_tag=_stap._tcp
-
- # We need either netcat or nc.
- netcat=`which netcat 2>/dev/null`
- test "X$netcat" = "X" && netcat=`which nc 2>/dev/null`
- test "X$netcat" = "X" && fatal "ERROR: cannot find required program 'netcat' or 'nc' on PATH"
}
# function: initialization
@@ -43,6 +38,29 @@ function initialization {
umask 0
staprun_running=0
+ # Where are we installed?
+ if test "`basename $0`" = "stap" -a "$0" = `which stap`; then
+ # The dejagnu test harness may invoke us as 'stap' relying on $PATH to
+ # find us. If so, then use the $PATH to find the rest of the systemtap
+ # tools.
+ exec_prefix=""
+ # Also, set the prefix to point to where we were found.
+ prefix=`which stap`
+ prefix=`dirname $prefix`
+ else
+ # Assume we were installed normally
+ exec_prefix=`dirname $0`
+ exec_prefix=`cd $exec_prefix && pwd`/
+ prefix=`dirname $exec_prefix`
+ fi
+
+ # Default location for server certificates if we're not root
+ if test $EUID != 0; then
+ local_ssl_dbs="$HOME/.systemtap/ssl/client"
+ fi
+ # Additional location for all users.
+ public_ssl_dbs=$prefix/etc/systemtap/ssl/client
+
# Default options settings
p_phase=5
v_level=0
@@ -86,14 +104,28 @@ function parse_options {
# It's not a lone dash, so it's an option.
# Is it a long option (i.e. --option)?
second_char=`expr "$first_token" : '.\(.\).*'`
- if test "$second_char" != "-"; then
- # It's not a lone dash, or a long option, so it's a short option string.
- # Remove the dash.
- first_token=`expr "$first_token" : '-\(.*\)'`
- dash_seen=1
- first_char=`expr "$first_token" : '\(.\).*'`
- cmdline2="$cmdline2 -"
+ if test "X$second_char" = "X-"; then
+ long_option=`expr "$first_token" : '--\(.*\)=.*'`
+ test "X$long_option" != "X" || long_option=`expr "$first_token" : '--\(.*\)'`
+ case $long_option in
+ ssl)
+ process_ssl $first_token
+ ;;
+ *)
+ # An unknown or unimportant option.
+ # Ignore it, but pass it on to the server.
+ cmdline2="$cmdline2 $first_token"
+ ;;
+ esac
+ advance_p=$(($advance_p + 1))
+ break
fi
+ # It's not a lone dash, or a long option, so it's a short option string.
+ # Remove the dash.
+ first_token=`expr "$first_token" : '-\(.*\)'`
+ dash_seen=1
+ first_char=`expr "$first_token" : '\(.\).*'`
+ cmdline2="$cmdline2 -"
fi
fi
if test $dash_seen = 0; then
@@ -212,6 +244,8 @@ function parse_options {
else
cmdline="$cmdline1 $cmdline2"
fi
+
+ local_ssl_dbs="$additional_local_ssl_dbs $local_ssl_dbs"
}
# function: get_arg FIRSTWORD SECONDWORD
@@ -236,6 +270,18 @@ function get_arg {
advance_p=$(($advance_p + 1))
}
+# function: process_ssl ARGUMENT
+#
+# Process the --ssl option.
+function process_ssl {
+ local db=`expr "$1" : '--ssl=\(.*\)'`
+
+ test "X$db" != "X" || \
+ fatal "Missing argument to --ssl"
+
+ additional_local_ssl_dbs="$additional_local_ssl_dbs $db"
+}
+
# function: process_c ARGUMENT
#
# Process the -c flag.
@@ -370,86 +416,44 @@ function client_sysinfo {
# Package the client's temp directory into a form suitable for sending to the
# server.
function package_request {
- # Package up the temporary directory into a tar file
+ # Package up the temporary directory into a zip file
cd $tmpdir_env
local tmpdir_client_base=`basename $tmpdir_client`
- tar_client=$tmpdir_env/`mktemp $tmpdir_client_base.tgz.XXXXXX` || \
- fatal "ERROR: cannot create temporary file " $tar_client
-
- tar -czhf $tar_client $tmpdir_client_base || \
- fatal "ERROR: tar of request tree, $tmpdir_client, failed"
-}
-
-# function: send_request
-#
-# Notify the server and then send $tar_client to the server
-# The protocol is:
-# client -> "request:"
-# client -> $tar_client
-function send_request {
- # Send the request file.
- for ((attempt=0; $attempt < 10; ++attempt))
- do
- if $netcat -w10 $server $(($port+1)) < $tar_client > /dev/null 2>&1; then
- return;
- fi
- sleep 1
- done
- fatal "ERROR: Unable to connect to server while sending request file"
-}
-
-# function: receive_response
-#
-# Wait for a response from the server indicating the results of our request.
-function receive_response {
- # Make a place to receive the response file.
- tar_server=`mktemp -t $tmpdir_prefix_client.server.tgz.XXXXXX` || \
- fatal "ERROR: cannot create temporary file " $tar_server
+ zip_client=$tmpdir_env/`mktemp $tmpdir_client_base.zip.XXXXXX` || \
+ fatal "ERROR: cannot create temporary file " $zip_client
- # Retrieve the file. Wait for up to 5 minutes for a response.
- for ((attempt=0; $attempt < 300; ++attempt))
- do
- if $netcat -d $server $(($port+1)) > $tar_server 2>/dev/null; then
- return;
- fi
- sleep 1
- done
- fatal "ERROR: Unable to connect to server while receiving response file"
+ (rm $zip_client && zip -r $zip_client $tmpdir_client_base > /dev/null) || \
+ fatal "ERROR: zip of request tree, $tmpdir_client, failed"
}
# function: unpack_response
#
-# Unpack the tar file received from the server and make the contents available
+# Unpack the jar file received from the server and make the contents available
# for printing the results and/or running 'staprun'.
function unpack_response {
tmpdir_server=`mktemp -dt $tmpdir_prefix_client.server.XXXXXX` || \
fatal "ERROR: cannot create temporary file " $tmpdir_server
- # Unpack the server output directory
- cd $tmpdir_server
- tar -xzf $tar_server || \
- fatal "ERROR: Unpacking of server response, $tar_server, failed"
-
- # Identify the server's response tree. The tar file should have expanded
- # into a single directory named to match $tmpdir_prefix_server.??????
- # which should now be the only item in the current directory.
- test "`ls | wc -l`" = 1 || \
- fatal "ERROR: Wrong number of files after expansion of server's tar file"
-
- tmpdir_server=`ls`
- tmpdir_server=`expr "$tmpdir_server" : "\\\($tmpdir_prefix_server\\\\.......\\\)"`
+ # Unpack and verify the digitally signed server output directory
+ if ! signtool -d $ssl_db -v $jar_server > /dev/null 2>&1; then
+ # Run the verification again to get the reason
+ fatal "ERROR: Verification of server response, $jar_server, failed.
+"`signtool -d $ssl_db -v $jar_server | grep "reported reason"`
+ fi
- test "X$tmpdir_server" != "X" || \
- fatal "ERROR: server tar file did not expand as expected"
+ # Unpack the server output directory
+ unzip -d $tmpdir_server $jar_server > /dev/null || \
+ fatal "ERROR: Cannot unpack server response, $jar_server"
# Check the contents of the expanded directory. It should contain:
# 1) a file called stdout
# 2) a file called stderr
# 3) a file called rc
- # 4) optionally a directory named to match stap??????
+ # 4) a directory called META-INF
+ # 5) optionally a directory named to match stap??????
local num_files=`ls $tmpdir_server | wc -l`
- test $num_files = 4 -o $num_files = 3 || \
+ test $num_files = 5 -o $num_files = 4 || \
fatal "ERROR: Wrong number of files in server's temp directory"
test -f $tmpdir_server/stdout || \
fatal "ERROR: `pwd`/$tmpdir_server/stdout does not exist or is not a regular file"
@@ -457,6 +461,8 @@ function unpack_response {
fatal "ERROR: `pwd`/$tmpdir_server/stderr does not exist or is not a regular file"
test -f $tmpdir_server/rc || \
fatal "ERROR: `pwd`/$tmpdir_server/rc does not exist or is not a regular file"
+ test -d $tmpdir_server/META-INF || \
+ fatal "ERROR: `pwd`/$tmpdir_server/META-INF does not exist or is not a directory"
# See if there is a systemtap temp directory
tmpdir_stap=`ls $tmpdir_server | grep stap`
@@ -479,16 +485,8 @@ function unpack_response {
else
# Make sure we own the systemtap temp directory if we are root.
test $EUID = 0 && chown $EUID:$EUID $tmpdir_server/$tmpdir_stap
- # The temp directory will be moved to here below.
- tmpdir_stap=`pwd`/$tmpdir_stap
fi
fi
-
- # Move the contents of the server's tmpdir down one level to the
- # current directory (our local server tmpdir)
- mv $tmpdir_server/* . 2>/dev/null
- rm -fr $tmpdir_server
- tmpdir_server=`pwd`
}
# function: find_and_connect_to_server
@@ -498,7 +496,7 @@ function find_and_connect_to_server {
# Use a temp file here instead of a pipeline so that the side effects
# of choose_server are seen by the rest of this script.
cd $tmpdir_client
- stap-find-servers > servers
+ ${exec_prefix}stap-find-servers > servers
choose_server < servers
rm -fr servers
}
@@ -514,6 +512,22 @@ function choose_server {
do
num_servers=$(($num_servers + 1))
+ # The server must match the dns name on the certificate
+ # and must be 'localhost' if the server is on the local host.
+ local server_host_name=`expr "$name" : "\\\([a-zA-Z0-9-]*\\\).*"`
+ local server_domain_name=`expr "$name" : "$server_host_name\\\(.*\\\)"`
+ local our_host_name=`expr "$HOSTNAME" : "\\\([a-zA-Z0-9-]*\\\).*"`
+ local our_domain_name=`expr "$HOSTNAME" : "$our_host_name\\\(.*\\\)"`
+
+ if test "X$server_domain_name" = "X.local"; then
+ server_domain_name=$our_domain_name
+ fi
+ if test "X$server_host_name$server_domain_name" = "X$our_host_name$our_domain_name"; then
+ server=localhost
+ else
+ server=$server_host_name$server_domain_name
+ fi
+
if test "X$server" = "X"; then
fatal "ERROR: server ip address not provided"
fi
@@ -522,7 +536,7 @@ function choose_server {
fatal "ERROR: server port not provided"
fi
- if connect_to_server $server $port; then
+ if send_receive; then
return 0
fi
done
@@ -531,36 +545,53 @@ function choose_server {
fatal "ERROR: unable to find a server"
fi
+ cat $tmpdir_client/connect >&2
fatal "ERROR: unable to connect to a server"
}
-# function: connect_to_server IP PORT
+# function: send_receive
#
-# Establish connection with the given server
-function connect_to_server {
- for ((attempt=0; $attempt < 10; ++attempt))
+# Connect to the server, send the request and receive the response
+function send_receive {
+ # Make a place to receive the response file.
+ jar_server=`mktemp -t $tmpdir_prefix_client.server.jar.XXXXXX` || \
+ fatal "ERROR: cannot create temporary file " $jar_server
+
+ # If the server is local, try to connect using each of the given local
+ # certificate databases in turn for verification.
+ if test "X$server" = "Xlocalhost"; then
+ for db in $local_ssl_dbs
+ do
+ # Send the request and receive the response using stap-client-connect
+ echo "Attempting connection with $server using certificate database in '$db'" >> $tmpdir_client/connect
+ ${exec_prefix}stap-client-connect -i $zip_client -o $jar_server -d $db -p $port -h $server >> $tmpdir_client/connect 2>&1 &
+ wait '%${exec_prefix}stap-client-connect'
+ test $? = 0 && ssl_db=$db && return 0
+ sleep 1
+ done
+ fi
+
+ # We can try the public certificate databases for all servers.
+ for db in $public_ssl_dbs
do
- if echo "request:" | $netcat -w10 $1 $2 >/dev/null 2>&1; then
- return 0
- fi
+ # Send the request and receive the response using stap-client-connect
+ echo "Attempting connection with $server using certificate database in '$db'" >> $tmpdir_client/connect
+ ${exec_prefix}stap-client-connect -i $zip_client -o $jar_server -d $db -p $port -h $server >> $tmpdir_client/connect 2>&1 &
+ wait '%${exec_prefix}stap-client-connect'
+ test $? = 0 && ssl_db=$db && return 0
sleep 1
done
+ # Could not connect using any of the certificate databases
return 1
}
-# function: disconnect_from_server
-#
-# Disconnect from the server.
-function disconnect_from_server {
- :
-}
-
# function: process_response
#
# Write the stdout and stderr from the server to stdout and stderr respectively.
function process_response {
# Pick up the results of running stap on the server.
+ cd $tmpdir_server
rc=`cat rc`
# Copy the module to the current directory, if -m was specified
@@ -637,7 +668,7 @@ function maybe_call_staprun {
if test $v_level -ge 2; then
echo "running `which staprun` $staprun_opts $tmpdir_stap/`ls $tmpdir_stap | grep '.ko$'`" >&2
fi
- PATH=`staprun_PATH` eval staprun "$staprun_opts" \
+ eval `staprun_PATH` "$staprun_opts" \
$tmpdir_stap/`ls $tmpdir_stap | grep '.ko$'`
staprun_running=1
wait '%?staprun' > /dev/null 2>&1
@@ -661,23 +692,25 @@ function maybe_call_staprun {
#
# Compute a PATH suitable for running staprun.
function staprun_PATH {
- # staprun may invoke 'stap'. So we can use the current PATH if we were
- # not invoked as 'stap' or we are not the first 'stap' on the PATH.
- local first_stap=`which stap 2>/dev/null`
-
- if test "X$first_stap" = "X"; then
- echo "$PATH"
+ # If $SYSTEMTAP_STAPRUN is set, then use that
+ if test "X$SYSTEMTAP_STAPRUN" != "X"; then
+ echo $SYSTEMTAP_STAPRUN
return
fi
- if test `which $0 2>/dev/null` != $first_stap; then
- echo "$PATH"
+ # Otherwise, if there is an exec_prefix, then use it.
+ if test "X$exec_prefix" != "X"; then
+ echo ${exec_prefix}staprun
return
fi
- # Otherwise, remove the PATH component where we live from the PATH
+ # Otherwise, we have been called by the dejagnu test harness as 'stap'
+ # and we are the first 'stap' on the path. Since staprun may call
+ # 'stap', remove the PATH component where we live from the PATH in order to
+ # avoid recursion.
+ local first_stap=`which stap`
local PATH_component=`dirname $first_stap`
- echo "$PATH" | sed "s,$PATH_component,,g"
+ echo "PATH=$PATH staprun" | sed "s,$PATH_component,,g"
}
# function: fatal [ MESSAGE ]
@@ -686,7 +719,6 @@ function staprun_PATH {
# Prints its arguments to stderr and exits
function fatal {
echo "$0:" "$@" >&2
- disconnect_from_server
cleanup
exit 1
}
@@ -699,8 +731,8 @@ function cleanup {
cd $tmpdir_env
if test $keep_temps != 1; then
rm -fr $tmpdir_client
- rm -f $tar_client
- rm -f $tar_server
+ rm -f $zip_client
+ rm -f $jar_server
rm -fr $tmpdir_server
fi
}
@@ -716,6 +748,9 @@ function terminate {
# Kill any running staprun job
kill -s SIGTERM '%?staprun' 2>/dev/null
+ # Kill any stap-client-connect job
+ kill -s SIGTERM '%${exec_prefix}stap-client-connect'
+
exit 1
}
@@ -729,6 +764,10 @@ function interrupt {
return
fi
+ # Kill any stap-client-connect job
+ # SIGINT won't do it.
+ kill -s SIGTERM '%${exec_prefix}stap-client-connect'
+
# If staprun was not running, then exit.
cleanup
exit 1
@@ -750,9 +789,6 @@ parse_options "$@"
create_request
package_request
find_and_connect_to_server
-send_request
-receive_response
-disconnect_from_server
unpack_response
process_response
maybe_call_staprun
diff --git a/stap-client-connect.c b/stap-client-connect.c
new file mode 100644
index 00000000..9466b566
--- /dev/null
+++ b/stap-client-connect.c
@@ -0,0 +1,488 @@
+/*
+ SSL client program that sets up a connection to a SSL server, transmits
+ the given input file and then writes the reply to the given output file.
+
+ Copyright (C) 2008, 2009 Red Hat Inc.
+
+ This file is part of systemtap, and is free software. You can
+ redistribute it and/or modify it under the terms of the GNU General Public
+ License as published by the Free Software Foundation; either version 2 of the
+ License, or (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+*/
+
+#include <stdio.h>
+
+#include <ssl.h>
+#include <nspr.h>
+#include <plgetopt.h>
+#include <nss.h>
+#include <prerror.h>
+#include <secerr.h>
+
+#define READ_BUFFER_SIZE (60 * 1024)
+static char *hostName = NULL;
+static unsigned short port = 0;
+static const char *infileName = NULL;
+static const char *outfileName = NULL;
+
+static void
+Usage(const char *progName)
+{
+ fprintf(stderr, "Usage: %s -h hostname -p port -d dbdir -i infile -o outfile\n",
+ progName);
+ exit(1);
+}
+
+static void
+errWarn(char *function)
+{
+ PRErrorCode errorNumber;
+ PRInt32 errorTextLength;
+ PRInt32 rc;
+ char *errorText;
+
+ errorNumber = PR_GetError();
+ fprintf(stderr, "Error in function %s: %d: ", function, errorNumber);
+
+ /* See if PR_GetErrorText can tell us what the error is. */
+ if (errorNumber >= PR_NSPR_ERROR_BASE && errorNumber <= PR_MAX_ERROR)
+ {
+ errorTextLength = PR_GetErrorTextLength ();
+ if (errorTextLength != 0) {
+ errorText = PORT_Alloc(errorTextLength);
+ rc = PR_GetErrorText (errorText);
+ if (rc != 0)
+ fprintf (stderr, "%s\n", errorText);
+ PR_Free (errorText);
+ if (rc != 0)
+ return;
+ }
+ }
+
+ /* Otherwise handle common errors ourselves. */
+ switch (errorNumber)
+ {
+ case SEC_ERROR_CA_CERT_INVALID:
+ fputs ("The issuer's certificate is invalid\n", stderr);
+ break;
+ case PR_CONNECT_RESET_ERROR:
+ fputs ("Connection reset by peer\n", stderr);
+ break;
+ default:
+ fputs ("Unknown error\n", stderr);
+ break;
+ }
+}
+
+static void
+exitErr(char *function)
+{
+ errWarn(function);
+ /* Exit gracefully. */
+ /* ignoring return value of NSS_Shutdown as code exits with 1*/
+ (void) NSS_Shutdown();
+ PR_Cleanup();
+ exit(1);
+}
+
+static PRFileDesc *
+setupSSLSocket(void)
+{
+ PRFileDesc *tcpSocket;
+ PRFileDesc *sslSocket;
+ PRSocketOptionData socketOption;
+ PRStatus prStatus;
+ SECStatus secStatus;
+
+ tcpSocket = PR_NewTCPSocket();
+ if (tcpSocket == NULL)
+ {
+ errWarn("PR_NewTCPSocket");
+ }
+
+ /* Make the socket blocking. */
+ socketOption.option = PR_SockOpt_Nonblocking;
+ socketOption.value.non_blocking = PR_FALSE;
+
+ prStatus = PR_SetSocketOption(tcpSocket, &socketOption);
+ if (prStatus != PR_SUCCESS)
+ {
+ errWarn("PR_SetSocketOption");
+ goto loser;
+ }
+
+ /* Import the socket into the SSL layer. */
+ sslSocket = SSL_ImportFD(NULL, tcpSocket);
+ if (!sslSocket)
+ {
+ errWarn("SSL_ImportFD");
+ goto loser;
+ }
+
+ /* Set configuration options. */
+ secStatus = SSL_OptionSet(sslSocket, SSL_SECURITY, PR_TRUE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet:SSL_SECURITY");
+ goto loser;
+ }
+
+ secStatus = SSL_OptionSet(sslSocket, SSL_HANDSHAKE_AS_CLIENT, PR_TRUE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet:SSL_HANDSHAKE_AS_CLIENT");
+ goto loser;
+ }
+
+ /* Set SSL callback routines. */
+#if 0 /* no client authentication */
+ secStatus = SSL_GetClientAuthDataHook(sslSocket,
+ (SSLGetClientAuthData)myGetClientAuthData,
+ (void *)certNickname);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_GetClientAuthDataHook");
+ goto loser;
+ }
+#endif
+#if 0 /* Use the default */
+ secStatus = SSL_AuthCertificateHook(sslSocket,
+ (SSLAuthCertificate)myAuthCertificate,
+ (void *)CERT_GetDefaultCertDB());
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_AuthCertificateHook");
+ goto loser;
+ }
+#endif
+#if 0 /* Use the default */
+ secStatus = SSL_BadCertHook(sslSocket,
+ (SSLBadCertHandler)myBadCertHandler, NULL);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_BadCertHook");
+ goto loser;
+ }
+#endif
+#if 0 /* No handshake callback */
+ secStatus = SSL_HandshakeCallback(sslSocket, myHandshakeCallback, NULL);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_HandshakeCallback");
+ goto loser;
+ }
+#endif
+
+ return sslSocket;
+
+ loser:
+ PR_Close(tcpSocket);
+ return NULL;
+}
+
+
+static SECStatus
+handle_connection(PRFileDesc *sslSocket)
+{
+#if DEBUG
+ int countRead = 0;
+#endif
+ PRInt32 numBytes;
+ char *readBuffer;
+ PRFileInfo info;
+ PRFileDesc *local_file_fd;
+ PRStatus prStatus;
+
+ /* read and send the data. */
+ /* Try to open the local file named.
+ * If successful, then write it to the server
+ */
+ prStatus = PR_GetFileInfo(infileName, &info);
+ if (prStatus != PR_SUCCESS ||
+ info.type != PR_FILE_FILE ||
+ info.size < 0)
+ {
+ fprintf (stderr, "could not find input file %s\n", infileName);
+ return SECFailure;
+ }
+
+ local_file_fd = PR_Open(infileName, PR_RDONLY, 0);
+ if (local_file_fd == NULL)
+ {
+ fprintf (stderr, "could not open input file %s\n", infileName);
+ return SECFailure;
+ }
+
+ /* Send the file size first, so the server knows when it has the entire file. */
+ numBytes = PR_Write(sslSocket, & info.size, sizeof (info.size));
+ if (numBytes < 0)
+ {
+ errWarn("PR_Write");
+ return SECFailure;
+ }
+
+ /* Transmit the local file across the socket. */
+ numBytes = PR_TransmitFile(sslSocket, local_file_fd,
+ NULL, 0,
+ PR_TRANSMITFILE_KEEP_OPEN,
+ PR_INTERVAL_NO_TIMEOUT);
+ if (numBytes < 0)
+ {
+ errWarn("PR_TransmitFile");
+ return SECFailure;
+ }
+
+#if DEBUG
+ /* Transmitted bytes successfully. */
+ fprintf(stderr, "PR_TransmitFile wrote %d bytes from %s\n",
+ numBytes, infileName);
+#endif
+
+ PR_Close(local_file_fd);
+
+ /* read until EOF */
+ readBuffer = PORT_Alloc(READ_BUFFER_SIZE);
+ if (! readBuffer)
+ exitErr("PORT_Alloc");
+
+ local_file_fd = PR_Open(outfileName, PR_WRONLY | PR_CREATE_FILE | PR_TRUNCATE,
+ PR_IRUSR | PR_IWUSR | PR_IRGRP | PR_IWGRP | PR_IROTH);
+ if (local_file_fd == NULL)
+ {
+ fprintf (stderr, "could not open output file %s\n", outfileName);
+ return SECFailure;
+ }
+ while (PR_TRUE)
+ {
+ numBytes = PR_Read(sslSocket, readBuffer, READ_BUFFER_SIZE);
+ if (numBytes == 0)
+ break; /* EOF */
+
+ if (numBytes < 0)
+ {
+ errWarn("PR_Read");
+ break;
+ }
+#if DEBUG
+ countRead += numBytes;
+#endif
+ /* Write to output file */
+ numBytes = PR_Write(local_file_fd, readBuffer, numBytes);
+ if (numBytes < 0)
+ {
+ fprintf (stderr, "could not write to %s\n", outfileName);
+ break;
+ }
+#if DEBUG
+ fprintf(stderr, "***** Connection read %d bytes (%d total).\n",
+ numBytes, countRead );
+ readBuffer[numBytes] = '\0';
+ fprintf(stderr, "************\n%s\n************\n", readBuffer);
+#endif
+ }
+
+ PR_Free(readBuffer);
+ PR_Close(local_file_fd);
+
+ /* Caller closes the socket. */
+#if DEBUG
+ fprintf(stderr, "***** Connection read %d bytes total.\n", countRead);
+#endif
+
+ return SECSuccess;
+}
+
+/* make the connection.
+*/
+static SECStatus
+do_connect(PRNetAddr *addr)
+{
+ PRFileDesc *sslSocket;
+ PRHostEnt hostEntry;
+ char buffer[PR_NETDB_BUF_SIZE];
+ PRStatus prStatus;
+ PRIntn hostenum;
+ SECStatus secStatus;
+
+ secStatus = SECSuccess;
+
+ /* Set up SSL secure socket. */
+ sslSocket = setupSSLSocket();
+ if (sslSocket == NULL)
+ {
+ errWarn("setupSSLSocket");
+ return SECFailure;
+ }
+
+#if 0 /* no client authentication */
+ secStatus = SSL_SetPKCS11PinArg(sslSocket, password);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_SetPKCS11PinArg");
+ goto done;
+ }
+#endif
+
+ secStatus = SSL_SetURL(sslSocket, hostName);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_SetURL");
+ goto done;
+ }
+
+ /* Prepare and setup network connection. */
+ prStatus = PR_GetHostByName(hostName, buffer, sizeof(buffer), &hostEntry);
+ if (prStatus != PR_SUCCESS)
+ {
+ errWarn("PR_GetHostByName");
+ secStatus = SECFailure;
+ goto done;
+ }
+
+ hostenum = PR_EnumerateHostEnt(0, &hostEntry, port, addr);
+ if (hostenum == -1)
+ {
+ errWarn("PR_EnumerateHostEnt");
+ secStatus = SECFailure;
+ goto done;
+ }
+
+ prStatus = PR_Connect(sslSocket, addr, PR_INTERVAL_NO_TIMEOUT);
+ if (prStatus != PR_SUCCESS)
+ {
+ errWarn("PR_Connect");
+ secStatus = SECFailure;
+ goto done;
+ }
+
+ /* Established SSL connection, ready to send data. */
+ secStatus = SSL_ResetHandshake(sslSocket, /* asServer */ PR_FALSE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_ResetHandshake");
+ goto done;
+ }
+
+ /* This is normally done automatically on the first I/O operation,
+ but doing it here catches any authentication problems early. */
+ secStatus = SSL_ForceHandshake(sslSocket);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_ForceHandshake");
+ goto done;
+ }
+
+ secStatus = handle_connection(sslSocket);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("handle_connection");
+ goto done;
+ }
+
+ done:
+ prStatus = PR_Close(sslSocket);
+ if (prStatus != PR_SUCCESS)
+ errWarn("PR_Close");
+
+ return secStatus;
+}
+
+static void
+client_main(unsigned short port, const char *hostName)
+{
+ SECStatus secStatus;
+ PRStatus prStatus;
+ PRInt32 rv;
+ PRNetAddr addr;
+ PRHostEnt hostEntry;
+ char buffer[PR_NETDB_BUF_SIZE];
+
+ /* Setup network connection. */
+ prStatus = PR_GetHostByName(hostName, buffer, sizeof (buffer), &hostEntry);
+ if (prStatus != PR_SUCCESS)
+ exitErr("PR_GetHostByName");
+
+ rv = PR_EnumerateHostEnt(0, &hostEntry, port, &addr);
+ if (rv < 0)
+ exitErr("PR_EnumerateHostEnt");
+
+ secStatus = do_connect (&addr);
+ if (secStatus != SECSuccess)
+ exitErr("do_connect");
+}
+
+#if 0 /* No client authorization */
+static char *
+myPasswd(PK11SlotInfo *info, PRBool retry, void *arg)
+{
+ char * passwd = NULL;
+
+ if ( (!retry) && arg )
+ passwd = PORT_Strdup((char *)arg);
+
+ return passwd;
+}
+#endif
+
+int
+main(int argc, char **argv)
+{
+ char * certDir = NULL;
+ char * progName = NULL;
+ SECStatus secStatus;
+ PLOptState *optstate;
+ PLOptStatus status;
+
+ /* Call the NSPR initialization routines */
+ PR_Init( PR_SYSTEM_THREAD, PR_PRIORITY_NORMAL, 1);
+
+ progName = PL_strdup(argv[0]);
+
+ hostName = NULL;
+ optstate = PL_CreateOptState(argc, argv, "d:h:i:o:p:");
+ while ((status = PL_GetNextOpt(optstate)) == PL_OPT_OK)
+ {
+ switch(optstate->option)
+ {
+ case 'd' : certDir = PL_strdup(optstate->value); break;
+ case 'h' : hostName = PL_strdup(optstate->value); break;
+ case 'i' : infileName = PL_strdup(optstate->value); break;
+ case 'o' : outfileName = PL_strdup(optstate->value); break;
+ case 'p' : port = PORT_Atoi(optstate->value); break;
+ case '?' :
+ default : Usage(progName);
+ }
+ }
+
+ if (port == 0 || hostName == NULL || infileName == NULL || outfileName == NULL || certDir == NULL)
+ Usage(progName);
+
+#if 0 /* no client authentication */
+ /* Set our password function callback. */
+ PK11_SetPasswordFunc(myPasswd);
+#endif
+
+ /* Initialize the NSS libraries. */
+ secStatus = NSS_Init(certDir);
+ if (secStatus != SECSuccess)
+ exitErr("NSS_Init");
+
+ /* All cipher suites except RSA_NULL_MD5 are enabled by Domestic Policy. */
+ NSS_SetDomesticPolicy();
+
+ client_main(port, hostName);
+
+ NSS_Shutdown();
+ PR_Cleanup();
+
+ return 0;
+}
diff --git a/stap-find-or-start-server b/stap-find-or-start-server
index 32a45052..efe23558 100755
--- a/stap-find-or-start-server
+++ b/stap-find-or-start-server
@@ -2,7 +2,7 @@
# Find or start a systemtap server
#
-# Copyright (C) 2008 Red Hat Inc.
+# Copyright (C) 2008, 2009 Red Hat Inc.
#
# This file is part of systemtap, and is free software. You can
# redistribute it and/or modify it under the terms of the GNU General
@@ -17,16 +17,20 @@
#
# Otherwise, it echoes -1 and exits with 1
+# Where are we installed?
+exec_prefix=`dirname $0`
+exec_prefix=`cd $exec_prefix && pwd`
+
# Is there a server available?
-stap-find-servers >/dev/null 2>&1 && echo 0 && exit 0
+$exec_prefix/stap-find-servers >/dev/null 2>&1 && echo 0 && exit 0
# No server available, try to start one.
-pid=`stap-start-server`
+pid=`$exec_prefix/stap-start-server "$@"`
if test $? = 0; then
echo $pid
exit 0
fi
# Could not find or start a server
-echo -1
+echo "-1"
exit 1
diff --git a/stap-gen-server-cert b/stap-gen-server-cert
new file mode 100755
index 00000000..f6445d8d
--- /dev/null
+++ b/stap-gen-server-cert
@@ -0,0 +1,92 @@
+#!/bin/bash
+
+# Generate a certificate for the systemtap server and add it to the
+# database of trusted servers for the client.
+#
+# Copyright (C) 2008, 2009 Red Hat Inc.
+#
+# This file is part of systemtap, and is free software. You can
+# redistribute it and/or modify it under the terms of the GNU General
+# Public License (GPL); either version 2, or (at your option) any
+# later version.
+
+# Obtain a password from stdin and echo it.
+function user_enter_password
+{
+ while true
+ do
+ while true
+ do
+ read -sp "Enter new password for systemtap server certificate/key database:" pw1 junk
+ echo "" >&2
+ test "X$pw1" != "X" && break
+ done
+ while true
+ do
+ read -sp "Reenter new password:" pw2 junk
+ echo "" >&2
+ test "X$pw2" != "X" && break
+ done
+ test "$pw1" = "$pw2" && break
+ echo "Passwords do not match" >&2
+ done
+
+ echo $pw1
+}
+
+# Obtain the certificate database directory name.
+if test "X$1" = "X"; then
+ echo "Certificate database directory must be specified" >&2
+ exit 1
+fi
+rm -fr $1
+
+# Create the server's certificate database directory.
+serverdb=$1/server
+if ! mkdir -p $serverdb; then
+ echo "Unable to create the server certificate database directory: $serverdb" >&2
+ exit 1
+fi
+
+# Create the certificate database password file. Care must be taken
+# that this file is only readable by the owner.
+if ! (touch $serverdb/pw && chmod 600 $serverdb/pw); then
+ echo "Unable to create the server certificate database password file: $serverdb/pw" >&2
+ exit 1
+fi
+
+# Generate a random password.
+mkpasswd -l 20 > $serverdb/pw 2>/dev/null || \
+apg -a 1 -n 1 -m 20 -x 20 > $serverdb/pw 2>/dev/null || \
+user_enter_password > $serverdb/pw
+
+# Generate the server certificate database
+if ! certutil -N -d $serverdb -f $serverdb/pw > /dev/null; then
+ echo "Unable to initialize the server certificate database directory: $serverdb" >&2
+ exit 1
+fi
+
+# We need some random noise for generating keys
+dd bs=123 count=1 < /dev/urandom > $1/noise 2> /dev/null
+
+# Generate a request for the server's certificate.
+certutil -R -d $serverdb -f $serverdb/pw -s "CN=Systemtap Compile Server, OU=Systemtap, O=Red Hat, C=US" -o $1/stap-server.req -z $1/noise 2> /dev/null
+rm -fr $1/noise
+
+# Now generate the actual certificate.
+certutil -C -i $1/stap-server.req -o $serverdb/stap-server.cert -x -d $serverdb -f $serverdb/pw -5 -8 "$HOSTNAME,localhost" >/dev/null <<-EOF
+1
+3
+7
+8
+y
+EOF
+rm -fr $1/stap-server.req
+
+# Ensure that the certificate is readable by others.
+if ! chmod +r $serverdb/stap-server.cert; then
+ echo "Warning: unable to make the server's certificate $serverdb/stap-server.cert readable by others" >&2
+fi
+
+# Add the certificate to the server's certificate/key database as a trusted peer, ssl server and object signer
+certutil -A -n stap-server -t "PCu,,PCu" -i $serverdb/stap-server.cert -d $serverdb -f $serverdb/pw
diff --git a/stap-server b/stap-server
index a06adc91..4f1ccf9b 100755
--- a/stap-server
+++ b/stap-server
@@ -2,7 +2,7 @@
# Compile server for systemtap
#
-# Copyright (C) 2008 Red Hat Inc.
+# Copyright (C) 2008, 2009 Red Hat Inc.
#
# This file is part of systemtap, and is free software. You can
# redistribute it and/or modify it under the terms of the GNU General
@@ -24,13 +24,6 @@ function configuration {
# Configuration
tmpdir_prefix_client=stap.client
tmpdir_prefix_server=stap.server
- port=$1
- test "X$port" = "X" && port=65001
-
- # We need either netcat or nc.
- netcat=`which netcat 2>/dev/null`
- test "X$netcat" = "X" && netcat=`which nc 2>/dev/null`
- test "X$netcat" = "X" && fatal "ERROR: cannot find required program 'netcat' or 'nc' on PATH"
}
# function: initialization
@@ -43,63 +36,57 @@ function initialization {
p_phase=5
keep_temps=0
- # Make a temp directory to work in.
- tmpdir_server=`mktemp -dt $tmpdir_prefix_server.XXXXXX` || \
- fatal "ERROR: cannot create temporary directory " $tmpdir_server
- tmpdir_env=`dirname $tmpdir_server`
-}
+ # Where are we installed?
+ exec_prefix=`dirname $0`
+ exec_prefix=`cd $exec_prefix && pwd`
-# function: receive_request
-#
-# Receive a tar file representing the request from the client:
-function receive_request {
- # Create a place to receive the client's tar file
- tar_client=`mktemp -t $tmpdir_prefix_server.client.tgz.XXXXXX` || \
- fatal "ERROR: cannot create temporary tar file " $tar_client
+ # Request file name.
+ zip_client=$1
+ test -f $zip_client || \
+ fatal "ERROR: Unable to find request file $zip_client"
- # Receive the file.
- $netcat -ld $port > $tar_client 2>/dev/null &
+ # Temp directory we will be working in
+ tmpdir_server=$2
+ test -d $tmpdir_server || \
+ fatal "ERROR: Cannot find temporary directory $tmpdir_server"
+ tmpdir_env=`dirname $tmpdir_server`
- # Wait for 10 seconds before timing out
- for ((t=0; $t < 10; ++t))
- do
- if jobs '%$netcat -l' >/dev/null 2>&1; then
- sleep 1
- else
- return
- fi
- done
+ # Signed reponse file name.
+ jar_server=$3
- # We have timed out. fatal will kill the job.
- fatal "Timed out waiting for client request file"
+ # Where is the ssl certificate/key database?
+ ssl_db=$4
+ test "X$ssl_db" = "X" && ssl_db=/etc/systemtap/ssl/server
+ nss_pw=$ssl_db/pw
+ nss_cert=stap-server
}
# function: unpack_request
#
-# Unpack the tar file received from the client and make the contents
+# Unpack the zip file received from the client and make the contents
# available for use when running 'stap'
function unpack_request {
cd $tmpdir_server
- # Unpack the tar file.
- tar -xzf $tar_client || \
- fatal "ERROR: cannot unpack tar archive $tar_client"
+ # Unpack the zip file.
+ unzip $zip_client > /dev/null || \
+ fatal "ERROR: cannot unpack zip archive $zip_client"
- # Identify the client's request tree. The tar file should have expanded
+ # Identify the client's request tree. The zip file should have expanded
# into a single directory named to match $tmpdir_prefix_client.??????
# which should now be the only item in the current directory.
test "`ls | wc -l`" = 1 || \
- fatal "ERROR: Wrong number of files after expansion of client's tar file"
+ fatal "ERROR: Wrong number of files after expansion of client's zip file"
tmpdir_client=`ls`
tmpdir_client=`expr "$tmpdir_client" : "\\\($tmpdir_prefix_client\\\\.......\\\)"`
test "X$tmpdir_client" != "X" || \
- fatal "ERROR: client tar file did not expand as expected"
+ fatal "ERROR: client zip file did not expand as expected"
# Move the client's temp directory to a local temp location
local local_tmpdir_client=`mktemp -dt $tmpdir_prefix_server.client.XXXXXX` || \
- fatal "ERROR: cannot create temporary tar file " $local_tmpdir_client
+ fatal "ERROR: cannot create temporary zip file " $local_tmpdir_client
mv $tmpdir_client/* $local_tmpdir_client
rm -fr $tmpdir_client
tmpdir_client=$local_tmpdir_client
@@ -329,7 +316,7 @@ function call_stap {
server_p_phase=$p_phase
fi
- eval stap "$cmdline" -k -p $server_p_phase \
+ eval $exec_prefix/stap "$cmdline" -k -p $server_p_phase \
>> $tmpdir_server/stdout \
2>> $tmpdir_server/stderr
@@ -373,36 +360,18 @@ function create_response {
# client.
function package_response {
cd $tmpdir_env
- # Create a place to generate our tar file of our temporary directory
- local tmpdir_server_base=`basename $tmpdir_server`
- tar_server=$tmpdir_env/`mktemp $tmpdir_server_base.tgz.XXXXXX` || \
- fatal "ERROR: cannot create temporary tar file " $tar_server
- chmod +r $tar_server
-
- # Generate the tar file
- tar -czhf $tar_server `basename $tmpdir_server` || \
- fatal "ERROR: tar of $tmpdir_server failed"
-}
-# function: send_response
-#
-# Wait for the client to take the response file.
-function send_response {
- # Now send it.
- $netcat -l $port < $tar_server > /dev/null 2>&1 &
-
- # Wait for 10 seconds before timing out
- for ((t=0; $t < 10; ++t))
- do
- if jobs '%$netcat -l' >/dev/null 2>&1; then
- sleep 1
- else
- return
- fi
- done
-
- # We have timed out. fatal will kill the job.
- fatal "Timed out waiting to send response file"
+ # We will be digitally signing the server's temporary directory. This
+ # will sign the entire directory and compress it into a .jar
+ # archive.
+ #
+ # Make sure the specified .jar file exists.
+ test -f $jar_server || \
+ fatal "ERROR: Could not find .jar archive file $jar_server"
+ #chmod +r $jar_server
+
+ # Generate the jar file
+ signtool -d $ssl_db -k $nss_cert -p `cat $nss_pw` -Z $jar_server $tmpdir_server >/dev/null
}
# function: fatal [ MESSAGE ]
@@ -428,15 +397,10 @@ function cleanup {
# Clean up.
cd $tmpdir_env
if test $keep_temps != 1; then
- rm -fr $tar_client
- rm -fr $tmpdir_client
- rm -fr $tar_server
rm -fr $tmpdir_server
+ rm -fr $tmpdir_client
rm -fr $tmpdir_stap
fi
-
- # Kill any $netcat job that may be running
- kill -s SIGTERM '%$netcat' 2> /dev/null
}
# function: terminate
@@ -451,16 +415,14 @@ function terminate {
#-----------------------------------------------------------------------------
# Beginning of main line execution.
#-----------------------------------------------------------------------------
-configuration "$@"
-initialization
-receive_request
+configuration
+initialization "$@"
unpack_request
check_request
eval parse_options "$cmdline"
call_stap
create_response
package_response
-send_response
cleanup
exit 0
diff --git a/stap-server-connect.c b/stap-server-connect.c
new file mode 100644
index 00000000..37b44a9b
--- /dev/null
+++ b/stap-server-connect.c
@@ -0,0 +1,771 @@
+/*
+ SSL server program listens on a port, accepts client connection, reads
+ the data into a temporary file, calls the systemtap server script and
+ then transmits the resulting fileback to the client.
+
+ Copyright (C) 2008, 2009 Red Hat Inc.
+
+ This file is part of systemtap, and is free software. You can
+ redistribute it and/or modify it under the terms of the GNU General Public
+ License as published by the Free Software Foundation; either version 2 of the
+ License, or (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+*/
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <errno.h>
+
+#include <ssl.h>
+#include <nspr.h>
+#include <plgetopt.h>
+#include <nss.h>
+#include <pk11func.h>
+
+#define READ_BUFFER_SIZE (60 * 1024)
+
+/* Global variables */
+static char *password = NULL;
+static CERTCertificate *cert = NULL;
+static SECKEYPrivateKey *privKey = NULL;
+static char *dbdir = NULL;
+static char requestFileName[] = "/tmp/stap.server.client.zip.XXXXXX";
+static char responseDirName[] = "/tmp/stap.server.XXXXXX";
+static char responseJarName[] = "/tmp/stap.server.XXXXXX.jar.XXXXXX";
+
+static void
+Usage(const char *progName)
+{
+ fprintf(stderr,
+ "Usage: %s -p port -d dbdir -n rsa_nickname -w passwordFile\n",
+ progName);
+ exit(1);
+}
+
+static void
+errWarn(char *function)
+{
+ PRErrorCode errorNumber = PR_GetError();
+
+ printf("Error in function %s: %d\n\n", function, errorNumber);
+}
+
+static void
+exitErr(char *function)
+{
+ errWarn(function);
+ /* Exit gracefully. */
+ /* ignoring return value of NSS_Shutdown as code exits with 1*/
+ (void) NSS_Shutdown();
+ PR_Cleanup();
+ exit(1);
+}
+
+/* Function: readDataFromSocket()
+ *
+ * Purpose: Read data from the socket into a temporary file.
+ *
+ */
+static SECStatus
+readDataFromSocket(PRFileDesc *sslSocket)
+{
+ PRFileDesc *local_file_fd;
+ PRFileInfo info;
+ PRInt32 numBytesRead;
+ PRInt32 numBytesWritten;
+ PRInt32 totalBytes;
+ char buffer[READ_BUFFER_SIZE];
+
+ /* Open the output file. */
+ local_file_fd = PR_Open(requestFileName, PR_WRONLY | PR_CREATE_FILE | PR_TRUNCATE,
+ PR_IRUSR | PR_IWUSR | PR_IRGRP | PR_IWGRP | PR_IROTH);
+ if (local_file_fd == NULL)
+ {
+ fprintf (stderr, "could not open output file %s\n", requestFileName);
+ return SECFailure;
+ }
+
+ /* Read the number fo bytes to be received. */
+ numBytesRead = PR_Read(sslSocket, & info.size, sizeof (info.size));
+ if (numBytesRead == 0) /* EOF */
+ {
+ fprintf (stderr, "Error reading size of request file\n");
+ return SECFailure;
+ }
+ if (numBytesRead < 0)
+ {
+ errWarn("PR_Read");
+ return SECFailure;
+ }
+
+ /* Read until EOF or until the expected number of bytes has been read. */
+ for (totalBytes = 0; totalBytes < info.size; totalBytes += numBytesRead)
+ {
+ numBytesRead = PR_Read(sslSocket, buffer, READ_BUFFER_SIZE);
+ if (numBytesRead == 0)
+ break; /* EOF */
+ if (numBytesRead < 0)
+ {
+ errWarn("PR_Read");
+ break;
+ }
+
+ /* Write to stdout */
+ numBytesWritten = PR_Write(local_file_fd, buffer, numBytesRead);
+ if (numBytesWritten < 0)
+ fprintf (stderr, "could not write to output file %s\n", requestFileName);
+ if (numBytesWritten != numBytesRead)
+ fprintf (stderr, "could not write to output file %s\n", requestFileName);
+#if DEBUG
+ fprintf(stderr, "***** Connection read %d bytes.\n", numBytesRead);
+#if 0
+ buffer[numBytesRead] = '\0';
+ fprintf(stderr, "************\n%s\n************\n", buffer);
+#endif
+#endif
+ }
+
+ if (totalBytes != info.size)
+ {
+ fprintf (stderr, "Expected %d bytes, got %d\n", info.size, totalBytes);
+ return SECFailure;
+ }
+
+ PR_Close(local_file_fd);
+
+ return SECSuccess;
+}
+
+/* Function: setupSSLSocket()
+ *
+ * Purpose: Configure a socket for SSL.
+ *
+ *
+ */
+static PRFileDesc *
+setupSSLSocket(PRFileDesc *tcpSocket)
+{
+ PRFileDesc *sslSocket;
+ SSLKEAType certKEA;
+#if 0
+ int certErr = 0;
+#endif
+ SECStatus secStatus;
+
+ /* Inport the socket into SSL. */
+ sslSocket = SSL_ImportFD(NULL, tcpSocket);
+ if (sslSocket == NULL)
+ {
+ errWarn("SSL_ImportFD");
+ goto loser;
+ }
+
+ /* Set the appropriate flags. */
+ secStatus = SSL_OptionSet(sslSocket, SSL_SECURITY, PR_TRUE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet SSL_SECURITY");
+ goto loser;
+ }
+
+ secStatus = SSL_OptionSet(sslSocket, SSL_HANDSHAKE_AS_SERVER, PR_TRUE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet:SSL_HANDSHAKE_AS_SERVER");
+ goto loser;
+ }
+
+ secStatus = SSL_OptionSet(sslSocket, SSL_REQUEST_CERTIFICATE, PR_FALSE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet:SSL_REQUEST_CERTIFICATE");
+ goto loser;
+ }
+
+ secStatus = SSL_OptionSet(sslSocket, SSL_REQUIRE_CERTIFICATE, PR_FALSE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet:SSL_REQUIRE_CERTIFICATE");
+ goto loser;
+ }
+
+ /* Set the appropriate callback routines. */
+#if 0 /* use the default */
+ secStatus = SSL_AuthCertificateHook(sslSocket, myAuthCertificate,
+ CERT_GetDefaultCertDB());
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_AuthCertificateHook");
+ goto loser;
+ }
+#endif
+#if 0 /* Use the default */
+ secStatus = SSL_BadCertHook(sslSocket,
+ (SSLBadCertHandler)myBadCertHandler, &certErr);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_BadCertHook");
+ goto loser;
+ }
+#endif
+#if 0 /* no handshake callback */
+ secStatus = SSL_HandshakeCallback(sslSocket,
+ myHandshakeCallback,
+ NULL);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_HandshakeCallback");
+ goto loser;
+ }
+#endif
+ secStatus = SSL_SetPKCS11PinArg(sslSocket, password);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_HandshakeCallback");
+ goto loser;
+ }
+
+ certKEA = NSS_FindCertKEAType(cert);
+
+ secStatus = SSL_ConfigSecureServer(sslSocket, cert, privKey, certKEA);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_ConfigSecureServer");
+ goto loser;
+ }
+
+ return sslSocket;
+
+loser:
+ PR_Close(tcpSocket);
+ return NULL;
+}
+
+#if 0 /* No client authentication and not authenticating after each transaction. */
+/* Function: authenticateSocket()
+ *
+ * Purpose: Perform client authentication on the socket.
+ *
+ */
+static SECStatus
+authenticateSocket(PRFileDesc *sslSocket, PRBool requireCert)
+{
+ CERTCertificate *cert;
+ SECStatus secStatus;
+
+ /* Returns NULL if client authentication is not enabled or if the
+ * client had no certificate. */
+ cert = SSL_PeerCertificate(sslSocket);
+ if (cert)
+ {
+ /* Client had a certificate, so authentication is through. */
+ CERT_DestroyCertificate(cert);
+ return SECSuccess;
+ }
+
+ /* Request client to authenticate itself. */
+ secStatus = SSL_OptionSet(sslSocket, SSL_REQUEST_CERTIFICATE, PR_TRUE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet:SSL_REQUEST_CERTIFICATE");
+ return SECFailure;
+ }
+
+ /* If desired, require client to authenticate itself. Note
+ * SSL_REQUEST_CERTIFICATE must also be on, as above. */
+ secStatus = SSL_OptionSet(sslSocket, SSL_REQUIRE_CERTIFICATE, requireCert);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_OptionSet:SSL_REQUIRE_CERTIFICATE");
+ return SECFailure;
+ }
+
+ /* Having changed socket configuration parameters, redo handshake. */
+ secStatus = SSL_ReHandshake(sslSocket, PR_TRUE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_ReHandshake");
+ return SECFailure;
+ }
+
+ /* Force the handshake to complete before moving on. */
+ secStatus = SSL_ForceHandshake(sslSocket);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_ForceHandshake");
+ return SECFailure;
+ }
+
+ return SECSuccess;
+}
+#endif /* No client authentication and not authenticating after each transaction. */
+
+/* Function: writeDataToSocket
+ *
+ * Purpose: Write the server's response back to the socket.
+ *
+ */
+static SECStatus
+writeDataToSocket(PRFileDesc *sslSocket)
+{
+ int numBytes;
+ PRFileDesc *local_file_fd;
+ PRFileInfo info;
+ PRStatus prStatus;
+
+ /* Try to open the local file named.
+ * If successful, then write it to the client.
+ */
+ prStatus = PR_GetFileInfo(responseJarName, &info);
+ if (prStatus != PR_SUCCESS || info.type != PR_FILE_FILE || info.size < 0)
+ {
+ fprintf (stderr, "Input file %s not found\n", responseJarName);
+ return SECFailure;
+ }
+
+ local_file_fd = PR_Open(responseJarName, PR_RDONLY, 0);
+ if (local_file_fd == NULL)
+ {
+ fprintf (stderr, "Could not open input file %s\n", responseJarName);
+ return SECFailure;
+ }
+
+ /* Transmit the local file across the socket.
+ */
+ numBytes = PR_TransmitFile(sslSocket, local_file_fd,
+ NULL, 0,
+ PR_TRANSMITFILE_KEEP_OPEN,
+ PR_INTERVAL_NO_TIMEOUT);
+
+ /* Error in transmission. */
+ if (numBytes < 0)
+ {
+ errWarn("PR_TransmitFile");
+ return SECFailure;
+ }
+#if DEBUG
+ /* Transmitted bytes successfully. */
+ fprintf(stderr, "PR_TransmitFile wrote %d bytes from %s\n",
+ numBytes, responseJarName);
+#endif
+
+ PR_Close(local_file_fd);
+
+ return SECSuccess;
+}
+
+/* Function: int handle_connection()
+ *
+ * Purpose: Handle a connection to a socket.
+ *
+ */
+static SECStatus
+handle_connection(PRFileDesc *tcpSocket)
+{
+ PRFileDesc * sslSocket = NULL;
+ SECStatus secStatus = SECFailure;
+ PRStatus prStatus;
+ PRSocketOptionData socketOption;
+ PRFileInfo info;
+ char *cmdline;
+ int rc;
+ char *rc1;
+
+ /* Make sure the socket is blocking. */
+ socketOption.option = PR_SockOpt_Nonblocking;
+ socketOption.value.non_blocking = PR_FALSE;
+ PR_SetSocketOption(tcpSocket, &socketOption);
+
+ sslSocket = setupSSLSocket(tcpSocket);
+ if (sslSocket == NULL)
+ {
+ errWarn("setupSSLSocket");
+ goto cleanup;
+ }
+
+ secStatus = SSL_ResetHandshake(sslSocket, /* asServer */ PR_TRUE);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_ResetHandshake");
+ goto cleanup;
+ }
+
+ /* Force the handshake to complete before moving on. */
+ secStatus = SSL_ForceHandshake(sslSocket);
+ if (secStatus != SECSuccess)
+ {
+ errWarn("SSL_ForceHandshake");
+ goto cleanup;
+ }
+
+ /* Create a temporary files and directories. */
+ memcpy (requestFileName + sizeof (requestFileName) - 1 - 6, "XXXXXX", 6);
+ rc = mkstemp(requestFileName);
+ if (rc == -1)
+ {
+ fprintf (stderr, "Could not create temporary file %s\n", requestFileName);
+ perror ("");
+ secStatus = SECFailure;
+ goto cleanup;
+ }
+
+ memcpy (responseDirName + sizeof (responseDirName) - 1 - 6, "XXXXXX", 6);
+ rc1 = mkdtemp(responseDirName);
+ if (! rc1)
+ {
+ fprintf (stderr, "Could not create temporary directory %s\n", responseDirName);
+ perror ("");
+ secStatus = SECFailure;
+ goto cleanup;
+ }
+
+ memcpy (responseJarName, responseDirName, sizeof (responseDirName) - 1);
+ memcpy (responseJarName + sizeof (responseJarName) - 1 - 6, "XXXXXX", 6);
+ rc = mkstemp(responseJarName);
+ if (rc == -1)
+ {
+ fprintf (stderr, "Could not create temporary file %s\n", responseJarName);
+ perror ("");
+ secStatus = SECFailure;
+
+ /* Remove this so that the other temp files will get removed in cleanup. */
+ prStatus = PR_RmDir (responseDirName);
+ if (prStatus != PR_SUCCESS)
+ errWarn ("PR_RmDir");
+ goto cleanup;
+ }
+
+ /* Read data from the socket.
+ * If the user is requesting/requiring authentication, authenticate
+ * the socket. */
+#if DEBUG
+ fprintf(stdout, "\nReading data from socket...\n\n");
+#endif
+ secStatus = readDataFromSocket(sslSocket);
+ if (secStatus != SECSuccess)
+ goto cleanup;
+
+#if 0 /* Don't authenticate after each transaction */
+ if (REQUEST_CERT_ALL)
+ {
+ fprintf(stdout, "\nAuthentication requested.\n\n");
+ secStatus = authenticateSocket(sslSocket);
+ if (secStatus != SECSuccess)
+ goto cleanup;
+ }
+#endif
+
+ /* Call the stap-server script. */
+ cmdline = PORT_Alloc(sizeof ("stap-server") +
+ sizeof (requestFileName) +
+ sizeof (responseDirName) +
+ sizeof (responseJarName) +
+ strlen (dbdir) + 1);
+ if (! cmdline) {
+ errWarn ("PORT_Alloc");
+ secStatus = SECFailure;
+ goto cleanup;
+ }
+
+ sprintf (cmdline, "stap-server %s %s %s %s",
+ requestFileName, responseDirName, responseJarName, dbdir);
+ rc = system (cmdline);
+
+ PR_Free (cmdline);
+
+#if DEBUG
+ fprintf(stdout, "\nWriting data to socket...\n\n");
+#endif
+ secStatus = writeDataToSocket(sslSocket);
+
+cleanup:
+ /* Close down the socket. */
+ prStatus = PR_Close(tcpSocket);
+ if (prStatus != PR_SUCCESS)
+ errWarn("PR_Close");
+
+ /* Attempt to remove temporary files, unless the temporary directory was
+ not deleted by the server script. */
+ prStatus = PR_GetFileInfo(responseDirName, &info);
+ if (prStatus != PR_SUCCESS)
+ {
+ prStatus = PR_Delete (requestFileName);
+ if (prStatus != PR_SUCCESS)
+ errWarn ("PR_Delete");
+ prStatus = PR_Delete (responseJarName);
+ if (prStatus != PR_SUCCESS)
+ errWarn ("PR_Delete");
+ }
+
+ return secStatus;
+}
+
+/* Function: int accept_connection()
+ *
+ * Purpose: Accept a connection to the socket.
+ *
+ */
+static SECStatus
+accept_connection(PRFileDesc *listenSocket)
+{
+ PRNetAddr addr;
+ PRStatus prStatus;
+ PRFileDesc *tcpSocket;
+#if 0
+ SECStatus result;
+#endif
+
+ while (PR_TRUE)
+ {
+#if DEBUG
+ fprintf(stderr, "\n\n\nAbout to call accept.\n");
+#endif
+
+ /* Accept a connection to the socket. */
+ tcpSocket = PR_Accept(listenSocket, &addr, PR_INTERVAL_NO_TIMEOUT);
+ if (tcpSocket == NULL)
+ {
+ errWarn("PR_Accept");
+ break;
+ }
+
+ /* Accepted the connection, now handle it. */
+ /*result =*/ handle_connection (tcpSocket);
+#if 0 /* Not necessary */
+ if (result != SECSuccess)
+ {
+ prStatus = PR_Close(tcpSocket);
+ if (prStatus != PR_SUCCESS)
+ exitErr("PR_Close");
+ break;
+ }
+#endif
+ }
+
+#if DEBUG
+ fprintf(stderr, "Closing listen socket.\n");
+#endif
+ prStatus = PR_Close(listenSocket);
+ if (prStatus != PR_SUCCESS)
+ exitErr("PR_Close");
+
+ return SECSuccess;
+}
+
+/* Function: void server_main()
+ *
+ * Purpose: This is the server's main function. It configures a socket
+ * and listens to it.
+ *
+ */
+static void
+server_main(unsigned short port, SECKEYPrivateKey *privKey, CERTCertificate *cert)
+{
+ SECStatus secStatus;
+ PRStatus prStatus;
+ PRFileDesc * listenSocket;
+ PRNetAddr addr;
+ PRSocketOptionData socketOption;
+
+ /* Create a new socket. */
+ listenSocket = PR_NewTCPSocket();
+ if (listenSocket == NULL)
+ exitErr("PR_NewTCPSocket");
+
+ /* Set socket to be blocking -
+ * on some platforms the default is nonblocking.
+ */
+ socketOption.option = PR_SockOpt_Nonblocking;
+ socketOption.value.non_blocking = PR_FALSE;
+
+ prStatus = PR_SetSocketOption(listenSocket, &socketOption);
+ if (prStatus != PR_SUCCESS)
+ exitErr("PR_SetSocketOption");
+
+#if 0
+ /* This cipher is not on by default. The Acceptance test
+ * would like it to be. Turn this cipher on.
+ */
+ secStatus = SSL_CipherPrefSetDefault(SSL_RSA_WITH_NULL_MD5, PR_TRUE);
+ if (secStatus != SECSuccess)
+ exitErr("SSL_CipherPrefSetDefault:SSL_RSA_WITH_NULL_MD5");
+#endif
+
+ /* Configure the network connection. */
+ addr.inet.family = PR_AF_INET;
+ addr.inet.ip = PR_INADDR_ANY;
+ addr.inet.port = PR_htons(port);
+
+ /* Bind the address to the listener socket. */
+ prStatus = PR_Bind(listenSocket, &addr);
+ if (prStatus != PR_SUCCESS)
+ exitErr("PR_Bind");
+
+ /* Listen for connection on the socket. The second argument is
+ * the maximum size of the queue for pending connections.
+ */
+ prStatus = PR_Listen(listenSocket, 5);
+ if (prStatus != PR_SUCCESS)
+ exitErr("PR_Listen");
+
+ /* Handle connections to the socket. */
+ secStatus = accept_connection (listenSocket);
+ if (secStatus != SECSuccess)
+ PR_Close(listenSocket);
+}
+
+/* Function: char * myPasswd()
+ *
+ * Purpose: This function is our custom password handler that is called by
+ * SSL when retreiving private certs and keys from the database. Returns a
+ * pointer to a string that with a password for the database. Password pointer
+ * should point to dynamically allocated memory that will be freed later.
+ */
+static char *
+myPasswd(PK11SlotInfo *info, PRBool retry, void *arg)
+{
+ char * passwd = NULL;
+
+ if (! retry && arg)
+ passwd = PORT_Strdup((char *)arg);
+
+ return passwd;
+}
+
+/* Obtain the certificate and key database password from the given file. */
+static char *
+getPassword(char *fileName)
+{
+ PRFileDesc *local_file_fd;
+ PRFileInfo fileInfo;
+ PRInt32 numBytesRead;
+ PRStatus prStatus;
+ char *password;
+ PRInt32 i;
+
+ prStatus = PR_GetFileInfo(fileName, &fileInfo);
+ if (prStatus != PR_SUCCESS || fileInfo.type != PR_FILE_FILE || fileInfo.size < 0)
+ {
+ fprintf (stderr, "Password file %s not found\n", fileName);
+ return NULL;
+ }
+
+ local_file_fd = PR_Open(fileName, PR_RDONLY, 0);
+ if (local_file_fd == NULL)
+ {
+ fprintf (stderr, "Could not open password file %s\n", fileName);
+ return NULL;
+ }
+
+ password = PORT_Alloc(fileInfo.size + 1);
+ if (! password) {
+ errWarn ("PORT_Alloc");
+ return NULL;
+ }
+
+ numBytesRead = PR_Read(local_file_fd, password, fileInfo.size);
+ if (numBytesRead <= 0)
+ {
+ fprintf (stderr, "Error reading password file\n");
+ exitErr ("PR_Read");
+ }
+
+ PR_Close(local_file_fd);
+
+ /* Keep only the first line of data. */
+ for (i = 0; i < numBytesRead; ++i)
+ {
+ if (password[i] == '\n' || password[i] == '\r' ||
+ password[i] == '\0')
+ break;
+ }
+ password[i] = '\0';
+
+ return password;
+}
+
+/* Function: int main()
+ *
+ * Purpose: Parses command arguments and configures SSL server.
+ *
+ */
+int
+main(int argc, char **argv)
+{
+ char * progName = NULL;
+ char * nickName = NULL;
+ char * passwordFile = NULL;
+ unsigned short port = 0;
+ SECStatus secStatus;
+ PLOptState * optstate;
+ PLOptStatus status;
+
+ progName = PL_strdup(argv[0]);
+
+ optstate = PL_CreateOptState(argc, argv, "d:p:n:w:");
+ while ((status = PL_GetNextOpt(optstate)) == PL_OPT_OK)
+ {
+ switch(optstate->option)
+ {
+ case 'd': dbdir = PL_strdup(optstate->value); break;
+ case 'n': nickName = PL_strdup(optstate->value); break;
+ case 'p': port = PORT_Atoi(optstate->value); break;
+ case 'w': passwordFile = PL_strdup(optstate->value); break;
+ default:
+ case '?': Usage(progName);
+ }
+ }
+
+ if (nickName == NULL || port == 0 || dbdir == NULL || passwordFile == NULL)
+ Usage(progName);
+
+ password = getPassword (passwordFile);
+
+ /* Call the NSPR initialization routines. */
+ PR_Init( PR_SYSTEM_THREAD, PR_PRIORITY_NORMAL, 1);
+
+ /* Set the cert database password callback. */
+ PK11_SetPasswordFunc(myPasswd);
+
+ /* Initialize NSS. */
+ secStatus = NSS_Init(dbdir);
+ if (secStatus != SECSuccess)
+ exitErr("NSS_Init");
+
+ /* Set the policy for this server (REQUIRED - no default). */
+ secStatus = NSS_SetDomesticPolicy();
+ if (secStatus != SECSuccess)
+ exitErr("NSS_SetDomesticPolicy");
+
+ /* Get own certificate and private key. */
+ cert = PK11_FindCertFromNickname(nickName, password);
+ if (cert == NULL)
+ exitErr("PK11_FindCertFromNickname");
+
+ privKey = PK11_FindKeyByAnyCert(cert, password);
+ if (privKey == NULL)
+ exitErr("PK11_FindKeyByAnyCert");
+
+ /* Configure the server's cache for a multi-process application
+ * using default timeout values (24 hrs) and directory location (/tmp).
+ */
+ SSL_ConfigMPServerSIDCache(256, 0, 0, NULL);
+
+ /* Launch server. */
+ server_main(port, privKey, cert);
+
+ /* Shutdown NSS and exit NSPR gracefully. */
+ NSS_Shutdown();
+ PR_Cleanup();
+
+ return 0;
+}
diff --git a/stap-serverd b/stap-serverd
index b46a4254..1c227e6c 100755
--- a/stap-serverd
+++ b/stap-serverd
@@ -2,7 +2,7 @@
# Compile server manager for systemtap
#
-# Copyright (C) 2008 Red Hat Inc.
+# Copyright (C) 2008, 2009 Red Hat Inc.
#
# This file is part of systemtap, and is free software. You can
# redistribute it and/or modify it under the terms of the GNU General
@@ -24,20 +24,42 @@ function initialization {
# Default settings.
avahi_type=_stap._tcp
- # We need either netcat or nc.
- netcat=`which netcat 2>/dev/null`
- test "X$netcat" = "X" && netcat=`which nc 2>/dev/null`
- test "X$netcat" = "X" && fatal "ERROR: cannot find required program 'netcat' or 'nc' on PATH"
+ # Where are we installed?
+ exec_prefix=`dirname $0`
+ exec_prefix=`cd $exec_prefix && pwd`
+ prefix=`dirname $exec_prefix`
- # See if the given port, or the default port is busy. If so, select another.
+ # What port will we listen on?
port=$1
test "X$port" = "X" && port=65000
- port2=$(($port + 1))
- while netstat -atn | awk '{print $4}' | cut -f2 -d: | egrep -q "^($port|$port2)\$"; do
+ while netstat -atn | awk '{print $4}' | cut -f2 -d: | egrep -q "^$port\$";
+ do
# Whoops, the port is busy; try another one.
+ echo "$0: Port $port is busy"
port=$((1024+($port + $RANDOM)%64000))
- port2=$(($port + 1))
done
+
+ # Where is the ssl certificate/key database?
+ ssl_db=$2
+ if test "X$ssl_db" = "X"; then
+ # If no certificate/key database has been specified, then find/create
+ # a local one.
+ if test $EUID = 0; then
+ ssl_db=$prefix/etc/systemtap/ssl/server
+ else
+ ssl_db=$HOME/.systemtap/ssl/server
+ fi
+ if ! test -f $ssl_db/stap-server.cert; then
+ $exec_prefix/stap-gen-server-cert `dirname $ssl_db` || exit 1
+ # Now add the server's certificate to the client's database,
+ # making it a trusted peer. Do this only if the client has been installed.
+ if test -f $exec_prefix/stap-add-server-cert -a -f $exec_prefix/stap-add-server-cert; then
+ $exec_prefix/stap-add-server-cert $ssl_db/stap-server.cert `dirname $ssl_db`
+ fi
+ fi
+ fi
+ nss_pw=$ssl_db/pw
+ nss_cert=stap-server
}
# function: advertise_presence
@@ -60,41 +82,10 @@ function advertise_presence {
#
# Listen for and handle requests to the server.
function listen {
- # Loop forever accepting requests
- while true
- do
- for ((attempt=0; $attempt < 5; ++attempt))
- do
- $netcat -ld $port 2>/dev/null | process_request &
- wait '%$netcat -l'
- rc=$?
- if test $rc = 0 -o $rc = 127; then
- break; # port was read ok
- fi
- done
- if test $attempt = 5; then
- fatal "ERROR: cannot listen on port $port. rc==$rc"
- fi
- done
-}
-
-# function: process_request
-#
-# Process an incoming request on stdin
-function process_request {
- read
- case $REPLY in
- request:)
- stap-server $port2 >/dev/null 2>&1 &
- wait '%stap-server'
- rc=$?
- test $rc = 127 && rc=0
- ;;
- *)
- rc=1
- esac
-
- exit $rc
+ # The stap-server-connect program will listen forever
+ # accepting requests.
+ $exec_prefix/stap-server-connect -p $port -n $nss_cert -d $ssl_db -w $nss_pw 2>&1 &
+ wait '%$exec_prefix/stap-server-connect' >/dev/null 2>&1
}
# function: fatal [ MESSAGE ]
@@ -114,16 +105,12 @@ function terminate {
echo "$0: Exiting"
# Kill the running 'avahi-publish-service' job
- kill -s SIGTERM %avahi-publish-service 2> /dev/null
+ kill -s SIGTERM '%avahi-publish-service' 2> /dev/null
wait '%avahi-publish-service' >/dev/null 2>&1
- # Kill any running 'stap-server' job.
- kill -s SIGTERM "%stap-server" 2> /dev/null
- wait '%stap-server' >/dev/null 2>&1
-
- # Kill any running '$netcat -l' job.
- kill -s SIGTERM '%$netcat -l' 2>/dev/null
- wait '%$netcat -l' >/dev/null 2>&1
+ # Kill any running 'stap-server-connect' job.
+ kill -s SIGTERM '%$exec_prefix/stap-server-connect' 2> /dev/null
+ wait '%$exec_prefix/stap-server-connect' >/dev/null 2>&1
exit
}
diff --git a/stap-start-server b/stap-start-server
index aa2850b5..c8ea8178 100755
--- a/stap-start-server
+++ b/stap-start-server
@@ -2,7 +2,7 @@
# Start a systemtap server
#
-# Copyright (C) 2008 Red Hat Inc.
+# Copyright (C) 2008, 2009 Red Hat Inc.
#
# This file is part of systemtap, and is free software. You can
# redistribute it and/or modify it under the terms of the GNU General
@@ -12,15 +12,29 @@
# This script attempts to start a systemtap server and echoes the
# process id, if successful.
+# Where are we installed?
+exec_prefix=`dirname $0`
+exec_prefix=`cd $exec_prefix && pwd`
+prefix=`dirname $exec_prefix`
+
# start the server
-stap-serverd </dev/null >/dev/null 2>&1 &
+$exec_prefix/stap-serverd "$@" </dev/null >/dev/null 2>&1 &
server_pid=$!
# Make sure the server is started
for ((attempt=0; $attempt < 5; ++attempt))
do
- (ps -a | grep $server_pid) >/dev/null 2>&1 && echo $server_pid && exit 0
- sleep 1
+ if test $EUID = 0; then
+ if ! test -f $prefix/etc/systemtap/ssl/server/stap-server.cert; then
+ sleep 1
+ continue;
+ fi
+ elif ! test -f $HOME/.systemtap/ssl/server/stap-server.cert; then
+ sleep 1
+ continue
+ fi
+ (ps -a | grep $server_pid) >/dev/null 2>&1 && echo $server_pid && exit 0
+ sleep 1
done
exit 1 # server did not start
diff --git a/stap.1.in b/stap.1.in
index 16e09523..cde049a3 100644
--- a/stap.1.in
+++ b/stap.1.in
@@ -126,7 +126,7 @@ embedded C.
.TP
.B \-P
Prologue-searching mode. Activate heuristics to work around incorrect
-debbugging information for $target variables.
+debugging information for $target variables.
.TP
.B \-u
Unoptimized mode. Disable unused code elision during elaboration.
@@ -190,7 +190,7 @@ points matching the given pattern. The pattern may include wildcards
and aliases.
.TP
.BI \-L " PROBE"
-Similar to "-l", but list probe points and local variables.
+Similar to "-l", but list probe points and script-level local variables.
.TP
.BI \-F
Load module and start probes, then detach from the module leaving the
@@ -652,7 +652,10 @@ Character.
Signed decimal.
.TP
%m
-Safely reads kernel memory at the given address, outputs its content. The width specifier determines the number of bytes to read. Default is 1 byte.
+Safely reads kernel memory at the given address, outputs its content. The precision specifier determines the number of bytes to read. Default is 1 byte.
+.TP
+%M
+Same as %m, but outputs in hexadecimal. The precision specifier determines the number of hexadecimal digits to output. Default is 1 digit.
.TP
%o
Unsigned octal.
diff --git a/staptree.cxx b/staptree.cxx
index 51992d7a..fafefc4e 100644
--- a/staptree.cxx
+++ b/staptree.cxx
@@ -494,6 +494,10 @@ print_format::components_to_string(vector<format_component> const & components)
oss << 'm';
break;
+ case conv_memory_hex:
+ oss << 'M';
+ break;
+
default:
break;
}
@@ -655,6 +659,10 @@ print_format::string_to_components(string const & str)
curr.type = conv_memory;
break;
+ case 'M':
+ curr.type = conv_memory_hex;
+ break;
+
case 'd':
case 'i':
curr.type = conv_signed_decimal;
diff --git a/staptree.h b/staptree.h
index 069c9bcc..12d84698 100644
--- a/staptree.h
+++ b/staptree.h
@@ -289,6 +289,7 @@ struct print_format: public expression
conv_string,
conv_char,
conv_memory,
+ conv_memory_hex,
conv_literal,
conv_binary
};
diff --git a/systemtap.spec b/systemtap.spec
index c8c6b030..2586b85a 100644
--- a/systemtap.spec
+++ b/systemtap.spec
@@ -1,5 +1,5 @@
%{!?release: %define release 1}
-%{!?with_sqllite: %define with_sqlite 1}
+%{!?with_sqlite: %define with_sqlite 1}
%{!?with_docs: %define with_docs 1}
%{!?with_crash: %define with_crash 0}
%{!?with_bundled_elfutils: %define with_bundled_elfutils 0}
@@ -20,16 +20,17 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires: kernel >= 2.6.9-11
%if %{with_sqlite}
BuildRequires: sqlite-devel
-Requires: sqlite
%endif
%if %{with_crash}
BuildRequires: crash-devel zlib-devel
%endif
-# Requires: kernel-devel
-# or is that kernel-smp-devel? kernel-hugemem-devel?
+# Alternate kernel packages kernel-PAE-devel et al have a virtual
+# provide for kernel-devel, so this requirement does the right thing.
+Requires: kernel-devel
Requires: gcc make
# Suggest: kernel-debuginfo
Requires: systemtap-runtime = %{version}-%{release}
+BuildRequires: nss-devel
%if %{with_bundled_elfutils}
Source1: elfutils-%{elfutils_version}.tar.gz
@@ -44,6 +45,10 @@ Requires: crash
%if %{with_docs}
BuildRequires: /usr/bin/latex /usr/bin/dvips /usr/bin/ps2pdf latex2html
+# On F10, xmlto's pdf support was broken off into a sub-package,
+# called 'xmlto-tex'. To avoid a specific F10 BuildReq, we'll do a
+# file-based buildreq on '/usr/share/xmlto/format/fo/pdf'.
+BuildRequires: xmlto /usr/share/xmlto/format/fo/pdf
%endif
%description
@@ -81,7 +86,7 @@ Group: Development/System
License: GPLv2+
URL: http://sourceware.org/systemtap/
Requires: systemtap-runtime = %{version}-%{release}
-Requires: avahi avahi-tools nc mktemp
+Requires: avahi avahi-tools nss nss-tools mktemp
%description client
SystemTap client is the client component of an instrumentation
@@ -94,13 +99,23 @@ Group: Development/System
License: GPLv2+
URL: http://sourceware.org/systemtap/
Requires: systemtap
-Requires: avahi avahi-tools nc net-tools mktemp
+Requires: avahi avahi-tools nss nss-tools mktemp
%description server
SystemTap server is the server component of an instrumentation
system for systems running Linux 2.6. Developers can write
instrumentation to collect data on the operation of the system.
+%package sdt-devel
+Summary: Static probe support tools
+Group: Development/System
+License: GPLv2+
+URL: http://sourceware.org/systemtap/
+Requires: systemtap
+
+%description sdt-devel
+Support tools to allow applications to use static probes.
+
%prep
%setup -q %{?setup_elfutils}
@@ -185,6 +200,7 @@ cp -rp testsuite $RPM_BUILD_ROOT%{_datadir}/systemtap
# %doc directive.
mkdir docs.installed
mv $RPM_BUILD_ROOT%{_datadir}/doc/systemtap/*.pdf docs.installed/
+mv $RPM_BUILD_ROOT%{_datadir}/doc/systemtap/tapsets docs.installed/
%endif
%clean
@@ -201,6 +217,7 @@ exit 0
%doc README AUTHORS NEWS COPYING examples
%if %{with_docs}
%doc docs.installed/*.pdf
+%doc docs.installed/tapsets
%endif
%{_bindir}/stap
@@ -240,6 +257,8 @@ exit 0
%{_bindir}/stap-client
%{_bindir}/stap-find-servers
%{_bindir}/stap-find-or-start-server
+%{_bindir}/stap-add-server-cert
+%{_bindir}/stap-client-connect
%{_mandir}/man8/stap-server.8*
%files server
@@ -248,8 +267,15 @@ exit 0
%{_bindir}/stap-serverd
%{_bindir}/stap-start-server
%{_bindir}/stap-stop-server
+%{_bindir}/stap-gen-server-cert
+%{_bindir}/stap-server-connect
%{_mandir}/man8/stap-server.8*
+%files sdt-devel
+%defattr(-,root,root)
+%{_bindir}/dtrace
+%{_includedir}/sys/sdt.h
+
%changelog
* Thu Nov 13 2008 Frank Ch. Eigler <fche@redhat.com> - 0.8-1
- Upstream release.
diff --git a/tapset/ChangeLog b/tapset/ChangeLog
index d1d2064c..d473a797 100644
--- a/tapset/ChangeLog
+++ b/tapset/ChangeLog
@@ -10,6 +10,11 @@
* context-unwind.stp (caller): Pass current task to
_stp_symbol_snprint.
+2009-01-06 Frank Ch. Eigler <fche@elastic.org>
+
+ PR 9699.
+ * context.stp, task.stp: Adapt to STAPCONF_TASK_UID.
+
2008-12-09 Frank Ch. Eigler <fche@elastic.org>
PR 6961.
diff --git a/tapset/context.stp b/tapset/context.stp
index c737edd0..7fd961c8 100644
--- a/tapset/context.stp
+++ b/tapset/context.stp
@@ -1,5 +1,5 @@
// context tapset
-// Copyright (C) 2005, 2006, 2007 Red Hat Inc.
+// Copyright (C) 2005-2009 Red Hat Inc.
// Copyright (C) 2006 Intel Corporation.
//
// This file is part of systemtap, and is free software. You can
@@ -76,7 +76,11 @@ function pexecname:string () %{ /* pure */
* Return the gid of the current process.
*/
function gid:long () %{ /* pure */
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = current->gid;
+#else
+ THIS->__retvalue = current_gid();
+#endif
%}
/**
@@ -85,7 +89,11 @@ function gid:long () %{ /* pure */
* Return the effective gid of the current process.
*/
function egid:long () %{ /* pure */
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = current->egid;
+#else
+ THIS->__retvalue = current_egid();
+#endif
%}
/**
@@ -94,7 +102,11 @@ function egid:long () %{ /* pure */
* Return the uid of the current process.
*/
function uid:long () %{ /* pure */
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = current->uid;
+#else
+ THIS->__retvalue = current_uid();
+#endif
%}
/**
@@ -103,7 +115,11 @@ function uid:long () %{ /* pure */
* Return the effective uid of the current process.
*/
function euid:long () %{ /* pure */
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = current->euid;
+#else
+ THIS->__retvalue = current_euid();
+#endif
%}
// cpuid() is not documented
diff --git a/tapset/task.stp b/tapset/task.stp
index 9215e83f..684cef93 100644
--- a/tapset/task.stp
+++ b/tapset/task.stp
@@ -12,6 +12,9 @@
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,25)
#include <linux/fdtable.h>
#endif
+#ifndef STAPCONF_TASK_UID
+#include <linux/cred.h>
+#endif
%}
// Return the task_struct representing the current process
@@ -74,7 +77,18 @@ function task_tid:long (task:long) %{ /* pure */
// Return the group id of the given task
function task_gid:long (task:long) %{ /* pure */
struct task_struct *t = (struct task_struct *)(long)THIS->task;
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = kread(&(t->gid));
+#else
+ /* XXX: We can't easily kread this rcu-protected field. */
+ /* XXX: no task_gid() in 2.6.28 */
+ struct cred *cred;
+ rcu_read_lock();
+ cred = get_task_cred (t);
+ rcu_read_unlock();
+ THIS->__retvalue = cred->gid;
+#endif
+
CATCH_DEREF_FAULT();
%}
@@ -82,7 +96,17 @@ function task_gid:long (task:long) %{ /* pure */
// Return the effective group id of the given task
function task_egid:long (task:long) %{ /* pure */
struct task_struct *t = (struct task_struct *)(long)THIS->task;
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = kread(&(t->egid));
+#else
+ /* XXX: We can't easily kread this rcu-protected field. */
+ /* XXX: no task_egid() in 2.6.28 */
+ struct cred *cred;
+ rcu_read_lock();
+ cred = get_task_cred (t);
+ rcu_read_unlock();
+ THIS->__retvalue = cred->egid;
+#endif
CATCH_DEREF_FAULT();
%}
@@ -90,7 +114,13 @@ function task_egid:long (task:long) %{ /* pure */
// Return the user id of the given task
function task_uid:long (task:long) %{ /* pure */
struct task_struct *t = (struct task_struct *)(long)THIS->task;
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = kread(&(t->uid));
+#else
+ /* XXX: We can't easily kread this rcu-protected field. */
+ THIS->__retvalue = task_uid (t);
+#endif
+
CATCH_DEREF_FAULT();
%}
@@ -98,7 +128,12 @@ function task_uid:long (task:long) %{ /* pure */
// Return the effective user id of the given task
function task_euid:long (task:long) %{ /* pure */
struct task_struct *t = (struct task_struct *)(long)THIS->task;
+#ifdef STAPCONF_TASK_UID
THIS->__retvalue = kread(&(t->euid));
+#else
+ /* XXX: We can't easily kread this rcu-protected field. */
+ THIS->__retvalue = task_euid (t);
+#endif
CATCH_DEREF_FAULT();
%}
diff --git a/tapsets.cxx b/tapsets.cxx
index fe4dad55..6e393b63 100644
--- a/tapsets.cxx
+++ b/tapsets.cxx
@@ -1,5 +1,5 @@
// tapset resolution
-// Copyright (C) 2005-2008 Red Hat Inc.
+// Copyright (C) 2005-2009 Red Hat Inc.
// Copyright (C) 2005-2007 Intel Corporation.
// Copyright (C) 2008 James.Bottomley@HansenPartnership.com
//
@@ -1578,8 +1578,9 @@ struct dwflpp
bool die_has_pc (Dwarf_Die & die, Dwarf_Addr pc)
{
int res = dwarf_haspc (&die, pc);
- if (res == -1)
- dwarf_assert ("dwarf_haspc", res);
+ // dwarf_ranges will return -1 if a function die has no DW_AT_ranges
+ // if (res == -1)
+ // dwarf_assert ("dwarf_haspc", res);
return res == 1;
}
@@ -1708,7 +1709,7 @@ struct dwflpp
assert (cu);
- if (scope_die)
+ if (scope_die && pc == 0)
nscopes = dwarf_getscopes_die (scope_die, &scopes);
else
nscopes = dwarf_getscopes (cu, pc, &scopes);
@@ -2258,8 +2259,8 @@ struct dwflpp
if (sess.verbose>2)
clog << "finding location for local '" << local
- << "' near address " << hex << pc
- << ", module bias " << module_bias << dec
+ << "' near address 0x" << hex << pc
+ << ", module bias 0x" << module_bias << dec
<< "\n";
Dwarf_Attribute attr_mem;
@@ -3856,7 +3857,8 @@ query_cu (Dwarf_Die * cudie, void * arg)
// Verify that a raw address matches the beginning of a
// statement. This is a somewhat lame check that the address
// is at the start of an assembly instruction.
- if (q->has_statement_num)
+ // Avoid for now since this thwarts a probe on a statement in a macro
+ if (0 && q->has_statement_num)
{
Dwarf_Addr queryaddr = q->statement_num_val;
dwarf_line_t address_line(dwarf_getsrc_die(cudie, queryaddr));
@@ -4605,6 +4607,15 @@ dwarf_var_expanding_copy_visitor::visit_target_symbol (target_symbol *e)
this->visit_target_symbol(tsym); // NB: throws nothing ...
if (tsym->saved_conversion_error) // ... but this is how we know it happened.
{
+ if (q.sess.verbose>2)
+ {
+ for (semantic_error *c = tsym->saved_conversion_error;
+ c != 0;
+ c = c->chain) {
+ clog << "variable location problem: " << c->what() << endl;
+ }
+ }
+
pf->raw_components += diename;
pf->raw_components += "=? ";
}
@@ -5037,7 +5048,7 @@ dwarf_derived_probe_group::emit_module_decls (systemtap_session& s)
assert (p->maxactive_val >= 0 && p->maxactive_val <= USHRT_MAX);
s.op->line() << " .maxactive_val=" << p->maxactive_val << ",";
}
- s.op->line() << " .address=0x" << hex << p->addr << dec << "UL,";
+ s.op->line() << " .address=(unsigned long)0x" << hex << p->addr << dec << "ULL,";
s.op->line() << " .module=\"" << p->module << "\",";
s.op->line() << " .section=\"" << p->section << "\",";
s.op->line() << " .pp=" << lex_cast_qstring (*p->sole_location()) << ",";
@@ -5294,17 +5305,17 @@ dwarf_builder::build(systemtap_session & sess,
use_debuginfo = 1
};
- location->components[0]->arg = new literal_string(sess.cmd);
- ((literal_map_t&)parameters)[location->components[0]->functor] = location->components[0]->arg;
+// location->components[0]->arg = new literal_string(sess.cmd);
+// ((literal_map_t&)parameters)[location->components[0]->functor] = location->components[0]->arg;
Dwarf_Addr bias;
- Elf* elf = (dwarf_getelf (dwfl_module_getdwarf (dw->module, &bias))
- ?: dwfl_module_getelf (dw->module, &bias));
+ Elf* elf = dwfl_module_getelf (dw->module, &bias);
size_t shstrndx;
Elf_Scn *probe_scn = NULL;
dwfl_assert ("getshstrndx", elf_getshstrndx (elf, &shstrndx));
__uint64_t probe_arg = 0;
int probe_type = no_debuginfo;
+ char *probe_name;
// Find the .probes section where the static probe label and arg are stored
while ((probe_scn = elf_nextscn (elf, probe_scn)))
{
@@ -5314,24 +5325,36 @@ dwarf_builder::build(systemtap_session & sess,
if (strcmp (elf_strptr (elf, shstrndx, shdr->sh_name), ".probes") != 0)
continue;
- Elf_Data *pdata = elf_getdata (probe_scn, NULL);
+ Elf_Data *pdata = elf_getdata_rawchunk (elf, shdr->sh_offset, shdr->sh_size, ELF_T_BYTE);
assert (pdata != NULL);
size_t probe_scn_offset = 0;
+ size_t probe_scn_addr = shdr->sh_addr;
while (probe_scn_offset < pdata->d_size)
{
- char *probe_name = (char*)pdata->d_buf + probe_scn_offset;
- probe_scn_offset += strlen(probe_name);
- probe_scn_offset += sizeof(int) - (probe_scn_offset % sizeof(int));
- probe_type = *(((char*)pdata->d_buf + probe_scn_offset));
+ const int stap_sentinel = 0x31425250;
+ probe_type = *((int*)((char*)pdata->d_buf + probe_scn_offset));
+ if (probe_type != stap_sentinel)
+ {
+ probe_scn_offset += sizeof(int);
+ continue;
+ }
probe_scn_offset += sizeof(int);
- probe_arg = *((__uint32_t*)((char*)pdata->d_buf + probe_scn_offset));
- probe_arg <<= 32;
- probe_arg |= *((__uint32_t*)((char*)pdata->d_buf + probe_scn_offset + 4));
+ if (probe_scn_offset % (sizeof(__uint64_t)))
+ probe_scn_offset += sizeof(__uint64_t) - (probe_scn_offset % sizeof(__uint64_t));
+
+ // pdata->d_buf + *(long*)(pdata->d_buf + probe_scn_offset) - probe_scn_addr
+ probe_name = ((char*)((long)(pdata->d_buf) + (long)(*((int*)((long)pdata->d_buf + probe_scn_offset)) - probe_scn_addr)));
+ probe_scn_offset += sizeof(void*);
+ if (probe_scn_offset % (sizeof(__uint64_t)))
+ probe_scn_offset += sizeof(__uint64_t) - (probe_scn_offset % sizeof(__uint64_t));
+ probe_arg = *((__uint64_t*)((char*)pdata->d_buf + probe_scn_offset));
if (strcmp (location->components[1]->arg->tok->content.c_str(), probe_name) == 0)
break;
- probe_scn_offset += sizeof(__uint64_t);
- probe_scn_offset += sizeof(__uint64_t)*2 - (probe_scn_offset % (sizeof(__uint64_t)*2));
+ if (probe_scn_offset % (sizeof(__uint64_t)*2))
+ probe_scn_offset = (probe_scn_offset + sizeof(__uint64_t)*2) - (probe_scn_offset % (sizeof(__uint64_t)*2));
}
+ if (probe_scn_offset < pdata->d_size)
+ break;
}
if (probe_type == no_debuginfo)
@@ -5378,7 +5401,6 @@ dwarf_builder::build(systemtap_session & sess,
size_t cuhl;
Dwarf_Off noff = 0;
const char *probe_file = "@sduprobes.c";
- int probe_line;
// Find where the probe instrumentation landing points are defined
while (dwarf_nextcu (dwarf, off = noff, &noff, &cuhl, NULL, NULL, NULL) == 0)
{
@@ -5393,15 +5415,6 @@ dwarf_builder::build(systemtap_session & sess,
break;
}
}
- else
- {
- Dwarf_Line *dwarf_line = dwarf_getsrc_die (cudie, probe_arg);
- if (dwarf_line == NULL)
- continue;
- dwarf_lineno (dwarf_line, &probe_line);
- probe_file = (dwarf_diename(&cudie_mem) ?: "<unknown>");
- break;
- }
}
location->components[1]->functor = TOK_STATEMENT;
if (probe_type == no_debuginfo)
@@ -5414,11 +5427,9 @@ dwarf_builder::build(systemtap_session & sess,
}
else
{
- char *pline;
- if (asprintf (&pline, "*@%s:%d", probe_file, probe_line + 1) < 0)
- return;
- location->components[1]->arg = new literal_string(pline);
+ location->components[1]->arg = new literal_number((int)probe_arg);
}
+
((literal_map_t&)parameters)[TOK_STATEMENT] = location->components[1]->arg;
dw->module = 0;
}
@@ -7107,7 +7118,7 @@ uprobe_derived_probe_group::emit_module_decls (systemtap_session& s)
s.op->line() << "},";
if (p->section != ".absolute")
s.op->line() << " .pathname=" << lex_cast_qstring(p->module) << ", ";
- s.op->line() << " .address=0x" << hex << p->address << dec << "UL,";
+ s.op->line() << " .address=(unsigned long)0x" << hex << p->address << dec << "ULL,";
s.op->line() << " .pp=" << lex_cast_qstring (*p->sole_location()) << ",";
s.op->line() << " .ph=&" << p->name << ",";
if (p->return_p) s.op->line() << " .return_p=1,";
diff --git a/testsuite/ChangeLog b/testsuite/ChangeLog
index 9ce0fd10..49ff7b95 100644
--- a/testsuite/ChangeLog
+++ b/testsuite/ChangeLog
@@ -9,6 +9,52 @@
* systemtap.context/usymbols.c: New test program.
* systemtap.context/usymbols.exp: New dejagnu test.
+2009-01-22 Stan Cox <scox@redhat.com>
+
+ * systemtap.base/static_uprobes.exp: Test dtrace.
+
+2009-01-20 Stan Cox <scox@redhat.com>
+
+ * systemtap.base/static_uprobes.exp: Don't test -lsduprobes.
+
+2009-01-20 Wenji Huang <wenji.huang@oracle.com>
+
+ * systemtap.base/bz5274.exp: Add checking utrace.
+ * systemtap.base/bz6850.exp: Ditto.
+ * systemtap.base/static_uprobes.exp: Ditto.
+ * systemtap.base/uprobes.exp: Ditto.
+
+2009-01-13 Stan Cox <scox@redhat.com>
+
+ * systemtap.base/static_uprobes.exp: Use sdt.h
+
+2009-01-11 Wenji Huang <wenji.huang@oracle.com>
+
+ * systemtap.base/badkprobe.exp: Add explicit timeout.
+
+2009-01-09 Dave Brolley <brolley@redhat.com>
+
+ * lib/systemtap.exp: Remove ssl_server_path and ssl_client_path.
+
+2009-01-06 Frank Ch. Eigler <fche@elastic.org>
+
+ PR 9699:
+ * systemtap.context/backtrace.tcl: Correct tcl syntax in fail message.
+
+2008-12-24 Dave Brolley <brolley@redhat.com>
+
+ * lib/systemtap.exp: Rename client_path to net_path.
+ (setup_systemtap_environment): Set ssl_server_path and
+ ssl_client_path. Pass ssl_server_path to stap-find-or-start-server.
+
+2008-12-21 Stan Cox <scox@redhat.com>
+
+ * systemtap.base/static_uprobes.exp: Parms now called $argN
+
+2008-12-16 Stan Cox <scox@redhat.com>
+
+ * systemtap.base/static_uprobes.exp: Generate our own probes file.
+
2008-12-09 Frank Ch. Eigler <fche@elastic.org>
PR6961.
diff --git a/testsuite/lib/systemtap.exp b/testsuite/lib/systemtap.exp
index 28129f0a..f399073e 100644
--- a/testsuite/lib/systemtap.exp
+++ b/testsuite/lib/systemtap.exp
@@ -37,7 +37,7 @@ proc print_systemtap_version {} {
proc setup_systemtap_environment {} {
- global srcdir prefix env server_pid client_path
+ global srcdir prefix env server_pid net_path
# need an absolute SRCDIR for the top-level src/ tree
# XXX: or, we could change nearby uses of ${SRCDIR}/testsuite to ${SRCDIR}
@@ -55,9 +55,14 @@ proc setup_systemtap_environment {} {
if {[use_server_p]} then {
print "Testing using a systemtap server"
- # Server management scripts are installed if this is an install test, otherwise
- # in the source directory. Make sure they are on the $PATH.
+ # A place for some temporary files and scripts.
+ set net_path [exec pwd]/net
+ exec /bin/mkdir -p $net_path
+
+ # Server management scripts and data are installed if this is an
+ # install test, otherwise there is some setup to do.
if {! [installtest_p]} then {
+ # Make sure the server management scripts are on the $PATH.
set env(PATH) "$srcdir/..:$env(PATH)"
}
@@ -76,14 +81,12 @@ proc setup_systemtap_environment {} {
# Make a copy of 'stap-client' as 'stap' and make sure it's at the
# beginning of the $PATH. Do this after starting the server so that
# The server does not call this instance of 'stap'
- set client_path [exec pwd]/net
- exec /bin/mkdir -p $client_path
if {[installtest_p]} then {
- exec /bin/cp -p [exec which stap-client] $client_path/stap
+ exec /bin/cp -p [exec which stap-client] $net_path/stap
} else {
- exec /bin/cp -p $srcdir/../stap-client $client_path/stap
+ exec /bin/cp -p $srcdir/../stap-client $net_path/stap
}
- set env(PATH) "$client_path:$env(PATH)"
+ set env(PATH) "$net_path:$env(PATH)"
}
# PATH, SYSTEMTAP_TAPSET, SYSTEMTAP_RUNTIME, LD_LIBRARY_PATH are already set.
@@ -121,7 +124,7 @@ proc systemtap_init {args} {}
proc systemtap_version {} {}
proc systemtap_exit {} {
- global server_pid client_path
+ global server_pid net_path
# Stop the stap server, if we started it.
if {[use_server_p]} then {
@@ -131,7 +134,7 @@ proc systemtap_exit {} {
}
# Remove the temporary stap script
- exec /bin/rm -fr $client_path
+ exec /bin/rm -fr $net_path
}
}
diff --git a/testsuite/systemtap.base/badkprobe.exp b/testsuite/systemtap.base/badkprobe.exp
index 1a1dbad5..efc06695 100644
--- a/testsuite/systemtap.base/badkprobe.exp
+++ b/testsuite/systemtap.base/badkprobe.exp
@@ -5,6 +5,7 @@ if {! [installtest_p]} { untested $test; return }
spawn stap -g -w -e "$script"
expect {
+ -timeout 60
-re "^WARNING: probe .*registration error.*" { pass $test }
eof { fail "$test (eof)" }
timeout { fail "$test (timeout)" }
diff --git a/testsuite/systemtap.base/bz5274.exp b/testsuite/systemtap.base/bz5274.exp
index 6e95a58b..db0e0a46 100755
--- a/testsuite/systemtap.base/bz5274.exp
+++ b/testsuite/systemtap.base/bz5274.exp
@@ -14,6 +14,14 @@ if {$err == "" && [file exists $test]} then { pass "$test compile"
if {! [installtest_p]} { untested "$test -p5"; return }
+# Try to find utrace_attach symbol in /proc/kallsyms
+# copy from utrace_p5.exp
+set utrace_support_found 0
+set path "/proc/kallsyms"
+if {! [catch {exec grep -q utrace_attach $path} dummy]} {
+ set utrace_support_found 1
+}
+if {$utrace_support_found == 0} { untested "$test -p5"; return }
if {[catch {exec stap $tpath.stp -c "$srcdir/$subdir/$test.sh"} res]} {
untested "$test longjmp to a uretprobed function"
diff --git a/testsuite/systemtap.base/bz6850.exp b/testsuite/systemtap.base/bz6850.exp
index b06b1696..73fedc8a 100644
--- a/testsuite/systemtap.base/bz6850.exp
+++ b/testsuite/systemtap.base/bz6850.exp
@@ -3,6 +3,15 @@ set test bz6850
catch {exec gcc -g -o bz6850 $srcdir/$subdir/bz6850.c} err
if {$err == "" && [file exists bz6850]} then { pass "$test compile" } else { fail "$test compile" }
+# Try to find utrace_attach symbol in /proc/kallsyms
+# copy from utrace_p5.exp
+set utrace_support_found 0
+set path "/proc/kallsyms"
+if {! [catch {exec grep -q utrace_attach $path} dummy]} {
+ set utrace_support_found 1
+}
+if {$utrace_support_found == 0} { untested "$test -p4"; untested "$test -p5"; return }
+
set rc [stap_run_batch $srcdir/$subdir/bz6850.stp]
if {$rc == 0} then { pass "$test -p4" } else { fail "$test -p4" }
diff --git a/testsuite/systemtap.base/static_uprobes.exp b/testsuite/systemtap.base/static_uprobes.exp
index 78641d3f..eb0d1c6e 100644
--- a/testsuite/systemtap.base/static_uprobes.exp
+++ b/testsuite/systemtap.base/static_uprobes.exp
@@ -8,28 +8,30 @@ set sup_flags "additional_flags=-iquote$env(SYSTEMTAP_RUNTIME) additional_flags=
set fp [open $sup_srcpath "w"]
puts $fp "
#include <stdlib.h>
-#include \"sduprobes.h\"
+#define USE_STAP_PROBE 1
+#include \"static_uprobes.h\"
foo ()
{
- STAP_PROBE(tstlabel,label1);
+ STAP_PROBE(static_uprobes,test_probe_1);
}
bar (int i)
{
if (i == 0)
i = 1000;
- STAP_PROBE1(tstlabel,label2,i);
+ STAP_PROBE1(static_uprobes,test_probe_2,i);
}
baz (int i, char* s)
{
+ STAP_PROBE1(static_uprobes,test_probe_0,i);
if (i == 0)
i = 1000;
- STAP_PROBE2(tstlabel,label3,i,s);
+ STATIC_UPROBES_TEST_PROBE_3(i,s);
}
-buz ()
+buz (int parm)
{
}
@@ -39,46 +41,120 @@ main ()
foo();
bar(2);
baz(3,\"abc\");
+ buz(4);
}
"
close $fp
-set res [target_compile $sup_srcpath $sup_exepath executable $sup_flags]
-if { $res != "" } {
- verbose "target_compile failed: $res" 2
- fail "compiling static_uprobes.c"
- return
-} else {
- pass "compiling static_uprobes.c"
+# set res [target_compile $sup_srcpath $sup_exepath executable $sup_flags]
+# if { $res != "" } {
+# verbose "target_compile failed: $res" 2
+# fail "compiling static_uprobes.c"
+# return
+# } else {
+# pass "compiling static_uprobes.c"
+# }
+
+set fp [open "[pwd]/static_uprobes.stp" "w"]
+puts $fp "
+probe process(\"static_uprobes.x\").mark(\"test_probe_0\")
+{
+ printf(\"In test_probe_0 probe %#x\\n\", \$arg1)
+}
+probe process(\"static_uprobes.x\").mark(\"test_probe_1\")
+{
+ printf(\"In test_probe_1 probe\\n\")
+}
+probe process(\"static_uprobes.x\").mark(\"test_probe_2\")
+{
+ printf(\"In test_probe_2 probe %#x\\n\", \$arg1)
}
+probe process(\"static_uprobes.x\").mark(\"test_probe_3\")
+{
+ printf(\"In test_probe_3 probe %#x %#x\\n\", \$arg1, \$arg2)
+}
+"
+close $fp
-set ok 0
-spawn stap -c $sup_exepath $srcdir/$subdir/static_uprobes.stp
-expect {
- -timeout 180
- -re {In label1 probe} { incr ok; exp_continue }
- -re {In label2 probe 0x2} { incr ok; exp_continue }
- -re {In label3 probe 0x3 0x[0-9a-f][0-9a-f]} { incr ok; exp_continue }
- timeout { fail "$test (timeout)" }
- eof { }
+# Try to find utrace_attach symbol in /proc/kallsyms
+# copy from utrace_p5.exp
+set utrace_support_found 0
+set path "/proc/kallsyms"
+if {! [catch {exec grep -q utrace_attach $path} dummy]} {
+ set utrace_support_found 1
}
+if {$utrace_support_found == 0} { untested "$test"; return }
+
+set ok 0
+# verbose -log "spawn stap -c $sup_exepath [pwd]/static_uprobes.stp"
+# spawn stap -c $sup_exepath [pwd]/static_uprobes.stp
+# expect {
+# -timeout 180
+# -re {In test_probe_1 probe} { incr ok; exp_continue }
+# -re {In test_probe_2 probe 0x2} { incr ok; exp_continue }
+# -re {In test_probe_0 probe 0x3} { incr ok; exp_continue }
+# -re {In test_probe_3 probe 0x3 0x[0-9a-f][0-9a-f]} { incr ok; exp_continue }
+# timeout { fail "$test (timeout)" }
+# eof { }
+# }
+
+# if {$ok == 4} { pass "$test" } { fail "$test ($ok)" }
+set ok 0
# Now do a debuginfo style probe of the above test
set fp [open "[pwd]/static_uprobes.sh" "w"]
puts $fp "
ed $sup_srcpath <<HERE
-1a
-#define USE_STAP_DEBUGINFO_PROBE 1
+/USE_STAP_PROBE/d
+/buz/+1
+a
+ DTRACE_PROBE1(static_uprobes,test_probe_4,parm);
.
w
q
-HERE
"
close $fp
spawn sh [pwd]/static_uprobes.sh
-set sup_flags "additional_flags=-iquote$env(SYSTEMTAP_RUNTIME) additional_flags=-g additional_flags=$env(SYSTEMTAP_RUNTIME)/sduprobes.c"
+set fp [open "[pwd]/static_uprobes.stp" "w"]
+puts $fp "
+probe process(\"static_uprobes.x\").mark(\"test_probe_0\")
+{
+ printf(\"In test_probe_0 probe %#x\\n\", \$arg1)
+}
+probe process(\"static_uprobes.x\").mark(\"test_probe_1\")
+{
+ printf(\"In test_probe_1 probe\\n\")
+}
+probe process(\"static_uprobes.x\").mark(\"test_probe_2\")
+{
+ printf(\"In test_probe_2 probe %#x\\n\", \$arg1)
+}
+probe process(\"static_uprobes.x\").mark(\"test_probe_3\")
+{
+ printf(\"In test_probe_3 probe %#x %#x\\n\", \$arg1, \$arg2)
+}
+probe process(\"static_uprobes.x\").mark(\"test_probe_4\")
+{
+ printf(\"In test_probe_4 dtrace probe %#x\\n\", \$arg1)
+}
+"
+close $fp
+
+set fp [open "[pwd]/static_uprobes.d" "w"]
+puts $fp "
+provider static_uprobes {
+ probe test_probe_1 ();
+ probe test_probe_2 (int i);
+ probe test_probe_3 (int i, char* x);
+ probe test_probe_4 (int i);
+};
+"
+close $fp
+spawn dtrace -h -s [pwd]/static_uprobes.d
+
+set sup_flags "additional_flags=-iquote$env(SYSTEMTAP_RUNTIME) additional_flags=-g additional_flags=-O additional_flags=-I."
set res [target_compile $sup_srcpath $sup_exepath executable $sup_flags]
if { $res != "" } {
verbose "target_compile failed: $res" 2
@@ -88,16 +164,19 @@ if { $res != "" } {
pass "compiling sduprobes.c -g"
}
-spawn stap -c $sup_exepath $srcdir/$subdir/static_uprobes.stp
+verbose -log "spawn stap -c $sup_exepath [pwd]/static_uprobes.stp"
+spawn stap -c $sup_exepath [pwd]/static_uprobes.stp
expect {
-timeout 180
- -re {In label1 probe} { incr ok; exp_continue }
- -re {In label2 probe 0x2} { incr ok; exp_continue }
- -re {In label3 probe 0x3 0x[0-9a-f][0-9a-f]} { incr ok; exp_continue }
+ -re {In test_probe_1 probe} { incr ok; exp_continue }
+ -re {In test_probe_2 probe 0x2} { incr ok; exp_continue }
+ -re {In test_probe_0 probe 0x3} { incr ok; exp_continue }
+ -re {In test_probe_3 probe 0x3 0x[0-9a-f][0-9a-f]} { incr ok; exp_continue }
+ -re {In test_probe_4 dtrace probe 0x4} { incr ok; exp_continue }
timeout { fail "$test (timeout)" }
eof { }
}
wait
-if {$ok == 6} { pass "$test" } { fail "$test ($ok)" }
+if {$ok == 5} { pass "$test" } { fail "$test ($ok)" }
diff --git a/testsuite/systemtap.base/static_uprobes.stp b/testsuite/systemtap.base/static_uprobes.stp
deleted file mode 100644
index b9de197e..00000000
--- a/testsuite/systemtap.base/static_uprobes.stp
+++ /dev/null
@@ -1,14 +0,0 @@
-probe process("static_uprobes.x").mark("label1")
-{
- printf("In label1 probe\n")
-}
-
-probe process("static_uprobes.x").mark("label2")
-{
- printf("In label2 probe %#x\n", $arg1)
-}
-
-probe process("static_uprobes.x").mark("label3")
-{
- printf("In label3 probe %#x %#x\n", $arg1, $arg2)
-}
diff --git a/testsuite/systemtap.base/uprobes.exp b/testsuite/systemtap.base/uprobes.exp
index 408ba8c4..e8318586 100644
--- a/testsuite/systemtap.base/uprobes.exp
+++ b/testsuite/systemtap.base/uprobes.exp
@@ -18,6 +18,15 @@ if [file exists $path] then { pass "$test prep" } else { fail "$test prep" }
catch {exec gcc -g -o jennie jennie.c} err
if {$err == "" && [file exists jennie]} then { pass "$test compile" } else { fail "$test compile" }
+# Try to find utrace_attach symbol in /proc/kallsyms
+# copy from utrace_p5.exp
+set utrace_support_found 0
+set path "/proc/kallsyms"
+if {! [catch {exec grep -q utrace_attach $path} dummy]} {
+ set utrace_support_found 1
+}
+if {$utrace_support_found == 0} { untested "$test -p4"; untested "$test -p5"; return }
+
set rc [stap_run_batch $srcdir/$subdir/uprobes.stp]
if {$rc == 0} then { pass "$test -p4" } else { fail "$test -p4" }
diff --git a/testsuite/systemtap.context/backtrace.tcl b/testsuite/systemtap.context/backtrace.tcl
index aaec4cb8..ca60c369 100644
--- a/testsuite/systemtap.context/backtrace.tcl
+++ b/testsuite/systemtap.context/backtrace.tcl
@@ -128,7 +128,7 @@ expect {
}
exp_continue
}
- eof {fail "backtrace of yyy_func[2-4]: unexpected EOF" }
+ eof {fail "backtrace of yyy_func*: unexpected EOF" }
}
exec kill -INT -[exp_pid]
if {$m1 == 3} {
diff --git a/testsuite/systemtap.examples/ChangeLog b/testsuite/systemtap.examples/ChangeLog
index 810df78c..253e1a76 100644
--- a/testsuite/systemtap.examples/ChangeLog
+++ b/testsuite/systemtap.examples/ChangeLog
@@ -1,3 +1,14 @@
+2009-01-02 Mark Wielaard <mjw@redhat.com>
+
+ PR9693. Reported by Eugeniy Meshcheryakov <eugen@debian.org>
+ * io/traceio2.stp: Add proper #! /usr/bin/env stap line.
+ * profiling/functioncallcount.stp: Likewise.
+
+2008-12-10 William Cohen <wcohen@redhat.com>
+
+ * process/futexes.stp:
+ * profiling/thread-times.stp: Tweak formatting.
+
2008-12-10 Tim Moore <timoore@redhat.com>
* profiling/latencytap.stp: Probe scheduler to identify processes
diff --git a/testsuite/systemtap.examples/io/traceio2.stp b/testsuite/systemtap.examples/io/traceio2.stp
index 032edcd9..1abea45d 100755
--- a/testsuite/systemtap.examples/io/traceio2.stp
+++ b/testsuite/systemtap.examples/io/traceio2.stp
@@ -1,3 +1,5 @@
+#! /usr/bin/env stap
+
global device_of_interest, dev
probe begin {
diff --git a/testsuite/systemtap.examples/process/futexes.stp b/testsuite/systemtap.examples/process/futexes.stp
index 0bd63262..d10a6a0b 100755
--- a/testsuite/systemtap.examples/process/futexes.stp
+++ b/testsuite/systemtap.examples/process/futexes.stp
@@ -11,7 +11,7 @@ global lock_waits # long-lived stats on (tid,lock) blockage elapsed time
global process_names # long-lived pid-to-execname mapping
probe syscall.futex {
- if (op != FUTEX_WAIT) next # we don't care about originators of WAKE events
+ if (op != FUTEX_WAIT) next # don't care about WAKE event originator
t = tid ()
process_names[pid()] = execname()
thread_thislock[t] = $uaddr
diff --git a/testsuite/systemtap.examples/profiling/functioncallcount.stp b/testsuite/systemtap.examples/profiling/functioncallcount.stp
index e393b612..9e9ec3fd 100755
--- a/testsuite/systemtap.examples/profiling/functioncallcount.stp
+++ b/testsuite/systemtap.examples/profiling/functioncallcount.stp
@@ -1,3 +1,4 @@
+#! /usr/bin/env stap
# The following line command will probe all the functions
# in kernel's memory management code:
#
diff --git a/testsuite/systemtap.examples/profiling/thread-times.stp b/testsuite/systemtap.examples/profiling/thread-times.stp
index 007e23ed..cbe4118e 100755
--- a/testsuite/systemtap.examples/profiling/thread-times.stp
+++ b/testsuite/systemtap.examples/profiling/thread-times.stp
@@ -16,7 +16,8 @@ global tids
probe timer.s(5), end {
allticks = @count(ticks)
- printf ("%5s %7s %7s (of %d ticks)\n", "tid", "%user", "%kernel", allticks)
+ printf ("%5s %7s %7s (of %d ticks)\n",
+ "tid", "%user", "%kernel", allticks)
foreach (tid in tids- limit 20) {
uscaled = @count(uticks[tid])*10000/allticks
kscaled = @count(kticks[tid])*10000/allticks
diff --git a/testsuite/systemtap.syscall/test.tcl b/testsuite/systemtap.syscall/test.tcl
index 66a943d6..db0df138 100755
--- a/testsuite/systemtap.syscall/test.tcl
+++ b/testsuite/systemtap.syscall/test.tcl
@@ -106,7 +106,7 @@ proc run_one_test {filename flags} {
}
}
if {$i < $ind} {
- send_log "--------- EXPECTED and NOT MATCHED ----------\n"
+ send_log -- "--------- EXPECTED and NOT MATCHED ----------\n"
}
for {} {$i < $ind} {incr i} {
send_log "$results($i)\n"
diff --git a/translate.cxx b/translate.cxx
index 1640d87e..cfd83438 100644
--- a/translate.cxx
+++ b/translate.cxx
@@ -26,6 +26,9 @@
extern "C" {
#include <elfutils/libdwfl.h>
+#ifdef HAVE_ELFUTILS_VERSION_H
+#include <elfutils/version.h>
+#endif
}
using namespace std;
@@ -4180,7 +4183,8 @@ c_unparser::visit_print_format (print_format* e)
prec_ix = arg_ix++;
/* Generate a noop call to deref_buffer for %m. */
- if (components[i].type == print_format::conv_memory) {
+ if (components[i].type == print_format::conv_memory
+ || components[i].type == print_format::conv_memory_hex) {
this->probe_or_function_needs_deref_fault_handler = true;
o->newline() << "deref_buffer (0, " << tmp[arg_ix].value() << ", ";
if (prec_ix == -1)
@@ -4241,7 +4245,8 @@ c_unparser::visit_print_format (print_format* e)
o->line() << ", (int)" << tmp[arg_ix++].value();
/* The type of the %m argument is 'char*'. */
- if (components[i].type == print_format::conv_memory)
+ if (components[i].type == print_format::conv_memory
+ || components[i].type == print_format::conv_memory_hex)
o->line() << ", (char*)(uintptr_t)" << tmp[arg_ix++].value();
/* The type of the %c argument is 'int'. */
else if (components[i].type == print_format::conv_char)
@@ -4473,8 +4478,15 @@ dump_unwindsyms (Dwfl_Module *m,
(const unsigned char **)&build_id_bits,
&build_id_vaddr)) > 0)
{
- /* XXX: But see https://bugzilla.redhat.com/show_bug.cgi?id=465872;
- dwfl_module_build_id was not intended to return the end address. */
+ // Enable workaround for elfutils dwfl bug.
+ // see https://bugzilla.redhat.com/show_bug.cgi?id=465872
+ // and http://sourceware.org/ml/systemtap/2008-q4/msg00579.html
+#ifdef _ELFUTILS_PREREQ
+#if _ELFUTILS_PREREQ(0,138)
+ // Let's standardize to the buggy "end of build-id bits" behavior.
+ build_id_vaddr += build_id_len;
+#endif
+#endif
if (c->session.verbose > 1) {
clog << "Found build-id in " << name
<< ", length " << build_id_len;