The "open-output-pipe":"no duplicate" test has been hanging, on and
off, and not completely reliably, for a few years. It's now doing so
fairly reliably for me, and investigation shows that
- the child shell process is in a tight loop (99% CPU)
- the parent Guile process is stuck calling waitpid().
The problem is that the child hasn't got the SIGPIPE that the test
intends, and so is continuing to echo "closed" forever; and Guile is
waiting for it to terminate, forever.
I haven't fully debugged the SIGPIPE problem, but it sounds very like
what Chet Ramey describes here:
http://old.nabble.com/Re%3A-SIGPIPE-not-properly-reset-with-%27trap---PIPE%27-p20985595.html.
(And my version of bash is 3.2.39.)
So, a fix should be to use something other than shell to implement the
child; and it appears that this works.
* check-guile.in (TEST_SUITE_DIR): Export.
* test-suite/tests/popen-child.scm: New script file.
* test-suite/tests/popen.test ("open-output-pipe", "no duplicate"):
Use Guile for the child process, instead of shell.
* libguile/measure-hwm.scm: Remove.
* .gitignore: Update for removal.
* test-suite/standalone/test-fast-slot-ref.in:
* test-suite/standalone/test-use-srfi.in:
* am/guilec:
* check-guile.in: Revert back to normal guile invocation.
* libguile/Makefile.am: Don't make a stack calibration file, as the
getrlimit-based limit setting should work fine.
* README: Add more info about building against an uninstalled Guile.
* meta/: New directory. The proximate cause of its creation is that I
want to be able to build external packages against uninstalled Guile,
and to do that I need guile-tools in the PATH, but I don't want
$top_builddir/libtool in the path. But it seems like a good
reorganization, for things that are /about/ Guile: pkg-config files, m4
files, guile-config... then we also include uninstalled info: the
environment, the pre-inst-guile script, etc.
* meta/guile-1.8-uninstalled.pc.in: New pkg-config template. pkg-config
prefers -uninstalled pkg-config files, if they are in its path.
* meta/Makefile.am:
* meta/ChangeLog-2008:
* meta/gdb-uninstalled-guile.in:
* meta/guile-1.8.pc.in:
* meta/guile-config.in:
* meta/guile.m4:
* meta/guile-tools.in: Moved to meta/.
* meta/guile.in: This is the new name of pre-inst-guile.in.
* meta/uninstalled-env.in: And this, pre-inst-guile-env.in.
* Makefile.am:
* am/guilec:
* am/pre-inst-guile:
* check-guile.in:
* configure.in:
* doc/ref/Makefile.am:
* gc-benchmarks/run-benchmark.scm:
* test-suite/standalone/Makefile.am:
* test-suite/standalone/README:
* testsuite/Makefile.am: Adapt to meta/ change.
For explanation, see comments and text in the new file
libguile/measure-hwm.scm.
* .gitignore: Add libguile/stack-limit-calibration.scm.
* check-guile.in: Load libguile/stack-limit-calibration.scm.
* configure.in: Add AC_CONFIG_FILES to generate test-use-srfi from
test-use-srfi.in.
* libguile/Makefile.am (TESTS, TESTS_ENVIRONMENT,
stack-limit-calibration.scm): New targets, so that `make check'
calibrates the stack limit before running the Guile test suite.
* libguile/measure-hwm.scm: New file, calibrates stack limit for `make
check'.
* libguile/stackchk.c (scm_sys_get_stack_size): New primitive.
* libguile/stackchk.h (scm_sys_get_stack_size): New primitive
(declaration).
* test-suite/standalone/test-use-srfi: Renamed test-use-srfi.in, so
that ./configure can fill in variables in it.
* test-suite/standalone/test-use-srfi.in: Load
libguile/stack-limit-calibration.scm.
(top_builddir, top_srcdir, guile_opts): New vars.
Use "set -e".
No longer set LTDL_LIBRARY_PATH.
Use ${top_srcdir}/pre-inst-guile instead of libguile/guile.
check" was run before Guile had been installed with the current
--prefix. made various changes to the script so that it runs
without a cd to the test-suite directory. For the -i option,
don't point GUILE_LOAD_PATH to the current directory, but let it
use it's own scheme library.
* tests/r4rs.test: use test-file-name to locate r4rs.test,
not data-file-name.
* guile-test: define tmp-dir, the location where r4rs.test will
create it's temporary files.
(data-file-name): use tmp-dir. this must be under build-dir,
not src-dir.
the current directory (build dir) not srcdir to find guile
executable. otherwise "make check" doesn't work with a separate
build directory. create the test log in
$build_dir/check-guile.log instead of in srcdir/test-suite
directory.
* configure.in: don't define or substitute test_suite_dir.
* guile-test: use #!/bogus-path/..., not #!/home/dirk/... in the
first line.