diff --git a/AUTHORS b/AUTHORS
deleted file mode 100644
--- a/AUTHORS
+++ /dev/null
@@ -1,5 +0,0 @@
-
-Don Stewart 	<http://www.cse.unsw.edu.au/~dons>
-Sean Seefried	<http://www.cse.unsw.edu.au/~sseefried>
-Andre Pang      <http://www.algorithm.com.au>
-
diff --git a/README b/README
deleted file mode 100644
--- a/README
+++ /dev/null
@@ -1,111 +0,0 @@
-
-------------------------------------------------------------------------
-                            hs-plugins
-------------------------------------------------------------------------
-
-Compiler and tool support for compiling and loading, and evaluating
-Haskell at runtime. 
-
-The library provides a convenient interface to GHC's runtime loader
-and linker, letting you load compiled Haskell code. 
-
-It also provides a `make' system for compiling plugin source
-automagically and for combining the user's .hs file with a stub of
-standard declarations and syntax, saving the user from having to write
-standard code themselves.
-
-It provides an `eval' function, for generating new, well-typed, compiled
-code from a Haskell source string.
-
-It also provides a new variation of printf for Haskell-- a runtime
-generated, dynamically-typed printf.
-
-Read the documentation in doc/ for more.
-
-------------------------------------------------------------------------
-
-BUILDING:
-        $ chmod +x Setup.lhs configure
-        $ ./Setup.lhs configure --prefix=/usr/local
-        $ ./Setup.lhs build
-        $ ./Setup.lhs install
-
-------------------------------------------------------------------------
-
-DEPENDENCIES:
-
-* Requires GHC >= 6.4
-* Requires Cabal
-
-------------------------------------------------------------------------
-
-* Optional:
-   If you are doing a lot of `merge'-related operations, and require
-   an extended haskell parser, you can compile hs-plugins to use 
-   HSX, Niklas Broberg's Haskell parser library, available at:
-
-    darcs get http://www.cs.chalmers.se/~d00nibro/haskell-src-exts
-
-   To get hs-plugins to use HSX, use: 
-
-        $ mv plugins.cabal.hsx plugins.cabal
-        $ ./Setup.lhs configure --enable-hsx
-
-   Make sure to install HSX first though :)
-
-------------------------------------------------------------------------
-
-* On cygwin/windows you (a) make sure the cygwin "find" is before the
-  windows "find" on your PATH, and (b) to give the windows-style path
-  (e.g., "c:/cygwin/usr/local") in the ./configure --prefix=foo/bar
-  step
-
-* 'plugs' requires a working readline library.
-
-* If you wish to use TH in plugins, or to run load()-programs in GHCi,
-  you require a patch to GHC's linker, that was committed into ghc
-  6.3, and ghc 6.2 -stable branch, and is available from 6.2.2 onwards.
-
-* If you need to regenerate ./configure you need >= autoreconf-2.53
-
-* The documentation relies on haddock, latex, dvips, tex2page:
-
-        $ cd doc && make
-
-------------------------------------------------------------------------
-
-EXAMPLES:
-
-Have a look in the testsuite/ directory for many examples of how to
-arrange your code.
-
-LICENSE:
-
-This library is distributed under the terms of the LGPL. The runtime
-loader code is based on code written by André Pang, and others, and is
-distributed under the BSD-style Glasgow University license.
-
-PORTABILITY:
-
-Requires GHC 6.4 or greater, though most testing has be done on 6.4.
-The dynamic loader requires a functional GHCi implementation.
-
----------------------+--------------------------------------------------
-  Platform           |  Works   Should work*    Unknown    Won't work
----------------------+--------------------------------------------------
-i386-*-linux         |    X
-i386-*-freebsd       |    X
-i386-*-openbsd       |    X           
-powerpc-apple-darwin |    X            
-powerpc-*-linux      |    X            
-sparc-*-solaris2     |    X            
-ia64-*-linux         |    #
-i386-*-solaris2      |                X
-sparc-*-linux        |                X
-sparc-*-openbsd      |                X
-i386-*-netbsd        |                              X 
-amd64-*-openbsd      |                              X
-mips64-sgi-irix      |                                         X
----------------------+--------------------------------------------------
-
-# .hi file parsing is currently broken
diff --git a/TODO b/TODO
deleted file mode 100644
--- a/TODO
+++ /dev/null
@@ -1,26 +0,0 @@
-For 1.0
-----------
-
-+ broken on mac.
-symbols with suspiciously many _ chars
-
-+ Add verbose versions of the load functions, to avoid -DDEBUG
-
-+ mention that you need .o archives, not .a ones. Use Cabal, ghc-pkg -u
-    or ld -r --whole-archive
-
-+ hs-plugins doesn't know to look for packages in the user packages,
-only in the global packages
-
-+ version numbers in package loads are annyoing
-
-+ .hi file parser is broken on Itanium, again.
-
-+ build way=p and way=''
-
-Cabal
---------
-
-What we'd like is a cabalMake version of make, so rather than just
-compiling simple plugins, we let cabalMake rebuild whole Haskell apps --
-like Yi!
diff --git a/configure b/configure
--- a/configure
+++ b/configure
@@ -1,3767 +1,4289 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.59.
-#
-# Copyright (C) 2003 Free Software Foundation, Inc.
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## --------------------- ##
-## M4sh Initialization.  ##
-## --------------------- ##
-
-# Be Bourne compatible
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
-  set -o posix
-fi
-DUALCASE=1; export DUALCASE # for MKS sh
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-  as_unset=unset
-else
-  as_unset=false
-fi
-
-
-# Work around bugs in pre-3.0 UWIN ksh.
-$as_unset ENV MAIL MAILPATH
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
-  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
-  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
-  LC_TELEPHONE LC_TIME
-do
-  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
-    eval $as_var=C; export $as_var
-  else
-    $as_unset $as_var
-  fi
-done
-
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
-  as_basename=basename
-else
-  as_basename=false
-fi
-
-
-# Name of the executable.
-as_me=`$as_basename "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)$' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
-  	  /^X\/\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\/\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-
-
-# PATH needs CR, and LINENO needs CR and PATH.
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
-  echo "#! /bin/sh" >conf$$.sh
-  echo  "exit 0"   >>conf$$.sh
-  chmod +x conf$$.sh
-  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
-    PATH_SEPARATOR=';'
-  else
-    PATH_SEPARATOR=:
-  fi
-  rm -f conf$$.sh
-fi
-
-
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
-  # Find who we are.  Look in the path if we contain no path at all
-  # relative or not.
-  case $0 in
-    *[\\/]* ) as_myself=$0 ;;
-    *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-
-       ;;
-  esac
-  # We did not find ourselves, most probably we were run as `sh COMMAND'
-  # in which case we are not to be found in the path.
-  if test "x$as_myself" = x; then
-    as_myself=$0
-  fi
-  if test ! -f "$as_myself"; then
-    { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
-   { (exit 1); exit 1; }; }
-  fi
-  case $CONFIG_SHELL in
-  '')
-    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for as_base in sh bash ksh sh5; do
-	 case $as_dir in
-	 /*)
-	   if ("$as_dir/$as_base" -c '
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
-	     $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
-	     $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
-	     CONFIG_SHELL=$as_dir/$as_base
-	     export CONFIG_SHELL
-	     exec "$CONFIG_SHELL" "$0" ${1+"$@"}
-	   fi;;
-	 esac
-       done
-done
-;;
-  esac
-
-  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
-  # uniformly replaced by the line number.  The first 'sed' inserts a
-  # line-number line before each line; the second 'sed' does the real
-  # work.  The second script uses 'N' to pair each line-number line
-  # with the numbered line, and appends trailing '-' during
-  # substitution so that $LINENO is not a special case at line end.
-  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
-  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
-  sed '=' <$as_myself |
-    sed '
-      N
-      s,$,-,
-      : loop
-      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
-      t loop
-      s,-$,,
-      s,^['$as_cr_digits']*\n,,
-    ' >$as_me.lineno &&
-  chmod +x $as_me.lineno ||
-    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
-   { (exit 1); exit 1; }; }
-
-  # Don't try to exec as it changes $[0], causing all sort of problems
-  # (the dirname of $[0] is not the place where we might find the
-  # original and so on.  Autoconf is especially sensible to this).
-  . ./$as_me.lineno
-  # Exit status is that of the last command.
-  exit
-}
-
-
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
-  *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T='	' ;;
-  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
-  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
-  # We could just check for DJGPP; but this test a) works b) is more generic
-  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
-  if test -f conf$$.exe; then
-    # Don't use ln at all; we don't have any links
-    as_ln_s='cp -p'
-  else
-    as_ln_s='ln -s'
-  fi
-elif ln conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s=ln
-else
-  as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.file
-
-if mkdir -p . 2>/dev/null; then
-  as_mkdir_p=:
-else
-  test -d ./-p && rmdir ./-p
-  as_mkdir_p=false
-fi
-
-as_executable_p="test -f"
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" 	$as_nl"
-
-# CDPATH.
-$as_unset CDPATH
-
-
-# Name of the host.
-# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-exec 6>&1
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_config_libobj_dir=.
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-# Maximum number of lines to put in a shell here document.
-# This variable seems obsolete.  It should probably be removed, and
-# only ac_max_sed_lines should be used.
-: ${ac_max_here_lines=38}
-
-# Identity of this package.
-PACKAGE_NAME=
-PACKAGE_TARNAME=
-PACKAGE_VERSION=
-PACKAGE_STRING=
-PACKAGE_BUGREPORT=
-
-ac_unique_file="src/System/Plugins.hs"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os PREFIX TOP GHC GLASGOW_HASKELL HASKELL_SRC CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA LIBOBJS LTLIBOBJS'
-ac_subst_files=''
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
-
-ac_prev=
-for ac_option
-do
-  # If the previous option needs an argument, assign it.
-  if test -n "$ac_prev"; then
-    eval "$ac_prev=\$ac_option"
-    ac_prev=
-    continue
-  fi
-
-  ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
-
-  # Accept the important Cygnus configure options, so we can diagnose typos.
-
-  case $ac_option in
-
-  -bindir | --bindir | --bindi | --bind | --bin | --bi)
-    ac_prev=bindir ;;
-  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
-    bindir=$ac_optarg ;;
-
-  -build | --build | --buil | --bui | --bu)
-    ac_prev=build_alias ;;
-  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
-    build_alias=$ac_optarg ;;
-
-  -cache-file | --cache-file | --cache-fil | --cache-fi \
-  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
-    ac_prev=cache_file ;;
-  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
-  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
-    cache_file=$ac_optarg ;;
-
-  --config-cache | -C)
-    cache_file=config.cache ;;
-
-  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
-    ac_prev=datadir ;;
-  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
-  | --da=*)
-    datadir=$ac_optarg ;;
-
-  -disable-* | --disable-*)
-    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
-   { (exit 1); exit 1; }; }
-    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
-    eval "enable_$ac_feature=no" ;;
-
-  -enable-* | --enable-*)
-    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
-   { (exit 1); exit 1; }; }
-    ac_feature=`echo $ac_feature | sed 's/-/_/g'`
-    case $ac_option in
-      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "enable_$ac_feature='$ac_optarg'" ;;
-
-  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
-  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
-  | --exec | --exe | --ex)
-    ac_prev=exec_prefix ;;
-  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
-  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
-  | --exec=* | --exe=* | --ex=*)
-    exec_prefix=$ac_optarg ;;
-
-  -gas | --gas | --ga | --g)
-    # Obsolete; use --with-gas.
-    with_gas=yes ;;
-
-  -help | --help | --hel | --he | -h)
-    ac_init_help=long ;;
-  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
-    ac_init_help=recursive ;;
-  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
-    ac_init_help=short ;;
-
-  -host | --host | --hos | --ho)
-    ac_prev=host_alias ;;
-  -host=* | --host=* | --hos=* | --ho=*)
-    host_alias=$ac_optarg ;;
-
-  -includedir | --includedir | --includedi | --included | --include \
-  | --includ | --inclu | --incl | --inc)
-    ac_prev=includedir ;;
-  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
-  | --includ=* | --inclu=* | --incl=* | --inc=*)
-    includedir=$ac_optarg ;;
-
-  -infodir | --infodir | --infodi | --infod | --info | --inf)
-    ac_prev=infodir ;;
-  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
-    infodir=$ac_optarg ;;
-
-  -libdir | --libdir | --libdi | --libd)
-    ac_prev=libdir ;;
-  -libdir=* | --libdir=* | --libdi=* | --libd=*)
-    libdir=$ac_optarg ;;
-
-  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
-  | --libexe | --libex | --libe)
-    ac_prev=libexecdir ;;
-  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
-  | --libexe=* | --libex=* | --libe=*)
-    libexecdir=$ac_optarg ;;
-
-  -localstatedir | --localstatedir | --localstatedi | --localstated \
-  | --localstate | --localstat | --localsta | --localst \
-  | --locals | --local | --loca | --loc | --lo)
-    ac_prev=localstatedir ;;
-  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
-  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
-  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
-    localstatedir=$ac_optarg ;;
-
-  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
-    ac_prev=mandir ;;
-  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
-    mandir=$ac_optarg ;;
-
-  -nfp | --nfp | --nf)
-    # Obsolete; use --without-fp.
-    with_fp=no ;;
-
-  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
-  | --no-cr | --no-c | -n)
-    no_create=yes ;;
-
-  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
-  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
-    no_recursion=yes ;;
-
-  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
-  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
-  | --oldin | --oldi | --old | --ol | --o)
-    ac_prev=oldincludedir ;;
-  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
-  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
-  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
-    oldincludedir=$ac_optarg ;;
-
-  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
-    ac_prev=prefix ;;
-  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
-    prefix=$ac_optarg ;;
-
-  -program-prefix | --program-prefix | --program-prefi | --program-pref \
-  | --program-pre | --program-pr | --program-p)
-    ac_prev=program_prefix ;;
-  -program-prefix=* | --program-prefix=* | --program-prefi=* \
-  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
-    program_prefix=$ac_optarg ;;
-
-  -program-suffix | --program-suffix | --program-suffi | --program-suff \
-  | --program-suf | --program-su | --program-s)
-    ac_prev=program_suffix ;;
-  -program-suffix=* | --program-suffix=* | --program-suffi=* \
-  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
-    program_suffix=$ac_optarg ;;
-
-  -program-transform-name | --program-transform-name \
-  | --program-transform-nam | --program-transform-na \
-  | --program-transform-n | --program-transform- \
-  | --program-transform | --program-transfor \
-  | --program-transfo | --program-transf \
-  | --program-trans | --program-tran \
-  | --progr-tra | --program-tr | --program-t)
-    ac_prev=program_transform_name ;;
-  -program-transform-name=* | --program-transform-name=* \
-  | --program-transform-nam=* | --program-transform-na=* \
-  | --program-transform-n=* | --program-transform-=* \
-  | --program-transform=* | --program-transfor=* \
-  | --program-transfo=* | --program-transf=* \
-  | --program-trans=* | --program-tran=* \
-  | --progr-tra=* | --program-tr=* | --program-t=*)
-    program_transform_name=$ac_optarg ;;
-
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil)
-    silent=yes ;;
-
-  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
-    ac_prev=sbindir ;;
-  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
-  | --sbi=* | --sb=*)
-    sbindir=$ac_optarg ;;
-
-  -sharedstatedir | --sharedstatedir | --sharedstatedi \
-  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
-  | --sharedst | --shareds | --shared | --share | --shar \
-  | --sha | --sh)
-    ac_prev=sharedstatedir ;;
-  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
-  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
-  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
-  | --sha=* | --sh=*)
-    sharedstatedir=$ac_optarg ;;
-
-  -site | --site | --sit)
-    ac_prev=site ;;
-  -site=* | --site=* | --sit=*)
-    site=$ac_optarg ;;
-
-  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
-    ac_prev=srcdir ;;
-  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
-    srcdir=$ac_optarg ;;
-
-  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
-  | --syscon | --sysco | --sysc | --sys | --sy)
-    ac_prev=sysconfdir ;;
-  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
-  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
-    sysconfdir=$ac_optarg ;;
-
-  -target | --target | --targe | --targ | --tar | --ta | --t)
-    ac_prev=target_alias ;;
-  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
-    target_alias=$ac_optarg ;;
-
-  -v | -verbose | --verbose | --verbos | --verbo | --verb)
-    verbose=yes ;;
-
-  -version | --version | --versio | --versi | --vers | -V)
-    ac_init_version=: ;;
-
-  -with-* | --with-*)
-    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid package name: $ac_package" >&2
-   { (exit 1); exit 1; }; }
-    ac_package=`echo $ac_package| sed 's/-/_/g'`
-    case $ac_option in
-      *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
-      *) ac_optarg=yes ;;
-    esac
-    eval "with_$ac_package='$ac_optarg'" ;;
-
-  -without-* | --without-*)
-    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid package name: $ac_package" >&2
-   { (exit 1); exit 1; }; }
-    ac_package=`echo $ac_package | sed 's/-/_/g'`
-    eval "with_$ac_package=no" ;;
-
-  --x)
-    # Obsolete; use --with-x.
-    with_x=yes ;;
-
-  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
-  | --x-incl | --x-inc | --x-in | --x-i)
-    ac_prev=x_includes ;;
-  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
-  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
-    x_includes=$ac_optarg ;;
-
-  -x-libraries | --x-libraries | --x-librarie | --x-librari \
-  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
-    ac_prev=x_libraries ;;
-  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
-  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
-    x_libraries=$ac_optarg ;;
-
-  -*) { echo "$as_me: error: unrecognized option: $ac_option
-Try \`$0 --help' for more information." >&2
-   { (exit 1); exit 1; }; }
-    ;;
-
-  *=*)
-    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
-    # Reject names that are not valid shell variable names.
-    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
-      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
-   { (exit 1); exit 1; }; }
-    ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
-    eval "$ac_envvar='$ac_optarg'"
-    export $ac_envvar ;;
-
-  *)
-    # FIXME: should be removed in autoconf 3.0.
-    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
-    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
-      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
-    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
-    ;;
-
-  esac
-done
-
-if test -n "$ac_prev"; then
-  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
-  { echo "$as_me: error: missing argument to $ac_option" >&2
-   { (exit 1); exit 1; }; }
-fi
-
-# Be sure to have absolute paths.
-for ac_var in exec_prefix prefix
-do
-  eval ac_val=$`echo $ac_var`
-  case $ac_val in
-    [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
-    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
-   { (exit 1); exit 1; }; };;
-  esac
-done
-
-# Be sure to have absolute paths.
-for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
-	      localstatedir libdir includedir oldincludedir infodir mandir
-do
-  eval ac_val=$`echo $ac_var`
-  case $ac_val in
-    [\\/$]* | ?:[\\/]* ) ;;
-    *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
-   { (exit 1); exit 1; }; };;
-  esac
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
-  if test "x$build_alias" = x; then
-    cross_compiling=maybe
-    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
-    If a cross compiler is detected then cross compile mode will be used." >&2
-  elif test "x$build_alias" != "x$host_alias"; then
-    cross_compiling=yes
-  fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
-  ac_srcdir_defaulted=yes
-  # Try the directory containing this script, then its parent.
-  ac_confdir=`(dirname "$0") 2>/dev/null ||
-$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$0" : 'X\(//\)[^/]' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X"$0" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-  srcdir=$ac_confdir
-  if test ! -r $srcdir/$ac_unique_file; then
-    srcdir=..
-  fi
-else
-  ac_srcdir_defaulted=no
-fi
-if test ! -r $srcdir/$ac_unique_file; then
-  if test "$ac_srcdir_defaulted" = yes; then
-    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
-   { (exit 1); exit 1; }; }
-  else
-    { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
-   { (exit 1); exit 1; }; }
-  fi
-fi
-(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
-  { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
-   { (exit 1); exit 1; }; }
-srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
-ac_env_build_alias_set=${build_alias+set}
-ac_env_build_alias_value=$build_alias
-ac_cv_env_build_alias_set=${build_alias+set}
-ac_cv_env_build_alias_value=$build_alias
-ac_env_host_alias_set=${host_alias+set}
-ac_env_host_alias_value=$host_alias
-ac_cv_env_host_alias_set=${host_alias+set}
-ac_cv_env_host_alias_value=$host_alias
-ac_env_target_alias_set=${target_alias+set}
-ac_env_target_alias_value=$target_alias
-ac_cv_env_target_alias_set=${target_alias+set}
-ac_cv_env_target_alias_value=$target_alias
-ac_env_CC_set=${CC+set}
-ac_env_CC_value=$CC
-ac_cv_env_CC_set=${CC+set}
-ac_cv_env_CC_value=$CC
-ac_env_CFLAGS_set=${CFLAGS+set}
-ac_env_CFLAGS_value=$CFLAGS
-ac_cv_env_CFLAGS_set=${CFLAGS+set}
-ac_cv_env_CFLAGS_value=$CFLAGS
-ac_env_LDFLAGS_set=${LDFLAGS+set}
-ac_env_LDFLAGS_value=$LDFLAGS
-ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
-ac_cv_env_LDFLAGS_value=$LDFLAGS
-ac_env_CPPFLAGS_set=${CPPFLAGS+set}
-ac_env_CPPFLAGS_value=$CPPFLAGS
-ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
-ac_cv_env_CPPFLAGS_value=$CPPFLAGS
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
-  # Omit some internal or obsolete options to make the list less imposing.
-  # This message is too long to be a string in the A/UX 3.1 sh.
-  cat <<_ACEOF
-\`configure' configures this package to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE.  See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
-  -h, --help              display this help and exit
-      --help=short        display options specific to this package
-      --help=recursive    display the short help of all the included packages
-  -V, --version           display version information and exit
-  -q, --quiet, --silent   do not print \`checking...' messages
-      --cache-file=FILE   cache test results in FILE [disabled]
-  -C, --config-cache      alias for \`--cache-file=config.cache'
-  -n, --no-create         do not create output files
-      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
-
-_ACEOF
-
-  cat <<_ACEOF
-Installation directories:
-  --prefix=PREFIX         install architecture-independent files in PREFIX
-			  [$ac_default_prefix]
-  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
-			  [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
-  --bindir=DIR           user executables [EPREFIX/bin]
-  --sbindir=DIR          system admin executables [EPREFIX/sbin]
-  --libexecdir=DIR       program executables [EPREFIX/libexec]
-  --datadir=DIR          read-only architecture-independent data [PREFIX/share]
-  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
-  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
-  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
-  --libdir=DIR           object code libraries [EPREFIX/lib]
-  --includedir=DIR       C header files [PREFIX/include]
-  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
-  --infodir=DIR          info documentation [PREFIX/info]
-  --mandir=DIR           man documentation [PREFIX/man]
-_ACEOF
-
-  cat <<\_ACEOF
-
-System types:
-  --build=BUILD     configure for building on BUILD [guessed]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
-
-  cat <<\_ACEOF
-
-Optional Features:
-  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
-  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
-  --enable-debug          Enable a debug version of hs-plugins to be built
-  --enable-hsx          Enable a debug version of hs-plugins to be built
-
-Optional Packages:
-  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
-  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
-  --with-ghc=<ghc>        use a specific Haskell compiler
-
-Some influential environment variables:
-  CC          C compiler command
-  CFLAGS      C compiler flags
-  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
-              nonstandard directory <lib dir>
-  CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
-              headers in a nonstandard directory <include dir>
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-_ACEOF
-fi
-
-if test "$ac_init_help" = "recursive"; then
-  # If there are subdirs, report their specific --help.
-  ac_popdir=`pwd`
-  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
-    test -d $ac_dir || continue
-    ac_builddir=.
-
-if test "$ac_dir" != .; then
-  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
-  # A "../" for each directory in $ac_dir_suffix.
-  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
-  ac_dir_suffix= ac_top_builddir=
-fi
-
-case $srcdir in
-  .)  # No --srcdir option.  We are building in place.
-    ac_srcdir=.
-    if test -z "$ac_top_builddir"; then
-       ac_top_srcdir=.
-    else
-       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
-    fi ;;
-  [\\/]* | ?:[\\/]* )  # Absolute path.
-    ac_srcdir=$srcdir$ac_dir_suffix;
-    ac_top_srcdir=$srcdir ;;
-  *) # Relative path.
-    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
-  case "$ac_dir" in
-  .) ac_abs_builddir=`pwd`;;
-  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
-  *) ac_abs_builddir=`pwd`/"$ac_dir";;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
-  case ${ac_top_builddir}. in
-  .) ac_abs_top_builddir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
-  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
-  case $ac_srcdir in
-  .) ac_abs_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
-  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
-  case $ac_top_srcdir in
-  .) ac_abs_top_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
-  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
-  esac;;
-esac
-
-    cd $ac_dir
-    # Check for guested configure; otherwise get Cygnus style configure.
-    if test -f $ac_srcdir/configure.gnu; then
-      echo
-      $SHELL $ac_srcdir/configure.gnu  --help=recursive
-    elif test -f $ac_srcdir/configure; then
-      echo
-      $SHELL $ac_srcdir/configure  --help=recursive
-    elif test -f $ac_srcdir/configure.ac ||
-	   test -f $ac_srcdir/configure.in; then
-      echo
-      $ac_configure --help
-    else
-      echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
-    fi
-    cd $ac_popdir
-  done
-fi
-
-test -n "$ac_init_help" && exit 0
-if $ac_init_version; then
-  cat <<\_ACEOF
-
-Copyright (C) 2003 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
-  exit 0
-fi
-exec 5>config.log
-cat >&5 <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by $as_me, which was
-generated by GNU Autoconf 2.59.  Invocation command line was
-
-  $ $0 $@
-
-_ACEOF
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
-
-/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
-/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
-/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
-/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
-/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  echo "PATH: $as_dir"
-done
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_sep=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
-  for ac_arg
-  do
-    case $ac_arg in
-    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
-    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-    | -silent | --silent | --silen | --sile | --sil)
-      continue ;;
-    *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
-      ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
-    esac
-    case $ac_pass in
-    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
-    2)
-      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
-      if test $ac_must_keep_next = true; then
-	ac_must_keep_next=false # Got value, back to normal.
-      else
-	case $ac_arg in
-	  *=* | --config-cache | -C | -disable-* | --disable-* \
-	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
-	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
-	  | -with-* | --with-* | -without-* | --without-* | --x)
-	    case "$ac_configure_args0 " in
-	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
-	    esac
-	    ;;
-	  -* ) ac_must_keep_next=true ;;
-	esac
-      fi
-      ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
-      # Get rid of the leading space.
-      ac_sep=" "
-      ;;
-    esac
-  done
-done
-$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
-$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log.  We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Be sure not to use single quotes in there, as some shells,
-# such as our DU 5.0 friend, will then `close' the trap.
-trap 'exit_status=$?
-  # Save into config.log some information that might help in debugging.
-  {
-    echo
-
-    cat <<\_ASBOX
-## ---------------- ##
-## Cache variables. ##
-## ---------------- ##
-_ASBOX
-    echo
-    # The following way of writing the cache mishandles newlines in values,
-{
-  (set) 2>&1 |
-    case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
-    *ac_space=\ *)
-      sed -n \
-	"s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
-	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
-      ;;
-    *)
-      sed -n \
-	"s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
-      ;;
-    esac;
-}
-    echo
-
-    cat <<\_ASBOX
-## ----------------- ##
-## Output variables. ##
-## ----------------- ##
-_ASBOX
-    echo
-    for ac_var in $ac_subst_vars
-    do
-      eval ac_val=$`echo $ac_var`
-      echo "$ac_var='"'"'$ac_val'"'"'"
-    done | sort
-    echo
-
-    if test -n "$ac_subst_files"; then
-      cat <<\_ASBOX
-## ------------- ##
-## Output files. ##
-## ------------- ##
-_ASBOX
-      echo
-      for ac_var in $ac_subst_files
-      do
-	eval ac_val=$`echo $ac_var`
-	echo "$ac_var='"'"'$ac_val'"'"'"
-      done | sort
-      echo
-    fi
-
-    if test -s confdefs.h; then
-      cat <<\_ASBOX
-## ----------- ##
-## confdefs.h. ##
-## ----------- ##
-_ASBOX
-      echo
-      sed "/^$/d" confdefs.h | sort
-      echo
-    fi
-    test "$ac_signal" != 0 &&
-      echo "$as_me: caught signal $ac_signal"
-    echo "$as_me: exit $exit_status"
-  } >&5
-  rm -f core *.core &&
-  rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
-    exit $exit_status
-     ' 0
-for ac_signal in 1 2 13 15; do
-  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo >confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
-  if test "x$prefix" != xNONE; then
-    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
-  else
-    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
-  fi
-fi
-for ac_site_file in $CONFIG_SITE; do
-  if test -r "$ac_site_file"; then
-    { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
-echo "$as_me: loading site script $ac_site_file" >&6;}
-    sed 's/^/| /' "$ac_site_file" >&5
-    . "$ac_site_file"
-  fi
-done
-
-if test -r "$cache_file"; then
-  # Some versions of bash will fail to source /dev/null (special
-  # files actually), so we avoid doing that.
-  if test -f "$cache_file"; then
-    { echo "$as_me:$LINENO: loading cache $cache_file" >&5
-echo "$as_me: loading cache $cache_file" >&6;}
-    case $cache_file in
-      [\\/]* | ?:[\\/]* ) . $cache_file;;
-      *)                      . ./$cache_file;;
-    esac
-  fi
-else
-  { echo "$as_me:$LINENO: creating cache $cache_file" >&5
-echo "$as_me: creating cache $cache_file" >&6;}
-  >$cache_file
-fi
-
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in `(set) 2>&1 |
-	       sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
-  eval ac_old_set=\$ac_cv_env_${ac_var}_set
-  eval ac_new_set=\$ac_env_${ac_var}_set
-  eval ac_old_val="\$ac_cv_env_${ac_var}_value"
-  eval ac_new_val="\$ac_env_${ac_var}_value"
-  case $ac_old_set,$ac_new_set in
-    set,)
-      { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
-      ac_cache_corrupted=: ;;
-    ,set)
-      { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
-echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
-      ac_cache_corrupted=: ;;
-    ,);;
-    *)
-      if test "x$ac_old_val" != "x$ac_new_val"; then
-	{ echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
-echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
-	{ echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
-echo "$as_me:   former value:  $ac_old_val" >&2;}
-	{ echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
-echo "$as_me:   current value: $ac_new_val" >&2;}
-	ac_cache_corrupted=:
-      fi;;
-  esac
-  # Pass precious variables to config.status.
-  if test "$ac_new_set" = set; then
-    case $ac_new_val in
-    *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
-      ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
-    *) ac_arg=$ac_var=$ac_new_val ;;
-    esac
-    case " $ac_configure_args " in
-      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
-      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
-    esac
-  fi
-done
-if $ac_cache_corrupted; then
-  { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
-echo "$as_me: error: changes in the environment can compromise the build" >&2;}
-  { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
-echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Prepare to generate the config.h.in file
-          ac_config_headers="$ac_config_headers config.h"
-
-
-# untested on earlier than 2.52, but it won't work anyway
-
-
-# Find out what type of system we're running on
-ac_aux_dir=
-for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
-  if test -f $ac_dir/install-sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install-sh -c"
-    break
-  elif test -f $ac_dir/install.sh; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/install.sh -c"
-    break
-  elif test -f $ac_dir/shtool; then
-    ac_aux_dir=$ac_dir
-    ac_install_sh="$ac_aux_dir/shtool install -c"
-    break
-  fi
-done
-if test -z "$ac_aux_dir"; then
-  { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
-echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"
-ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
-
-# Make sure we can run config.sub.
-$ac_config_sub sun4 >/dev/null 2>&1 ||
-  { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
-echo "$as_me: error: cannot run $ac_config_sub" >&2;}
-   { (exit 1); exit 1; }; }
-
-echo "$as_me:$LINENO: checking build system type" >&5
-echo $ECHO_N "checking build system type... $ECHO_C" >&6
-if test "${ac_cv_build+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_build_alias=$build_alias
-test -z "$ac_cv_build_alias" &&
-  ac_cv_build_alias=`$ac_config_guess`
-test -z "$ac_cv_build_alias" &&
-  { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
-echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
-   { (exit 1); exit 1; }; }
-ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
-  { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
-   { (exit 1); exit 1; }; }
-
-fi
-echo "$as_me:$LINENO: result: $ac_cv_build" >&5
-echo "${ECHO_T}$ac_cv_build" >&6
-build=$ac_cv_build
-build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-
-
-
-Platform="$build_cpu-$build_vendor-$build_os"
-
-# This isn't right for msys mingw.
-PREFIX="$prefix"
-if test "$prefix" = "NONE"
-then
-  if test "$build_os" = "cygwin"
-  then
-    PREFIX="c:/cygwin$ac_default_prefix"
-  else
-    PREFIX="$ac_default_prefix"
-  fi
-fi
-
-
-case $Platform in
-*-apple-darwin*)
-        MACOSX=yes
-
-cat >>confdefs.h <<_ACEOF
-#define MACOSX 1
-_ACEOF
-
-        LEADING_UNDERSCORE=1
-	;;
-*)
-        MACOSX=no
-        LEADING_UNDERSCORE=0
-	;;
-esac
-
-if test "$build_os" = "mingw32"
-then
-
-cat >>confdefs.h <<\_ACEOF
-#define __MINGW32__ 1
-_ACEOF
-
-  LEADING_UNDERSCORE=1
-fi
-
-if test "$build_os" = "cygwin"
-then
-
-cat >>confdefs.h <<\_ACEOF
-#define CYGWIN 1
-_ACEOF
-
-  LEADING_UNDERSCORE=1
-fi
-
-
-cat >>confdefs.h <<_ACEOF
-#define LEADING_UNDERSCORE $LEADING_UNDERSCORE
-_ACEOF
-
-
-# Find pwd, in a cygwin friendly way.
-# Suggested by: http://www.haskell.org/ghc/docs/latest/html/users_guide/ch11s04.html
-TOP=`echo "Directory.getCurrentDirectory >>= putStrLn.init.tail.show " | ghc --interactive -ignore-dot-ghci -v0 | tr -d '\r'`
-
-
-cat >>confdefs.h <<_ACEOF
-#define TOP "$TOP"
-_ACEOF
-
-
-
-# necessary tools
-
-# allow user supplied haskell compiler
-
-# Check whether --with-ghc or --without-ghc was given.
-if test "${with_ghc+set}" = set; then
-  withval="$with_ghc"
-   GHC="$withval"
-    if test ! -f "$GHC" ; then
-       { { echo "$as_me:$LINENO: error: $GHC not found. You need GHC to build this project" >&5
-echo "$as_me: error: $GHC not found. You need GHC to build this project" >&2;}
-   { (exit 1); exit 1; }; }
-    fi
-
-else
-   # Extract the first word of "ghc", so it can be a program name with args.
-set dummy ghc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_GHC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$GHC"; then
-  ac_cv_prog_GHC="$GHC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_GHC="ghc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-fi
-fi
-GHC=$ac_cv_prog_GHC
-if test -n "$GHC"; then
-  echo "$as_me:$LINENO: result: $GHC" >&5
-echo "${ECHO_T}$GHC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-    if test -z "$GHC" ; then
-       { { echo "$as_me:$LINENO: error: You need GHC to build this project" >&5
-echo "$as_me: error: You need GHC to build this project" >&2;}
-   { (exit 1); exit 1; }; }
-    fi
-
-
-fi;
-
-cat >>confdefs.h <<_ACEOF
-#define WITH_GHC "$GHC"
-_ACEOF
-
-
-
-# Work out value of __GLASGOW_HASKELL__
-if test -n "$GHC" ; then
- echo "$as_me:$LINENO: checking for value of __GLASGOW_HASKELL__" >&5
-echo $ECHO_N "checking for value of __GLASGOW_HASKELL__... $ECHO_C" >&6
- echo "main = print __GLASGOW_HASKELL__" > t.hs
- GLASGOW_HASKELL=`echo 'main' | "$GHC" --interactive -ignore-dot-ghci -v0 -cpp t.hs`
- rm t.hs
- echo "$as_me:$LINENO: result: $GLASGOW_HASKELL" >&5
-echo "${ECHO_T}$GLASGOW_HASKELL" >&6
-fi
-
-
-# find path to GHC libs, for runtime_loader
-if test -n "$GHC" ; then
-    echo "$as_me:$LINENO: checking for ghc library directory" >&5
-echo $ECHO_N "checking for ghc library directory... $ECHO_C" >&6
-    GHC_LIB_PATH=`$GHC --print-libdir | tr -d '\r'`
-    echo "$as_me:$LINENO: result: $GHC_LIB_PATH" >&5
-echo "${ECHO_T}$GHC_LIB_PATH" >&6
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define GHC_LIB_PATH "$GHC_LIB_PATH"
-_ACEOF
-
-
-# Allow a debugging version of hs-plugins to be built
-# Check whether --enable-debug or --disable-debug was given.
-if test "${enable_debug+set}" = set; then
-  enableval="$enable_debug"
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEBUG 1
-_ACEOF
-
-else
-   :
-fi;
-
-# Allow a debugging version of hs-plugins to be built
-# Check whether --enable-hsx or --disable-hsx was given.
-if test "${enable_hsx+set}" = set; then
-  enableval="$enable_hsx"
-   HASKELL_SRC=haskell-src-exts ;
-
-cat >>confdefs.h <<_ACEOF
-#define WITH_HSX 1
-_ACEOF
-
-else
-   HASKELL_SRC=haskell-src
-fi;
-
-
-
-#AC_CHECK_PROG(TEX,tex,tex)
-#if test -z "$TEX" ; then
-#    AC_MSG_WARN(tex is needed to build some of the documentation)
-#fi
-#AC_CHECK_PROG(TEX2PAGE,tex2page,tex2page)
-#if test -z "$TEX2PAGE" ; then
-#    AC_MSG_WARN(tex2page is needed to build some of the documentation
-#		    http://www.ccs.neu.edu/home/dorai/tex2page/tex2page-doc.html)
-#fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_CC="${ac_tool_prefix}gcc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-fi
-if test -z "$ac_cv_prog_CC"; then
-  ac_ct_CC=$CC
-  # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_CC"; then
-  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_ac_ct_CC="gcc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
-  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-  CC=$ac_ct_CC
-else
-  CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
-  if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_CC="${ac_tool_prefix}cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-fi
-if test -z "$ac_cv_prog_CC"; then
-  ac_ct_CC=$CC
-  # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_CC"; then
-  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_ac_ct_CC="cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
-  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-  CC=$ac_ct_CC
-else
-  CC="$ac_cv_prog_CC"
-fi
-
-fi
-if test -z "$CC"; then
-  # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-  ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
-       ac_prog_rejected=yes
-       continue
-     fi
-    ac_cv_prog_CC="cc"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-if test $ac_prog_rejected = yes; then
-  # We found a bogon in the path, so make sure we never use it.
-  set dummy $ac_cv_prog_CC
-  shift
-  if test $# != 0; then
-    # We chose a different compiler from the bogus one.
-    # However, it has the same basename, so the bogon will be chosen
-    # first if we set CC to just the basename; use the full file name.
-    shift
-    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
-  fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-fi
-if test -z "$CC"; then
-  if test -n "$ac_tool_prefix"; then
-  for ac_prog in cl
-  do
-    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CC"; then
-  ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
-  echo "$as_me:$LINENO: result: $CC" >&5
-echo "${ECHO_T}$CC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-    test -n "$CC" && break
-  done
-fi
-if test -z "$CC"; then
-  ac_ct_CC=$CC
-  for ac_prog in cl
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
-if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_CC"; then
-  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
-    ac_cv_prog_ac_ct_CC="$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
-  echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
-echo "${ECHO_T}$ac_ct_CC" >&6
-else
-  echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6
-fi
-
-  test -n "$ac_ct_CC" && break
-done
-
-  CC=$ac_ct_CC
-fi
-
-fi
-
-
-test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
-See \`config.log' for more details." >&5
-echo "$as_me: error: no acceptable C compiler found in \$PATH
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-
-# Provide some information about the compiler.
-echo "$as_me:$LINENO:" \
-     "checking for C compiler version" >&5
-ac_compiler=`set X $ac_compile; echo $2`
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
-  (eval $ac_compiler --version </dev/null >&5) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
-  (eval $ac_compiler -v </dev/null >&5) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
-  (eval $ac_compiler -V </dev/null >&5) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
-echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
-ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
-  (eval $ac_link_default) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  # Find the output, starting from the most likely.  This scheme is
-# not robust to junk in `.', hence go to wildcards (a.*) only as a last
-# resort.
-
-# Be careful to initialize this variable, since it used to be cached.
-# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
-ac_cv_exeext=
-# b.out is created by i960 compilers.
-for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
-do
-  test -f "$ac_file" || continue
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
-	;;
-    conftest.$ac_ext )
-	# This is the source file.
-	;;
-    [ab].out )
-	# We found the default executable, but exeext='' is most
-	# certainly right.
-	break;;
-    *.* )
-	ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	# FIXME: I believe we export ac_cv_exeext for Libtool,
-	# but it would be cool to find out if it's true.  Does anybody
-	# maintain Libtool? --akim.
-	export ac_cv_exeext
-	break;;
-    * )
-	break;;
-  esac
-done
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
-See \`config.log' for more details." >&5
-echo "$as_me: error: C compiler cannot create executables
-See \`config.log' for more details." >&2;}
-   { (exit 77); exit 77; }; }
-fi
-
-ac_exeext=$ac_cv_exeext
-echo "$as_me:$LINENO: result: $ac_file" >&5
-echo "${ECHO_T}$ac_file" >&6
-
-# Check the compiler produces executables we can run.  If not, either
-# the compiler is broken, or we cross compile.
-echo "$as_me:$LINENO: checking whether the C compiler works" >&5
-echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
-# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
-# If not cross compiling, check that we can run a simple program.
-if test "$cross_compiling" != yes; then
-  if { ac_try='./$ac_file'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-    cross_compiling=no
-  else
-    if test "$cross_compiling" = maybe; then
-	cross_compiling=yes
-    else
-	{ { echo "$as_me:$LINENO: error: cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-    fi
-  fi
-fi
-echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6
-
-rm -f a.out a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-# Check the compiler produces executables we can run.  If not, either
-# the compiler is broken, or we cross compile.
-echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
-echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
-echo "$as_me:$LINENO: result: $cross_compiling" >&5
-echo "${ECHO_T}$cross_compiling" >&6
-
-echo "$as_me:$LINENO: checking for suffix of executables" >&5
-echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
-  test -f "$ac_file" || continue
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
-    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
-	  export ac_cv_exeext
-	  break;;
-    * ) break;;
-  esac
-done
-else
-  { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-rm -f conftest$ac_cv_exeext
-echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
-echo "${ECHO_T}$ac_cv_exeext" >&6
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-echo "$as_me:$LINENO: checking for suffix of object files" >&5
-echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
-if test "${ac_cv_objext+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; then
-  for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
-  case $ac_file in
-    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
-    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
-       break;;
-  esac
-done
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." >&5
-echo "$as_me: error: cannot compute suffix of object files: cannot compile
-See \`config.log' for more details." >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
-echo "${ECHO_T}$ac_cv_objext" >&6
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
-echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
-if test "${ac_cv_c_compiler_gnu+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-#ifndef __GNUC__
-       choke me
-#endif
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"
-			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_compiler_gnu=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-ac_compiler_gnu=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
-echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
-GCC=`test $ac_compiler_gnu = yes && echo yes`
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-CFLAGS="-g"
-echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
-echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
-if test "${ac_cv_prog_cc_g+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"
-			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_cv_prog_cc_g=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-ac_cv_prog_cc_g=no
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
-if test "$ac_test_CFLAGS" = set; then
-  CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
-  if test "$GCC" = yes; then
-    CFLAGS="-g -O2"
-  else
-    CFLAGS="-g"
-  fi
-else
-  if test "$GCC" = yes; then
-    CFLAGS="-O2"
-  else
-    CFLAGS=
-  fi
-fi
-echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
-echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
-if test "${ac_cv_prog_cc_stdc+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_prog_cc_stdc=no
-ac_save_CC=$CC
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <stdarg.h>
-#include <stdio.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
-     char **p;
-     int i;
-{
-  return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
-  char *s;
-  va_list v;
-  va_start (v,p);
-  s = g (p, va_arg (v,int));
-  va_end (v);
-  return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
-   function prototypes and stuff, but not '\xHH' hex character constants.
-   These don't provoke an error unfortunately, instead are silently treated
-   as 'x'.  The following induces an error, until -std1 is added to get
-   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
-   array size at least.  It's necessary to write '\x00'==0 to get something
-   that's true only with -std1.  */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
-  ;
-  return 0;
-}
-_ACEOF
-# Don't try gcc -ansi; that turns off useful extensions and
-# breaks some systems' header files.
-# AIX			-qlanglvl=ansi
-# Ultrix and OSF/1	-std1
-# HP-UX 10.20 and later	-Ae
-# HP-UX older versions	-Aa -D_HPUX_SOURCE
-# SVR4			-Xc -D__EXTENSIONS__
-for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
-  CC="$ac_save_CC $ac_arg"
-  rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"
-			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_cv_prog_cc_stdc=$ac_arg
-break
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext
-done
-rm -f conftest.$ac_ext conftest.$ac_objext
-CC=$ac_save_CC
-
-fi
-
-case "x$ac_cv_prog_cc_stdc" in
-  x|xno)
-    echo "$as_me:$LINENO: result: none needed" >&5
-echo "${ECHO_T}none needed" >&6 ;;
-  *)
-    echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
-echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
-    CC="$CC $ac_cv_prog_cc_stdc" ;;
-esac
-
-# Some people use a C++ compiler to compile C.  Since we use `exit',
-# in C++ we need to declare it.  In case someone uses the same compiler
-# for both compiling C and C++ we need to have the C++ compiler decide
-# the declaration of exit, since it's the most demanding environment.
-cat >conftest.$ac_ext <<_ACEOF
-#ifndef __cplusplus
-  choke me
-#endif
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"
-			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  for ac_declaration in \
-   '' \
-   'extern "C" void std::exit (int) throw (); using std::exit;' \
-   'extern "C" void std::exit (int); using std::exit;' \
-   'extern "C" void exit (int) throw ();' \
-   'extern "C" void exit (int);' \
-   'void exit (int);'
-do
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_declaration
-#include <stdlib.h>
-int
-main ()
-{
-exit (42);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"
-			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  :
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-continue
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_declaration
-int
-main ()
-{
-exit (42);
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
-  (eval $ac_compile) 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"
-			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest.$ac_objext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  break
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-rm -f conftest*
-if test -n "$ac_declaration"; then
-  echo '#ifdef __cplusplus' >>confdefs.h
-  echo $ac_declaration      >>confdefs.h
-  echo '#endif'             >>confdefs.h
-fi
-
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-fi
-rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-for ac_func in arc4random
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
-if eval "test \"\${$as_ac_var+set}\" = set"; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $ac_func
-
-/* Override any gcc2 internal prototype to avoid an error.  */
-#ifdef __cplusplus
-extern "C"
-{
-#endif
-/* We use char because int might match the return type of a gcc2
-   builtin and then its argument prototype would still apply.  */
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-char (*f) () = $ac_func;
-#endif
-#ifdef __cplusplus
-}
-#endif
-
-int
-main ()
-{
-return f != $ac_func;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
-  (eval $ac_link) 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } &&
-	 { ac_try='test -z "$ac_c_werror_flag"
-			 || test ! -s conftest.err'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; } &&
-	 { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
-  (eval $ac_try) 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  eval "$as_ac_var=yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-eval "$as_ac_var=no"
-fi
-rm -f conftest.err conftest.$ac_objext \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
-echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
-if test `eval echo '${'$as_ac_var'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-
-# Find a good install program.  We prefer a C program (faster),
-# so one script is as good as another.  But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
-echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
-if test -z "$INSTALL"; then
-if test "${ac_cv_path_install+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in
-  ./ | .// | /cC/* | \
-  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
-  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
-  /usr/ucb/* ) ;;
-  *)
-    # OSF1 and SCO ODT 3.0 have their own names for install.
-    # Don't use installbsd from OSF since it installs stuff as root
-    # by default.
-    for ac_prog in ginstall scoinst install; do
-      for ac_exec_ext in '' $ac_executable_extensions; do
-	if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
-	  if test $ac_prog = install &&
-	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
-	    # AIX install.  It has an incompatible calling convention.
-	    :
-	  elif test $ac_prog = install &&
-	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
-	    # program-specific install script used by HP pwplus--don't use.
-	    :
-	  else
-	    ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
-	    break 3
-	  fi
-	fi
-      done
-    done
-    ;;
-esac
-done
-
-
-fi
-  if test "${ac_cv_path_install+set}" = set; then
-    INSTALL=$ac_cv_path_install
-  else
-    # As a last resort, use the slow shell script.  We don't cache a
-    # path for INSTALL within a source directory, because that will
-    # break other packages using the cache if that directory is
-    # removed, or if the path is relative.
-    INSTALL=$ac_install_sh
-  fi
-fi
-echo "$as_me:$LINENO: result: $INSTALL" >&5
-echo "${ECHO_T}$INSTALL" >&6
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-
-# System.Process uses cmd or command.com shell on Windows, doen't use Cygwin or MSYS shell
-                              ac_config_files="$ac_config_files config.mk testsuite/makewith/io/TestIO.conf testsuite/makewith/unsafeio/Unsafe.conf"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems.  If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-{
-  (set) 2>&1 |
-    case `(ac_space=' '; set | grep ac_space) 2>&1` in
-    *ac_space=\ *)
-      # `set' does not quote correctly, so add quotes (double-quote
-      # substitution turns \\\\ into \\, and sed turns \\ into \).
-      sed -n \
-	"s/'/'\\\\''/g;
-	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
-      ;;
-    *)
-      # `set' quotes correctly as required by POSIX, so do not add quotes.
-      sed -n \
-	"s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
-      ;;
-    esac;
-} |
-  sed '
-     t clear
-     : clear
-     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
-     t end
-     /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
-     : end' >>confcache
-if diff $cache_file confcache >/dev/null 2>&1; then :; else
-  if test -w $cache_file; then
-    test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
-    cat confcache >$cache_file
-  else
-    echo "not updating unwritable cache $cache_file"
-  fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# VPATH may cause trouble with some makes, so we remove $(srcdir),
-# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
-  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
-s/:*\$(srcdir):*/:/;
-s/:*\${srcdir}:*/:/;
-s/:*@srcdir@:*/:/;
-s/^\([^=]*=[	 ]*\):*/\1/;
-s/:*$//;
-s/^[^=]*=[	 ]*$//;
-}'
-fi
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
-  # 1. Remove the extension, and $U if already installed.
-  ac_i=`echo "$ac_i" |
-	 sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
-  # 2. Add them.
-  ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
-  ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-
-: ${CONFIG_STATUS=./config.status}
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
-echo "$as_me: creating $CONFIG_STATUS" >&6;}
-cat >$CONFIG_STATUS <<_ACEOF
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-SHELL=\${CONFIG_SHELL-$SHELL}
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-## --------------------- ##
-## M4sh Initialization.  ##
-## --------------------- ##
-
-# Be Bourne compatible
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
-  emulate sh
-  NULLCMD=:
-  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
-  # is contrary to our usage.  Disable this feature.
-  alias -g '${1+"$@"}'='"$@"'
-elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
-  set -o posix
-fi
-DUALCASE=1; export DUALCASE # for MKS sh
-
-# Support unset when possible.
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
-  as_unset=unset
-else
-  as_unset=false
-fi
-
-
-# Work around bugs in pre-3.0 UWIN ksh.
-$as_unset ENV MAIL MAILPATH
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-for as_var in \
-  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
-  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
-  LC_TELEPHONE LC_TIME
-do
-  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
-    eval $as_var=C; export $as_var
-  else
-    $as_unset $as_var
-  fi
-done
-
-# Required to use basename.
-if expr a : '\(a\)' >/dev/null 2>&1; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
-  as_basename=basename
-else
-  as_basename=false
-fi
-
-
-# Name of the executable.
-as_me=`$as_basename "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
-	 X"$0" : 'X\(//\)$' \| \
-	 X"$0" : 'X\(/\)$' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X/"$0" |
-    sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
-  	  /^X\/\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\/\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-
-
-# PATH needs CR, and LINENO needs CR and PATH.
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
-  echo "#! /bin/sh" >conf$$.sh
-  echo  "exit 0"   >>conf$$.sh
-  chmod +x conf$$.sh
-  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
-    PATH_SEPARATOR=';'
-  else
-    PATH_SEPARATOR=:
-  fi
-  rm -f conf$$.sh
-fi
-
-
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2"  || {
-  # Find who we are.  Look in the path if we contain no path at all
-  # relative or not.
-  case $0 in
-    *[\\/]* ) as_myself=$0 ;;
-    *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
-done
-
-       ;;
-  esac
-  # We did not find ourselves, most probably we were run as `sh COMMAND'
-  # in which case we are not to be found in the path.
-  if test "x$as_myself" = x; then
-    as_myself=$0
-  fi
-  if test ! -f "$as_myself"; then
-    { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
-echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
-   { (exit 1); exit 1; }; }
-  fi
-  case $CONFIG_SHELL in
-  '')
-    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for as_base in sh bash ksh sh5; do
-	 case $as_dir in
-	 /*)
-	   if ("$as_dir/$as_base" -c '
-  as_lineno_1=$LINENO
-  as_lineno_2=$LINENO
-  as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
-  test "x$as_lineno_1" != "x$as_lineno_2" &&
-  test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
-	     $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
-	     $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
-	     CONFIG_SHELL=$as_dir/$as_base
-	     export CONFIG_SHELL
-	     exec "$CONFIG_SHELL" "$0" ${1+"$@"}
-	   fi;;
-	 esac
-       done
-done
-;;
-  esac
-
-  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
-  # uniformly replaced by the line number.  The first 'sed' inserts a
-  # line-number line before each line; the second 'sed' does the real
-  # work.  The second script uses 'N' to pair each line-number line
-  # with the numbered line, and appends trailing '-' during
-  # substitution so that $LINENO is not a special case at line end.
-  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
-  # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
-  sed '=' <$as_myself |
-    sed '
-      N
-      s,$,-,
-      : loop
-      s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
-      t loop
-      s,-$,,
-      s,^['$as_cr_digits']*\n,,
-    ' >$as_me.lineno &&
-  chmod +x $as_me.lineno ||
-    { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
-echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
-   { (exit 1); exit 1; }; }
-
-  # Don't try to exec as it changes $[0], causing all sort of problems
-  # (the dirname of $[0] is not the place where we might find the
-  # original and so on.  Autoconf is especially sensible to this).
-  . ./$as_me.lineno
-  # Exit status is that of the last command.
-  exit
-}
-
-
-case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
-  *c*,-n*) ECHO_N= ECHO_C='
-' ECHO_T='	' ;;
-  *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
-  *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
-esac
-
-if expr a : '\(a\)' >/dev/null 2>&1; then
-  as_expr=expr
-else
-  as_expr=false
-fi
-
-rm -f conf$$ conf$$.exe conf$$.file
-echo >conf$$.file
-if ln -s conf$$.file conf$$ 2>/dev/null; then
-  # We could just check for DJGPP; but this test a) works b) is more generic
-  # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
-  if test -f conf$$.exe; then
-    # Don't use ln at all; we don't have any links
-    as_ln_s='cp -p'
-  else
-    as_ln_s='ln -s'
-  fi
-elif ln conf$$.file conf$$ 2>/dev/null; then
-  as_ln_s=ln
-else
-  as_ln_s='cp -p'
-fi
-rm -f conf$$ conf$$.exe conf$$.file
-
-if mkdir -p . 2>/dev/null; then
-  as_mkdir_p=:
-else
-  test -d ./-p && rmdir ./-p
-  as_mkdir_p=false
-fi
-
-as_executable_p="test -f"
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-# IFS
-# We need space, tab and new line, in precisely that order.
-as_nl='
-'
-IFS=" 	$as_nl"
-
-# CDPATH.
-$as_unset CDPATH
-
-exec 6>&1
-
-# Open the log real soon, to keep \$[0] and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.  Logging --version etc. is OK.
-exec 5>>config.log
-{
-  echo
-  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
-} >&5
-cat >&5 <<_CSEOF
-
-This file was extended by $as_me, which was
-generated by GNU Autoconf 2.59.  Invocation command line was
-
-  CONFIG_FILES    = $CONFIG_FILES
-  CONFIG_HEADERS  = $CONFIG_HEADERS
-  CONFIG_LINKS    = $CONFIG_LINKS
-  CONFIG_COMMANDS = $CONFIG_COMMANDS
-  $ $0 $@
-
-_CSEOF
-echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
-echo >&5
-_ACEOF
-
-# Files that config.status was made for.
-if test -n "$ac_config_files"; then
-  echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_headers"; then
-  echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_links"; then
-  echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
-fi
-
-if test -n "$ac_config_commands"; then
-  echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-
-ac_cs_usage="\
-\`$as_me' instantiates files from templates according to the
-current configuration.
-
-Usage: $0 [OPTIONS] [FILE]...
-
-  -h, --help       print this help, then exit
-  -V, --version    print version number, then exit
-  -q, --quiet      do not print progress messages
-  -d, --debug      don't remove temporary files
-      --recheck    update $as_me by reconfiguring in the same conditions
-  --file=FILE[:TEMPLATE]
-		   instantiate the configuration file FILE
-  --header=FILE[:TEMPLATE]
-		   instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Report bugs to <bug-autoconf@gnu.org>."
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-ac_cs_version="\\
-config.status
-configured by $0, generated by GNU Autoconf 2.59,
-  with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
-
-Copyright (C) 2003 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-srcdir=$srcdir
-INSTALL="$INSTALL"
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-# If no file are specified by the user, then we need to provide default
-# value.  By we need to know if files were specified by the user.
-ac_need_defaults=:
-while test $# != 0
-do
-  case $1 in
-  --*=*)
-    ac_option=`expr "x$1" : 'x\([^=]*\)='`
-    ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
-    ac_shift=:
-    ;;
-  -*)
-    ac_option=$1
-    ac_optarg=$2
-    ac_shift=shift
-    ;;
-  *) # This is not an option, so the user has probably given explicit
-     # arguments.
-     ac_option=$1
-     ac_need_defaults=false;;
-  esac
-
-  case $ac_option in
-  # Handling of the options.
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
-    ac_cs_recheck=: ;;
-  --version | --vers* | -V )
-    echo "$ac_cs_version"; exit 0 ;;
-  --he | --h)
-    # Conflict between --help and --header
-    { { echo "$as_me:$LINENO: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: ambiguous option: $1
-Try \`$0 --help' for more information." >&2;}
-   { (exit 1); exit 1; }; };;
-  --help | --hel | -h )
-    echo "$ac_cs_usage"; exit 0 ;;
-  --debug | --d* | -d )
-    debug=: ;;
-  --file | --fil | --fi | --f )
-    $ac_shift
-    CONFIG_FILES="$CONFIG_FILES $ac_optarg"
-    ac_need_defaults=false;;
-  --header | --heade | --head | --hea )
-    $ac_shift
-    CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
-    ac_need_defaults=false;;
-  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
-  | -silent | --silent | --silen | --sile | --sil | --si | --s)
-    ac_cs_silent=: ;;
-
-  # This is an error.
-  -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&5
-echo "$as_me: error: unrecognized option: $1
-Try \`$0 --help' for more information." >&2;}
-   { (exit 1); exit 1; }; } ;;
-
-  *) ac_config_targets="$ac_config_targets $1" ;;
-
-  esac
-  shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
-  exec 6>/dev/null
-  ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-if \$ac_cs_recheck; then
-  echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
-  exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
-fi
-
-_ACEOF
-
-
-
-
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-for ac_config_target in $ac_config_targets
-do
-  case "$ac_config_target" in
-  # Handling of arguments.
-  "config.mk" ) CONFIG_FILES="$CONFIG_FILES config.mk" ;;
-  "testsuite/makewith/io/TestIO.conf" ) CONFIG_FILES="$CONFIG_FILES testsuite/makewith/io/TestIO.conf" ;;
-  "testsuite/makewith/unsafeio/Unsafe.conf" ) CONFIG_FILES="$CONFIG_FILES testsuite/makewith/unsafeio/Unsafe.conf" ;;
-  "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
-  *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
-echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
-   { (exit 1); exit 1; }; };;
-  esac
-done
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used.  Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
-  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
-  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
-fi
-
-# Have a temporary directory for convenience.  Make it in the build tree
-# simply because there is no reason to put it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Create a temporary directory, and hook for its removal unless debugging.
-$debug ||
-{
-  trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
-  trap '{ (exit 1); exit 1; }' 1 2 13 15
-}
-
-# Create a (secure) tmp directory for tmp files.
-
-{
-  tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
-  test -n "$tmp" && test -d "$tmp"
-}  ||
-{
-  tmp=./confstat$$-$RANDOM
-  (umask 077 && mkdir $tmp)
-} ||
-{
-   echo "$me: cannot create a temporary directory in ." >&2
-   { (exit 1); exit 1; }
-}
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<_ACEOF
-
-#
-# CONFIG_FILES section.
-#
-
-# No need to generate the scripts if there are no CONFIG_FILES.
-# This happens for instance when ./config.status config.h
-if test -n "\$CONFIG_FILES"; then
-  # Protect against being on the right side of a sed subst in config.status.
-  sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
-   s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
-s,@SHELL@,$SHELL,;t t
-s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
-s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
-s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
-s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
-s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
-s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
-s,@exec_prefix@,$exec_prefix,;t t
-s,@prefix@,$prefix,;t t
-s,@program_transform_name@,$program_transform_name,;t t
-s,@bindir@,$bindir,;t t
-s,@sbindir@,$sbindir,;t t
-s,@libexecdir@,$libexecdir,;t t
-s,@datadir@,$datadir,;t t
-s,@sysconfdir@,$sysconfdir,;t t
-s,@sharedstatedir@,$sharedstatedir,;t t
-s,@localstatedir@,$localstatedir,;t t
-s,@libdir@,$libdir,;t t
-s,@includedir@,$includedir,;t t
-s,@oldincludedir@,$oldincludedir,;t t
-s,@infodir@,$infodir,;t t
-s,@mandir@,$mandir,;t t
-s,@build_alias@,$build_alias,;t t
-s,@host_alias@,$host_alias,;t t
-s,@target_alias@,$target_alias,;t t
-s,@DEFS@,$DEFS,;t t
-s,@ECHO_C@,$ECHO_C,;t t
-s,@ECHO_N@,$ECHO_N,;t t
-s,@ECHO_T@,$ECHO_T,;t t
-s,@LIBS@,$LIBS,;t t
-s,@build@,$build,;t t
-s,@build_cpu@,$build_cpu,;t t
-s,@build_vendor@,$build_vendor,;t t
-s,@build_os@,$build_os,;t t
-s,@PREFIX@,$PREFIX,;t t
-s,@TOP@,$TOP,;t t
-s,@GHC@,$GHC,;t t
-s,@GLASGOW_HASKELL@,$GLASGOW_HASKELL,;t t
-s,@HASKELL_SRC@,$HASKELL_SRC,;t t
-s,@CC@,$CC,;t t
-s,@CFLAGS@,$CFLAGS,;t t
-s,@LDFLAGS@,$LDFLAGS,;t t
-s,@CPPFLAGS@,$CPPFLAGS,;t t
-s,@ac_ct_CC@,$ac_ct_CC,;t t
-s,@EXEEXT@,$EXEEXT,;t t
-s,@OBJEXT@,$OBJEXT,;t t
-s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
-s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
-s,@INSTALL_DATA@,$INSTALL_DATA,;t t
-s,@LIBOBJS@,$LIBOBJS,;t t
-s,@LTLIBOBJS@,$LTLIBOBJS,;t t
-CEOF
-
-_ACEOF
-
-  cat >>$CONFIG_STATUS <<\_ACEOF
-  # Split the substitutions into bite-sized pieces for seds with
-  # small command number limits, like on Digital OSF/1 and HP-UX.
-  ac_max_sed_lines=48
-  ac_sed_frag=1 # Number of current file.
-  ac_beg=1 # First line for current file.
-  ac_end=$ac_max_sed_lines # Line after last line for current file.
-  ac_more_lines=:
-  ac_sed_cmds=
-  while $ac_more_lines; do
-    if test $ac_beg -gt 1; then
-      sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
-    else
-      sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
-    fi
-    if test ! -s $tmp/subs.frag; then
-      ac_more_lines=false
-    else
-      # The purpose of the label and of the branching condition is to
-      # speed up the sed processing (if there are no `@' at all, there
-      # is no need to browse any of the substitutions).
-      # These are the two extra sed commands mentioned above.
-      (echo ':t
-  /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
-      if test -z "$ac_sed_cmds"; then
-	ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
-      else
-	ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
-      fi
-      ac_sed_frag=`expr $ac_sed_frag + 1`
-      ac_beg=$ac_end
-      ac_end=`expr $ac_end + $ac_max_sed_lines`
-    fi
-  done
-  if test -z "$ac_sed_cmds"; then
-    ac_sed_cmds=cat
-  fi
-fi # test -n "$CONFIG_FILES"
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case $ac_file in
-  - | *:- | *:-:* ) # input from stdin
-	cat >$tmp/stdin
-	ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  * )   ac_file_in=$ac_file.in ;;
-  esac
-
-  # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
-  ac_dir=`(dirname "$ac_file") 2>/dev/null ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$ac_file" : 'X\(//\)[^/]' \| \
-	 X"$ac_file" : 'X\(//\)$' \| \
-	 X"$ac_file" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X"$ac_file" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-  { if $as_mkdir_p; then
-    mkdir -p "$ac_dir"
-  else
-    as_dir="$ac_dir"
-    as_dirs=
-    while test ! -d "$as_dir"; do
-      as_dirs="$as_dir $as_dirs"
-      as_dir=`(dirname "$as_dir") 2>/dev/null ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$as_dir" : 'X\(//\)[^/]' \| \
-	 X"$as_dir" : 'X\(//\)$' \| \
-	 X"$as_dir" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X"$as_dir" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-    done
-    test ! -n "$as_dirs" || mkdir $as_dirs
-  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
-   { (exit 1); exit 1; }; }; }
-
-  ac_builddir=.
-
-if test "$ac_dir" != .; then
-  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
-  # A "../" for each directory in $ac_dir_suffix.
-  ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
-else
-  ac_dir_suffix= ac_top_builddir=
-fi
-
-case $srcdir in
-  .)  # No --srcdir option.  We are building in place.
-    ac_srcdir=.
-    if test -z "$ac_top_builddir"; then
-       ac_top_srcdir=.
-    else
-       ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
-    fi ;;
-  [\\/]* | ?:[\\/]* )  # Absolute path.
-    ac_srcdir=$srcdir$ac_dir_suffix;
-    ac_top_srcdir=$srcdir ;;
-  *) # Relative path.
-    ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
-    ac_top_srcdir=$ac_top_builddir$srcdir ;;
-esac
-
-# Do not use `cd foo && pwd` to compute absolute paths, because
-# the directories may not exist.
-case `pwd` in
-.) ac_abs_builddir="$ac_dir";;
-*)
-  case "$ac_dir" in
-  .) ac_abs_builddir=`pwd`;;
-  [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
-  *) ac_abs_builddir=`pwd`/"$ac_dir";;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_builddir=${ac_top_builddir}.;;
-*)
-  case ${ac_top_builddir}. in
-  .) ac_abs_top_builddir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
-  *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_srcdir=$ac_srcdir;;
-*)
-  case $ac_srcdir in
-  .) ac_abs_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
-  *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
-  esac;;
-esac
-case $ac_abs_builddir in
-.) ac_abs_top_srcdir=$ac_top_srcdir;;
-*)
-  case $ac_top_srcdir in
-  .) ac_abs_top_srcdir=$ac_abs_builddir;;
-  [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
-  *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
-  esac;;
-esac
-
-
-  case $INSTALL in
-  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
-  *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
-  esac
-
-  if test x"$ac_file" != x-; then
-    { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
-    rm -f "$ac_file"
-  fi
-  # Let's still pretend it is `configure' which instantiates (i.e., don't
-  # use $as_me), people would be surprised to read:
-  #    /* config.h.  Generated by config.status.  */
-  if test x"$ac_file" = x-; then
-    configure_input=
-  else
-    configure_input="$ac_file.  "
-  fi
-  configure_input=$configure_input"Generated from `echo $ac_file_in |
-				     sed 's,.*/,,'` by configure."
-
-  # First look for the input files in the build tree, otherwise in the
-  # src tree.
-  ac_file_inputs=`IFS=:
-    for f in $ac_file_in; do
-      case $f in
-      -) echo $tmp/stdin ;;
-      [\\/$]*)
-	 # Absolute (can't be DOS-style, as IFS=:)
-	 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 echo "$f";;
-      *) # Relative
-	 if test -f "$f"; then
-	   # Build tree
-	   echo "$f"
-	 elif test -f "$srcdir/$f"; then
-	   # Source tree
-	   echo "$srcdir/$f"
-	 else
-	   # /dev/null tree
-	   { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 fi;;
-      esac
-    done` || { (exit 1); exit 1; }
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF
-  sed "$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s,@configure_input@,$configure_input,;t t
-s,@srcdir@,$ac_srcdir,;t t
-s,@abs_srcdir@,$ac_abs_srcdir,;t t
-s,@top_srcdir@,$ac_top_srcdir,;t t
-s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
-s,@builddir@,$ac_builddir,;t t
-s,@abs_builddir@,$ac_abs_builddir,;t t
-s,@top_builddir@,$ac_top_builddir,;t t
-s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
-s,@INSTALL@,$ac_INSTALL,;t t
-" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
-  rm -f $tmp/stdin
-  if test x"$ac_file" != x-; then
-    mv $tmp/out $ac_file
-  else
-    cat $tmp/out
-    rm -f $tmp/out
-  fi
-
-done
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF
-
-#
-# CONFIG_HEADER section.
-#
-
-# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
-# NAME is the cpp macro being defined and VALUE is the value it is being given.
-#
-# ac_d sets the value in "#define NAME VALUE" lines.
-ac_dA='s,^\([	 ]*\)#\([	 ]*define[	 ][	 ]*\)'
-ac_dB='[	 ].*$,\1#\2'
-ac_dC=' '
-ac_dD=',;t'
-# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
-ac_uA='s,^\([	 ]*\)#\([	 ]*\)undef\([	 ][	 ]*\)'
-ac_uB='$,\1#\2define\3'
-ac_uC=' '
-ac_uD=',;t'
-
-for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
-  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
-  case $ac_file in
-  - | *:- | *:-:* ) # input from stdin
-	cat >$tmp/stdin
-	ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
-	ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
-  * )   ac_file_in=$ac_file.in ;;
-  esac
-
-  test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
-echo "$as_me: creating $ac_file" >&6;}
-
-  # First look for the input files in the build tree, otherwise in the
-  # src tree.
-  ac_file_inputs=`IFS=:
-    for f in $ac_file_in; do
-      case $f in
-      -) echo $tmp/stdin ;;
-      [\\/$]*)
-	 # Absolute (can't be DOS-style, as IFS=:)
-	 test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 # Do quote $f, to prevent DOS paths from being IFS'd.
-	 echo "$f";;
-      *) # Relative
-	 if test -f "$f"; then
-	   # Build tree
-	   echo "$f"
-	 elif test -f "$srcdir/$f"; then
-	   # Source tree
-	   echo "$srcdir/$f"
-	 else
-	   # /dev/null tree
-	   { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
-echo "$as_me: error: cannot find input file: $f" >&2;}
-   { (exit 1); exit 1; }; }
-	 fi;;
-      esac
-    done` || { (exit 1); exit 1; }
-  # Remove the trailing spaces.
-  sed 's/[	 ]*$//' $ac_file_inputs >$tmp/in
-
-_ACEOF
-
-# Transform confdefs.h into two sed scripts, `conftest.defines' and
-# `conftest.undefs', that substitutes the proper values into
-# config.h.in to produce config.h.  The first handles `#define'
-# templates, and the second `#undef' templates.
-# And first: Protect against being on the right side of a sed subst in
-# config.status.  Protect against being in an unquoted here document
-# in config.status.
-rm -f conftest.defines conftest.undefs
-# Using a here document instead of a string reduces the quoting nightmare.
-# Putting comments in sed scripts is not portable.
-#
-# `end' is used to avoid that the second main sed command (meant for
-# 0-ary CPP macros) applies to n-ary macro definitions.
-# See the Autoconf documentation for `clear'.
-cat >confdef2sed.sed <<\_ACEOF
-s/[\\&,]/\\&/g
-s,[\\$`],\\&,g
-t clear
-: clear
-s,^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 (][^	 (]*\)\(([^)]*)\)[	 ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
-t end
-s,^[	 ]*#[	 ]*define[	 ][	 ]*\([^	 ][^	 ]*\)[	 ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
-: end
-_ACEOF
-# If some macros were called several times there might be several times
-# the same #defines, which is useless.  Nevertheless, we may not want to
-# sort them, since we want the *last* AC-DEFINE to be honored.
-uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
-sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
-rm -f confdef2sed.sed
-
-# This sed command replaces #undef with comments.  This is necessary, for
-# example, in the case of _POSIX_SOURCE, which is predefined and required
-# on some systems where configure will not decide to define it.
-cat >>conftest.undefs <<\_ACEOF
-s,^[	 ]*#[	 ]*undef[	 ][	 ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
-_ACEOF
-
-# Break up conftest.defines because some shells have a limit on the size
-# of here documents, and old seds have small limits too (100 cmds).
-echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
-echo '  if grep "^[	 ]*#[	 ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
-echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
-echo '  :' >>$CONFIG_STATUS
-rm -f conftest.tail
-while grep . conftest.defines >/dev/null
-do
-  # Write a limited-size here document to $tmp/defines.sed.
-  echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
-  # Speed up: don't consider the non `#define' lines.
-  echo '/^[	 ]*#[	 ]*define/!b' >>$CONFIG_STATUS
-  # Work around the forget-to-reset-the-flag bug.
-  echo 't clr' >>$CONFIG_STATUS
-  echo ': clr' >>$CONFIG_STATUS
-  sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
-  echo 'CEOF
-  sed -f $tmp/defines.sed $tmp/in >$tmp/out
-  rm -f $tmp/in
-  mv $tmp/out $tmp/in
-' >>$CONFIG_STATUS
-  sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
-  rm -f conftest.defines
-  mv conftest.tail conftest.defines
-done
-rm -f conftest.defines
-echo '  fi # grep' >>$CONFIG_STATUS
-echo >>$CONFIG_STATUS
-
-# Break up conftest.undefs because some shells have a limit on the size
-# of here documents, and old seds have small limits too (100 cmds).
-echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
-rm -f conftest.tail
-while grep . conftest.undefs >/dev/null
-do
-  # Write a limited-size here document to $tmp/undefs.sed.
-  echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
-  # Speed up: don't consider the non `#undef'
-  echo '/^[	 ]*#[	 ]*undef/!b' >>$CONFIG_STATUS
-  # Work around the forget-to-reset-the-flag bug.
-  echo 't clr' >>$CONFIG_STATUS
-  echo ': clr' >>$CONFIG_STATUS
-  sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
-  echo 'CEOF
-  sed -f $tmp/undefs.sed $tmp/in >$tmp/out
-  rm -f $tmp/in
-  mv $tmp/out $tmp/in
-' >>$CONFIG_STATUS
-  sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
-  rm -f conftest.undefs
-  mv conftest.tail conftest.undefs
-done
-rm -f conftest.undefs
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-  # Let's still pretend it is `configure' which instantiates (i.e., don't
-  # use $as_me), people would be surprised to read:
-  #    /* config.h.  Generated by config.status.  */
-  if test x"$ac_file" = x-; then
-    echo "/* Generated by configure.  */" >$tmp/config.h
-  else
-    echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
-  fi
-  cat $tmp/in >>$tmp/config.h
-  rm -f $tmp/in
-  if test x"$ac_file" != x-; then
-    if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
-      { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
-echo "$as_me: $ac_file is unchanged" >&6;}
-    else
-      ac_dir=`(dirname "$ac_file") 2>/dev/null ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$ac_file" : 'X\(//\)[^/]' \| \
-	 X"$ac_file" : 'X\(//\)$' \| \
-	 X"$ac_file" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X"$ac_file" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-      { if $as_mkdir_p; then
-    mkdir -p "$ac_dir"
-  else
-    as_dir="$ac_dir"
-    as_dirs=
-    while test ! -d "$as_dir"; do
-      as_dirs="$as_dir $as_dirs"
-      as_dir=`(dirname "$as_dir") 2>/dev/null ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
-	 X"$as_dir" : 'X\(//\)[^/]' \| \
-	 X"$as_dir" : 'X\(//\)$' \| \
-	 X"$as_dir" : 'X\(/\)' \| \
-	 .     : '\(.\)' 2>/dev/null ||
-echo X"$as_dir" |
-    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
-  	  /^X\(\/\/\)[^/].*/{ s//\1/; q; }
-  	  /^X\(\/\/\)$/{ s//\1/; q; }
-  	  /^X\(\/\).*/{ s//\1/; q; }
-  	  s/.*/./; q'`
-    done
-    test ! -n "$as_dirs" || mkdir $as_dirs
-  fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
-echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
-   { (exit 1); exit 1; }; }; }
-
-      rm -f $ac_file
-      mv $tmp/config.h $ac_file
-    fi
-  else
-    cat $tmp/config.h
-    rm -f $tmp/config.h
-  fi
-done
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF
-
-{ (exit 0); exit 0; }
-_ACEOF
-chmod +x $CONFIG_STATUS
-ac_clean_files=$ac_clean_files_save
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded.  So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status.  When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
-  ac_cs_success=:
-  ac_config_status_args=
-  test "$silent" = yes &&
-    ac_config_status_args="$ac_config_status_args --quiet"
-  exec 5>/dev/null
-  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
-  exec 5>>config.log
-  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
-  # would make configure fail if this is the last instruction.
-  $ac_cs_success || { (exit 1); exit 1; }
+# Generated by GNU Autoconf 2.67.
+#
+#
+# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
+# 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
+# Foundation, Inc.
+#
+#
+# This configure script is free software; the Free Software Foundation
+# gives unlimited permission to copy, distribute and modify it.
+## -------------------- ##
+## M4sh Initialization. ##
+## -------------------- ##
+
+# Be more Bourne compatible
+DUALCASE=1; export DUALCASE # for MKS sh
+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
+  emulate sh
+  NULLCMD=:
+  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
+  # is contrary to our usage.  Disable this feature.
+  alias -g '${1+"$@"}'='"$@"'
+  setopt NO_GLOB_SUBST
+else
+  case `(set -o) 2>/dev/null` in #(
+  *posix*) :
+    set -o posix ;; #(
+  *) :
+     ;;
+esac
+fi
+
+
+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
+# Prefer a ksh shell builtin over an external printf program on Solaris,
+# but without wasting forks for bash or zsh.
+if test -z "$BASH_VERSION$ZSH_VERSION" \
+    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
+  as_echo='print -r --'
+  as_echo_n='print -rn --'
+elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
+  as_echo='printf %s\n'
+  as_echo_n='printf %s'
+else
+  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
+    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
+    as_echo_n='/usr/ucb/echo -n'
+  else
+    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
+    as_echo_n_body='eval
+      arg=$1;
+      case $arg in #(
+      *"$as_nl"*)
+	expr "X$arg" : "X\\(.*\\)$as_nl";
+	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
+      esac;
+      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
+    '
+    export as_echo_n_body
+    as_echo_n='sh -c $as_echo_n_body as_echo'
+  fi
+  export as_echo_body
+  as_echo='sh -c $as_echo_body as_echo'
+fi
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+  PATH_SEPARATOR=:
+  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
+    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
+      PATH_SEPARATOR=';'
+  }
+fi
+
+
+# IFS
+# We need space, tab and new line, in precisely that order.  Quoting is
+# there to prevent editors from complaining about space-tab.
+# (If _AS_PATH_WALK were called with IFS unset, it would disable word
+# splitting by setting IFS to empty value.)
+IFS=" ""	$as_nl"
+
+# Find who we are.  Look in the path if we contain no directory separator.
+case $0 in #((
+  *[\\/]* ) as_myself=$0 ;;
+  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+  done
+IFS=$as_save_IFS
+
+     ;;
+esac
+# We did not find ourselves, most probably we were run as `sh COMMAND'
+# in which case we are not to be found in the path.
+if test "x$as_myself" = x; then
+  as_myself=$0
+fi
+if test ! -f "$as_myself"; then
+  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+  exit 1
+fi
+
+# Unset variables that we do not need and which cause bugs (e.g. in
+# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
+# suppresses any "Segmentation fault" message there.  '((' could
+# trigger a bug in pdksh 5.2.14.
+for as_var in BASH_ENV ENV MAIL MAILPATH
+do eval test x\${$as_var+set} = xset \
+  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
+done
+PS1='$ '
+PS2='> '
+PS4='+ '
+
+# NLS nuisances.
+LC_ALL=C
+export LC_ALL
+LANGUAGE=C
+export LANGUAGE
+
+# CDPATH.
+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
+
+if test "x$CONFIG_SHELL" = x; then
+  as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
+  emulate sh
+  NULLCMD=:
+  # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
+  # is contrary to our usage.  Disable this feature.
+  alias -g '\${1+\"\$@\"}'='\"\$@\"'
+  setopt NO_GLOB_SUBST
+else
+  case \`(set -o) 2>/dev/null\` in #(
+  *posix*) :
+    set -o posix ;; #(
+  *) :
+     ;;
+esac
+fi
+"
+  as_required="as_fn_return () { (exit \$1); }
+as_fn_success () { as_fn_return 0; }
+as_fn_failure () { as_fn_return 1; }
+as_fn_ret_success () { return 0; }
+as_fn_ret_failure () { return 1; }
+
+exitcode=0
+as_fn_success || { exitcode=1; echo as_fn_success failed.; }
+as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
+as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
+as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
+if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
+
+else
+  exitcode=1; echo positional parameters were not saved.
+fi
+test x\$exitcode = x0 || exit 1"
+  as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
+  as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
+  eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
+  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1"
+  if (eval "$as_required") 2>/dev/null; then :
+  as_have_required=yes
+else
+  as_have_required=no
+fi
+  if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
+
+else
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+as_found=false
+for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  as_found=:
+  case $as_dir in #(
+	 /*)
+	   for as_base in sh bash ksh sh5; do
+	     # Try only shells that exist, to save several forks.
+	     as_shell=$as_dir/$as_base
+	     if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
+		    { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
+  CONFIG_SHELL=$as_shell as_have_required=yes
+		   if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
+  break 2
+fi
+fi
+	   done;;
+       esac
+  as_found=false
+done
+$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
+	      { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
+  CONFIG_SHELL=$SHELL as_have_required=yes
+fi; }
+IFS=$as_save_IFS
+
+
+      if test "x$CONFIG_SHELL" != x; then :
+  # We cannot yet assume a decent shell, so we have to provide a
+	# neutralization value for shells without unset; and this also
+	# works around shells that cannot unset nonexistent variables.
+	BASH_ENV=/dev/null
+	ENV=/dev/null
+	(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
+	export CONFIG_SHELL
+	exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
+fi
+
+    if test x$as_have_required = xno; then :
+  $as_echo "$0: This script requires a shell more modern than all"
+  $as_echo "$0: the shells that I found on your system."
+  if test x${ZSH_VERSION+set} = xset ; then
+    $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
+    $as_echo "$0: be upgraded to zsh 4.3.4 or later."
+  else
+    $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
+$0: including any error possibly output before this
+$0: message. Then install a modern shell, or manually run
+$0: the script under such a shell if you do have one."
+  fi
+  exit 1
+fi
+fi
+fi
+SHELL=${CONFIG_SHELL-/bin/sh}
+export SHELL
+# Unset more variables known to interfere with behavior of common tools.
+CLICOLOR_FORCE= GREP_OPTIONS=
+unset CLICOLOR_FORCE GREP_OPTIONS
+
+## --------------------- ##
+## M4sh Shell Functions. ##
+## --------------------- ##
+# as_fn_unset VAR
+# ---------------
+# Portably unset VAR.
+as_fn_unset ()
+{
+  { eval $1=; unset $1;}
+}
+as_unset=as_fn_unset
+
+# as_fn_set_status STATUS
+# -----------------------
+# Set $? to STATUS, without forking.
+as_fn_set_status ()
+{
+  return $1
+} # as_fn_set_status
+
+# as_fn_exit STATUS
+# -----------------
+# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
+as_fn_exit ()
+{
+  set +e
+  as_fn_set_status $1
+  exit $1
+} # as_fn_exit
+
+# as_fn_mkdir_p
+# -------------
+# Create "$as_dir" as a directory, including parents if necessary.
+as_fn_mkdir_p ()
+{
+
+  case $as_dir in #(
+  -*) as_dir=./$as_dir;;
+  esac
+  test -d "$as_dir" || eval $as_mkdir_p || {
+    as_dirs=
+    while :; do
+      case $as_dir in #(
+      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
+      *) as_qdir=$as_dir;;
+      esac
+      as_dirs="'$as_qdir' $as_dirs"
+      as_dir=`$as_dirname -- "$as_dir" ||
+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+	 X"$as_dir" : 'X\(//\)[^/]' \| \
+	 X"$as_dir" : 'X\(//\)$' \| \
+	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X"$as_dir" |
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)[^/].*/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
+      test -d "$as_dir" && break
+    done
+    test -z "$as_dirs" || eval "mkdir $as_dirs"
+  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
+
+
+} # as_fn_mkdir_p
+# as_fn_append VAR VALUE
+# ----------------------
+# Append the text in VALUE to the end of the definition contained in VAR. Take
+# advantage of any shell optimizations that allow amortized linear growth over
+# repeated appends, instead of the typical quadratic growth present in naive
+# implementations.
+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
+  eval 'as_fn_append ()
+  {
+    eval $1+=\$2
+  }'
+else
+  as_fn_append ()
+  {
+    eval $1=\$$1\$2
+  }
+fi # as_fn_append
+
+# as_fn_arith ARG...
+# ------------------
+# Perform arithmetic evaluation on the ARGs, and store the result in the
+# global $as_val. Take advantage of shells that can avoid forks. The arguments
+# must be portable across $(()) and expr.
+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
+  eval 'as_fn_arith ()
+  {
+    as_val=$(( $* ))
+  }'
+else
+  as_fn_arith ()
+  {
+    as_val=`expr "$@" || test $? -eq 1`
+  }
+fi # as_fn_arith
+
+
+# as_fn_error STATUS ERROR [LINENO LOG_FD]
+# ----------------------------------------
+# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
+# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
+# script with STATUS, using 1 if that was 0.
+as_fn_error ()
+{
+  as_status=$1; test $as_status -eq 0 && as_status=1
+  if test "$4"; then
+    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
+  fi
+  $as_echo "$as_me: error: $2" >&2
+  as_fn_exit $as_status
+} # as_fn_error
+
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+   test "X`expr 00001 : '.*\(...\)'`" = X001; then
+  as_expr=expr
+else
+  as_expr=false
+fi
+
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
+  as_basename=basename
+else
+  as_basename=false
+fi
+
+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
+  as_dirname=dirname
+else
+  as_dirname=false
+fi
+
+as_me=`$as_basename -- "$0" ||
+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
+	 X"$0" : 'X\(//\)$' \| \
+	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X/"$0" |
+    sed '/^.*\/\([^/][^/]*\)\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
+
+# Avoid depending upon Character Ranges.
+as_cr_letters='abcdefghijklmnopqrstuvwxyz'
+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
+as_cr_Letters=$as_cr_letters$as_cr_LETTERS
+as_cr_digits='0123456789'
+as_cr_alnum=$as_cr_Letters$as_cr_digits
+
+
+  as_lineno_1=$LINENO as_lineno_1a=$LINENO
+  as_lineno_2=$LINENO as_lineno_2a=$LINENO
+  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
+  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
+  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
+  sed -n '
+    p
+    /[$]LINENO/=
+  ' <$as_myself |
+    sed '
+      s/[$]LINENO.*/&-/
+      t lineno
+      b
+      :lineno
+      N
+      :loop
+      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
+      t loop
+      s/-\n.*//
+    ' >$as_me.lineno &&
+  chmod +x "$as_me.lineno" ||
+    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
+
+  # Don't try to exec as it changes $[0], causing all sort of problems
+  # (the dirname of $[0] is not the place where we might find the
+  # original and so on.  Autoconf is especially sensitive to this).
+  . "./$as_me.lineno"
+  # Exit status is that of the last command.
+  exit
+}
+
+ECHO_C= ECHO_N= ECHO_T=
+case `echo -n x` in #(((((
+-n*)
+  case `echo 'xy\c'` in
+  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
+  xy)  ECHO_C='\c';;
+  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
+       ECHO_T='	';;
+  esac;;
+*)
+  ECHO_N='-n';;
+esac
+
+rm -f conf$$ conf$$.exe conf$$.file
+if test -d conf$$.dir; then
+  rm -f conf$$.dir/conf$$.file
+else
+  rm -f conf$$.dir
+  mkdir conf$$.dir 2>/dev/null
+fi
+if (echo >conf$$.file) 2>/dev/null; then
+  if ln -s conf$$.file conf$$ 2>/dev/null; then
+    as_ln_s='ln -s'
+    # ... but there are two gotchas:
+    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+    # In both cases, we have to default to `cp -p'.
+    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+      as_ln_s='cp -p'
+  elif ln conf$$.file conf$$ 2>/dev/null; then
+    as_ln_s=ln
+  else
+    as_ln_s='cp -p'
+  fi
+else
+  as_ln_s='cp -p'
+fi
+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
+rmdir conf$$.dir 2>/dev/null
+
+if mkdir -p . 2>/dev/null; then
+  as_mkdir_p='mkdir -p "$as_dir"'
+else
+  test -d ./-p && rmdir ./-p
+  as_mkdir_p=false
+fi
+
+if test -x / >/dev/null 2>&1; then
+  as_test_x='test -x'
+else
+  if ls -dL / >/dev/null 2>&1; then
+    as_ls_L_option=L
+  else
+    as_ls_L_option=
+  fi
+  as_test_x='
+    eval sh -c '\''
+      if test -d "$1"; then
+	test -d "$1/.";
+      else
+	case $1 in #(
+	-*)set "./$1";;
+	esac;
+	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
+	???[sx]*):;;*)false;;esac;fi
+    '\'' sh
+  '
+fi
+as_executable_p=$as_test_x
+
+# Sed expression to map a string onto a valid CPP name.
+as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
+
+# Sed expression to map a string onto a valid variable name.
+as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
+
+
+test -n "$DJDIR" || exec 7<&0 </dev/null
+exec 6>&1
+
+# Name of the host.
+# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
+# so uname gets run too.
+ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
+
+#
+# Initializations.
+#
+ac_default_prefix=/usr/local
+ac_clean_files=
+ac_config_libobj_dir=.
+LIBOBJS=
+cross_compiling=no
+subdirs=
+MFLAGS=
+MAKEFLAGS=
+
+# Identity of this package.
+PACKAGE_NAME=
+PACKAGE_TARNAME=
+PACKAGE_VERSION=
+PACKAGE_STRING=
+PACKAGE_BUGREPORT=
+PACKAGE_URL=
+
+ac_unique_file="src/System/Plugins.hs"
+ac_subst_vars='LTLIBOBJS
+LIBOBJS
+INSTALL_DATA
+INSTALL_SCRIPT
+INSTALL_PROGRAM
+OBJEXT
+EXEEXT
+ac_ct_CC
+CPPFLAGS
+LDFLAGS
+CFLAGS
+CC
+HASKELL_SRC
+GLASGOW_HASKELL
+GHC
+TOP
+PREFIX
+build_os
+build_vendor
+build_cpu
+build
+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_URL
+PACKAGE_BUGREPORT
+PACKAGE_STRING
+PACKAGE_VERSION
+PACKAGE_TARNAME
+PACKAGE_NAME
+PATH_SEPARATOR
+SHELL'
+ac_subst_files=''
+ac_user_opts='
+enable_option_checking
+with_ghc
+enable_debug
+enable_hsx
+'
+      ac_precious_vars='build_alias
+host_alias
+target_alias
+CC
+CFLAGS
+LDFLAGS
+LIBS
+CPPFLAGS'
+
+
+# Initialize some variables set by options.
+ac_init_help=
+ac_init_version=false
+ac_unrecognized_opts=
+ac_unrecognized_sep=
+# The variables have the same names as the options, with
+# dashes changed to underlines.
+cache_file=/dev/null
+exec_prefix=NONE
+no_create=
+no_recursion=
+prefix=NONE
+program_prefix=NONE
+program_suffix=NONE
+program_transform_name=s,x,x,
+silent=
+site=
+srcdir=
+verbose=
+x_includes=NONE
+x_libraries=NONE
+
+# Installation directory options.
+# These are left unexpanded so users can "make install exec_prefix=/foo"
+# and all the variables that are supposed to be based on exec_prefix
+# by default will actually change.
+# Use braces instead of parens because sh, perl, etc. also accept them.
+# (The list follows the same order as the GNU Coding Standards.)
+bindir='${exec_prefix}/bin'
+sbindir='${exec_prefix}/sbin'
+libexecdir='${exec_prefix}/libexec'
+datarootdir='${prefix}/share'
+datadir='${datarootdir}'
+sysconfdir='${prefix}/etc'
+sharedstatedir='${prefix}/com'
+localstatedir='${prefix}/var'
+includedir='${prefix}/include'
+oldincludedir='/usr/include'
+docdir='${datarootdir}/doc/${PACKAGE}'
+infodir='${datarootdir}/info'
+htmldir='${docdir}'
+dvidir='${docdir}'
+pdfdir='${docdir}'
+psdir='${docdir}'
+libdir='${exec_prefix}/lib'
+localedir='${datarootdir}/locale'
+mandir='${datarootdir}/man'
+
+ac_prev=
+ac_dashdash=
+for ac_option
+do
+  # If the previous option needs an argument, assign it.
+  if test -n "$ac_prev"; then
+    eval $ac_prev=\$ac_option
+    ac_prev=
+    continue
+  fi
+
+  case $ac_option in
+  *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
+  *=)   ac_optarg= ;;
+  *)    ac_optarg=yes ;;
+  esac
+
+  # Accept the important Cygnus configure options, so we can diagnose typos.
+
+  case $ac_dashdash$ac_option in
+  --)
+    ac_dashdash=yes ;;
+
+  -bindir | --bindir | --bindi | --bind | --bin | --bi)
+    ac_prev=bindir ;;
+  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
+    bindir=$ac_optarg ;;
+
+  -build | --build | --buil | --bui | --bu)
+    ac_prev=build_alias ;;
+  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
+    build_alias=$ac_optarg ;;
+
+  -cache-file | --cache-file | --cache-fil | --cache-fi \
+  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
+    ac_prev=cache_file ;;
+  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
+  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
+    cache_file=$ac_optarg ;;
+
+  --config-cache | -C)
+    cache_file=config.cache ;;
+
+  -datadir | --datadir | --datadi | --datad)
+    ac_prev=datadir ;;
+  -datadir=* | --datadir=* | --datadi=* | --datad=*)
+    datadir=$ac_optarg ;;
+
+  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
+  | --dataroo | --dataro | --datar)
+    ac_prev=datarootdir ;;
+  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
+  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
+    datarootdir=$ac_optarg ;;
+
+  -disable-* | --disable-*)
+    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
+    # Reject names that are not valid shell variable names.
+    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+      as_fn_error $? "invalid feature name: $ac_useropt"
+    ac_useropt_orig=$ac_useropt
+    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+    case $ac_user_opts in
+      *"
+"enable_$ac_useropt"
+"*) ;;
+      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
+	 ac_unrecognized_sep=', ';;
+    esac
+    eval enable_$ac_useropt=no ;;
+
+  -docdir | --docdir | --docdi | --doc | --do)
+    ac_prev=docdir ;;
+  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
+    docdir=$ac_optarg ;;
+
+  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
+    ac_prev=dvidir ;;
+  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
+    dvidir=$ac_optarg ;;
+
+  -enable-* | --enable-*)
+    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
+    # Reject names that are not valid shell variable names.
+    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+      as_fn_error $? "invalid feature name: $ac_useropt"
+    ac_useropt_orig=$ac_useropt
+    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+    case $ac_user_opts in
+      *"
+"enable_$ac_useropt"
+"*) ;;
+      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
+	 ac_unrecognized_sep=', ';;
+    esac
+    eval enable_$ac_useropt=\$ac_optarg ;;
+
+  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
+  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
+  | --exec | --exe | --ex)
+    ac_prev=exec_prefix ;;
+  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
+  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
+  | --exec=* | --exe=* | --ex=*)
+    exec_prefix=$ac_optarg ;;
+
+  -gas | --gas | --ga | --g)
+    # Obsolete; use --with-gas.
+    with_gas=yes ;;
+
+  -help | --help | --hel | --he | -h)
+    ac_init_help=long ;;
+  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
+    ac_init_help=recursive ;;
+  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
+    ac_init_help=short ;;
+
+  -host | --host | --hos | --ho)
+    ac_prev=host_alias ;;
+  -host=* | --host=* | --hos=* | --ho=*)
+    host_alias=$ac_optarg ;;
+
+  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
+    ac_prev=htmldir ;;
+  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
+  | --ht=*)
+    htmldir=$ac_optarg ;;
+
+  -includedir | --includedir | --includedi | --included | --include \
+  | --includ | --inclu | --incl | --inc)
+    ac_prev=includedir ;;
+  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
+  | --includ=* | --inclu=* | --incl=* | --inc=*)
+    includedir=$ac_optarg ;;
+
+  -infodir | --infodir | --infodi | --infod | --info | --inf)
+    ac_prev=infodir ;;
+  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
+    infodir=$ac_optarg ;;
+
+  -libdir | --libdir | --libdi | --libd)
+    ac_prev=libdir ;;
+  -libdir=* | --libdir=* | --libdi=* | --libd=*)
+    libdir=$ac_optarg ;;
+
+  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
+  | --libexe | --libex | --libe)
+    ac_prev=libexecdir ;;
+  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
+  | --libexe=* | --libex=* | --libe=*)
+    libexecdir=$ac_optarg ;;
+
+  -localedir | --localedir | --localedi | --localed | --locale)
+    ac_prev=localedir ;;
+  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
+    localedir=$ac_optarg ;;
+
+  -localstatedir | --localstatedir | --localstatedi | --localstated \
+  | --localstate | --localstat | --localsta | --localst | --locals)
+    ac_prev=localstatedir ;;
+  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
+  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
+    localstatedir=$ac_optarg ;;
+
+  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
+    ac_prev=mandir ;;
+  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
+    mandir=$ac_optarg ;;
+
+  -nfp | --nfp | --nf)
+    # Obsolete; use --without-fp.
+    with_fp=no ;;
+
+  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
+  | --no-cr | --no-c | -n)
+    no_create=yes ;;
+
+  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
+  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
+    no_recursion=yes ;;
+
+  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
+  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
+  | --oldin | --oldi | --old | --ol | --o)
+    ac_prev=oldincludedir ;;
+  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
+  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
+  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
+    oldincludedir=$ac_optarg ;;
+
+  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
+    ac_prev=prefix ;;
+  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
+    prefix=$ac_optarg ;;
+
+  -program-prefix | --program-prefix | --program-prefi | --program-pref \
+  | --program-pre | --program-pr | --program-p)
+    ac_prev=program_prefix ;;
+  -program-prefix=* | --program-prefix=* | --program-prefi=* \
+  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
+    program_prefix=$ac_optarg ;;
+
+  -program-suffix | --program-suffix | --program-suffi | --program-suff \
+  | --program-suf | --program-su | --program-s)
+    ac_prev=program_suffix ;;
+  -program-suffix=* | --program-suffix=* | --program-suffi=* \
+  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
+    program_suffix=$ac_optarg ;;
+
+  -program-transform-name | --program-transform-name \
+  | --program-transform-nam | --program-transform-na \
+  | --program-transform-n | --program-transform- \
+  | --program-transform | --program-transfor \
+  | --program-transfo | --program-transf \
+  | --program-trans | --program-tran \
+  | --progr-tra | --program-tr | --program-t)
+    ac_prev=program_transform_name ;;
+  -program-transform-name=* | --program-transform-name=* \
+  | --program-transform-nam=* | --program-transform-na=* \
+  | --program-transform-n=* | --program-transform-=* \
+  | --program-transform=* | --program-transfor=* \
+  | --program-transfo=* | --program-transf=* \
+  | --program-trans=* | --program-tran=* \
+  | --progr-tra=* | --program-tr=* | --program-t=*)
+    program_transform_name=$ac_optarg ;;
+
+  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
+    ac_prev=pdfdir ;;
+  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
+    pdfdir=$ac_optarg ;;
+
+  -psdir | --psdir | --psdi | --psd | --ps)
+    ac_prev=psdir ;;
+  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
+    psdir=$ac_optarg ;;
+
+  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
+  | -silent | --silent | --silen | --sile | --sil)
+    silent=yes ;;
+
+  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
+    ac_prev=sbindir ;;
+  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
+  | --sbi=* | --sb=*)
+    sbindir=$ac_optarg ;;
+
+  -sharedstatedir | --sharedstatedir | --sharedstatedi \
+  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
+  | --sharedst | --shareds | --shared | --share | --shar \
+  | --sha | --sh)
+    ac_prev=sharedstatedir ;;
+  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
+  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
+  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
+  | --sha=* | --sh=*)
+    sharedstatedir=$ac_optarg ;;
+
+  -site | --site | --sit)
+    ac_prev=site ;;
+  -site=* | --site=* | --sit=*)
+    site=$ac_optarg ;;
+
+  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
+    ac_prev=srcdir ;;
+  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
+    srcdir=$ac_optarg ;;
+
+  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
+  | --syscon | --sysco | --sysc | --sys | --sy)
+    ac_prev=sysconfdir ;;
+  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
+  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
+    sysconfdir=$ac_optarg ;;
+
+  -target | --target | --targe | --targ | --tar | --ta | --t)
+    ac_prev=target_alias ;;
+  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
+    target_alias=$ac_optarg ;;
+
+  -v | -verbose | --verbose | --verbos | --verbo | --verb)
+    verbose=yes ;;
+
+  -version | --version | --versio | --versi | --vers | -V)
+    ac_init_version=: ;;
+
+  -with-* | --with-*)
+    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
+    # Reject names that are not valid shell variable names.
+    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+      as_fn_error $? "invalid package name: $ac_useropt"
+    ac_useropt_orig=$ac_useropt
+    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+    case $ac_user_opts in
+      *"
+"with_$ac_useropt"
+"*) ;;
+      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
+	 ac_unrecognized_sep=', ';;
+    esac
+    eval with_$ac_useropt=\$ac_optarg ;;
+
+  -without-* | --without-*)
+    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
+    # Reject names that are not valid shell variable names.
+    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
+      as_fn_error $? "invalid package name: $ac_useropt"
+    ac_useropt_orig=$ac_useropt
+    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
+    case $ac_user_opts in
+      *"
+"with_$ac_useropt"
+"*) ;;
+      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
+	 ac_unrecognized_sep=', ';;
+    esac
+    eval with_$ac_useropt=no ;;
+
+  --x)
+    # Obsolete; use --with-x.
+    with_x=yes ;;
+
+  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
+  | --x-incl | --x-inc | --x-in | --x-i)
+    ac_prev=x_includes ;;
+  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
+  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
+    x_includes=$ac_optarg ;;
+
+  -x-libraries | --x-libraries | --x-librarie | --x-librari \
+  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
+    ac_prev=x_libraries ;;
+  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
+  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
+    x_libraries=$ac_optarg ;;
+
+  -*) as_fn_error $? "unrecognized option: \`$ac_option'
+Try \`$0 --help' for more information"
+    ;;
+
+  *=*)
+    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
+    # Reject names that are not valid shell variable names.
+    case $ac_envvar in #(
+      '' | [0-9]* | *[!_$as_cr_alnum]* )
+      as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
+    esac
+    eval $ac_envvar=\$ac_optarg
+    export $ac_envvar ;;
+
+  *)
+    # FIXME: should be removed in autoconf 3.0.
+    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
+    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
+      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
+    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
+    ;;
+
+  esac
+done
+
+if test -n "$ac_prev"; then
+  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
+  as_fn_error $? "missing argument to $ac_option"
+fi
+
+if test -n "$ac_unrecognized_opts"; then
+  case $enable_option_checking in
+    no) ;;
+    fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
+    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
+  esac
+fi
+
+# Check all directory arguments for consistency.
+for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
+		datadir sysconfdir sharedstatedir localstatedir includedir \
+		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
+		libdir localedir mandir
+do
+  eval ac_val=\$$ac_var
+  # Remove trailing slashes.
+  case $ac_val in
+    */ )
+      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
+      eval $ac_var=\$ac_val;;
+  esac
+  # Be sure to have absolute directory names.
+  case $ac_val in
+    [\\/$]* | ?:[\\/]* )  continue;;
+    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
+  esac
+  as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
+done
+
+# There might be people who depend on the old broken behavior: `$host'
+# used to hold the argument of --host etc.
+# FIXME: To remove some day.
+build=$build_alias
+host=$host_alias
+target=$target_alias
+
+# FIXME: To remove some day.
+if test "x$host_alias" != x; then
+  if test "x$build_alias" = x; then
+    cross_compiling=maybe
+    $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
+    If a cross compiler is detected then cross compile mode will be used" >&2
+  elif test "x$build_alias" != "x$host_alias"; then
+    cross_compiling=yes
+  fi
+fi
+
+ac_tool_prefix=
+test -n "$host_alias" && ac_tool_prefix=$host_alias-
+
+test "$silent" = yes && exec 6>/dev/null
+
+
+ac_pwd=`pwd` && test -n "$ac_pwd" &&
+ac_ls_di=`ls -di .` &&
+ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
+  as_fn_error $? "working directory cannot be determined"
+test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
+  as_fn_error $? "pwd does not report name of working directory"
+
+
+# Find the source files, if location was not specified.
+if test -z "$srcdir"; then
+  ac_srcdir_defaulted=yes
+  # Try the directory containing this script, then the parent directory.
+  ac_confdir=`$as_dirname -- "$as_myself" ||
+$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+	 X"$as_myself" : 'X\(//\)[^/]' \| \
+	 X"$as_myself" : 'X\(//\)$' \| \
+	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X"$as_myself" |
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)[^/].*/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
+  srcdir=$ac_confdir
+  if test ! -r "$srcdir/$ac_unique_file"; then
+    srcdir=..
+  fi
+else
+  ac_srcdir_defaulted=no
+fi
+if test ! -r "$srcdir/$ac_unique_file"; then
+  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
+  as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
+fi
+ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
+ac_abs_confdir=`(
+	cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
+	pwd)`
+# When building in place, set srcdir=.
+if test "$ac_abs_confdir" = "$ac_pwd"; then
+  srcdir=.
+fi
+# Remove unnecessary trailing slashes from srcdir.
+# Double slashes in file names in object file debugging info
+# mess up M-x gdb in Emacs.
+case $srcdir in
+*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
+esac
+for ac_var in $ac_precious_vars; do
+  eval ac_env_${ac_var}_set=\${${ac_var}+set}
+  eval ac_env_${ac_var}_value=\$${ac_var}
+  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
+  eval ac_cv_env_${ac_var}_value=\$${ac_var}
+done
+
+#
+# Report the --help message.
+#
+if test "$ac_init_help" = "long"; then
+  # Omit some internal or obsolete options to make the list less imposing.
+  # This message is too long to be a string in the A/UX 3.1 sh.
+  cat <<_ACEOF
+\`configure' configures this package to adapt to many kinds of systems.
+
+Usage: $0 [OPTION]... [VAR=VALUE]...
+
+To assign environment variables (e.g., CC, CFLAGS...), specify them as
+VAR=VALUE.  See below for descriptions of some of the useful variables.
+
+Defaults for the options are specified in brackets.
+
+Configuration:
+  -h, --help              display this help and exit
+      --help=short        display options specific to this package
+      --help=recursive    display the short help of all the included packages
+  -V, --version           display version information and exit
+  -q, --quiet, --silent   do not print \`checking ...' messages
+      --cache-file=FILE   cache test results in FILE [disabled]
+  -C, --config-cache      alias for \`--cache-file=config.cache'
+  -n, --no-create         do not create output files
+      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
+
+Installation directories:
+  --prefix=PREFIX         install architecture-independent files in PREFIX
+                          [$ac_default_prefix]
+  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
+                          [PREFIX]
+
+By default, \`make install' will install all the files in
+\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
+an installation prefix other than \`$ac_default_prefix' using \`--prefix',
+for instance \`--prefix=\$HOME'.
+
+For better control, use the options below.
+
+Fine tuning of the installation directories:
+  --bindir=DIR            user executables [EPREFIX/bin]
+  --sbindir=DIR           system admin executables [EPREFIX/sbin]
+  --libexecdir=DIR        program executables [EPREFIX/libexec]
+  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
+  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
+  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
+  --libdir=DIR            object code libraries [EPREFIX/lib]
+  --includedir=DIR        C header files [PREFIX/include]
+  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
+  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
+  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
+  --infodir=DIR           info documentation [DATAROOTDIR/info]
+  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
+  --mandir=DIR            man documentation [DATAROOTDIR/man]
+  --docdir=DIR            documentation root [DATAROOTDIR/doc/PACKAGE]
+  --htmldir=DIR           html documentation [DOCDIR]
+  --dvidir=DIR            dvi documentation [DOCDIR]
+  --pdfdir=DIR            pdf documentation [DOCDIR]
+  --psdir=DIR             ps documentation [DOCDIR]
+_ACEOF
+
+  cat <<\_ACEOF
+
+System types:
+  --build=BUILD     configure for building on BUILD [guessed]
+_ACEOF
+fi
+
+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-debug          Enable a debug version of hs-plugins to be built
+  --enable-hsx          Enable a debug version of hs-plugins to be built
+
+Optional Packages:
+  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
+  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
+  --with-ghc=<ghc>        use a specific Haskell compiler
+
+Some influential environment variables:
+  CC          C compiler command
+  CFLAGS      C compiler flags
+  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
+              nonstandard directory <lib dir>
+  LIBS        libraries to pass to the linker, e.g. -l<library>
+  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
+              you have headers in a nonstandard directory <include dir>
+
+Use these variables to override the choices made by `configure' or to help
+it to find libraries and programs with nonstandard names/locations.
+
+Report bugs to the package provider.
+_ACEOF
+ac_status=$?
+fi
+
+if test "$ac_init_help" = "recursive"; then
+  # If there are subdirs, report their specific --help.
+  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
+    test -d "$ac_dir" ||
+      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
+      continue
+    ac_builddir=.
+
+case "$ac_dir" in
+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
+*)
+  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
+  # A ".." for each directory in $ac_dir_suffix.
+  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
+  case $ac_top_builddir_sub in
+  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
+  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
+  esac ;;
+esac
+ac_abs_top_builddir=$ac_pwd
+ac_abs_builddir=$ac_pwd$ac_dir_suffix
+# for backward compatibility:
+ac_top_builddir=$ac_top_build_prefix
+
+case $srcdir in
+  .)  # We are building in place.
+    ac_srcdir=.
+    ac_top_srcdir=$ac_top_builddir_sub
+    ac_abs_top_srcdir=$ac_pwd ;;
+  [\\/]* | ?:[\\/]* )  # Absolute name.
+    ac_srcdir=$srcdir$ac_dir_suffix;
+    ac_top_srcdir=$srcdir
+    ac_abs_top_srcdir=$srcdir ;;
+  *) # Relative name.
+    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
+    ac_top_srcdir=$ac_top_build_prefix$srcdir
+    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
+esac
+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
+
+    cd "$ac_dir" || { ac_status=$?; continue; }
+    # Check for guested configure.
+    if test -f "$ac_srcdir/configure.gnu"; then
+      echo &&
+      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
+    elif test -f "$ac_srcdir/configure"; then
+      echo &&
+      $SHELL "$ac_srcdir/configure" --help=recursive
+    else
+      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
+    fi || ac_status=$?
+    cd "$ac_pwd" || { ac_status=$?; break; }
+  done
+fi
+
+test -n "$ac_init_help" && exit $ac_status
+if $ac_init_version; then
+  cat <<\_ACEOF
+configure
+generated by GNU Autoconf 2.67
+
+Copyright (C) 2010 Free Software Foundation, Inc.
+This configure script is free software; the Free Software Foundation
+gives unlimited permission to copy, distribute and modify it.
+_ACEOF
+  exit
+fi
+
+## ------------------------ ##
+## Autoconf initialization. ##
+## ------------------------ ##
+
+# ac_fn_c_try_compile LINENO
+# --------------------------
+# Try to compile conftest.$ac_ext, and return whether this succeeded.
+ac_fn_c_try_compile ()
+{
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+  rm -f conftest.$ac_objext
+  if { { ac_try="$ac_compile"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_compile") 2>conftest.err
+  ac_status=$?
+  if test -s conftest.err; then
+    grep -v '^ *+' conftest.err >conftest.er1
+    cat conftest.er1 >&5
+    mv -f conftest.er1 conftest.err
+  fi
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; } && {
+	 test -z "$ac_c_werror_flag" ||
+	 test ! -s conftest.err
+       } && test -s conftest.$ac_objext; then :
+  ac_retval=0
+else
+  $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+	ac_retval=1
+fi
+  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  as_fn_set_status $ac_retval
+
+} # ac_fn_c_try_compile
+
+# ac_fn_c_try_link LINENO
+# -----------------------
+# Try to link conftest.$ac_ext, and return whether this succeeded.
+ac_fn_c_try_link ()
+{
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+  rm -f conftest.$ac_objext conftest$ac_exeext
+  if { { ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_link") 2>conftest.err
+  ac_status=$?
+  if test -s conftest.err; then
+    grep -v '^ *+' conftest.err >conftest.er1
+    cat conftest.er1 >&5
+    mv -f conftest.er1 conftest.err
+  fi
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; } && {
+	 test -z "$ac_c_werror_flag" ||
+	 test ! -s conftest.err
+       } && test -s conftest$ac_exeext && {
+	 test "$cross_compiling" = yes ||
+	 $as_test_x conftest$ac_exeext
+       }; then :
+  ac_retval=0
+else
+  $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+	ac_retval=1
+fi
+  # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
+  # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
+  # interfere with the next link command; also delete a directory that is
+  # left behind by Apple's compiler.  We do this before executing the actions.
+  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
+  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+  as_fn_set_status $ac_retval
+
+} # ac_fn_c_try_link
+
+# ac_fn_c_check_func LINENO FUNC VAR
+# ----------------------------------
+# Tests whether FUNC exists, setting the cache variable VAR accordingly
+ac_fn_c_check_func ()
+{
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
+$as_echo_n "checking for $2... " >&6; }
+if eval "test \"\${$3+set}\"" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
+   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
+#define $2 innocuous_$2
+
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $2 (); below.
+    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+    <limits.h> exists even on freestanding compilers.  */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $2
+
+/* Override any GCC internal prototype to avoid an error.
+   Use char because int might match the return type of a GCC
+   builtin and then its argument prototype would still apply.  */
+#ifdef __cplusplus
+extern "C"
+#endif
+char $2 ();
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined __stub_$2 || defined __stub___$2
+choke me
+#endif
+
+int
+main ()
+{
+return $2 ();
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_link "$LINENO"; then :
+  eval "$3=yes"
+else
+  eval "$3=no"
+fi
+rm -f core conftest.err conftest.$ac_objext \
+    conftest$ac_exeext conftest.$ac_ext
+fi
+eval ac_res=\$$3
+	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
+$as_echo "$ac_res" >&6; }
+  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
+
+} # ac_fn_c_check_func
+cat >config.log <<_ACEOF
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+
+It was created by $as_me, which was
+generated by GNU Autoconf 2.67.  Invocation command line was
+
+  $ $0 $@
+
+_ACEOF
+exec 5>>config.log
+{
+cat <<_ASUNAME
+## --------- ##
+## Platform. ##
+## --------- ##
+
+hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
+uname -m = `(uname -m) 2>/dev/null || echo unknown`
+uname -r = `(uname -r) 2>/dev/null || echo unknown`
+uname -s = `(uname -s) 2>/dev/null || echo unknown`
+uname -v = `(uname -v) 2>/dev/null || echo unknown`
+
+/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
+/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
+
+/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
+/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
+/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
+/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
+/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
+/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
+/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
+
+_ASUNAME
+
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    $as_echo "PATH: $as_dir"
+  done
+IFS=$as_save_IFS
+
+} >&5
+
+cat >&5 <<_ACEOF
+
+
+## ----------- ##
+## Core tests. ##
+## ----------- ##
+
+_ACEOF
+
+
+# Keep a trace of the command line.
+# Strip out --no-create and --no-recursion so they do not pile up.
+# Strip out --silent because we don't want to record it for future runs.
+# Also quote any args containing shell meta-characters.
+# Make two passes to allow for proper duplicate-argument suppression.
+ac_configure_args=
+ac_configure_args0=
+ac_configure_args1=
+ac_must_keep_next=false
+for ac_pass in 1 2
+do
+  for ac_arg
+  do
+    case $ac_arg in
+    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
+    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
+    | -silent | --silent | --silen | --sile | --sil)
+      continue ;;
+    *\'*)
+      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+    esac
+    case $ac_pass in
+    1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
+    2)
+      as_fn_append ac_configure_args1 " '$ac_arg'"
+      if test $ac_must_keep_next = true; then
+	ac_must_keep_next=false # Got value, back to normal.
+      else
+	case $ac_arg in
+	  *=* | --config-cache | -C | -disable-* | --disable-* \
+	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
+	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
+	  | -with-* | --with-* | -without-* | --without-* | --x)
+	    case "$ac_configure_args0 " in
+	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
+	    esac
+	    ;;
+	  -* ) ac_must_keep_next=true ;;
+	esac
+      fi
+      as_fn_append ac_configure_args " '$ac_arg'"
+      ;;
+    esac
+  done
+done
+{ ac_configure_args0=; unset ac_configure_args0;}
+{ ac_configure_args1=; unset ac_configure_args1;}
+
+# When interrupted or exit'd, cleanup temporary files, and complete
+# config.log.  We remove comments because anyway the quotes in there
+# would cause problems or look ugly.
+# WARNING: Use '\'' to represent an apostrophe within the trap.
+# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
+trap 'exit_status=$?
+  # Save into config.log some information that might help in debugging.
+  {
+    echo
+
+    $as_echo "## ---------------- ##
+## Cache variables. ##
+## ---------------- ##"
+    echo
+    # The following way of writing the cache mishandles newlines in values,
+(
+  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
+    eval ac_val=\$$ac_var
+    case $ac_val in #(
+    *${as_nl}*)
+      case $ac_var in #(
+      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
+      esac
+      case $ac_var in #(
+      _ | IFS | as_nl) ;; #(
+      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
+      *) { eval $ac_var=; unset $ac_var;} ;;
+      esac ;;
+    esac
+  done
+  (set) 2>&1 |
+    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
+    *${as_nl}ac_space=\ *)
+      sed -n \
+	"s/'\''/'\''\\\\'\'''\''/g;
+	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
+      ;; #(
+    *)
+      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
+      ;;
+    esac |
+    sort
+)
+    echo
+
+    $as_echo "## ----------------- ##
+## Output variables. ##
+## ----------------- ##"
+    echo
+    for ac_var in $ac_subst_vars
+    do
+      eval ac_val=\$$ac_var
+      case $ac_val in
+      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+      esac
+      $as_echo "$ac_var='\''$ac_val'\''"
+    done | sort
+    echo
+
+    if test -n "$ac_subst_files"; then
+      $as_echo "## ------------------- ##
+## File substitutions. ##
+## ------------------- ##"
+      echo
+      for ac_var in $ac_subst_files
+      do
+	eval ac_val=\$$ac_var
+	case $ac_val in
+	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
+	esac
+	$as_echo "$ac_var='\''$ac_val'\''"
+      done | sort
+      echo
+    fi
+
+    if test -s confdefs.h; then
+      $as_echo "## ----------- ##
+## confdefs.h. ##
+## ----------- ##"
+      echo
+      cat confdefs.h
+      echo
+    fi
+    test "$ac_signal" != 0 &&
+      $as_echo "$as_me: caught signal $ac_signal"
+    $as_echo "$as_me: exit $exit_status"
+  } >&5
+  rm -f core *.core core.conftest.* &&
+    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
+    exit $exit_status
+' 0
+for ac_signal in 1 2 13 15; do
+  trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
+done
+ac_signal=0
+
+# confdefs.h avoids OS command line length limits that DEFS can exceed.
+rm -f -r conftest* confdefs.h
+
+$as_echo "/* confdefs.h */" > confdefs.h
+
+# Predefined preprocessor variables.
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_NAME "$PACKAGE_NAME"
+_ACEOF
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
+_ACEOF
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_VERSION "$PACKAGE_VERSION"
+_ACEOF
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_STRING "$PACKAGE_STRING"
+_ACEOF
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
+_ACEOF
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_URL "$PACKAGE_URL"
+_ACEOF
+
+
+# Let the site file select an alternate cache file if it wants to.
+# Prefer an explicitly selected file to automatically selected ones.
+ac_site_file1=NONE
+ac_site_file2=NONE
+if test -n "$CONFIG_SITE"; then
+  # We do not want a PATH search for config.site.
+  case $CONFIG_SITE in #((
+    -*)  ac_site_file1=./$CONFIG_SITE;;
+    */*) ac_site_file1=$CONFIG_SITE;;
+    *)   ac_site_file1=./$CONFIG_SITE;;
+  esac
+elif test "x$prefix" != xNONE; then
+  ac_site_file1=$prefix/share/config.site
+  ac_site_file2=$prefix/etc/config.site
+else
+  ac_site_file1=$ac_default_prefix/share/config.site
+  ac_site_file2=$ac_default_prefix/etc/config.site
+fi
+for ac_site_file in "$ac_site_file1" "$ac_site_file2"
+do
+  test "x$ac_site_file" = xNONE && continue
+  if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
+$as_echo "$as_me: loading site script $ac_site_file" >&6;}
+    sed 's/^/| /' "$ac_site_file" >&5
+    . "$ac_site_file" \
+      || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "failed to load site script $ac_site_file
+See \`config.log' for more details" "$LINENO" 5 ; }
+  fi
+done
+
+if test -r "$cache_file"; then
+  # Some versions of bash will fail to source /dev/null (special files
+  # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
+  if test /dev/null != "$cache_file" && test -f "$cache_file"; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
+$as_echo "$as_me: loading cache $cache_file" >&6;}
+    case $cache_file in
+      [\\/]* | ?:[\\/]* ) . "$cache_file";;
+      *)                      . "./$cache_file";;
+    esac
+  fi
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
+$as_echo "$as_me: creating cache $cache_file" >&6;}
+  >$cache_file
+fi
+
+# Check that the precious variables saved in the cache have kept the same
+# value.
+ac_cache_corrupted=false
+for ac_var in $ac_precious_vars; do
+  eval ac_old_set=\$ac_cv_env_${ac_var}_set
+  eval ac_new_set=\$ac_env_${ac_var}_set
+  eval ac_old_val=\$ac_cv_env_${ac_var}_value
+  eval ac_new_val=\$ac_env_${ac_var}_value
+  case $ac_old_set,$ac_new_set in
+    set,)
+      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
+$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
+      ac_cache_corrupted=: ;;
+    ,set)
+      { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
+$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
+      ac_cache_corrupted=: ;;
+    ,);;
+    *)
+      if test "x$ac_old_val" != "x$ac_new_val"; then
+	# differences in whitespace do not lead to failure.
+	ac_old_val_w=`echo x $ac_old_val`
+	ac_new_val_w=`echo x $ac_new_val`
+	if test "$ac_old_val_w" != "$ac_new_val_w"; then
+	  { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
+$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
+	  ac_cache_corrupted=:
+	else
+	  { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
+$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
+	  eval $ac_var=\$ac_old_val
+	fi
+	{ $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
+$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
+	{ $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
+$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
+      fi;;
+  esac
+  # Pass precious variables to config.status.
+  if test "$ac_new_set" = set; then
+    case $ac_new_val in
+    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
+    *) ac_arg=$ac_var=$ac_new_val ;;
+    esac
+    case " $ac_configure_args " in
+      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
+      *) as_fn_append ac_configure_args " '$ac_arg'" ;;
+    esac
+  fi
+done
+if $ac_cache_corrupted; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+  { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
+$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
+  as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
+fi
+## -------------------- ##
+## Main body of script. ##
+## -------------------- ##
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+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
+
+
+
+# Prepare to generate the config.h.in file
+ac_config_headers="$ac_config_headers config.h"
+
+
+# untested on earlier than 2.52, but it won't work anyway
+
+
+# Find out what type of system we're running on
+ac_aux_dir=
+for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
+  if test -f "$ac_dir/install-sh"; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install-sh -c"
+    break
+  elif test -f "$ac_dir/install.sh"; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/install.sh -c"
+    break
+  elif test -f "$ac_dir/shtool"; then
+    ac_aux_dir=$ac_dir
+    ac_install_sh="$ac_aux_dir/shtool install -c"
+    break
+  fi
+done
+if test -z "$ac_aux_dir"; then
+  as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
+fi
+
+# These three variables are undocumented and unsupported,
+# and are intended to be withdrawn in a future Autoconf release.
+# They can cause serious problems if a builder's source tree is in a directory
+# whose full name contains unusual characters.
+ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
+ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
+ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
+
+
+# Make sure we can run config.sub.
+$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
+  as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
+
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
+$as_echo_n "checking build system type... " >&6; }
+if test "${ac_cv_build+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  ac_build_alias=$build_alias
+test "x$ac_build_alias" = x &&
+  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
+test "x$ac_build_alias" = x &&
+  as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
+ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
+  as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
+$as_echo "$ac_cv_build" >&6; }
+case $ac_cv_build in
+*-*-*) ;;
+*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5 ;;
+esac
+build=$ac_cv_build
+ac_save_IFS=$IFS; IFS='-'
+set x $ac_cv_build
+shift
+build_cpu=$1
+build_vendor=$2
+shift; shift
+# Remember, the first character of IFS is used to create $*,
+# except with old shells:
+build_os=$*
+IFS=$ac_save_IFS
+case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
+
+
+
+Platform="$build_cpu-$build_vendor-$build_os"
+
+# This isn't right for msys mingw.
+PREFIX="$prefix"
+if test "$prefix" = "NONE"
+then
+  if test "$build_os" = "cygwin"
+  then
+    PREFIX="c:/cygwin$ac_default_prefix"
+  else
+    PREFIX="$ac_default_prefix"
+  fi
+fi
+
+
+case $Platform in
+*-apple-darwin*)
+        MACOSX=yes
+
+cat >>confdefs.h <<_ACEOF
+#define MACOSX 1
+_ACEOF
+
+        LEADING_UNDERSCORE=1
+	;;
+*)
+        MACOSX=no
+        LEADING_UNDERSCORE=0
+	;;
+esac
+
+if test "$build_os" = "mingw32"
+then
+
+$as_echo "#define __MINGW32__ 1" >>confdefs.h
+
+  LEADING_UNDERSCORE=1
+fi
+
+if test "$build_os" = "cygwin"
+then
+
+$as_echo "#define CYGWIN 1" >>confdefs.h
+
+  LEADING_UNDERSCORE=1
+fi
+
+
+cat >>confdefs.h <<_ACEOF
+#define LEADING_UNDERSCORE $LEADING_UNDERSCORE
+_ACEOF
+
+
+# Find pwd, in a cygwin friendly way.
+# Suggested by: http://www.haskell.org/ghc/docs/latest/html/users_guide/ch11s04.html
+TOP=`echo "System.Directory.getCurrentDirectory >>= putStrLn.init.tail.show " | ghc --interactive -ignore-dot-ghci -v0 | tr -d '\r'`
+
+
+cat >>confdefs.h <<_ACEOF
+#define TOP "$TOP"
+_ACEOF
+
+
+
+# necessary tools
+
+# allow user supplied haskell compiler
+
+# Check whether --with-ghc was given.
+if test "${with_ghc+set}" = set; then :
+  withval=$with_ghc;  GHC="$withval"
+    if test ! -f "$GHC" ; then
+       as_fn_error $? "$GHC not found. You need GHC to build this project" "$LINENO" 5
+    fi
+
+else
+   # Extract the first word of "ghc", so it can be a program name with args.
+set dummy ghc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_GHC+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$GHC"; then
+  ac_cv_prog_GHC="$GHC" # 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_GHC="ghc"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+GHC=$ac_cv_prog_GHC
+if test -n "$GHC"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GHC" >&5
+$as_echo "$GHC" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+    if test -z "$GHC" ; then
+       as_fn_error $? "You need GHC to build this project" "$LINENO" 5
+    fi
+
+
+fi
+
+
+cat >>confdefs.h <<_ACEOF
+#define WITH_GHC "$GHC"
+_ACEOF
+
+
+
+# Work out value of __GLASGOW_HASKELL__
+if test -n "$GHC" ; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for value of __GLASGOW_HASKELL__" >&5
+$as_echo_n "checking for value of __GLASGOW_HASKELL__... " >&6; }
+ echo "main = print __GLASGOW_HASKELL__" > t.hs
+ GLASGOW_HASKELL=`echo 'main' | "$GHC" --interactive -ignore-dot-ghci -v0 -cpp t.hs`
+ rm t.hs
+ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GLASGOW_HASKELL" >&5
+$as_echo "$GLASGOW_HASKELL" >&6; }
+fi
+
+
+# find path to GHC libs, for runtime_loader
+if test -n "$GHC" ; then
+    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ghc library directory" >&5
+$as_echo_n "checking for ghc library directory... " >&6; }
+    GHC_LIB_PATH=`$GHC --print-libdir | tr -d '\r'`
+    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GHC_LIB_PATH" >&5
+$as_echo "$GHC_LIB_PATH" >&6; }
+fi
+
+cat >>confdefs.h <<_ACEOF
+#define GHC_LIB_PATH "$GHC_LIB_PATH"
+_ACEOF
+
+
+# Allow a debugging version of hs-plugins to be built
+# Check whether --enable-debug was given.
+if test "${enable_debug+set}" = set; then :
+  enableval=$enable_debug;
+
+cat >>confdefs.h <<_ACEOF
+#define DEBUG 1
+_ACEOF
+
+else
+   :
+fi
+
+
+# Allow a debugging version of hs-plugins to be built
+# Check whether --enable-hsx was given.
+if test "${enable_hsx+set}" = set; then :
+  enableval=$enable_hsx;  HASKELL_SRC=haskell-src-exts ;
+
+cat >>confdefs.h <<_ACEOF
+#define WITH_HSX 1
+_ACEOF
+
+else
+   HASKELL_SRC=haskell-src
+fi
+
+
+
+
+#AC_CHECK_PROG(TEX,tex,tex)
+#if test -z "$TEX" ; then
+#    AC_MSG_WARN(tex is needed to build some of the documentation)
+#fi
+#AC_CHECK_PROG(TEX2PAGE,tex2page,tex2page)
+#if test -z "$TEX2PAGE" ; then
+#    AC_MSG_WARN(tex2page is needed to build some of the documentation
+#		    http://www.ccs.neu.edu/home/dorai/tex2page/tex2page-doc.html)
+#fi
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
+set dummy ${ac_tool_prefix}gcc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_CC+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$CC"; then
+  ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_CC="${ac_tool_prefix}gcc"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+$as_echo "$CC" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+fi
+if test -z "$ac_cv_prog_CC"; then
+  ac_ct_CC=$CC
+  # Extract the first word of "gcc", so it can be a program name with args.
+set dummy gcc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$ac_ct_CC"; then
+  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_CC="gcc"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_CC=$ac_cv_prog_ac_ct_CC
+if test -n "$ac_ct_CC"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+$as_echo "$ac_ct_CC" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+  if test "x$ac_ct_CC" = x; then
+    CC=""
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+    CC=$ac_ct_CC
+  fi
+else
+  CC="$ac_cv_prog_CC"
+fi
+
+if test -z "$CC"; then
+          if test -n "$ac_tool_prefix"; then
+    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
+set dummy ${ac_tool_prefix}cc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_CC+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$CC"; then
+  ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_CC="${ac_tool_prefix}cc"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+$as_echo "$CC" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+  fi
+fi
+if test -z "$CC"; then
+  # Extract the first word of "cc", so it can be a program name with args.
+set dummy cc; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_CC+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$CC"; then
+  ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+  ac_prog_rejected=no
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
+       ac_prog_rejected=yes
+       continue
+     fi
+    ac_cv_prog_CC="cc"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+if test $ac_prog_rejected = yes; then
+  # We found a bogon in the path, so make sure we never use it.
+  set dummy $ac_cv_prog_CC
+  shift
+  if test $# != 0; then
+    # We chose a different compiler from the bogus one.
+    # However, it has the same basename, so the bogon will be chosen
+    # first if we set CC to just the basename; use the full file name.
+    shift
+    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
+  fi
+fi
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+$as_echo "$CC" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+fi
+if test -z "$CC"; then
+  if test -n "$ac_tool_prefix"; then
+  for ac_prog in cl.exe
+  do
+    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_CC+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$CC"; then
+  ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
+$as_echo "$CC" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+    test -n "$CC" && break
+  done
+fi
+if test -z "$CC"; then
+  ac_ct_CC=$CC
+  for ac_prog in cl.exe
+do
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
+$as_echo_n "checking for $ac_word... " >&6; }
+if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  if test -n "$ac_ct_CC"; then
+  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_CC="$ac_prog"
+    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+  done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_CC=$ac_cv_prog_ac_ct_CC
+if test -n "$ac_ct_CC"; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
+$as_echo "$ac_ct_CC" >&6; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+fi
+
+
+  test -n "$ac_ct_CC" && break
+done
+
+  if test "x$ac_ct_CC" = x; then
+    CC=""
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
+$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
+ac_tool_warned=yes ;;
+esac
+    CC=$ac_ct_CC
+  fi
+fi
+
+fi
+
+
+test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "no acceptable C compiler found in \$PATH
+See \`config.log' for more details" "$LINENO" 5 ; }
+
+# Provide some information about the compiler.
+$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
+set X $ac_compile
+ac_compiler=$2
+for ac_option in --version -v -V -qversion; do
+  { { ac_try="$ac_compiler $ac_option >&5"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_compiler $ac_option >&5") 2>conftest.err
+  ac_status=$?
+  if test -s conftest.err; then
+    sed '10a\
+... rest of stderr output deleted ...
+         10q' conftest.err >conftest.er1
+    cat conftest.er1 >&5
+  fi
+  rm -f conftest.er1 conftest.err
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }
+done
+
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+ac_clean_files_save=$ac_clean_files
+ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
+# Try to create an executable without -o first, disregard a.out.
+# It will help us diagnose broken compilers, and finding out an intuition
+# of exeext.
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
+$as_echo_n "checking whether the C compiler works... " >&6; }
+ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
+
+# The possible output files:
+ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
+
+ac_rmfiles=
+for ac_file in $ac_files
+do
+  case $ac_file in
+    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
+    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
+  esac
+done
+rm -f $ac_rmfiles
+
+if { { ac_try="$ac_link_default"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_link_default") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; then :
+  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
+# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
+# in a Makefile.  We should not override ac_cv_exeext if it was cached,
+# so that the user can short-circuit this test for compilers unknown to
+# Autoconf.
+for ac_file in $ac_files ''
+do
+  test -f "$ac_file" || continue
+  case $ac_file in
+    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
+	;;
+    [ab].out )
+	# We found the default executable, but exeext='' is most
+	# certainly right.
+	break;;
+    *.* )
+	if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
+	then :; else
+	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
+	fi
+	# We set ac_cv_exeext here because the later test for it is not
+	# safe: cross compilers may not add the suffix if given an `-o'
+	# argument, so we may need to know it at that point already.
+	# Even if this section looks crufty: it has the advantage of
+	# actually working.
+	break;;
+    * )
+	break;;
+  esac
+done
+test "$ac_cv_exeext" = no && ac_cv_exeext=
+
+else
+  ac_file=''
+fi
+if test -z "$ac_file"; then :
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
+$as_echo "no" >&6; }
+$as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error 77 "C compiler cannot create executables
+See \`config.log' for more details" "$LINENO" 5 ; }
+else
+  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
+$as_echo "yes" >&6; }
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
+$as_echo_n "checking for C compiler default output file name... " >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
+$as_echo "$ac_file" >&6; }
+ac_exeext=$ac_cv_exeext
+
+rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
+ac_clean_files=$ac_clean_files_save
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
+$as_echo_n "checking for suffix of executables... " >&6; }
+if { { ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_link") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; then :
+  # If both `conftest.exe' and `conftest' are `present' (well, observable)
+# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
+# work properly (i.e., refer to `conftest.exe'), while it won't with
+# `rm'.
+for ac_file in conftest.exe conftest conftest.*; do
+  test -f "$ac_file" || continue
+  case $ac_file in
+    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
+    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
+	  break;;
+    * ) break;;
+  esac
+done
+else
+  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot compute suffix of executables: cannot compile and link
+See \`config.log' for more details" "$LINENO" 5 ; }
+fi
+rm -f conftest conftest$ac_cv_exeext
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
+$as_echo "$ac_cv_exeext" >&6; }
+
+rm -f conftest.$ac_ext
+EXEEXT=$ac_cv_exeext
+ac_exeext=$EXEEXT
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+#include <stdio.h>
+int
+main ()
+{
+FILE *f = fopen ("conftest.out", "w");
+ return ferror (f) || fclose (f) != 0;
+
+  ;
+  return 0;
+}
+_ACEOF
+ac_clean_files="$ac_clean_files conftest.out"
+# Check that the compiler produces executables we can run.  If not, either
+# the compiler is broken, or we cross compile.
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
+$as_echo_n "checking whether we are cross compiling... " >&6; }
+if test "$cross_compiling" != yes; then
+  { { ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_link") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }
+  if { ac_try='./conftest$ac_cv_exeext'
+  { { case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_try") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; }; then
+    cross_compiling=no
+  else
+    if test "$cross_compiling" = maybe; then
+	cross_compiling=yes
+    else
+	{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot run C compiled programs.
+If you meant to cross compile, use \`--host'.
+See \`config.log' for more details" "$LINENO" 5 ; }
+    fi
+  fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
+$as_echo "$cross_compiling" >&6; }
+
+rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
+ac_clean_files=$ac_clean_files_save
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
+$as_echo_n "checking for suffix of object files... " >&6; }
+if test "${ac_cv_objext+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.o conftest.obj
+if { { ac_try="$ac_compile"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
+$as_echo "$ac_try_echo"; } >&5
+  (eval "$ac_compile") 2>&5
+  ac_status=$?
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; then :
+  for ac_file in conftest.o conftest.obj conftest.*; do
+  test -f "$ac_file" || continue;
+  case $ac_file in
+    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
+    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
+       break;;
+  esac
+done
+else
+  $as_echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "cannot compute suffix of object files: cannot compile
+See \`config.log' for more details" "$LINENO" 5 ; }
+fi
+rm -f conftest.$ac_cv_objext conftest.$ac_ext
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
+$as_echo "$ac_cv_objext" >&6; }
+OBJEXT=$ac_cv_objext
+ac_objext=$OBJEXT
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
+$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
+if test "${ac_cv_c_compiler_gnu+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+#ifndef __GNUC__
+       choke me
+#endif
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_compiler_gnu=yes
+else
+  ac_compiler_gnu=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ac_cv_c_compiler_gnu=$ac_compiler_gnu
+
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
+$as_echo "$ac_cv_c_compiler_gnu" >&6; }
+if test $ac_compiler_gnu = yes; then
+  GCC=yes
+else
+  GCC=
+fi
+ac_test_CFLAGS=${CFLAGS+set}
+ac_save_CFLAGS=$CFLAGS
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
+$as_echo_n "checking whether $CC accepts -g... " >&6; }
+if test "${ac_cv_prog_cc_g+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  ac_save_c_werror_flag=$ac_c_werror_flag
+   ac_c_werror_flag=yes
+   ac_cv_prog_cc_g=no
+   CFLAGS="-g"
+   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_prog_cc_g=yes
+else
+  CFLAGS=""
+      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+
+else
+  ac_c_werror_flag=$ac_save_c_werror_flag
+	 CFLAGS="-g"
+	 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_prog_cc_g=yes
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+   ac_c_werror_flag=$ac_save_c_werror_flag
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
+$as_echo "$ac_cv_prog_cc_g" >&6; }
+if test "$ac_test_CFLAGS" = set; then
+  CFLAGS=$ac_save_CFLAGS
+elif test $ac_cv_prog_cc_g = yes; then
+  if test "$GCC" = yes; then
+    CFLAGS="-g -O2"
+  else
+    CFLAGS="-g"
+  fi
+else
+  if test "$GCC" = yes; then
+    CFLAGS="-O2"
+  else
+    CFLAGS=
+  fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
+$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
+if test "${ac_cv_prog_cc_c89+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  ac_cv_prog_cc_c89=no
+ac_save_CC=$CC
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+#include <stdarg.h>
+#include <stdio.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
+struct buf { int x; };
+FILE * (*rcsopen) (struct buf *, struct stat *, int);
+static char *e (p, i)
+     char **p;
+     int i;
+{
+  return p[i];
+}
+static char *f (char * (*g) (char **, int), char **p, ...)
+{
+  char *s;
+  va_list v;
+  va_start (v,p);
+  s = g (p, va_arg (v,int));
+  va_end (v);
+  return s;
+}
+
+/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
+   function prototypes and stuff, but not '\xHH' hex character constants.
+   These don't provoke an error unfortunately, instead are silently treated
+   as 'x'.  The following induces an error, until -std is added to get
+   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
+   array size at least.  It's necessary to write '\x00'==0 to get something
+   that's true only with -std.  */
+int osf4_cc_array ['\x00' == 0 ? 1 : -1];
+
+/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
+   inside strings and character constants.  */
+#define FOO(x) 'x'
+int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
+
+int test (int i, double x);
+struct s1 {int (*f) (int a);};
+struct s2 {int (*f) (double a);};
+int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
+int argc;
+char **argv;
+int
+main ()
+{
+return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
+  ;
+  return 0;
+}
+_ACEOF
+for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
+	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
+do
+  CC="$ac_save_CC $ac_arg"
+  if ac_fn_c_try_compile "$LINENO"; then :
+  ac_cv_prog_cc_c89=$ac_arg
+fi
+rm -f core conftest.err conftest.$ac_objext
+  test "x$ac_cv_prog_cc_c89" != "xno" && break
+done
+rm -f conftest.$ac_ext
+CC=$ac_save_CC
+
+fi
+# AC_CACHE_VAL
+case "x$ac_cv_prog_cc_c89" in
+  x)
+    { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
+$as_echo "none needed" >&6; } ;;
+  xno)
+    { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
+$as_echo "unsupported" >&6; } ;;
+  *)
+    CC="$CC $ac_cv_prog_cc_c89"
+    { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
+$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
+esac
+if test "x$ac_cv_prog_cc_c89" != xno; then :
+
+fi
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+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
+
+
+for ac_func in arc4random
+do :
+  ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random"
+if test "x$ac_cv_func_arc4random" = x""yes; then :
+  cat >>confdefs.h <<_ACEOF
+#define HAVE_ARC4RANDOM 1
+_ACEOF
+
+fi
+done
+
+
+# Find a good install program.  We prefer a C program (faster),
+# so one script is as good as another.  But avoid the broken or
+# incompatible versions:
+# SysV /etc/install, /usr/sbin/install
+# SunOS /usr/etc/install
+# IRIX /sbin/install
+# AIX /bin/install
+# AmigaOS /C/install, which installs bootblocks on floppy discs
+# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
+# AFS /usr/afsws/bin/install, which mishandles nonexistent args
+# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
+# OS/2's system install, which has a completely different semantic
+# ./install, which can be erroneously created by make from ./install.sh.
+# Reject install programs that cannot install multiple files.
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
+$as_echo_n "checking for a BSD-compatible install... " >&6; }
+if test -z "$INSTALL"; then
+if test "${ac_cv_path_install+set}" = set; then :
+  $as_echo_n "(cached) " >&6
+else
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    # Account for people who put trailing slashes in PATH elements.
+case $as_dir/ in #((
+  ./ | .// | /[cC]/* | \
+  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
+  ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
+  /usr/ucb/* ) ;;
+  *)
+    # OSF1 and SCO ODT 3.0 have their own names for install.
+    # Don't use installbsd from OSF since it installs stuff as root
+    # by default.
+    for ac_prog in ginstall scoinst install; do
+      for ac_exec_ext in '' $ac_executable_extensions; do
+	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
+	  if test $ac_prog = install &&
+	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+	    # AIX install.  It has an incompatible calling convention.
+	    :
+	  elif test $ac_prog = install &&
+	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+	    # program-specific install script used by HP pwplus--don't use.
+	    :
+	  else
+	    rm -rf conftest.one conftest.two conftest.dir
+	    echo one > conftest.one
+	    echo two > conftest.two
+	    mkdir conftest.dir
+	    if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
+	      test -s conftest.one && test -s conftest.two &&
+	      test -s conftest.dir/conftest.one &&
+	      test -s conftest.dir/conftest.two
+	    then
+	      ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
+	      break 3
+	    fi
+	  fi
+	fi
+      done
+    done
+    ;;
+esac
+
+  done
+IFS=$as_save_IFS
+
+rm -rf conftest.one conftest.two conftest.dir
+
+fi
+  if test "${ac_cv_path_install+set}" = set; then
+    INSTALL=$ac_cv_path_install
+  else
+    # As a last resort, use the slow shell script.  Don't cache a
+    # value for INSTALL within a source directory, because that will
+    # break other packages using the cache if that directory is
+    # removed, or if the value is a relative name.
+    INSTALL=$ac_install_sh
+  fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
+$as_echo "$INSTALL" >&6; }
+
+# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
+# It thinks the first close brace ends the variable substitution.
+test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
+
+test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
+
+test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
+
+# System.Process uses cmd or command.com shell on Windows, doen't use Cygwin or MSYS shell
+ac_config_files="$ac_config_files config.mk testsuite/makewith/io/TestIO.conf testsuite/makewith/unsafeio/Unsafe.conf"
+
+cat >confcache <<\_ACEOF
+# This file is a shell script that caches the results of configure
+# tests run on this system so they can be shared between configure
+# scripts and configure runs, see configure's option --config-cache.
+# It is not useful on other systems.  If it contains results you don't
+# want to keep, you may remove or edit it.
+#
+# config.status only pays attention to the cache file if you give it
+# the --recheck option to rerun configure.
+#
+# `ac_cv_env_foo' variables (set or unset) will be overridden when
+# loading this file, other *unset* `ac_cv_foo' will be assigned the
+# following values.
+
+_ACEOF
+
+# The following way of writing the cache mishandles newlines in values,
+# but we know of no workaround that is simple, portable, and efficient.
+# So, we kill variables containing newlines.
+# Ultrix sh set writes to stderr and can't be redirected directly,
+# and sets the high bit in the cache file unless we assign to the vars.
+(
+  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
+    eval ac_val=\$$ac_var
+    case $ac_val in #(
+    *${as_nl}*)
+      case $ac_var in #(
+      *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
+$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
+      esac
+      case $ac_var in #(
+      _ | IFS | as_nl) ;; #(
+      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
+      *) { eval $ac_var=; unset $ac_var;} ;;
+      esac ;;
+    esac
+  done
+
+  (set) 2>&1 |
+    case $as_nl`(ac_space=' '; set) 2>&1` in #(
+    *${as_nl}ac_space=\ *)
+      # `set' does not quote correctly, so add quotes: double-quote
+      # substitution turns \\\\ into \\, and sed turns \\ into \.
+      sed -n \
+	"s/'/'\\\\''/g;
+	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
+      ;; #(
+    *)
+      # `set' quotes correctly as required by POSIX, so do not add quotes.
+      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
+      ;;
+    esac |
+    sort
+) |
+  sed '
+     /^ac_cv_env_/b end
+     t clear
+     :clear
+     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
+     t end
+     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
+     :end' >>confcache
+if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
+  if test -w "$cache_file"; then
+    test "x$cache_file" != "x/dev/null" &&
+      { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
+$as_echo "$as_me: updating cache $cache_file" >&6;}
+    cat confcache >$cache_file
+  else
+    { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
+$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
+  fi
+fi
+rm -f confcache
+
+test "x$prefix" = xNONE && prefix=$ac_default_prefix
+# Let make expand exec_prefix.
+test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
+
+DEFS=-DHAVE_CONFIG_H
+
+ac_libobjs=
+ac_ltlibobjs=
+U=
+for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
+  # 1. Remove the extension, and $U if already installed.
+  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
+  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
+  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
+  #    will be set to the directory where LIBOBJS objects are built.
+  as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
+  as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
+done
+LIBOBJS=$ac_libobjs
+
+LTLIBOBJS=$ac_ltlibobjs
+
+
+
+: ${CONFIG_STATUS=./config.status}
+ac_write_fail=0
+ac_clean_files_save=$ac_clean_files
+ac_clean_files="$ac_clean_files $CONFIG_STATUS"
+{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
+$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
+as_write_fail=0
+cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
+#! $SHELL
+# Generated by $as_me.
+# Run this file to recreate the current configuration.
+# Compiler output produced by configure, useful for debugging
+# configure, is in config.log if it exists.
+
+debug=false
+ac_cs_recheck=false
+ac_cs_silent=false
+
+SHELL=\${CONFIG_SHELL-$SHELL}
+export SHELL
+_ASEOF
+cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
+## -------------------- ##
+## M4sh Initialization. ##
+## -------------------- ##
+
+# Be more Bourne compatible
+DUALCASE=1; export DUALCASE # for MKS sh
+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
+  emulate sh
+  NULLCMD=:
+  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
+  # is contrary to our usage.  Disable this feature.
+  alias -g '${1+"$@"}'='"$@"'
+  setopt NO_GLOB_SUBST
+else
+  case `(set -o) 2>/dev/null` in #(
+  *posix*) :
+    set -o posix ;; #(
+  *) :
+     ;;
+esac
+fi
+
+
+as_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
+# Prefer a ksh shell builtin over an external printf program on Solaris,
+# but without wasting forks for bash or zsh.
+if test -z "$BASH_VERSION$ZSH_VERSION" \
+    && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
+  as_echo='print -r --'
+  as_echo_n='print -rn --'
+elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
+  as_echo='printf %s\n'
+  as_echo_n='printf %s'
+else
+  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
+    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
+    as_echo_n='/usr/ucb/echo -n'
+  else
+    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
+    as_echo_n_body='eval
+      arg=$1;
+      case $arg in #(
+      *"$as_nl"*)
+	expr "X$arg" : "X\\(.*\\)$as_nl";
+	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
+      esac;
+      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
+    '
+    export as_echo_n_body
+    as_echo_n='sh -c $as_echo_n_body as_echo'
+  fi
+  export as_echo_body
+  as_echo='sh -c $as_echo_body as_echo'
+fi
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+  PATH_SEPARATOR=:
+  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
+    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
+      PATH_SEPARATOR=';'
+  }
+fi
+
+
+# IFS
+# We need space, tab and new line, in precisely that order.  Quoting is
+# there to prevent editors from complaining about space-tab.
+# (If _AS_PATH_WALK were called with IFS unset, it would disable word
+# splitting by setting IFS to empty value.)
+IFS=" ""	$as_nl"
+
+# Find who we are.  Look in the path if we contain no directory separator.
+case $0 in #((
+  *[\\/]* ) as_myself=$0 ;;
+  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+    test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+  done
+IFS=$as_save_IFS
+
+     ;;
+esac
+# We did not find ourselves, most probably we were run as `sh COMMAND'
+# in which case we are not to be found in the path.
+if test "x$as_myself" = x; then
+  as_myself=$0
+fi
+if test ! -f "$as_myself"; then
+  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
+  exit 1
+fi
+
+# Unset variables that we do not need and which cause bugs (e.g. in
+# pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
+# suppresses any "Segmentation fault" message there.  '((' could
+# trigger a bug in pdksh 5.2.14.
+for as_var in BASH_ENV ENV MAIL MAILPATH
+do eval test x\${$as_var+set} = xset \
+  && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
+done
+PS1='$ '
+PS2='> '
+PS4='+ '
+
+# NLS nuisances.
+LC_ALL=C
+export LC_ALL
+LANGUAGE=C
+export LANGUAGE
+
+# CDPATH.
+(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
+
+
+# as_fn_error STATUS ERROR [LINENO LOG_FD]
+# ----------------------------------------
+# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
+# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
+# script with STATUS, using 1 if that was 0.
+as_fn_error ()
+{
+  as_status=$1; test $as_status -eq 0 && as_status=1
+  if test "$4"; then
+    as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
+    $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
+  fi
+  $as_echo "$as_me: error: $2" >&2
+  as_fn_exit $as_status
+} # as_fn_error
+
+
+# as_fn_set_status STATUS
+# -----------------------
+# Set $? to STATUS, without forking.
+as_fn_set_status ()
+{
+  return $1
+} # as_fn_set_status
+
+# as_fn_exit STATUS
+# -----------------
+# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
+as_fn_exit ()
+{
+  set +e
+  as_fn_set_status $1
+  exit $1
+} # as_fn_exit
+
+# as_fn_unset VAR
+# ---------------
+# Portably unset VAR.
+as_fn_unset ()
+{
+  { eval $1=; unset $1;}
+}
+as_unset=as_fn_unset
+# as_fn_append VAR VALUE
+# ----------------------
+# Append the text in VALUE to the end of the definition contained in VAR. Take
+# advantage of any shell optimizations that allow amortized linear growth over
+# repeated appends, instead of the typical quadratic growth present in naive
+# implementations.
+if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
+  eval 'as_fn_append ()
+  {
+    eval $1+=\$2
+  }'
+else
+  as_fn_append ()
+  {
+    eval $1=\$$1\$2
+  }
+fi # as_fn_append
+
+# as_fn_arith ARG...
+# ------------------
+# Perform arithmetic evaluation on the ARGs, and store the result in the
+# global $as_val. Take advantage of shells that can avoid forks. The arguments
+# must be portable across $(()) and expr.
+if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
+  eval 'as_fn_arith ()
+  {
+    as_val=$(( $* ))
+  }'
+else
+  as_fn_arith ()
+  {
+    as_val=`expr "$@" || test $? -eq 1`
+  }
+fi # as_fn_arith
+
+
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+   test "X`expr 00001 : '.*\(...\)'`" = X001; then
+  as_expr=expr
+else
+  as_expr=false
+fi
+
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
+  as_basename=basename
+else
+  as_basename=false
+fi
+
+if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
+  as_dirname=dirname
+else
+  as_dirname=false
+fi
+
+as_me=`$as_basename -- "$0" ||
+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
+	 X"$0" : 'X\(//\)$' \| \
+	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X/"$0" |
+    sed '/^.*\/\([^/][^/]*\)\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\/\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
+
+# Avoid depending upon Character Ranges.
+as_cr_letters='abcdefghijklmnopqrstuvwxyz'
+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
+as_cr_Letters=$as_cr_letters$as_cr_LETTERS
+as_cr_digits='0123456789'
+as_cr_alnum=$as_cr_Letters$as_cr_digits
+
+ECHO_C= ECHO_N= ECHO_T=
+case `echo -n x` in #(((((
+-n*)
+  case `echo 'xy\c'` in
+  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
+  xy)  ECHO_C='\c';;
+  *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
+       ECHO_T='	';;
+  esac;;
+*)
+  ECHO_N='-n';;
+esac
+
+rm -f conf$$ conf$$.exe conf$$.file
+if test -d conf$$.dir; then
+  rm -f conf$$.dir/conf$$.file
+else
+  rm -f conf$$.dir
+  mkdir conf$$.dir 2>/dev/null
+fi
+if (echo >conf$$.file) 2>/dev/null; then
+  if ln -s conf$$.file conf$$ 2>/dev/null; then
+    as_ln_s='ln -s'
+    # ... but there are two gotchas:
+    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
+    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
+    # In both cases, we have to default to `cp -p'.
+    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
+      as_ln_s='cp -p'
+  elif ln conf$$.file conf$$ 2>/dev/null; then
+    as_ln_s=ln
+  else
+    as_ln_s='cp -p'
+  fi
+else
+  as_ln_s='cp -p'
+fi
+rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
+rmdir conf$$.dir 2>/dev/null
+
+
+# as_fn_mkdir_p
+# -------------
+# Create "$as_dir" as a directory, including parents if necessary.
+as_fn_mkdir_p ()
+{
+
+  case $as_dir in #(
+  -*) as_dir=./$as_dir;;
+  esac
+  test -d "$as_dir" || eval $as_mkdir_p || {
+    as_dirs=
+    while :; do
+      case $as_dir in #(
+      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
+      *) as_qdir=$as_dir;;
+      esac
+      as_dirs="'$as_qdir' $as_dirs"
+      as_dir=`$as_dirname -- "$as_dir" ||
+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+	 X"$as_dir" : 'X\(//\)[^/]' \| \
+	 X"$as_dir" : 'X\(//\)$' \| \
+	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X"$as_dir" |
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)[^/].*/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
+      test -d "$as_dir" && break
+    done
+    test -z "$as_dirs" || eval "mkdir $as_dirs"
+  } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
+
+
+} # as_fn_mkdir_p
+if mkdir -p . 2>/dev/null; then
+  as_mkdir_p='mkdir -p "$as_dir"'
+else
+  test -d ./-p && rmdir ./-p
+  as_mkdir_p=false
+fi
+
+if test -x / >/dev/null 2>&1; then
+  as_test_x='test -x'
+else
+  if ls -dL / >/dev/null 2>&1; then
+    as_ls_L_option=L
+  else
+    as_ls_L_option=
+  fi
+  as_test_x='
+    eval sh -c '\''
+      if test -d "$1"; then
+	test -d "$1/.";
+      else
+	case $1 in #(
+	-*)set "./$1";;
+	esac;
+	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
+	???[sx]*):;;*)false;;esac;fi
+    '\'' sh
+  '
+fi
+as_executable_p=$as_test_x
+
+# Sed expression to map a string onto a valid CPP name.
+as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
+
+# Sed expression to map a string onto a valid variable name.
+as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
+
+
+exec 6>&1
+## ----------------------------------- ##
+## Main body of $CONFIG_STATUS script. ##
+## ----------------------------------- ##
+_ASEOF
+test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
+
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+# Save the log message, to keep $0 and so on meaningful, and to
+# report actual input values of CONFIG_FILES etc. instead of their
+# values after options handling.
+ac_log="
+This file was extended by $as_me, which was
+generated by GNU Autoconf 2.67.  Invocation command line was
+
+  CONFIG_FILES    = $CONFIG_FILES
+  CONFIG_HEADERS  = $CONFIG_HEADERS
+  CONFIG_LINKS    = $CONFIG_LINKS
+  CONFIG_COMMANDS = $CONFIG_COMMANDS
+  $ $0 $@
+
+on `(hostname || uname -n) 2>/dev/null | sed 1q`
+"
+
+_ACEOF
+
+case $ac_config_files in *"
+"*) set x $ac_config_files; shift; ac_config_files=$*;;
+esac
+
+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"
+
+_ACEOF
+
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+ac_cs_usage="\
+\`$as_me' instantiates files and other configuration actions
+from templates according to the current configuration.  Unless the files
+and actions are specified as TAGs, all are instantiated by default.
+
+Usage: $0 [OPTION]... [TAG]...
+
+  -h, --help       print this help, then exit
+  -V, --version    print version number and configuration settings, then exit
+      --config     print configuration, then exit
+  -q, --quiet, --silent
+                   do not print progress messages
+  -d, --debug      don't remove temporary files
+      --recheck    update $as_me by reconfiguring in the same conditions
+      --file=FILE[:TEMPLATE]
+                   instantiate the configuration file FILE
+      --header=FILE[:TEMPLATE]
+                   instantiate the configuration header FILE
+
+Configuration files:
+$config_files
+
+Configuration headers:
+$config_headers
+
+Report bugs to the package provider."
+
+_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
+ac_cs_version="\\
+config.status
+configured by $0, generated by GNU Autoconf 2.67,
+  with options \\"\$ac_cs_config\\"
+
+Copyright (C) 2010 Free Software Foundation, Inc.
+This config.status script is free software; the Free Software Foundation
+gives unlimited permission to copy, distribute and modify it."
+
+ac_pwd='$ac_pwd'
+srcdir='$srcdir'
+INSTALL='$INSTALL'
+test -n "\$AWK" || AWK=awk
+_ACEOF
+
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+# The default lists apply if the user does not specify any file.
+ac_need_defaults=:
+while test $# != 0
+do
+  case $1 in
+  --*=?*)
+    ac_option=`expr "X$1" : 'X\([^=]*\)='`
+    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
+    ac_shift=:
+    ;;
+  --*=)
+    ac_option=`expr "X$1" : 'X\([^=]*\)='`
+    ac_optarg=
+    ac_shift=:
+    ;;
+  *)
+    ac_option=$1
+    ac_optarg=$2
+    ac_shift=shift
+    ;;
+  esac
+
+  case $ac_option in
+  # Handling of the options.
+  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
+    ac_cs_recheck=: ;;
+  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
+    $as_echo "$ac_cs_version"; exit ;;
+  --config | --confi | --conf | --con | --co | --c )
+    $as_echo "$ac_cs_config"; exit ;;
+  --debug | --debu | --deb | --de | --d | -d )
+    debug=: ;;
+  --file | --fil | --fi | --f )
+    $ac_shift
+    case $ac_optarg in
+    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
+    '') as_fn_error $? "missing file argument" ;;
+    esac
+    as_fn_append CONFIG_FILES " '$ac_optarg'"
+    ac_need_defaults=false;;
+  --header | --heade | --head | --hea )
+    $ac_shift
+    case $ac_optarg in
+    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
+    esac
+    as_fn_append CONFIG_HEADERS " '$ac_optarg'"
+    ac_need_defaults=false;;
+  --he | --h)
+    # Conflict between --help and --header
+    as_fn_error $? "ambiguous option: \`$1'
+Try \`$0 --help' for more information.";;
+  --help | --hel | -h )
+    $as_echo "$ac_cs_usage"; exit ;;
+  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
+  | -silent | --silent | --silen | --sile | --sil | --si | --s)
+    ac_cs_silent=: ;;
+
+  # This is an error.
+  -*) as_fn_error $? "unrecognized option: \`$1'
+Try \`$0 --help' for more information." ;;
+
+  *) as_fn_append ac_config_targets " $1"
+     ac_need_defaults=false ;;
+
+  esac
+  shift
+done
+
+ac_configure_extra_args=
+
+if $ac_cs_silent; then
+  exec 6>/dev/null
+  ac_configure_extra_args="$ac_configure_extra_args --silent"
+fi
+
+_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+if \$ac_cs_recheck; then
+  set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+  shift
+  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
+  CONFIG_SHELL='$SHELL'
+  export CONFIG_SHELL
+  exec "\$@"
+fi
+
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+exec 5>>config.log
+{
+  echo
+  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
+## Running $as_me. ##
+_ASBOX
+  $as_echo "$ac_log"
+} >&5
+
+_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+_ACEOF
+
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+
+# Handling of arguments.
+for ac_config_target in $ac_config_targets
+do
+  case $ac_config_target in
+    "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
+    "config.mk") CONFIG_FILES="$CONFIG_FILES config.mk" ;;
+    "testsuite/makewith/io/TestIO.conf") CONFIG_FILES="$CONFIG_FILES testsuite/makewith/io/TestIO.conf" ;;
+    "testsuite/makewith/unsafeio/Unsafe.conf") CONFIG_FILES="$CONFIG_FILES testsuite/makewith/unsafeio/Unsafe.conf" ;;
+
+  *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5 ;;
+  esac
+done
+
+
+# If the user did not use the arguments to specify the items to instantiate,
+# then the envvar interface is used.  Set only those that are not.
+# We use the long form for the default assignment because of an extremely
+# bizarre bug on SunOS 4.1.3.
+if $ac_need_defaults; then
+  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
+  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
+fi
+
+# Have a temporary directory for convenience.  Make it in the build tree
+# simply because there is no reason against having it here, and in addition,
+# creating and moving files from /tmp can sometimes cause problems.
+# Hook for its removal unless debugging.
+# Note that there is a small window in which the directory will not be cleaned:
+# after its creation but before its name has been assigned to `$tmp'.
+$debug ||
+{
+  tmp=
+  trap 'exit_status=$?
+  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
+' 0
+  trap 'as_fn_exit 1' 1 2 13 15
+}
+# Create a (secure) tmp directory for tmp files.
+
+{
+  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
+  test -n "$tmp" && test -d "$tmp"
+}  ||
+{
+  tmp=./conf$$-$RANDOM
+  (umask 077 && mkdir "$tmp")
+} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
+
+# Set up the scripts for CONFIG_FILES section.
+# No need to generate them if there are no CONFIG_FILES.
+# This happens for instance with `./config.status config.h'.
+if test -n "$CONFIG_FILES"; then
+
+
+ac_cr=`echo X | tr X '\015'`
+# On cygwin, bash can eat \r inside `` if the user requested igncr.
+# But we know of no other shell where ac_cr would be empty at this
+# point, so we can use a bashism as a fallback.
+if test "x$ac_cr" = x; then
+  eval ac_cr=\$\'\\r\'
+fi
+ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 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
+
+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_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
+ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
+ac_delim='%!_!# '
+for ac_last_try in false false false false false :; do
+  . ./conf$$subs.sh ||
+    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
+
+  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
+  if test $ac_delim_n = $ac_delim_num; then
+    break
+  elif $ac_last_try; then
+    as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
+  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 = ""
+
+}
+{
+  line = $ 0
+  nfields = split(line, field, "@")
+  substed = 0
+  len = length(field[1])
+  for (i = 2; i < nfields; i++) {
+    key = field[i]
+    keylen = length(key)
+    if (S_is_set[key]) {
+      value = S[key]
+      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
+      len += length(value) + length(field[++i])
+      substed = 1
+    } else
+      len += 1 + keylen
+  }
+
+  print line
+}
+
+_ACAWK
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
+  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
+else
+  cat
+fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
+  || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
+_ACEOF
+
+# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
+# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
+# trailing colons and then remove the whole line if VPATH becomes empty
+# (actually we leave an empty line to preserve line numbers).
+if test "x$srcdir" = x.; then
+  ac_vpsub='/^[	 ]*VPATH[	 ]*=[	 ]*/{
+h
+s///
+s/^/:/
+s/[	 ]*$/:/
+s/:\$(srcdir):/:/g
+s/:\${srcdir}:/:/g
+s/:@srcdir@:/:/g
+s/^:*//
+s/:*$//
+x
+s/\(=[	 ]*\).*/\1/
+G
+s/\n//
+s/^[^=]*=[	 ]*$//
+}'
+fi
+
+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_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
+  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_fn_error $? "could not setup config headers machinery" "$LINENO" 5
+fi # test -n "$CONFIG_HEADERS"
+
+
+eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
+shift
+for ac_tag
+do
+  case $ac_tag in
+  :[FHLC]) ac_mode=$ac_tag; continue;;
+  esac
+  case $ac_mode$ac_tag in
+  :[FHL]*:*);;
+  :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5 ;;
+  :[FH]-) ac_tag=-:-;;
+  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
+  esac
+  ac_save_IFS=$IFS
+  IFS=:
+  set x $ac_tag
+  IFS=$ac_save_IFS
+  shift
+  ac_file=$1
+  shift
+
+  case $ac_mode in
+  :L) ac_source=$1;;
+  :[FH])
+    ac_file_inputs=
+    for ac_f
+    do
+      case $ac_f in
+      -) ac_f="$tmp/stdin";;
+      *) # Look for the file first in the build tree, then in the source tree
+	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
+	 # because $ac_f cannot contain `:'.
+	 test -f "$ac_f" ||
+	   case $ac_f in
+	   [\\/$]*) false;;
+	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
+	   esac ||
+	   as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5 ;;
+      esac
+      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
+      as_fn_append ac_file_inputs " '$ac_f'"
+    done
+
+    # Let's still pretend it is `configure' which instantiates (i.e., don't
+    # use $as_me), people would be surprised to read:
+    #    /* config.h.  Generated by config.status.  */
+    configure_input='Generated from '`
+	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
+	`' by configure.'
+    if test x"$ac_file" != x-; then
+      configure_input="$ac_file.  $configure_input"
+      { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
+$as_echo "$as_me: creating $ac_file" >&6;}
+    fi
+    # Neutralize special characters interpreted by sed in replacement strings.
+    case $configure_input in #(
+    *\&* | *\|* | *\\* )
+       ac_sed_conf_input=`$as_echo "$configure_input" |
+       sed 's/[\\\\&|]/\\\\&/g'`;; #(
+    *) ac_sed_conf_input=$configure_input;;
+    esac
+
+    case $ac_tag in
+    *:-:* | *:-) cat >"$tmp/stdin" \
+      || as_fn_error $? "could not create $ac_file" "$LINENO" 5  ;;
+    esac
+    ;;
+  esac
+
+  ac_dir=`$as_dirname -- "$ac_file" ||
+$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+	 X"$ac_file" : 'X\(//\)[^/]' \| \
+	 X"$ac_file" : 'X\(//\)$' \| \
+	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X"$ac_file" |
+    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)[^/].*/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\/\)$/{
+	    s//\1/
+	    q
+	  }
+	  /^X\(\/\).*/{
+	    s//\1/
+	    q
+	  }
+	  s/.*/./; q'`
+  as_dir="$ac_dir"; as_fn_mkdir_p
+  ac_builddir=.
+
+case "$ac_dir" in
+.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
+*)
+  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
+  # A ".." for each directory in $ac_dir_suffix.
+  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
+  case $ac_top_builddir_sub in
+  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
+  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
+  esac ;;
+esac
+ac_abs_top_builddir=$ac_pwd
+ac_abs_builddir=$ac_pwd$ac_dir_suffix
+# for backward compatibility:
+ac_top_builddir=$ac_top_build_prefix
+
+case $srcdir in
+  .)  # We are building in place.
+    ac_srcdir=.
+    ac_top_srcdir=$ac_top_builddir_sub
+    ac_abs_top_srcdir=$ac_pwd ;;
+  [\\/]* | ?:[\\/]* )  # Absolute name.
+    ac_srcdir=$srcdir$ac_dir_suffix;
+    ac_top_srcdir=$srcdir
+    ac_abs_top_srcdir=$srcdir ;;
+  *) # Relative name.
+    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
+    ac_top_srcdir=$ac_top_build_prefix$srcdir
+    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
+esac
+ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
+
+
+  case $ac_mode in
+  :F)
+  #
+  # CONFIG_FILE
+  #
+
+  case $INSTALL in
+  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
+  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
+  esac
+_ACEOF
+
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+# If the template does not know about datarootdir, expand it.
+# FIXME: This hack should be removed a few years after 2.60.
+ac_datarootdir_hack=; ac_datarootdir_seen=
+ac_sed_dataroot='
+/datarootdir/ {
+  p
+  q
+}
+/@datadir@/p
+/@docdir@/p
+/@infodir@/p
+/@localedir@/p
+/@mandir@/p'
+case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
+*datarootdir*) ac_datarootdir_seen=yes;;
+*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
+  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
+$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
+_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+  ac_datarootdir_hack='
+  s&@datadir@&$datadir&g
+  s&@docdir@&$docdir&g
+  s&@infodir@&$infodir&g
+  s&@localedir@&$localedir&g
+  s&@mandir@&$mandir&g
+  s&\\\${datarootdir}&$datarootdir&g' ;;
+esac
+_ACEOF
+
+# Neutralize VPATH when `$srcdir' = `.'.
+# Shell code in configure.ac might set extrasub.
+# FIXME: do we really want to maintain this feature?
+cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
+ac_sed_extra="$ac_vpsub
+$extrasub
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
+:t
+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
+s|@configure_input@|$ac_sed_conf_input|;t t
+s&@top_builddir@&$ac_top_builddir_sub&;t t
+s&@top_build_prefix@&$ac_top_build_prefix&;t t
+s&@srcdir@&$ac_srcdir&;t t
+s&@abs_srcdir@&$ac_abs_srcdir&;t t
+s&@top_srcdir@&$ac_top_srcdir&;t t
+s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
+s&@builddir@&$ac_builddir&;t t
+s&@abs_builddir@&$ac_abs_builddir&;t t
+s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
+s&@INSTALL@&$ac_INSTALL&;t t
+$ac_datarootdir_hack
+"
+eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
+  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
+
+test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
+  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
+  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
+  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+which seems to be undefined.  Please make sure it is defined" >&5
+$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
+which seems to be undefined.  Please make sure it is defined" >&2;}
+
+  rm -f "$tmp/stdin"
+  case $ac_file in
+  -) cat "$tmp/out" && rm -f "$tmp/out";;
+  *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
+  esac \
+  || as_fn_error $? "could not create $ac_file" "$LINENO" 5
+ ;;
+  :H)
+  #
+  # CONFIG_HEADER
+  #
+  if test x"$ac_file" != x-; then
+    {
+      $as_echo "/* $configure_input  */" \
+      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
+    } >"$tmp/config.h" \
+      || as_fn_error $? "could not create $ac_file" "$LINENO" 5
+    if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
+      { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
+$as_echo "$as_me: $ac_file is unchanged" >&6;}
+    else
+      rm -f "$ac_file"
+      mv "$tmp/config.h" "$ac_file" \
+	|| as_fn_error $? "could not create $ac_file" "$LINENO" 5
+    fi
+  else
+    $as_echo "/* $configure_input  */" \
+      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
+      || as_fn_error $? "could not create -" "$LINENO" 5
+  fi
+ ;;
+
+
+  esac
+
+done # for ac_tag
+
+
+as_fn_exit 0
+_ACEOF
+ac_clean_files=$ac_clean_files_save
+
+test $ac_write_fail = 0 ||
+  as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
+
+
+# configure is writing to config.log, and then calls config.status.
+# config.status does its own redirection, appending to config.log.
+# Unfortunately, on DOS this fails, as config.log is still kept open
+# by configure, so config.status won't be able to write to it; its
+# output is simply discarded.  So we exec the FD to /dev/null,
+# effectively closing config.log, so it can be properly (re)opened and
+# appended to by config.status.  When coming back to configure, we
+# need to make the FD available again.
+if test "$no_create" != yes; then
+  ac_cs_success=:
+  ac_config_status_args=
+  test "$silent" = yes &&
+    ac_config_status_args="$ac_config_status_args --quiet"
+  exec 5>/dev/null
+  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
+  exec 5>>config.log
+  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
+  # would make configure fail if this is the last instruction.
+  $ac_cs_success || as_fn_exit 1
+fi
+if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
+  { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
+$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
 fi
 
 
diff --git a/configure.ac b/configure.ac
--- a/configure.ac
+++ b/configure.ac
@@ -63,7 +63,7 @@
 
 # Find pwd, in a cygwin friendly way. 
 # Suggested by: http://www.haskell.org/ghc/docs/latest/html/users_guide/ch11s04.html
-TOP=`echo "Directory.getCurrentDirectory >>= putStrLn.init.tail.show " | ghc --interactive -ignore-dot-ghci -v0 | tr -d '\r'`
+TOP=`echo "System.Directory.getCurrentDirectory >>= putStrLn.init.tail.show " | ghc --interactive -ignore-dot-ghci -v0 | tr -d '\r'`
 
 AC_DEFINE_UNQUOTED(TOP, "$TOP", [Path to top of build tree])
 AC_SUBST(TOP)
diff --git a/docs/Makefile b/docs/Makefile
deleted file mode 100644
--- a/docs/Makefile
+++ /dev/null
@@ -1,31 +0,0 @@
-# Copyright (c) 2004 Don Stewart - http://www.cse.unsw.edu.au/~dons
-# LGPL version 2.1 or later (see http://www.gnu.org/copyleft/lesser.html)
-
-.PHONY: build clean html
-
-SRC = hs-plugins
-
-build: $(SRC).ps html
-
-$(SRC).ps: $(SRC).dvi
-	dvips -f $(SRC).dvi > $@
-
-html: $(SRC).tex
-	tex2page $(SRC)
-	tex2page $(SRC)
-	sed -f munge.sed < $(SRC)/$(SRC).html > tmp.out
-	mv tmp.out $(SRC)/$(SRC).html
-	cp $(SRC)/$(SRC).html $(SRC)/index.html
-	tar czf $(SRC).html.tar.gz $(SRC)
-	mv $(SRC).html.tar.gz $(SRC)/
-
-$(SRC).dvi: $(SRC).tex
-	latex $(SRC).tex && latex $(SRC).tex
-
-CLEANS= *.{ps,dvi,aux,log} *~ hs-plugins *-Z-* *.toc
-
-clean: 
-	rm -rf $(CLEANS)
-
-all: doc
-
diff --git a/docs/haskell.sty b/docs/haskell.sty
deleted file mode 100644
--- a/docs/haskell.sty
+++ /dev/null
@@ -1,452 +0,0 @@
-%%% This is a LaTeX2e style file.
-%%%
-%%% It supports setting functional languages like Haskell.
-%%%
-%%% Manuel M. T. Chakravarty <chak@cse.unsw.edu.au> [1998..2000]
-%%%
-%%% $Id: haskell.sty,v 1.2 2004/05/16 08:20:09 dons Exp $
-%%%
-%%% This file is free software; you can redistribute it and/or modify
-%%% it under the terms of the GNU General Public License as published by
-%%% the Free Software Foundation; either version 2 of the License, or
-%%% (at your option) any later version.
-%%%
-%%% This file 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.
-%%%
-%%% Acknowledegments ==========================================================
-%%%
-%%% Thanks to Gabriele Keller <keller@cs.tu-berlin.de> for beta testing and
-%%% code contributions.  Thanks to the LaTeX3 project for improving the LaTeX
-%%% sources (which helped me writing this code).  Furthermore, I am grateful
-%%% to Martin Erwig <Martin.Erwig@FernUni-Hagen.de> for feedback and
-%%% suggestions, and to Conal Elliott <conal@MICROSOFT.com> for pointing out
-%%% a tricky bug.
-%%%
-%%% TODO ======================================================================
-%%%
-%%% B ~ bug; F ~ feature
-%%%
-%%% * F: Along the lines of the discussion with Martin Erwig add support for
-%%%      keywords etc (see the emails)
-%%%
-%%% * B: If we have as input 
-%%%
-%%%        \<map
-%%%        g\>
-%%%
-%%%      there won't be a `\hsap' inserted!!  (Can this be solved by using
-%%%      \obeylines in \<...\>?)
-%%%
-%%% * B: A \relax is needed after a & if it immediately followed by a \hsbody{}
-%%%   (See TeXbook, S.240)
-%%%
-%%% * F: Implement a \hstext{...} as \(\text{...}\).
-%%%
-%%% * We would like hswhere* etc that are like haskell* (\hsalign already
-%%%   supports this, ie, there is a \hsalign*).
-%%%
-%%% * Star-Versions of if, let etc that use a single line layout (maybe not
-%%%   with star, because of the above).
-%%%
-%%% * Support for enforcing and prohibiting breaks in `haskell' displays.
-%%%
-%%% * Comments in a let-in should be aligned in the same way for the bindings
-%%%   and the body.
-%%%
-%%% * It would be nice to have different styles (indentation after in of
-%%%   let-in or not) etc; either to be set with a package option or in the
-%%%   preamble (the latter probably makes more sense). 
-%%%
-%%% * Literate programming facility: Variant of the `haskell' env (maybe
-%%%   `hschunk', which is named and can be used in other chunks).  But maybe
-%%%   it is not necessary to provide a chunk-based reordering mechanism,
-%%%   because most of the Haskell stuff can be in any order anyway...
-%%%   Important is to provide a way to define visually pleasing layout
-%%%   together with the raw Haskell form for program output. (Maybe `haskell*' 
-%%%   as Haskell env that outputs its contents?)
-%%%
-
-%% Initialization
-%% ==============
-
-\NeedsTeXFormat{LaTeX2e} 
-\ProvidesPackage{haskell}[2000/10/05 v1.0e Chilli's Haskell Style]
-
-
-%% Parameters
-%% ==========
-
-\newskip\hsmargin
-\hsmargin\leftmargini
-
-
-%% Main macros and environments
-%% ============================
-
-% applications
-%
-\newcommand{\hsap}{%                    % application by juxtaposition
-  \unskip\mskip 4mu plus 1mu}           %   only the last \hsap counts
-
-% commands to start and stop setting spaces as \hsap
-%
-{\obeyspaces\gdef\@hsSpaceToApp{\obeyspaces\let =\hsap}}  % spaces matter!!!
-{\obeyspaces\gdef\@hsNormalSpace{\let =\space}}
-
-% commands to start and stop treating numbers specially, ie, we don't want
-% them to be affected by font changing commands in Haskell contexts as this
-% would give italic numerals; the trick is to redefine their math code such
-% that they go into math class 0 and thus don't change families (cf. `The
-% TeXbook', Chapter 17, pp152)
-%
-\newcommand{\@hsRmNumbers}{%
-  \mathcode`0="0030
-  \mathcode`1="0031
-  \mathcode`2="0032
-  \mathcode`3="0033
-  \mathcode`4="0034
-  \mathcode`5="0035
-  \mathcode`6="0036
-  \mathcode`7="0037
-  \mathcode`8="0038
-  \mathcode`9="0039
-  }
-\newcommand{\@hsNormalNumbers}{%
-  \mathcode`0="7030
-  \mathcode`1="7031
-  \mathcode`2="7032
-  \mathcode`3="7033
-  \mathcode`4="7034
-  \mathcode`5="7035
-  \mathcode`6="7036
-  \mathcode`7="7037
-  \mathcode`8="7038
-  \mathcode`9="7039
-  }
-
-% Save the bindings of the standard math commands
-%
-% This is somewhat subtle as we want to able to enter the original math mode
-% within Haskell mode and we have to ensure that the different opening
-% commands are matched by the correct versions of the closing commands.
-%
-\let\@hsmathorg=\(
-\let\@hsmathendorg=\)
-\let\hs@crorg=\\
-\newcommand{\@hsmath}{%
-  \relax\hbox\bgroup
-  \@hsNormalSpace
-  \@hsNormalNumbers
-  \let\(=\@hsmathorgx
-  \let\)=\@hsmathend
-  \def\\{\hs@crorg}%
-  \@hsmathorg
-  }
-\newcommand{\@hsmathend}{%
-  \@hsmathendorg
-  \egroup
-  }
-\newcommand{\@hsmathorgx}{%
-  \relax\@hsmathorg
-  \let\)=\@hsmathendorg
-  }
-
-%% Typesetting of Haskell
-%% ======================
-
-% Inline Haskell phrases are delimited by `\<' and `\>'.
-%
-% Note: `\>' is only locally redefined.
-% 
-\newcommand{\<}{%
-  \@hsmathorg
-  \mathit\bgroup
-  \@hsSpaceToApp
-  \@hsRmNumbers
-  \let\>=\@endhs
-  \let\(=\@hsmath  
-  \def\\{\cr}           % for Haskell alignments
-  }
-\newcommand{\@endhs}{%
-  \egroup
-  \@hsmathendorg
-  }
-
-% Displayed Haskell (environment `haskell' and `haskell*')
-%
-% There are two kind of preambles for \halign: \hs@preambleNorm is for 
-% `amsmath' style alignments and \hs@preambleStar for `equation' style
-% alignments (but with an unbound number of columns to its right)
-%
-% We need #### to get a ## in the \edef building the \halign command.
-%
-% first the preambles (also used in \hs@align below):
-%
-\def\hs@preambleNorm{%
-  \noexpand\<####\unskip\noexpand\>\hfil&&\noexpand%
-  \<{}####\unskip\noexpand\>\hfil}
-\def\hs@preambleStar{%
-  \noexpand\<####\unskip\noexpand\>\hfil&\hfil\noexpand%
-  \<{}####\unskip{}\noexpand\>\hfil&&\noexpand\<{}####\noexpand\>\hfil}
-%
-% the environments:
-%
-\newenvironment{haskell}{%
-  \@haskell\hs@preambleNorm}{%
-  \@endhaskell
-  }
-\newenvironment{haskell*}{%
-  \@haskell\hs@preambleStar}{%
-  \@endhaskell
-  }
-%
-% auxiliary definition getting the preamble as its first argument and starting 
-% the environment:
-%
-\def\@haskell#1{%
-  \bgroup
-  \vspace\abovedisplayskip
-  \let\(=\@hsmath               % Important when `\(' occurs after `&'!  
-  \edef\@preamble{%
-    \halign\bgroup\hskip\hsmargin#1\cr}
-  \@preamble
-  }
-%
-% Auxiliary definition ending environment:
-%
-\def\@endhaskell{%
-  \crcr\egroup
-  \vspace\belowdisplayskip
-  \egroup\noindent\ignorespaces\global\@ignoretrue%
-  }
-
-% single line comment and keyword style
-%
-\newcommand{\hscom}[1]{%
-  \relax\(\quad\textnormal{--- #1}\)}
-\newcommand{\hskwd}[1]{%
-  \mathbf{#1}}
-
-% informal description
-%
-\newcommand{\hsinf}[1]{%
-  \(\langle\textnormal{#1}\rangle\)}
-
-% literals and some special symbols
-%
-\newcommand{\hschar}[1]{\textrm'\mathrm{#1}\textrm'}  % character literals
-\newcommand{\hsstr}[1]{"\mathrm{#1}"}                 % strings literals
-\newcommand{\hsfrom}{\leftarrow}                      % <-
-
-% aligned subphrases
-%
-% check for an optional star and combine prefix (in #1) with one of the two
-% preambles (with star means to center the material between the first and
-% second &) 
-%
-\def\hs@align#1{%
-  \@ifstar
-    {\hs@align@pre{#1\hs@preambleStar}}%
-    {\hs@align@pre{#1\hs@preambleNorm}}%
-  }
-%
-% test for optional argument; #1: preamble
-%
-\def\hs@align@pre#1{%
-  \@testopt{\hs@align@prealign#1}t}
-%
-% got all arguments, now for the real code; #1: preamble; #2: alignment; 
-% #3: body (the material set by the \halign)
-%
-\def\hs@align@prealign#1[#2]#3{%
-  \relax\(
-  \edef\@preamble{%
-    \halign\bgroup#1\cr}
-  \if #2t\vtop \else \if#2b\vbox \else \vcenter \fi\fi
-  \bgroup%
-    \@preamble
-        #3%
-    \crcr\egroup%
-  \egroup\)
-  }
-%
-% user-level command: alignment without a prefix
-%
-\newcommand{\hsalign}{%
-  \relax
-  \hs@align\relax%
-  }
-
-% subphrase breaking the surrounding alignment being flushed left
-%
-\newcommand{\hsnoalign}[1]{%
-  \noalign{%
-    \hs@align{\hskip\hsmargin}{#1}%
-    }%
-  }
-
-% body expression breaking the surrounding alignment
-%
-% * setting \hsmargin to 0pt within the preamble (and _after_ it is used in
-%   the preamble) is crucial, as we want \hsmargin only to be applied in
-%   _outermost_ alignments
-%
-\newcommand{\hsbody}[1]{%
-  {}\\
-  \noalign{%
-    \hs@align{\hskip\hsmargin\quad\hsmargin0pt}{#1}%
-    }%
-  }
-
-
-%% Defining commands for use in the Haskell mode
-%% =============================================
-%%
-%% We use some of the low-level machinery defined in LaTeX's source file
-%% `ltdefns.dtx'.
-%%
-%% \hscommand is similar to \newcommand, but there is no *-version.
-%%
-%% We use our own definitions here to insert a strategic `\relax' (see below)
-%% and to obey spaces within the bodies of Haskell definitions.
-
-\newcommand{\hscommand}[1]{\@testopt{\hs@newcommand#1}0}
-\def\hs@newcommand#1[#2]{%
-  \obeyspaces                           % spaces count in Haskell macros
-  \@ifnextchar [{\hs@xargdef#1[#2]}%
-                {\hs@argdef#1[#2]}}
-
-% All this trouble only to be able to add the `\relax' into the expansion
-% process.  If we don't that, commands without optional arguments when
-% invoked after an alignment character & don't work properly (actually, the
-% \obeyspaces doesn't work).  I am sure that has to do with the scanning for
-% \omit etc in \halign (TeXbook, p240), but I don't understand yet why it
-% is problematic in this case.
-%
-% Furthermore, we switch off \obeyspaces in the end.
-%
-\long\def\hs@argdef#1[#2]#3{%
-   \@ifdefinable#1{%
-     \expandafter\def\expandafter#1\expandafter{%
-       \relax                % in order to stop token expansion after &
-       \csname\string#1\expandafter\endcsname}%
-     \expandafter\@yargdef
-     \csname\string#1\endcsname
-     \@ne
-     {#2}%
-     {#3}}%
-   \catcode`\ =10%           % stop obeying spaces now
-   }
-
-% Switch off \obeyspaces in the end.
-%
-\long\def\hs@xargdef#1[#2][#3]#4{%
-  \@ifdefinable#1{%
-    \expandafter\def\expandafter#1\expandafter{%
-      \expandafter
-      \@protected@testopt
-      \expandafter
-      #1%
-      \csname\string#1\expandafter\endcsname
-      {#3}}%
-    \expandafter\@yargdef
-    \csname\string#1\endcsname
-    \tw@
-    {#2}%
-    {#4}}%
-  \catcode`\ =10%           % stop obeying spaces now
-  }
-
-
-%% Abbreviations
-%% =============
-
-% infix operators
-%
-\newcommand{\hsapp}{\mathbin{+\mkern-7mu+}}
-\newcommand{\hsifix}[1]{\mathbin{\string`#1\string`}}
-
-% let expression
-%
-\hscommand{\hslet}[3][t]{%
-  \hsalign[#1]{%
-    \hskwd{let}\\
-    \quad\hsalign{#2}\\
-    \hskwd{in}\\
-    #3
-    }%
-  }
-  
-% if expression
-%
-\hscommand{\hsif}[4][t]{%
-  \hsalign[#1]{%
-    \hskwd{if} #2 \hskwd{then}\\
-    \quad\hsalign{#3}\\
-    \hskwd{else}\\
-    \quad\hsalign{#4}% 
-    }%
-  }
-
-% case expression
-%
-\hscommand{\hscase}[3][t]{%
-  \hsalign[#1]{%
-    \hskwd{case} #2 \hskwd{of}\\
-    \quad\hsalign{#3}%
-    }%
-  }
-  
-% where clause
-%
-% * it is important to take the \quad into the preamble, so that nested
-%   \noaligns can break it
-%
-\hscommand{\hswhere}[1]{%
-  \hsbody{%
-    \hskwd{where}\\
-    \hs@align{\quad}{#1}%
-    }%
-  }
-
-% do expression
-%
-\hscommand{\hsdo}[2][t]{%
-  \hsalign[#1]{%
-    \hskwd{do}\\
-    \quad\hsalign{#2}\\
-    }%
-  }
-
-
-%% Extensions for Distributed Haskell (Goffin)
-%% ===========================================
-%%
-%% These definitions may change in the future.
-
-\hscommand{\hsunif}{\mathbin{:=:}}
-\hscommand{\hsalias}{\mathrel{\sim}}
-\hscommand{\hsoutof}{\twoheadleftarrow}
-\hscommand{\hsinto}{\twoheadrightarrow}
-\hscommand{\hsparc}{\binampersand}
-\hscommand{\hsseq}{\Longrightarrow}
-\hscommand{\hsex}[2]{{\hskwd{ex} #1 \hskwd{in} #2}}
-
-\hscommand{\hsexin}[3][t]{%
-  \hsalign[#1]{%
-    \hskwd{ex} #2 \hskwd{in}\\
-    \quad\hsalign{#3}\\
-    }%
-  }
-
-\hscommand{\hschoice}[2][t]{%
-  \hsalign[#1]{%
-    \hskwd{choice}\\
-    \quad\hsalign{#2}\\
-    }%
-  }
-
-
diff --git a/docs/hs-plugins.1 b/docs/hs-plugins.1
deleted file mode 100644
--- a/docs/hs-plugins.1
+++ /dev/null
@@ -1,36 +0,0 @@
-.TH HS-PLUGINS 1 2005-12-27 "hs-plugins version 1.0" "User Manual"
-
-.SH NAME
-hs-plugins \- dynamic linker library for Haskell
-
-.SH DESCRIPTION
-.ds c \fIhs-plugins\fP
-\*c is a library for loading code written in Haskell into an
-application at runtime, in the form of plugins. It also provides a
-mechanism for (re-)compiling Haskell source at runtime. Thirdly, a
-combination of runtime compilation and dynamic loading provides a set
-of eval functions.  Values exported by plugins are transparently
-available to Haskell host applications, and bindings exist to use
-Haskell plugins from at least C and Objective C programs. hs-plugins
-requires GHC 6.4 or later.
-
-.SH DOCUMENTATION
-The hs-plugins user manual is distributed in html format, and may be
-found at <http://www.cse.unsw.edu.au/~dons/hs-plugins/>
-
-.SH BUGS
-Bug reports, and any other feedback, should be sent to
-Don Stewart <dons@cse.unsw.edu.au>
-.SH COPYRIGHT
-Copyright \(co 2003-2005 Don Stewart
-.PP
-The hs-plugins library modules are distributed under the terms of the
-LGPL.
-.SH "SEE ALSO"
-.BR dlopen (3)
-
-.SH AUTHOR
-
-This manual page was written by Don Stewart, based on the man page for
-cpphs (written by Ian Lynagh).
-
diff --git a/docs/hs-plugins.hdir b/docs/hs-plugins.hdir
deleted file mode 100644
--- a/docs/hs-plugins.hdir
+++ /dev/null
@@ -1,1 +0,0 @@
-hs-plugins
diff --git a/docs/hs-plugins.tex b/docs/hs-plugins.tex
deleted file mode 100644
--- a/docs/hs-plugins.tex
+++ /dev/null
@@ -1,1804 +0,0 @@
-\documentclass{article}
-
-\usepackage{url}
-\usepackage{tex2page}
-
-% typeset math as ascii
-\htmlmathstyle{no-in-text-image no-display-image}
-
-% something other than |
-\verbescapechar\&
-
-\cssblock 
-h1      {font-size: 16pt}
-h2      {font-size: 15pt}
-\endcssblock 
-
-% color of verbatim elements
-\cssblock
-.verbatim {color: grey20}
-
-.scheme  .variable  {color: grey20} 
-.scheme  .keyword   {color: navy}
-.scheme  .builtin   {color: maroon}
-\endcssblock
-
-% add some extra keywords
-\scmkeyword{as case class data default deriving do else hiding if}
-\scmkeyword{import in infix infixl infixr instance let module newtype}
-\scmkeyword{of qualified then type where forall \\ }
-\scmbuiltin{: :: = -> <- @ ~ => - >>= >> }
-
-\newcommand{\code}[1]{{\texttt{#1}}}
-\newcommand{\hsplugins}{{\texttt{hs-plugins}}}
-
-\title{hs-plugins\\
-       Dynamically Loaded Haskell Modules}
-
-\author{\urlh{http://www.cse.unsw.edu.au/~dons}{Don Stewart}}
-
-\begin{document}
-
-\maketitle
-
-\medskip
-%
-{\htmlonly \textbf{Download \endhtmlonly 
-\urlh{ftp://ftp.cse.unsw.edu.au/pub/users/dons/hs-plugins/hs-plugins-1.0.tar.gz}
-     {version 1.0}}
-%
-\medskip
-
-\hsplugins{} is a library for loading code written in Haskell into an
-application at runtime, in the form of plugins. It also provides a
-mechanism for (re-)compiling Haskell source at runtime. Thirdly, a
-combination of runtime compilation and dynamic loading provides a set of
-\code{eval} functions-- a form of runtime metaprogramming. Values
-exported by Haskell plugins are transparently available to Haskell host
-applications, and bindings exist to use Haskell dynamically in C, Perl
-and Objective C programs. \hsplugins{} requires GHC 6.4 or later.
-
-\medskip
-
-% grr. double spaced.
-
-\tableofcontents
-
-\newpage
-
-\section{Download}
-
-\begin{itemize}
-
-\item
-Download the latest stable release:\\
-\url{ftp://ftp.cse.unsw.edu.au/pub/users/dons/hs-plugins/hs-plugins-1.0.tar.gz}
-
-\item
-Darcs repository of the latest code:\\
-\url{darcs get http://www.cse.unsw.edu.au/~dons/code/hs-plugins}
-
-\item
-A tarball of the document you are reading:\\
-\url{http://www.cse.unsw.edu.au/~dons/hs-plugins/hs-plugins.html.tar.gz}
-
-\item
-A postscript version of the document you are reading:\\
-\url{http://www.cse.unsw.edu.au/~dons/hs-plugins/hs-plugins.ps.gz}
-
-\item
-Papers:
-\begin{itemize}
-\item A paper on interesting uses of \hsplugins{} to enable Haskell to be used
-as an application extension language:\\
-\url{http://www.cse.unsw.edu.au/~dons/papers/PSSC04.html}
-
-\item
-A paper on dynamic applications in Haskell, utilizing \hsplugins{}:\\
-\url{http://www.cse.unsw.edu.au/~dons/papers/SC05.html}
-\end{itemize}
-
-\end{itemize}
-
-It is known to run on \code{i386-\{linux,freebsd,openbsd\}},
-\code{sparc-solaris2}, \code{powerpc-\{macosx,linux\}} and flavours of
-Windows.
-
-\section{History}
-
-\begin{itemize}
-        \item Jan 2006, v1.0
-        \begin{itemize}
-        \item Cabalised build system
-        \item Behave better on 64 bit platforms
-        \item Haddock documentation of the API.
-        \item A couple of bug fixes
-        \end{itemize}
-
-        \item June 2005, v0.9.10
-        \begin{itemize}
-        \item Support for GHC 6.4, with help from Sean
-                        Seefried for the package.conf parser.
-        \item Ported to Windows of various flavours thanks to Vivian McPhail and Shelarcy
-        \item Removed posix and unix dependencies
-        \item Now uses HSX parser, thanks to Niklas Broberg
-        \item Extended load interface, thanks to Lemmih
-        \item Source now in a darcs repository
-        \item Supports building with GNU make -jN
-        \item Simplified module hierarchy, moved under System.* namespace
-        \item pdynload clarifications, thanks to Alistair Bayley 
-        \item Miscellaneous bug fixes
-        \end{itemize}
-
-	\item February 2005, v0.9.8
-        \begin{itemize}
-		\item Fix bug in .hi parsing. 
-		\item Add reloading of packages. 
-		\item Fix bug in canonical module names 
-                      (fixing problems with "Foo.o" and "./Foo.o"
-		\item Fix for hierarchical names, don't guess them,
-			read them from the .hi file.
-		\item Add new varients of load.
-		\item Fix bug in makeAll, such that dependent module
-			changes were not noticed.
-		\item Add varient of eval:\code{ unsafeEval\_}, returing
-			Either.
-		\item Better, bigger testsuite.
-		\item Better api.
-	\end{itemize}
-
-	\item September 2004.
-        \begin{itemize}
-		\item makeAll
-		\item Better return type for make.
-	\end{itemize}
-
-	\item Mid August 2004, v0.9.6 release.
-        \begin{itemize}
-		\item More portable, thanks to debugging by Niklas Broberg.
-		\item Other small fixes to the interfaces.
-		\item Provides a runtime-generated printf.
-	\end{itemize}
-
-	\item Mid July 2004, added new pdynload strategy.
-
-	\item Mid-June 2004, v0.9.5 release.
-        \begin{itemize}
-		\item dynamic typing is working
-
-		\item static typing of interfaces is working
-
-		\item Adds \code{eval}, and \code{hs\_eval}
-
-		\item bugs fixed.
-        \end{itemize}
-
-        \item Early-June 2004, v0.9.4 release. 
-        \begin{itemize}
-
-                \item Adds a .hi file parser. We use this to work out
-                plugin dependencies directly, meaning no more
-                \code{.dep} files or \code{ghcp}. 
-
-                \item It also adds a package.conf parser, meaning we
-                can properly handle packages that either aren't stored
-                in the normal location, don't have a canonical name,
-                or are found using a -package-conf argument. Thanks to
-                Sean for this work. 
-
-                \item the interface to load() has changed to allow a
-                list of package.conf files to search for packages.
-
-                \item the interace to make() has changed, so that you
-                can get back any stderr output produced during plugin
-                compilation.
-
-                \item It solves a bug whereby a package that is
-                required by another package would not be loaded unless
-                the plugin itself depended on this indirect package.
-
-                \item more stable, more examples.
-        \end{itemize}
-
-        \item May 2004, v0.9.3 released, adding support for dependency
-        conflict resolution between multiple plugins.  Several plugins with
-        shared dependencies can now be safely loaded at once. --prefix is now
-        respected in ./configure.  Thanks to Sean for this patch.
-
-        \item v0.9.2 change licence to LGPL
-
-        \item v0.9.1 expand on the documentation
-
-        \item v0.9   released, initial source release
-
-\end{itemize}
-
-\section{Acknowledgements}
-
-\begin{itemize}
-
-\item Andr\'e Pang's \code{runtime\_loader} was the inspiration and basis
-of the dynamic loader (\url{http://www.algorithm.com.au}).
-\hsplugins{} has benefited from many discussions with him,
-particularly to do with dependency checking and dynamic typing, and
-bug reports. Andr\'e wrote an objective C binding to hs-plugins, and
-helped with the design of eval(). He also fixed GHC so we could load
-the dynamic loader dynamically.
-
-\item Sean Seefried (\url{http://www.cse.unsw.edu.au/~sseefried}) was
-the first user of \hsplugins{} and his code and feedback have helped
-make the library much more useful and powerful.
-
-\item Manuel Chakravarty's \code{take} system provided the basis for
-\code{make}, and helped with several issues to do with safety of
-plugins, apis and the applications that use them.
-Manuel also helped with the design of eval(), and on how to
-successfully evaluate polymorphic functions using rank-N types.
-
-\item Simon Marlow helped with several issues to do with linking and
-loading static and dynamic code, and provided many useful suggestions.
-
-\item Hampus Ram's dynamic loader
-(\url{http://www.dtek.chalmers.se/~d00ram/dynamic/}) provided the
-design of the state maintained by the loader, and for thread safety
-issues relating to this.
-
-\item Shae Erisson provided several insights into more powerful uses
-of the library. Thanks to everyone on \#haskell who provided
-discussion about the library.
-
-\item Malcolm Wallace's \code{hmake} provided some useful insights in
-how to compile Haskell source in a way that makes it appear like an
-interpreter, used in the interactive environment: \code{plugs}.
-
-\item Niklas Broberg helped a lot by testing, and providing feedback for
-the new make and load API. Thanks Niklas.
-
-\item Finally, thanks to everyone who has worked on GHC and its
-libraries: for GHCi, the .hi interface parser, the package system, and
-all the other code the \hsplugins{} depends on.
-
-\end{itemize}
-
-\newpage
-
-\section{Overview}
-
-\hsplugins{} is a library for compiling and loading Haskell code into a
-program at runtime. It allows you to write Haskell code (which may
-be spread over multiple modules), and have an application (implemented in
-any language with a Haskell FFI binding, including Haskell) load and use
-your code at runtime.
-
-\hsplugins{} provides 3 major features:
-%
-\begin{itemize}
-        \item a dynamic loader,
-        \item a compilation manager, and
-        \item a Haskell evaluator
-\end{itemize}
-
-The \emph{dynamic loader} loads objects into the address space of an
-application, along with any dependencies the plugin may have. The
-loader is a binding to the GHC runtime system's dynamic linker, which
-does single object loading. GHC also performs the necessary linking of
-new objects into the running process. On top of the GHC loader is a
-Haskell layer that arranges for module and package dependencies to be
-found prior to loading individual modules.
-
-The \emph{compilation manager} is a \code{make}-like system for
-compiling Haskell source code into a form suitable for loading.  While
-plugins are normally thought of as strictly object code, there are a
-variety of scenarios where it is desirable to be able to inspect the
-source code of a plugin, or to be able to recompile a plugin at runtime.
-The compilation manager fills this role. It is particularly useful in
-the implementation of \code{eval}.
-
-The \emph{evaluator}, \code{eval}, utilizes the loader and compilation
-manager. When passed a string containing a Haskell expression, it
-compiles the string to object code, loads the result, and returns a
-Haskell value representing the compiled string to the caller. It can be
-considered a Haskell interpreter, implemented as a library, and can be
-used to embed Haskell evaluation facilities in an application.
-
-\section{Dynamic Loader}
-
-The interface to the \hsplugins{} library can be divided into a number
-of sections representing the functional units of the library.
-Additionally, depending on the level of trust the application places
-in the plugins, a variety of additional checks can be made on the
-plugin as it is loaded. The levels of type safety possible are
-summarised at the end of Section \ref{sec:compilation-manger} section.
-The dynamic loader is available by using \code{-package plugins}.
-
-\subsection*{Interface}
-%
-\begin{quote}
-\scm{
-import System.Plugins
-
-load :: FilePath 
-     -> [FilePath] 
-     -> [PackageConf] 
-     -> Symbol 
-     -> IO (LoadStatus a)
-}
-
-\scm{
-load_ :: FilePath 
-      -> [FilePath] 
-      -> Symbol 
-      -> IO (LoadStatus a)
-}
-
-\scm{
-data LoadStatus a
-    = LoadSuccess Module a 
-    | LoadFailure Errors
-}
-\end{quote}
-%
-Example:
-%
-\begin{quote}
-\scm{
-do mv <- load "Plugin.o" ["api"] [] "resource"
-   case mv of
-	LoadFailure msg -> print msg
-	LoadSuccess _ v -> return v
-}
-\end{quote}
-%
-This is the basic interface to the dynamic loader. Load the object file
-specified by the first argument into the address space (the library will
-preload any module or package dependencies). The second argument is an
-include path to any additional objects to load (possibly the API of the
-plugin). The third argument is a list of paths to any user-defined
-\code{package.conf} files, specifying packages unknown to the GHC
-package system. \code{Symbol} is a string specifying the symbol name you
-wish to lookup. \code{load} returns a \code{LoadStatus} value representing
-failure, or an abstract representation of the module (for calls to
-\code{unload} or \code{reload}) with the symbol as a Haskell value. The
-value returned must be given an explicit type signature, or provided
-with appropriate type constraints such that GHC can determine the
-expected type returned by \code{load}.
-
-\code{load\_} is provided for the common situation where no user-defined
-package.conf files are required.
-
-\begin{quote}
-\scm{
-dynload :: Typeable a    
-        => FilePath  
-        -> [FilePath]
-        -> [PackageConf]
-        -> Symbol
-        -> IO (LoadStatus a)
-}
-\end{quote}
-%
-Example:
-%
-\begin{quote}
-\scm{
-do mv <- dynload "Plugin.o" ["api"] ["plugins.conf.inplace"] "resource"
-   case mv of
-	LoadFailure msg -> print msg
-	LoadSuccess _ v -> putStrLn v
-}
-\end{quote}
-%
-\code{dynload} is a safer form of \code{load}. It uses dynamic types
-to perform a check on the value returned by \code{load} at runtime, to
-ensure that it has the type the application expects it to have.
-
-In order to use \code{dynload}, the symbol the plugin exports must be
-of type \code{AltData.Dynamic:Dynamic}. (See the \code{AltData} library
-distributed with \hsplugins{}, and the \hsplugins{}
-\code{examples/dynload} directory. References to \code{Typeable} and
-\code{Dynamic} refer to the \hsplugins{} reimplementation of these
-libraries. \code{AltData.Dynamic} is used at the moment, as there is a
-limitation in the existing Data.Dynamic library in the presence of
-dynamic loading).
-
-The value wrapped up in the \code{Dynamic} must be an instance of
-\code{AltData.Typeable}. If the value exported by the plugin \emph{is}
-of type \code{Dynamic}, and the value wrapped by the \code{Dynamic}
-does not match the type expected of it by the application,
-\code{dynload} will return \code{Nothing}, indicating that the plugin
-is not typesafe with respect to the application. If the value passes
-the typecheck, \code{dynload} will return \code{LoadSuccess}. If the value
-exported by the plugin is \emph{not} of type \code{Dynamic},
-\code{dynload} will crash---this is a limitation of the existing
-\code{Dynamic} library, it can only type-check \code{Dynamic} values.
-Additionally, Data.Dynamic is limited to monomorphic types, or must be
-wrapped inside a rank-N type to hide the polymorphism from the
-typechecker. This is a bit cumbersome. An alternative typesafe
-\code{load} is available via the \code{pdynload} interface, which is
-able to enforce the type of the plugin using GHC's type inference
-mechanism, and is not restricted in its expressiveness (at the cost of
-greater load times):
-
-\begin{quote}
-\scm{
-pdynload :: FilePath
-         -> [FilePath]
-         -> [PackageConf]
-         -> Type
-         -> Symbol
-         -> IO (LoadStatus a)
-}
-
-\scm{
-pdynload_ :: FilePath
-          -> [FilePath]
-          -> [PackageConf]
-          -> [Arg]
-          -> Type
-          -> Symbol
-          -> IO (LoadStatus a)
-}
-\end{quote}
-%
-Example:
-%
-\begin{quote}
-\scm{
-do v <- pdynload "Plugin.o" ["api"] [] "API.Interface" "resource"
-   case v of
-	LoadSuccess _ a  -> putStrLn "yay!"
-	_                -> putStrLn "type error"
-}
-\end{quote}
-%
-\code{pdynload} is a replacement for \code{dynload}, which provides a
-solution to the various problems caused by the existing dynamics
-library in Haskell. Rather than use normal dynamics, which constrain
-us to monomorphic types only (or rank-N types), it instead uses GHC's
-type inference to unify the plugin's export value with that provided
-by the api (via its .hi file).  It is a form of \emph{staged type inference}
-for module interfaces, allowing plugins to use any type definable in Haskell.
-\code{pdynload} is like \code{dynload}, but requires a new \code{Type}
-argument. This can be considered a type annotation on the value the plugin
-should be constrained to.
-
-Prior to loading the object, \code{pdynload} generates a tiny Haskell
-source file containing, for example:
-%
-\begin{quote}
-\scm{
-module APITypeConstraint where
-import qualified API
-import qualified Plugin
-
-_ = Plugin.resource :: API.Interface
-}
-\end{quote}
-%
-It then calls GHC's type checker on this file, which runs the full
-Haskell type inference machinery. If the file typecheckes, then the
-plugin type is correct, and the plugin is safe to load, otherwise it
-is an error. 
-
-Because we use the full Haskell type checker, we can have a form of
-dynamic typechecking, on any type expressable in Haskell. A plugin's
-value may, for example, have class constraints -- something not
-checkable using the standard Dyanmic type. The cost is that
-\code{pdynload} is roughly 46\% slower than an unchecked load.
- 
-The type of the plugin's resource field must be equivalent to the
-\code{Type}. There are some restrictions on the arguments that may be
-passed to pdynload. Currently, we require:
-        \begin{itemize}
-        \item The object name has the suffix (.o) removed and this
-        becomes a qualified module name in the generated type-checker
-        input file.
-
-        \item The type name must be a single fully-qualified
-        type-identifier, as the module name is stripped off (i.e.
-        everything up to the last ".") and used as a qualified import.
-        This means that you can't use, for example, \code{"Int ->
-        String"} as a type (type synonyms are fine, though).
-
-\end{itemize}
-
-For example, \code{pdynload "API2.o" ["./"] [] "API.PluginAPI"
-"doAction"} generates:
-
-\begin{quote}
-\scm{
-module <temp-generated-name> where
-import qualified API    -- comes from API.PluginAPI argument
-import qualified API2   -- comes from API2.o argument
-_ = API2.doAction :: API.PluginAPI
-}
-\end{quote}
-
-\begin{quote}
-\scm{
-unload :: Module -> IO ()
-}
-
-\scm{
-unloadAll :: Module -> IO ()
-}
-\end{quote}
-
-Unload an object, \emph{but not its dependencies} from the address
-space. \code{unloadAll} performs cascading unloading of a module
-\emph{and} its dependencies.
-
-\begin{quote}
-\scm{
-reload :: Module -> Symbol -> IO (LoadStatus a)
-}
-\end{quote}
-
-Unload, and then reload a module that must have been previously
-loaded.  Doesn't reload the dependencies. \code{reload} is useful in
-conjunction with \code{make}---a call to \code{reload} can be
-performed if \code{make} has recompiled the plugin source.
-
-Additionally, some support is provided to manipulation of 
-libraries of Haskell modules (usually known as packages):
-
-\begin{quote}
-\scm{
-loadPackage     :: String -> IO ()
-
-unloadPackage   :: String -> IO ()
-
-loadPackageWith :: String -> [PackageConf] -> IO ()
-}
-\end{quote}
-
-\code{loadPackage} explcitly pulls in a library (which must be visible
-in the current package namespace. \code{unloadPackage} unloads it.
-\code{loadPackageWith} behaves like \code{loadPackage}, but you are able
-to supply extra package.confs to augment the library search path.
-
-Examples:
-\begin{quote}
-\scm{
-do loadPackageWith "yi" ["yi.conf"]
-   unloadPackage "yi-0.1"
-}
-\end{quote}
-
-\newpage
-
-\section{Compilation Manager}
-
-The compilation manager is the system by which Haskell source code is
-compiled to object code suitable for loading.
-
-\subsection*{Interface}
-
-\begin{quote}
-\scm{
-import System.Plugins
-
-make :: FilePath 
-     -> [Arg] 
-     -> IO MakeStatus
-
-makeAll :: FilePath 
-        -> [Arg] 
-        -> IO MakeStatus
-
-recompileAll :: Module 
-             -> [Arg] 
-             -> IO MakeStatus
-
-data MakeStatus 
-        = MakeSuccess MakeCode FilePath 
-        | MakeFailure Errors
-
-data MakeCode = ReComp | NotReq
-}
-\end{quote}
-
-Compile a Haskell source file to an object file, with any arguments
-specified in the argument list passed through to GHC.  Returns the
-build status.
-
-\code{make} generates a GHC \code{.hi} file containing a list of
-package and objects that the source depends on. Subsequent calls to
-\code{load} will use this interface file to load module and library
-dependencies prior to loading the object itself. \code{makeAll} also
-recursively compiles any dependencies it can find using GHC's
-\code{--make} flag.
-
-\code{recompileAll} is like \code{makeAll}, but rather than relying on
-\code{ghc --make}, we explicitly check a module's dependencies.
-
-\begin{quote}
-\scm{
-merge   :: FilePath -> FilePath -> IO MergeStatus
-
-mergeTo :: FilePath -> FilePath -> FilePath -> IO MergeStatus
-
-mergeToDir :: FilePath -> FilePath -> FilePath -> IO MergeStatus
-
-data MergeStatus 
-        = MergeSuccess MergeCode Args FilePath 
-        | MergeFailure Errors
-
-type MergeCode = MakeCode
-}
-\end{quote}
-
-The merging operation is extremely useful for providing extra default
-syntax. An EDSL user then need not worry about declaring module names,
-or having required imports.  In this way, the stub file can also be
-used to provide syntax declarations that would be inconvenient to
-require of the plugin author. \code{merge} will include any import and
-export declarations written in the stub, as well as any module name,
-so that plugin author's need not worry about this compulsory syntax.
-Additionally, if a plugin requires some non-standard library, which
-must be provided as a \code{-package} flag to GHC, they may specify
-this using the non-standard \code{GLOBALOPTIONS} pragma.  Options
-specified in the source this way will be added to the command line.
-This is useful for users who wish to use GHC flags that cannot be
-specified using the conventional \code{OPTIONS} pragma. The merging
-operation uses the HSX parser library to parse Haskell source files.
-
-\code{mergeTo} behaves like \code{merge}, but we can specify the file in
-which to place output. \code{mergeToDir} lets you specify a directory in
-which to place merged files.
-
-\begin{quote}
-\scm{
-makeWith :: FilePath
-         -> FilePath
-         -> [Arg]
-         -> IO MakeStatus
-}
-\end{quote}
-
-This is a variety of \code{make} that first calls \code{merge} to
-combine the plugin source with a syntax stub. The result is then
-compiled. This is the preferred interface to EDSL authors who wish to
-add extra syntax to a user's source. It is important to note that the
-module and types from the second file argument are used to override
-any of those that appear in the first argument. For example, consider
-the following source files:
-
-\begin{quote}
-\scm{
-module A where
-
-a :: Integer
-a = 1
-}
-\end{quote}
-
-\begin{quote}
-\scm{
-module B where
-
-a :: Int
-}
-\end{quote}
-
-Calling \code{makeWith "A" "B" []} will merge the module name and types
-from module B into module A, generating a third file:
-
-\begin{quote}
-\scm{
-{-# LINE 1 "A.hs" #-}
-module MxYz123 where
-
-{-# LINE 3 "B.hs" #-}
-a :: Int
-{-# LINE 4 "A.hs" #-}
-a = 1
-}
-\end{quote}
-
-Leading to the desired result that we can ignore user-supplied module
-names and types. Knowing the module name, in particular, is important
-for dynamic loading, which requires the module name be known when
-searching for symbols.
-
-\begin{quote}
-\scm{
-hasChanged :: Module -> IO Bool
-}
-\end{quote}
-
-\code{hasChanged} returns \code{True} if the module or any of its
-dependencies have older object files than source files. Defaults to
-\code{True} if some files couldn't be located.
-
-\subsection*{Levels of Safety}
-
-The normal dynamic loader, using \code{load} on object files only,
-places full trust in the author of the plugin to provide a type-safe
-object file, containing valid code. This can be mitigated somewhat via
-the use of \code{make} to ensure that the plugin is at least Haskell
-code that is well-typed internally (if we trust GHC to compile it
-correctly). 
-
-If we trust the user to provide an interface of \code{Dynamic} type, we
-can check the plugin type at runtime, but the plugin's value must be
-\code{Typeable}, which restricts it to be a monomorphic type (or to
-using rank-N tricks). 
-
-The greatest safety can be obtained by using \code{pdynload}, at the
-cost of increased load times. \code{pdynload} essentially performs full
-type inference on the plugin interface at runtime. The type safety of
-the plugin, using \code{pdynload}, is then as safe as if the plugin was
-statically compiled into the application. It does not provide any
-\emph{further} safety than exists in static compilation. For example, it
-does not preclude the use of (evil) \code{unsafeCoerce\#} to defeat
-type-checking, either statically or at runtime. An extensive discussion
-of type safe plugin loading is available in the \hsplugins{} paper
-\urlh{http://www.cse.unsw.edu.au/~dons/hs-plugins/paper}{here}.
-
-\newpage
-
-\section{Eval.Haskell}
-
-\code{eval}, and its siblings, provide a mechanism to compile and run
-Haskell code at runtime, in the form of a String. The general framework
-is that the string is used to create a plugin source file, which is
-compiled and loaded, and type checked against its use. The resulting
-value is returned to the caller. It resembles a runtime metaprogramming
-\code{run} operator for closed code fragments.
-
-\subsection*{Interface}
-
-\begin{quote}
-\scm{
-import System.Eval.Haskell
-
-eval :: Typeable a => String -> [Import] -> IO (Maybe a)
-
-eval_ :: Typeable a =>
-         String      -- code to compile
-      -> [Import]    -- any imports
-      -> [String]    -- extra ghc flags
-      -> [FilePath]  -- extra package.conf files
-      -> [FilePath]  -- include search paths
-      -> IO (Either [String] (Maybe a))
-}
-\end{quote}
-
-\code{eval} takes a string, and a list of import module names, and
-returns a \code{Maybe} value. \code{Nothing} means the code did not
-compile, or did not typecheck at its splice point. \code{Just v} gives
-you \code{v}, the result of evaluating your code. It is interesting to
-note that \code{eval} has the type of an interpreter. The
-\code{Typeable} constraint is used to type check the evaluated code when
-it is loaded, using \code{dynload}.  As usual, \code{eval\_} is a
-version of \code{eval} that lets you pass extra flags to ghc and to the
-dynamic loader.
-
-The existing \code{Data.Dynamic} library requires that only monomorphic
-values are \code{Typeable}, so in order to evaluate polymorphic
-functions you need to wrap them up using rank-N types. Some examples:
-%
-\begin{quote}
-\scm{
-import System.Eval.Haskell
-
-main = do i <- eval "1 + 6 :: Int" [] :: IO (Maybe Int)
-          if isJust i then putStrLn (show (fromJust i)) else return ()
-}
-\end{quote}
- 
-When executed this program calls \code{eval} to compile and load the
-simple arithmetic expression, returning the result, which is
-displayed. If the value loaded is not of type \code{Int},
-\code{dynload} will throw an exception.
- 
-The following example, due to Manuel Chakravarty, shows how to
-evaluate a polymorphic function. Polymorphic values are not easily
-made dynamically typeable, but this example shows how to do it. The
-module \code{Poly} is imported as the second argument, providing the
-type of the polymorphic function:
-%
-\begin{quote}
-\scm{
-import Poly
-import System.Eval.Haskell
-
-main = do m_f <- eval "Fn (\\x y -> x == y)" ["Poly"]
-          when (isJust m_f) $ do
-                let (Fn f) = fromJust m_f
-                putStrLn $ show (f True True)
-                putStrLn $ show (f 1 2)
-}
-\end{quote}
-% 
-And the type of \code{Fn}:
-%
-\begin{quote}
-\scm{
-{-# OPTIONS -fglasgow-exts #-} 
-module Poly where
-
-import AltData.Typeable
-
-data Fn = Fn {fn :: forall t. Eq t => t -> t -> Bool}
-
-instance Typeable Fn where
-    typeOf _ = mkAppTy (mkTyCon "Poly.Fn") []
-}
-\end{quote}
-% 
-When executed, this program produces:
-%
-\begin{quote}
-\begin{verbatim}
-$ ./a.out
-True
-False
-\end{verbatim}
-\end{quote}
-
-We thus get dynamically typeable polymorphic functions.
-
-\begin{quote}
-\scm{
-unsafeEval :: String -> [Import] -> IO (Maybe a)
-
-unsafeEval_ :: String
-            -> [Import]
-            -> [String]
-            -> [FilePath]
-            -> IO (Either [String] a)
-}
-\end{quote}
-
-Wrapping up polymorphic values can be annoying, so we provide a
-\code{unsafeEval} function for people who like to live on the edge,
-which dispenses with dynamic typing, relying instead on the
-application to provide the correct type annotation on the call to
-\code{eval}. If the type loaded by \code{eval} is wrong,
-\code{unsafeEval} will crash. However, its lets us remove some
-restrictions on what types can be evaluated, which can be useful.
-
-{unsafeEval\_} lets the application have full control over the import
-environment and load flags to the eval call, which is useful for
-applications that wish to script themselves, and require specific
-modules and packages to be in scope in the eval-generated module.
-
-This example maps a \code{toUpper} over a list:
-%
-\begin{quote}
-\scm{
-import Eval.Haskell
-
-main = do s <- unsafeEval "map toUpper \"haskell\"" ["Data.Char"]
-          when (isJust s) $ putStrLn (fromJust s)
-}
-\end{quote}
- 
-And here we evaluate a lambda abstraction, applying the result to
-construct a tuple. Note the type information that must be supplied in
-order for Haskell to type the usage of \code{fn}:
-%
-\begin{quote}
-\scm{
-import System.Eval.Haskell
-
-main = do fn <- unsafeEval "(\\(x::Int) -> (x,x))" [] :: IO (Maybe (Int -> (Int,Int)))
-          when (isJust fn) $ putStrLn $ show $ (fromJust fn) 7
-}
-\end{quote}
-\subsection{Utilities for use with eval}
-\code{hs-plugins} proves the following utilities for use with \code{eval}:
-\begin{itemize}
-\item
-\code{mkHsValues} is a helper function for converting \code{Data.Map}s
-of names and values into Haskell code. It relies on the assumption
-that the passed values' Show instances produce valid Haskell
-literals (this is true for all prelude types). It's type is as follows:
-\begin{quote}
-\scm{
-mkHsValues :: (Show a) => Data.Map String a -> String
-}
-\end{quote}
-\end{itemize}
-% \subsection{Foreign Eval}
-% 
-% A preliminary binding to \code{eval} has been implemented to allow C
-% (and Objective C) programs access to the evaluator. Foreign bindings
-% to the compilation manager and dynamic loader are yet to be
-% implemented, but shouldn't be too hard. An foreign binding to a
-% Haskell module that wraps up calls to \code{make} and \code{load}
-% would be fairly trivial.
-%  
-% At the moment we have an ad-hoc binding to \code{eval}, so that C
-% programmers who know the type of value that will be returned by
-% Haskell can call the appropriate hook into the evaluator. If they get
-% the type wrong, a nullPtr will be returned (so calling Haskell is
-% still typesafe). The foreign bindings to \code{eval} all return
-% \code{NULL} if an error occurred, otherwise a pointer to the value is
-% returned.
-% 
-% \begin{quote}
-% \scm{
-% foreign export ccall hs_eval_b :: CString -> IO (Ptr CInt)
-% 
-% foreign export ccall hs_eval_c :: CString -> IO (Ptr CChar)
-%   
-% foreign export ccall hs_eval_i :: CString -> IO (Ptr CInt)
-% 
-% foreign export ccall hs_eval_s :: CString -> IO CString
-% }
-% \end{quote}
-% 
-% An example C program for compiling and evaluating Haskell code at
-% runtime follows. This program calculates a fibonacci number, returning
-% it as a \code{CString} to the C program:
-% %
-% \begin{quote}
-% \begin{verbatim}
-% #include "EvalHaskell.h"
-% #include <stdio.h>
-% 
-% int main(int argc, char *argv[])
-% {
-%   char *p;
-%   hs_init(&argc, &argv);
-%   p = hs_eval_s("show $ let fibs = 1:1:zipWith (+) fibs (tail fibs) in fibs !! 20");
-%   if (p != NULL)
-%      printf("%s\n",p);
-%   else
-%      printf("error in code\n");
-%   hs_exit();
-%   return 0;
-% }
-% \end{verbatim}
-% \end{quote}
-% 
-
-\section{RTS Binding}
-
-The low level interface is the binding to GHC's Linker.c. Therefore,
-\hsplugins{} only works on platforms with a working GHCi. This library
-is based on code from André Pang's runtime loader. The low level
-interface is as follows:
-
-\begin{itemize}
-      \item \code{initLinker}  \em  start the linker up 
-      \item \code{loadObject}  \em  load a vanilla .o
-      \item \code{loadPackage} \em  load a GHC library and its cbits
-      \item \code{loadShared } \em  load a .so object file
-      \item \code{resolveObjs} \em  and resolve symbols
-\end{itemize}
-
-Additionally, \code{Hi.Parser} provides an interface to a GHC
-\code{.hi} file parser. Currently we only parse just the dependency
-information, import and export information from \code{.hi} files, but
-all the code is there for an application to extract other information
-from \code{.hi} files.
-
-\newpage
-
-\section{Dynamic Loader Implementation}
-
-The dynamic loader is the system by which modules, and their
-dependencies can be loaded, unloaded or reloaded at runtime, and
-through which we access the functions we need.
-
-At its lowest level, the \hsplugins{} loader is a binding to the GHC
-runtime loader and linker. This layer is a direct reimplementation of
-Andre Pang's \code{runtime\_loader} (barely any code changed). The
-code at this level can only load single modules, or packages/archives
-(which are just objects too). Any dependency resolution must be
-performed by hand.
-
-On top of Andre's interface is a more convenient interface through
-which user's should interact with the dynamic loader.  The most
-significant extension to Andre's work is the automatic calculation and
-loading of a plugin's package or module dependencies via .hi file
-information.  It also handles initialisation of the loader, and
-retrieval of values from the plugin in a more convenient way. Some
-state is also stored in the loader to keep track of which modules and
-packages have been loaded, to prevent unnecessary (actually, fatal)
-loading of object files and packages already loaded.  Thus you can
-safely load several plugins at once, that share common dependencies,
-without worrying about the dependencies being loaded multiple times.
-We also store package.conf information in the state, so we can work
-out where a package lives and what it depends on.
-
-The ability to remember which packages and objects have been loaded is
-based on ideas in Hampus Ram's dynamic loader, which has a more
-advanced dependency tracking system, with the ability to unload the
-dependencies of a plugin. \hsplugins{} doesn't provide ``cascading
-unloading''. The advantage \hsplugins{} has over Hampus' loader seems
-to be the automatic dependency resolution via vanilla .hi files and
-the dynamic recompilation stuff.
-
-Using \code{load}, any library packages, or any \code{.o} files, that a
-plugin depends upon will be automatically loaded prior to loading the
-module itself. \code{load} then looks up a symbol from the object file,
-and returns the value associated with the symbol as a conventional
-Haskell value. It should also be possible to load a GHCi-style \code{.o}
-archive of object files this way, although there is currently no way
-to extract multple plugin interfaces from a archive of objects.
-
-The application writer is not required to recalculate dependencies if
-the plugin changes, and the plugin author does not need to specify
-what dependencies exist, as is required in the lower level interface.
-This is achieved by using the dependency information calculated by GHC
-itself, stored in .hi files, to work out which modules and packages to
-load, and in what order. A plugin in \hsplugins{} is really a pair of
-an object file (or archive) and a \code{.hi} file, containing package
-and module dependency information.  
-
-The \code{.hi} file is created by GHC when the plugin is compiled,
-either by hand or via \code{make}.  \code{load} uses a binary parser to
-extract the relevant information from the \code{.hi} data. Because the
-dependency information is stored in a separate file to the application
-that loads the plugin, such information can be recalculated without
-having to modify the application. Becaues of this, it was easy to
-extend the load to support recompilation of module source, even if
-dependencies change, because dependencies are no longer hard-coded
-into the application source itself, but are specified by the plugin.
-
-Assuming we have a plugin exporting some data, ``resource'', with a
-record name \code{field :: String}, here is an example call to \code{load}:
-%
-\begin{quote}
-\scm{
-do m_v   <- load "Test.o" ["."] [] "resource"
-   v <- case m_v of
-          LoadSuccess _ v -> return v
-          _               -> error "load failed"
-   putStrLn $ field v
-}
-\end{quote}
-
-This loads the object file \code{Test.o}, and any packages or objects
-\code{Test.o} depends on. It resolves undefined symbols, and returns
-from the object file the Haskell value named ``resource'', as the
-value ``v''. This must be a value exported by the plugin. We then
-retrieve the \code{field} component of \code{v}, and print it out.
-
-This simple usage assumes that the plugin to load is in the same
-directory as the application, and that the api defining the interface
-between plugin and application is also in the current directory (hence
-the ``.'' in the 2nd argument to \code{load}).
-
-\subsection*{Dynamically Loading the Dynamic Loader}
-
-It is also possible to load the \code{plugins} or \code{eval}
-libraries in GHC. Here, for example, we load the \code{plugs}
-interactive environment in GHCi, and evaluated some code. The source to
-\code{plugs} is in Appendix
-\ref{sec:plugs}.
-%
-\begin{quote}
-\begin{verbatim}
-paprika$ ghci -package-conf ../../../plugins.conf.inplace -package eval
-   ___         ___ _
-  / _ \ /\  /\/ __(_)
- / /_\// /_/ / /  | |      GHC Interactive, version 6.3, for Haskell 98.
-/ /_\\/ __  / /___| |      http://www.haskell.org/ghc/
-\____/\/ /_/\____/|_|      Type :? for help.
-
-Loading package base ... linking ... done.
-Loading package altdata ... linking ... done.
-Loading package unix ... linking ... done.
-Loading package mtl ... linking ... done.
-Loading package lang ... linking ... done.
-Loading package posix ... linking ... done.
-Loading package haskell98 ... linking ... done.
-Loading package haskell-src ... linking ... done.
-Loading package plugins ... linking ... done.
-Loading package eval ... linking ... done.
-Prelude> :l Main
-Skipping  Main             ( Main.hs, Main.o )
-Ok, modules loaded: Main.
-Prelude Main> main
-Loading package readline ... linking ... done.
-           __                          
-    ____  / /_  ______ ______          
-   / __ \/ / / / / __ `/ ___/     PLugin User's GHCi System, for Haskell 98
-  / /_/ / / /_/ / /_/ (__  )      http://www.cse.unsw.edu.au/~dons/hs-plugins
- / .___/_/\__,_/\__, /____/       Type :? for help     
-/_/            /____/                  
-
-Loading package base ... linking ... done
-plugs> map (\x -> x + 1) [0..10]
-[1,2,3,4,5,6,7,8,9,10,11]
-plugs> :t "haskell"
-"haskell" :: [Char]
-plugs> :q
-*** Exception: exit: ExitSuccess
-Prelude Main> :q
-Leaving GHCi.
-\end{verbatim}
-\end{quote}
-
-\subsection*{Dynamic Typing}
-
-Support is also provided to unwrap and check the type of dynamically
-typed plugin values (those wrapper in a \code{toDyn}) via
-\code{dynload}. This is the same as \code{load}, except that instead
-of a returning the value it finds, it unwraps a dynamically typed
-value, checks the type, and returns the unwrapped value. This is to
-provide further trust that the symbol you are retrieving from the
-plugin is of the type you think it is, beyond that trust you have by
-knowing that the plugin was compiled against a shared API. By using
-\code{dynload} it is not enough for an object file to just have the
-same symbol name as the function you require, it must also carry the
-\code{Data.Dynamic} representation of the type, too. \code{pdynload}
-rectifies most of \code{dynload}'s limitations, but at the cost of
-additional running time.
-
-\section{Compilation Manager Implementation}
-
-Along side the dynamic loader is the compilation manager.  This is a
-\code{make}-like system for compiling Haskell source, prior to loading
-it. \code{make} checks if a source file is newer than its associated
-object file. If so, the source is recompiled to an object file, and a
-new dependency file is created, in case the dependencies have changed
-in the source. This module can then be loaded.  The idea is to allow
-EDSL authors to write plugins without having to touch a compiler: it
-is all transparent. It also allows us to enforce type safety in the
-plugin by injecting type constraints into the plugin source, as has
-been discussed eariler.
-
-The effect is much like \emph{hi} (Hmake Interactive), funnily enough.
-An application using both \code{make} and \code{load} behaves like a
-Haskell interpreter, using \code{eval}.  You modify your plugin, and
-the application notices the change, recompiles it (possibly issuing
-type errors) and then reloads the object file, providing the
-application with the latest version of the code.
- 
-An example:
-%
-\begin{quote}
-\scm{
-do status <- make "Plugin.hs" []
-   obj    <- case status of
-                MakeSuccess _ o -> return o
-                MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-
-   m_v    <- load obj ["api"] [] "resource"
-   v      <- case m_v of
-            	LoadSuccess _ v -> return v
-            	_               -> error "load failed"
-   putStrLn $ field v
-}
-\end{quote}
-
-\code{make} accepts a source file as an argument, and a (usually empty)
-list of GHC flags needed to compile the object file. It then checks to
-see if compilation is required, and if so, it calls GHC to compile the
-code, with and arguments supplied. If any errors were generated by
-GHC, they are returned as the third component of the triple.
-
-Usually it will be necessary to ensure that GHC can find the plugin
-API to compile against. This can be done by either making sure the API
-is in the same directory as the plugin, or by adding a \code{-i} flag to
-\code{make}'s arguments. If the API is created as a ``package'' with a
-package.conf file, \code{make} can be given \code{-package-conf} arguments
-to the same effect.
-
-Normally, \code{make} generates the \code{.o} and \code{.hi} files in
-the same directory as the source file. This is not always desirable,
-particularly for interpreter-like applications. To solve this, you can
-pass \code{[''-odir'', path]} as elements of the arg list to
-\code{make}, and it will respect these arguments, generating the
-object and interface file in the directory specified. GHC's argument
-\code{''-o''} is also respected in a similar manner, so you could also
-say \code{[''-o'', obj]} for the same effect.
-
-\code{make} is entirely optional. All user's have to do to use the
-loader on its own is make sure they only load object files that also
-have a \code{.hi} file. This will usually be the case if the plugin is
-compiled with GHC.
-
-\subsection*{makeWith}
-
-\code{makeWith} merges two source files together, using the function
-and value declarations from one file, with any syntax in the second,
-creating a new third source file. It then compiles this source file
-via \code{make}.
-
-This function exists as a benefit to EDSL authors and is related to
-the original motivation for \hsplugins{}, as a .conf file language
-library. Configuration files need to be clean and simple, and you
-can't rely, or trust, the user to get all the compulsory details
-correct. So the solution is to factor out any compulsory syntax, such
-as module names, imports, and also to provide a default instance of
-the API, and store this code in a separate file provided by the
-application writer, not the user.  \code{makeWith} then merges
-whatever the user has written, with the syntax stub, generating a
-complete Haskell plugin source, with the correct module names and
-import declarations. We also ensure the plugin only exports a single
-interface value while we are here.
-
-\code{makeWith} thus requires a Haskell parser to parse two source files
-and merge the results. We are merging abstract syntax here. This is
-implemented using the Language.Haskell parser library. Unfortunately,
-this library doesn't implement all of GHC's extensions, so if you wish
-to use \code{makeWith} you can only write Haskell source that can be
-parsed by this library, which is just H98 and a few extensions. This
-is another short coming in the current design that will be overcome
-with \code{-package ghc}. Remember, however, for normal uses of
-\code{make} and \code{load} you are unrestricted in what Haskell you use.
-This is the same restriction present in happy, the Haskell parser,
-placed on the code you can provide in the \code{.y} source.
-
-\code{makeWith} also makes use of line pragmas. If the merged file
-fails to compile, the judicious use of line number pragmas ensure that
-the user receives errors messages reported with reference to their
-source file, and not line number in the merged file. This is a
-property of the Language.Haskell parser that we can make use of.
-
-An example of \code{makeWith}:
-%
-\begin{quote}
-\scm{
-do status <- makeWith "Plugin.in" "Plugin.stub" []
-   obj <- case status of
-                MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess _ o -> return o
-   m_v  <- load obj [apipath] [] "resource"
-   v <- case m_v of
-                LoadSuccess _ v -> return v
-                _               -> error "load failed"
-   putStrLn $ field v
-}
-\end{quote}
-
-We combine the user's file (\code{Plugin.in}) with a stub of syntax
-generating a new, third Haskell file in the default tmpdir. This is
-compiled as per usual, producing object and interface files. The
-object is then loaded, and we extract the value exported.
-
-Using \code{makeWith} it is possible to write very simple, clear
-Haskell plugins, that appear not to be Haskell at all. It is an easy
-way to get EDSL user's writing plugins that are actually Haskell
-programs, for .e.g, configuration files. See the examples that come
-with the src.
-
-\newpage
-
-\section{An Example}
-
-This is an introductory example.
-
-\subsection*{API}
-
-First we need an interface between the application and the plugin.
-This module needs to be visible to both the app and the plugin, in the
-interest of clear and well-defined interfaces: 
-%
-\begin{quote}
-\scm{
-module StringProcAPI (Interface(..), plugin) where
-
-data Interface = Interface {
-       stringProcessor :: String -> String
-}
-
-plugin :: Interface
-plugin = Interface { stringProcessor = id }
-}
-\end{quote}
-
-Here we define \code{Interface} as the inteface signature for the
-object passed between plugin and application. We'll use the record
-syntax as it looks intuitive in the plugin. We provide a default
-instance, the \code{plugin} value, that can be overwritten in the
-actual plugin, ensuring sensible behaviour in the absence of any
-plugins. The API should theoretically be compiled with \code{-Onot} to
-avoid interface details leaking out into the \code{.hi} file.
-
-\subsection*{The Plugin}
-
-This is our plugin. Note that the plugin will be compiled entirely
-seperately from the application. It must only rely on the API, and
-nothing in the application source.
-%
-\begin{quote}
-\scm{
-module StringProcPlugin (resource) where
-
-import StringProcAPI (plugin)
-
-resource = plugin {
-     stringProcessor = reverse 
-}
-}
-\end{quote}
-
-Using the record syntax we overwrite the \code{function} field with our
-own value, \code{reverse}. The value \code{resource} is the magic symbol
-that must be defined, and which the application will use to find the
-data the plugin exports.
-
-Now, we can make this even easier on the plugin writer by the use of a
-``stub'' file. \code{makeWith} lets you merge a plugin source with
-another Haskell file, and compiles the result into the actual plugin
-object. So the application can provide a stub file containing module
-declarations and imports, and a default plugin value. Here is an
-application-provided stub, factoring out compulsory syntax and type
-declarations from the plugin:
-%
-\begin{quote}
-\scm{
-module StringProcPlugin ( resource ) where
-
-import StringProcAPI
-
-resource :: Interface
-resource = plugin
-}
-\end{quote}
-
-By factoring out compulsory syntax, the plugin author only has to
-provide an overriding instance of the \code{resource} field. So all
-the plugin actually consists of, is:
-%
-\begin{quote}
-\scm{
-resource = plugin {
-      stringProcessor = reverse
-}
-}
-\end{quote}
-
-That is all the code we need! This file may be called anything at all.
-
-More complex APIs may have more fields, of course. The nice thing
-about this arrangement is that the user will write some simple syntax,
-which will nonetheless by typechecked safely against the API. Errors
-are also reported using line numbers from the source file, not the
-stub, which makes things less confusing.
-
-\subsection*{The Application}
-
-Now we need to write an application that can use values of the kind
-defined in the API, and which can compile and load plugins. The basic
-mechanism to compile and load a plugin is as follows:
-%
-\begin{quote}
-\scm{
-do status <- make "StringProcPlugin.hs" []
-   obj    <- case status of
-                MakeSuccess _ o -> return o
-                MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-
-   m_v    <- load obj ["."] [] "resource"
-   val    <- case m_v of
-                LoadSuccess _ v -> return v
-                _               -> error "load failed"
-}
-\end{quote}
-%
-This code calls \code{make} to compile the plugin source, yielding
-wrapper around a handle to an object file. The object can then be loaded
-using \code{load}, and the code associated with the symbol
-\code{resource} is retrieved. 
-
-We embed this code in a simple shell-like loop, applying the function
-exported by the plugin:
-%
-\begin{quote}
-\scm{
-import System.Plugins
-import StringProcessorAPI
-import System.Console.Readline
-import System.Exit
-
-source = "Plugin.hs"
-stub   = "Plugin.stub"
-symbol = "resource"
-
-main = do s <- makeWith source stub []
-          o <- case s of
-                MakeSuccess _ obj -> do
-                        ls <- load obj ["."] [] symbol
-                        case ls of LoadSuccess m v -> return (m,v)
-                                   LoadFailure err -> error "load failed"
-                MakeFailure e -> mapM_ putStrLn e >> error "compile failed"
-          shell o
-
-shell o@(m,plugin) = do 
-        s <- readline "> "
-        cmd <- case s of 
-                Nothing          -> exitWith ExitSuccess
-                Just (':':'q':_) -> exitWith ExitSuccess
-                Just s           -> addHistory s >> return s
-
-        s  <- makeWith source stub []   -- maybe recompile the source
-        o' <- case s of
-                MakeSuccess ReComp o -> do 
-                        ls <- reload m symbol
-                        case ls of LoadSuccess m' v' -> return (m',v')
-                                   LoadFailure err   -> error "reload failed"
-                MakeSuccess NotReq _ -> return o
-                MakeFailure e -> mapM_ putStrLn e >> shell o
-        eval cmd o'
-        shell o'
-
-eval ":?" _ = putStrLn ":?\n:q\n<string>"
-
-eval s (_,plugin) = let fn = (stringProcessor plugin) in putStrLn (fn s)
-}
-\end{quote}
-
-We have to import the hs-plugins library, and the API. The main loop
-proceeds by compiling and loading the plugin for the first time, and
-then calls \code{shell}, the interpeter loop. This loop lets us apply
-the function in the plugin to strings we supply.  We have to pass
-around the \code{(Module, a)} pair we get back from \code{reload}, so
-that we can pass it to \code{eval} to do the real work.  The first
-\code{eval} case is where we use the record syntax to select the
-\code{function} field out of \code{v}, the plugin interface object,
-and we apply it to s. Try it out:
-%
-\begin{quote}
-\begin{verbatim}
-paprika$ ./a.out 
-Loading package base ... linking ... done
-Loading objects API Plugin ... done
-> :?
-":?"
-":q"
-"<string>"
-> abcdefg
-gfedcba
-\end{verbatim}
-\end{quote}
-
-Now, if we edit the plugin while the shell is running, the next time
-we type something at the prompt the plugin will be unloaded,
-recompiled and reloaded. Because the plugin is really an EDSL, we can
-use any Haskell we want, so we'll change the plugin to:
-%
-\begin{quote}
-\scm{
-import Data.Char
-
-resource = plugin {
-	stringProcessor = my_fn
-}
-
-my_fn s = map toUpper (reverse s)
-}
-\end{quote}
-
-Back to the shell:
-%
-\begin{quote}
-\begin{verbatim}
-> abcdefg 
-Compiling plugin ... done
-Reloading Plugin ... done
-GFEDCBA
-\end{verbatim}
-\end{quote}
-
-And that's it: dynamically recompiled and reload Haskell code!
-
-\section{Multiple Plugins}
-
-It is quite easy to load multiple plugins, that all implement the
-common plugin API, and that all export the same value (though
-implemented differently). This make \hsplugins{} suitable for
-applications that wish to allow an arbitrary number of plugins. The
-main problem with multiple plugins is that they may share
-dependencies, and if \code{load} na\"ively loaded all dependencies
-found in the set of \code{.hi} files associated with all the plugins,
-the GHC rts would crash. To solve this the \hsplugins{} dynamic loader
-maintains state storing a list of what modules and packages have been
-loaded already. If \code{load} is called on a module that is already
-loaded, or dependencies are attempted to load, that have already been
-loaded, the dynamic loader ignores these extra dependencies. This
-makes it quite easy to write an application that will allows an
-arbitrary number of plugins to be loaded. An example follows.
-
-\subsection*{Definition}
-
-First we need to define the API that a plugin must type check against,
-in order to be valid.  
-%
-\begin{quote}
-\scm{
-module API where
-
-data Interface = Interface { 
-	valueOf :: String -> String 
-}
-
-plugin :: Interface 
-plugin = Interface { valueOf = id }
-}
-\end{quote}
-
-We can then implement a number of plugins that provide values of type
-"Interface". We show three plugins that export string manipulation functions:
-%
-\begin{quote}
-\scm{
-module Plugin1 where
-
-import API
-import Data.Char
-
-resource = plugin {
-	valueOf = \s -> map toUpper s
-}
-}
-\end{quote}
-
-\begin{quote}
-\scm{
-module Plugin2 where
-
-import API
-import Data.Char
-
-resource = plugin {
-	valueOf = \s -> map toLower s
-}
-}
-\end{quote}
-
-\begin{quote}
-\scm{
-module Plugin3 where
-
-import API
-
-resource = plugin {
-	valueOf = reverse
-}
-}
-\end{quote}
-
-And finally we need to write an application that would use these
-plugins. Remember that the application is written without knowledge of
-the plugins, and the plugins are written without knowledge of the
-application. They are each implemented only in terms of the API, a
-shared module and \code{.hi} file. An application needs to make the
-API interface available to plugin authors, by distributing the API
-object file and \code{.hi} file with the application.
-%
-\begin{quote}
-\scm{
-import System.Plugins
-import API
-
-main = do
- let plist = ["Plugin1.o", "Plugin2.o", "Plugin3.o"]
- plugins <- mapM (\p -> load p ["."] [] "resource") plist
- let functions = map (valueOf . fromLoadSuc) plugins
- mapM_ (\f -> putStrLn $ f "haskell is for hackers") functions
-
-fromLoadSuc (LoadFailure _)   = error "load failed"
-fromLoadSuc (LoadSuccess _ v) = v
-
-}
-\end{quote}
-
-This application simply loads all the plugins and retrieves the
-functions they export. It then applies each of these functions to a
-string, printing the result. We assume for this example that the
-plugins are compiled once only, and are not compiled dynamically via
-\code{make}. This implies that you have to use \code{GHC} to generate
-the \code{.hi} file for each plugin. A sample Makefile to compile the
-plugins, and the api:
-%
-\begin{quote}
-\begin{verbatim}
-all:
-    ghc -Onot -c API.hs
-    ghc -O -c Plugin1.hs
-    ghc -O -c Plugin2.hs
-    ghc -O -c Plugin3.hs
-\end{verbatim}
-\end{quote}
-
-Ghc creates \code{.hi} files for each plugin, which can be inspected
-using the \code{Plugins.BinIface.readBinIface} function. It parses the
-\code{.hi} file, generating, roughly, the following:
-%
-\begin{quote}
-\begin{verbatim}
-interface "Main" Main
-module dependencies: A, B
-package dependencies: base, haskell98, lang, unix
-\end{verbatim}
-\end{quote}
-
-which says that the plugin depends upon a variety of system packages,
-and the modules A and B. All these dependencies must be loaded before
-the plugin itself.
-
-You then need to compile the application against the API, and against
-the \hsplugins{} library:
-%
-\begin{quote}
-\begin{verbatim}
-ghc -O --make -package plugins Main.hs
-\end{verbatim}
-\end{quote}
-
-Running the application produces the following result. Note that the
-verbose output can be switched off by compiling \hsplugins{} without
-the \code{-DDEBUG} flag. If you look at the \code{.hi} file, using
-\code{ghc --show-iface}, you'll see that they all depend on the base
-package, and on the API, but the state stored in the dynamic loader
-ensures that these shared modules are only loaded once:
-%
-\begin{quote}
-\begin{verbatim}
-Loading package base ... linking ... done
-Loading object API Plugin1 ... done
-Loading object Plugin2 ... done
-Loading object Plugin3 ... done
-
-HASKELL IS FOR HACKERS
-haskell is for hackers
-srekcah rof si lleksah
-\end{verbatim}
-\end{quote}
-
-Archives of plugins can be loaded in one go if they have been linked
-into a .o GHCi package, see \code{loadPackage}.
-
-\newpage
-
-\appendix
-
-\section{License} 
-
-This library is distributed under the terms of the LGPL:
-
-\begin{quote}
-
-Copyright 2003-5, Don Stewart - \url{http://www.cse.unsw.edu.au/~dons}
-
-This library is free software; you can redistribute it and/or
-modify it under the terms of the GNU Lesser General Public
-License as published by the Free Software Foundation; either
-version 2.1 of the License, or (at your option) any later version.
-
-This library 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
-Lesser General Public License for more details.
-
-You should have received a copy of the GNU Lesser General Public
-License along with this library; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307
-USA
-
-\end{quote}
-
-\section{Portability}
-
-The library tries to be portable. There are two major points that
-limit easy portabilty. The main issue is a dependence on the GHC dynamic
-linker. \hsplugins{} is thus limited to platforms to which GHC's dyn
-linker has been ported (this is essentially the same as the platforms
-that can run GHCi).
-
-\newpage
-
-\section{A Haskell Interpreter using Plugins}
-% \label{sec:plugs}
-
-Here is a full length example of a Haskell interpreter/compiler in the
-style of Malcolm Wallace's \code{hi}. Rather than compiling the
-user's code to an executable, we use \hsplugins{} to instead load an
-object file and execute that instead, using the \code{eval} interface.
-This cuts out the linking phase from the process, making turnaround at
-the prompt around twice as fast as \code{hi}.
-
-\subsection*{Source of Plugs}
-
-\begin{quote}
-\scm{
-import System.Eval.Haskell
-import System.Plugins
-
-import System.Exit              ( ExitCode(..), exitWith )
-import System.IO
-import System.Console.Readline  ( readline, addHistory )
-
-symbol = "resource"
-
-main = do
-        putStrLn banner 
-        putStr "Loading package base" >> hFlush stdout
-        loadPackage "base" 
-        putStr " ... linking ... " >> hFlush stdout
-        resolveObjs
-        putStrLn "done"
-
-        shell []
-
-shell :: [String] -> IO ()
-shell imps = do 
-        s <- readline "plugs> "
-        cmd <- case s of 
-                Nothing          -> exitWith ExitSuccess
-                Just (':':'q':_) -> exitWith ExitSuccess
-                Just s           -> addHistory s >> return s
-        imps' <- run cmd imps
-        shell imps'
-
-run :: String -> [String] -> IO [String]
-run ""   is = return is
-run ":?" is = putStrLn help >> return is
-
-run ":l" _             = return []
-run (':':'l':' ':m) is = return (m:is)
-
-run (':':'t':' ':s) is = do 
-        ty <- typeOf s is
-        when (not $ null ty) (putStrLn $ s ++ " :: " ++ ty)
-        return is
-
-run (':':_) is = putStrLn help >> return is
-
-run s is = do 
-        s <- unsafeEval ("show $ "++s) is
-        when (isJust s) (putStrLn (fromJust s))
-        return is
-
-banner = "\ 
-\           __                          \n\
-\    ____  / /_  ______ ______          \n\
-\   / __ \\/ / / / / __ `/ ___/     PLugin User's GHCi System, for Haskell 98\n\
-\  / /_/ / / /_/ / /_/ (__  )      http://www.cse.unsw.edu.au/~dons/hs-plugins\n\
-\ / .___/_/\\__,_/\\__, /____/       Type :? for help     \n\
-\/_/            /____/                  \n"
-
-help = "\
-\Commands :\n\ 
-\  <expr>               evaluate expression\n\ 
-\  :t <expr>            show type of expression (monomorphic only)\n\ 
-\  :l module            bring module in to scope\n\ 
-\  :l                   clear module list\n\ 
-\  :quit                quit\n\ 
-\  :?                   display this list of commands"
-}
-\end{quote}
-
-\subsection*{A Transcript}
-
-And a transcript:
-%
-\begin{quote}
-\begin{verbatim}
-$ ./plugs
-           __                          
-    ____  / /_  ______ ______          
-   / __ \/ / / / / __ `/ ___/     PLugin User's GHCi System, for Haskell 98
-  / /_/ / / /_/ / /_/ (__  )      http://www.cse.unsw.edu.au/~dons/hs-plugins
- / .___/_/\__,_/\__, /____/       Type :? for help     
-/_/            /____/                  
-
-Loading package base ... linking ... done
-plugs> 1
-1
-plugs> let x = 1 + 2 in x
-3
-plugs> :l Data.List
-plugs> case [1,3,2] of x -> sort x
-[1,2,3]
-plugs> reverse [1,3,2]
-[2,3,1]
-plugs> map (\x -> (x,2^x)) [1,2,3,4,5,6,7,8,9,10]
-[(1,2),(2,4),(3,8),(4,16),(5,32),(6,64),(7,128),(8,256),(9,512),(10,1024)]
-plugs> :t "haskell"
-"haskell" :: [Char]
-plugs> :quit
-\end{verbatim}
-\end{quote}
-
-\end{document}
diff --git a/docs/munge.sed b/docs/munge.sed
deleted file mode 100644
--- a/docs/munge.sed
+++ /dev/null
@@ -1,16 +0,0 @@
-
-# de-boldify and <p>-ify the Contents.
-
-/Contents/ { 
-	:loop
-	/Go to/ { 
-		b end
-	}
-	s,<p>,,
-        s,<b>,,
-        s,</b>,,
-        s,</p>,,
-	n
-	b loop
-}
-:end
diff --git a/docs/tex2page.sty b/docs/tex2page.sty
deleted file mode 100644
--- a/docs/tex2page.sty
+++ /dev/null
@@ -1,9 +0,0 @@
-% tex2page.sty
-% Dorai Sitaram
-
-% Loading this file in a LaTeX document
-% gives it all the macros of tex2page.tex,
-% but via a more LaTeX-convenient filename.
-
-\input{tex2page}
-
diff --git a/docs/tex2page.tex b/docs/tex2page.tex
deleted file mode 100644
--- a/docs/tex2page.tex
+++ /dev/null
@@ -1,1381 +0,0 @@
-% tex2page.tex
-% Dorai Sitaram
-
-% TeX files using these macros
-% can be converted by the program
-% tex2page into HTML
-
-\message{version 2003-10-26} % last change 
-
-\let\texonly\relax
-\let\endtexonly\relax
-
-\texonly
-
-\newcount\evalQauxfilecount
-\evalQauxfilecount=0
-
-\def\eval{\begingroup
-  \ifx\evalfortexQport\UNDEFINED
-    \expandafter\csname newwrite\endcsname
-      \evalfortexQport
-    \immediate\openout\evalfortexQport
-      \jobname.eval4tex 
-    \immediate\write\evalfortexQport
-      {\string\ifx\string\shipout\string\UNDEFINED
-         \string\eval{(eval-for-tex-only)}%
-       \string\else\string\endinput\string\fi}%
-  \fi
-  \global\advance\evalQauxfilecount by 1
-  \edef\evalQauxfile{\jobname-Z-E-\the\evalQauxfilecount}%
-  {\immediate\openin0=\evalQauxfile.tex 
-   \ifeof0 \immediate\closein0 
-   \else \input \evalQauxfile.tex \fi}%
-  \def\do##1{\catcode`##1=12 }\dospecials
-  \catcode`\{=1 \catcode`\}=2 
-  \catcode`\^^M=12 
-  \newlinechar=`\^^M%
-  \evalQii}
-
-\def\evalQii#1{%
-  \immediate\write\evalfortexQport{\string\eval{#1}}%
-  \endgroup}
-
-%\def\verbwritefile#1 {\relax}
-%\let\verbwrite\gobbleencl
-
-\def\verbwritefile{%
-  \ifx\verbwritefileQport\UNDEFINED
-    \expandafter\csname newwrite\endcsname\verbwritefileQport 
-  \else\immediate\closeout\verbwritefileQport
-  \fi
-  \futurelet\verbwritefileQnext\verbwritefileQcheckchar}
-
-\def\verbwritefileQcheckchar{%
-  \ifx\verbwritefileQnext\bgroup
-    \let\verbwritefileQnext\verbwritefileQbracedfile
-  \else
-    \let\verbwritefileQnext\verbwritefileQspacedfile
-  \fi\verbwritefileQnext}
-
-\def\verbwritefileQspacedfile#1 {%
-  \immediate\openout\verbwritefileQport #1
-}
-
-\def\verbwritefileQbracedfile#1{%
-  \verbwritefileQspacedfile #1
-}
-
-\def\verbwrite{%
-  \ifx\verbwritefileQport\UNDEFINED
-    \verbwritefile \jobname.txt \fi
-  \begingroup
-    \def\do##1{\catcode`##1=12 }\dospecials
-    \catcode`\{=1 \catcode`\}=2 
-    \catcode`\^^M=12 \newlinechar=`\^^M%
-    \futurelet\verbwriteQopeningchar\verbwriteQii}
-
-\def\verbwriteQii{\ifx\verbwriteQopeningchar\bgroup
-  \let\verbwriteQiii\verbwriteQbrace\else
-  \let\verbwriteQiii\verbwriteQnonbrace\fi
-  \verbwriteQiii}
-
-\def\verbwriteQbrace#1{\immediate
-  \write\verbwritefileQport{#1}\endgroup}
-
-\def\verbwriteQnonbrace#1{%
-  \catcode`\{12 \catcode`\}12
-  \def\verbwriteQnonbraceQii##1#1{%
-    \immediate\write\verbwritefileQport{##1}\endgroup}%
-  \verbwriteQnonbraceQii} 
-
-\ifx\loadonlyQevalfortex1%
-  \let\maybeloadfollowing\endinput
-\else
-  \let\maybeloadfollowing\relax
-\fi\maybeloadfollowing
-
-\ifx\slatexignorecurrentfile\UNDEFINED\relax\fi
-
-\edef\atcatcodebeforetiip{\the\catcode`\@ }
-\catcode`\@11
-
-% margins
-
-\def\sidemargin{\afterassignment\sidemarginQadjustoffset
-  \hoffset}
-
-\def\sidemarginQadjustoffset{%
-  \advance\hoffset -1true in
-  \advance\hsize -2\hoffset}
-
-\def\vertmargin{\afterassignment\vertmarginQadjustoffset
-  \voffset}
-
-\def\vertmarginQadjustoffset{%
-  \advance\voffset -1true in
-  \advance\vsize -2\voffset}
-
-%
-
-\def\defcsactive#1{\defnumactive{`#1}}
-
-\def\defnumactive#1{\catcode#1\active
-  \begingroup\lccode`\~#1%
-    \lowercase{\endgroup\def~}}
-
-% gobblegobblegobble
-
-\def\gobblegroup{\bgroup
-  \def\do##1{\catcode`##1=9 }\dospecials
-  \catcode`\{1 \catcode`\}2 \catcode`\^^M=9
-  \gobblegroupI}
-
-\def\gobblegroupI#1{\egroup}
-
-\def\gobbleencl{\bgroup
-  \def\do##1{\catcode`##1=12 }\dospecials
-  \catcode`\{1 \catcode`\}2 \catcode`\^^M=9
-  \futurelet\gobbleenclnext\gobbleenclI}
-
-\def\gobbleenclI{\ifx\gobbleenclnext\bgroup
-    \let\gobbleenclnext\gobblegroupI
-  \else\let\gobbleenclnext\gobbleenclII\fi
-  \gobbleenclnext}
-
-\def\gobbleenclII#1{%
-  \def\gobbleenclIII##1#1{\egroup}%
-  \gobbleenclIII}
-
-% \verb
-% Usage: \verb{...lines...} or \verb|...lines...|
-% In the former case, | can be used as escape char within
-% the verbatim text
-
-\let\verbhook\relax
-
-\def\verbfont{\tt}
-%\hyphenchar\tentt-1
-
-\def\verbsetup{\frenchspacing
-  \def\do##1{\catcode`##1=12 }\dospecials
-  \catcode`\|=12 % needed?
-  \verbfont
-  \edef\verbQoldhyphenchar{\the\hyphenchar\font}%
-  \hyphenchar\font-1
-  \def\verbQendgroup{\hyphenchar\font\verbQoldhyphenchar\endgroup}%
-}
-
-% The current font is cmtt iff fontdimen3 = 0 _and_
-% fontdimen7 != 0
-
-\def\checkifusingcmtt{\let\usingcmtt n%
-  \ifdim\the\fontdimen3\the\font=0.0pt
-    \ifdim\the\fontdimen7\the\font=0.0pt
-    \else\let\usingcmtt y\fi\fi}
-
-% In a nonmonospaced font, - followed by a letter
-% is a regular hyphen.  Followed by anything else, it is a
-% typewriter hyphen.
-
-\def\variablelengthhyphen{\futurelet\variablelengthhyphenI
-  \variablelengthhyphenII}
-
-\def\variablelengthhyphenII{\ifcat\noexpand\variablelengthhyphenI
- a-\else{\tt\char`\-}\fi}
-
-\def\verbavoidligs{% avoid ligatures
-  \defcsactive\`{\relax\lq}%
-  \defcsactive\ {\leavevmode\ }%
-  \defcsactive\^^I{\leavevmode\ \ \ \ \ \ \ \ }%
-  \defcsactive\^^M{\leavevmode\endgraf}%
-  \checkifusingcmtt
-  \ifx\usingcmtt n%
-  \defcsactive\<{\relax\char`\<}%
-  \defcsactive\>{\relax\char`\>}%
-  \defcsactive\-{\variablelengthhyphen}%
-  \fi}
-
-\def\verbinsertskip{%
-  \let\firstpar y%
-  \defcsactive\^^M{\ifx\firstpar y%
-    \let\firstpar n%
-    \verbdisplayskip
-    \parskip 0pt
-    \aftergroup\verbdisplayskip
-    \else\leavevmode\fi\endgraf}%
-  \verbhook}
-
-\ifx\verb\UnDeFiNeD\else
-% Save LaTeX's \verb away, because
-% we'll be defining our own \verb
-\let\LaTeXverb\verb
-\fi
-
-%\def\verb{\begingroup
-%  \verbsetup\verbI}
-
-\def\verb{\begingroup
-  \verbsetup\verbavoidligs\verbQcheckstar}
-
-\def\verbQcheckstar{%
-  \futurelet\verbQcheckstarQnext\verbQcheckstarQii}
-
-\def\verbQcheckstarQii{%
-  \if\verbQcheckstarQnext*%
-    \let\verbQcheckstarQnext\verbQcheckstarQiii
-  \else
-    \let\verbQcheckstarQnext\verbI
-  \fi
-  \verbQcheckstarQnext}
-
-\def\verbQcheckstarQiii#1{%
-  \defcsactive\ {\relax\char`\ }%
-  \verbI}
-
-\def\verbc{\begingroup
-  \verbsetup\afterassignment\verbcI
-  \let\verbcII=}
-
-\def\verbcI{{\verbfont\verbcII}\endgroup}
-
-\let\E\verbc
-
-\newcount\verbbracebalancecount
-
-\def\verblbrace{\char`\{}
-\def\verbrbrace{\char`\}}
-
-\def\verbescapechar#1{%
-  \def\escapifyverbescapechar{\catcode`#1=0 }}
-
-\verbescapechar\|
-
-{\catcode`\[1 \catcode`\]2
-\catcode`\{12 \catcode`\}12
-\gdef\verbI#1[%\verbavoidligs
-  \verbinsertskip\verbhook
-  %\edef\verbQoldhyphenchar{\the\hyphenchar\tentt}%
-  %\hyphenchar\tentt=-1
-  %\def\verbQendgroup{\hyphenchar\tentt\verbQoldhyphenchar\endgroup}%
-  %\let\verbQendgroup\endgroup%
-  \if#1{\escapifyverbescapechar
-    \def\{[\char`\{]%
-    \def\}[\char`\}]%
-    \def\|[\char`\|]%
-    \verbbracebalancecount0
-    \defcsactive\{[\advance\verbbracebalancecount by 1
-      \verblbrace]%
-    \defcsactive\}[\ifnum\verbbracebalancecount=0
-      \let\verbrbracenext\verbQendgroup\else
-      \advance\verbbracebalancecount by -1
-      \let\verbrbracenext\verbrbrace\fi
-      \verbrbracenext]\else
-  \defcsactive#1[\verbQendgroup]\fi
-  \verbII
-]]
-
-\def\verbII{\futurelet\verbIInext\verbIII}
-
-{\catcode`\^^M\active%
-\gdef\verbIII{\ifx\verbIInext^^M\else%
-  \defcsactive\^^M{\leavevmode\ }\fi}}
-
-\let\verbdisplayskip\medbreak
-
-% \verbatiminput FILENAME
-% displays contents of file FILENAME verbatim.
-
-%\def\verbatiminput#1 {{\verbsetup\verbavoidligs\verbhook
-%  \input #1 }}
-
-% ^ original \verbatiminput
-
-\ifx\verbatiminput\UNDEFINED
-% LaTeX's (optional) verbatim package defines a \verbatiminput --
-% don't clobber it
-\def\verbatiminput{%
-  \futurelet\verbatiminputQnext\verbatiminputQcheckchar}%
-\fi
-
-\def\verbatiminputQcheckchar{%
-  \ifx\verbatiminputQnext\bgroup
-    \let\verbatiminputQnext\verbatiminputQbracedfile
-  \else
-    \let\verbatiminputQnext\verbatiminputQspacedfile
-  \fi\verbatiminputQnext}
-
-\def\verbatiminputQbracedfile#1{\verbatiminputQdoit{#1}}
-
-\def\verbatiminputQspacedfile#1 {\verbatiminputQdoit{#1}}
-
-\def\verbatiminputQdoit#1{{\verbsetup
-  \verbavoidligs\verbhook
-  \input #1 }}
-
-
-% \url{URL} becomes
-% <a href="URL">URL</a> in HTML, and
-% URL in DVI.
-
-% A-VERY-VERY-LONG-URL in a .bib file
-% could be split by BibTeX
-% across a linebreak, with % before the newline.
-% To accommodate this, %-followed-by-newline will
-% be ignored in the URL argument of \url and related
-% macros.
-
-\ifx\url\UnDeFiNeD
-\def\url{\bgroup\urlsetup\let\dummy=}%
-\fi
-
-\def\urlsetup{\verbsetup\urlfont\verbavoidligs
-  \catcode`\{1 \catcode`\}2
-  \defcsactive\%{\urlpacifybibtex}%
-  \defcsactive\ {\relax}%
-  \defcsactive\^^M{\relax}%
-  \defcsactive\.{\discretionary{}{\char`\.}{\char`\.}}%
-  \defcsactive\/{\discretionary{\char`\/}{}{\char`\/}}%
-  \defcsactive\`{\relax\lq}}
-
-\let\urlfont\relax
-
-\def\urlpacifybibtex{\futurelet\urlpacifybibtexnext\urlpacifybibtexI}
-
-\def\urlpacifybibtexI{\ifx\urlpacifybibtexnext^^M%
-  \else\%\fi}
-
-% \mailto{ADDRESS} becomes
-% <a href="mailto:ADDRESS">ADDRESS</a> in HTML, and
-% ADDRESS in DVI.
-
-\let\mailto\url
-
-% \urlh{URL}{TEXT} becomes
-% <a href="URL">TEXT</a> in HTML, and
-% TEXT in DVI.
-
-% If TEXT contains \\, the part after \\ appears in
-% the DVI only.  If, further, this part contains \1,
-% the latter is replaced by a fixed-width representation
-% of URL.
-
-\def\urlh{\bgroup\urlsetup
-  \afterassignment\urlhI
-  \gdef\urlhQurlarg}
-
-\def\urlhI{\egroup
-  \bgroup
-    \let\\\relax
-    \def\1{{\urlsetup\urlhQurlarg}}%
-    \let\dummy=}
-
-\def\urlp#1{{#1} \bgroup\urlsetup
-  \afterassignment\urlpQwrapparens
-  \gdef\urlpQurlarg}
-
-\def\urlpQwrapparens{\egroup
-  {\rm(}{\urlsetup\urlpQurlarg}{\rm)}}
-
-% \urlhd{URL}{HTML-TEXT}{DVI-TEXT} becomes
-% <a href="URL">HTML-TEXT</a> in HTML, and
-% DVI-TEXT in DVI
-
-\def\urlhd{\bgroup
-  \def\do##1{\catcode`##1=12 }\dospecials
-  \catcode`\{1 \catcode`\}2
-  \urlhdQeaturlhtmlargs}
-
-\def\urlhdQeaturlhtmlargs#1#2{\egroup}
-
-\ifx\hyperref\UnDeFiNeD
-\let\href\urlh
-\let\hypertarget\gobblegroup
-\let\hyperlink\gobblegroup
-\def\hyperref#1#2#3#4{#2\ref{#4}#3}
-\fi
-
-%
-
-\let\ignorenextinputtimestamp\relax
-
-% don't let caps disable end-of-sentence spacing
-
-\def\nocapdot{%
-\count255=`\A
-\loop
-\sfcode\the\count255=1000
-\ifnum\count255<`\Z
-\advance\count255 by 1
-\repeat
-}
-
-%
-
-%\ifx\newenvironment\UnDeFiNeD
-\let\htmlonly\iffalse
-\let\endhtmlonly\fi
-%\else
-%\usepackage{comment}
-%\excludecomment{htmlonly}
-%\fi
-
-\def\rawhtml{\errmessage{Can't occur outside
-  \string\htmlonly}}
-\def\endrawhtml{\errmessage{Can't occur outside
-  \string\htmlonly}}
-
-\let\htmlheadonly\iffalse
-\let\endhtmlheadonly\fi
-
-\let\cssblock\iffalse
-\let\endcssblock\fi
-
-\def\inputcss#1 {\relax}
-\let\htmlstylesheet\inputcss
-\let\htmladdimg\gobblegroup
-
-\def\htmlref{\bgroup\aftergroup\gobblegroup\let\dummy=}
-
-%
-
-\let\htmlcolophon\gobblegroup
-\let\htmlmathstyle\gobblegroup
-\let\htmladvancedentities\relax
-
-% Scheme
-
-\let\scm\verb
-\let\scminput\verbatiminput
-
-\let\scmwritefile\verbwritefile
-\let\scmwrite\verbwrite
-\let\scmdribble\scm
-
-\ifx\slatexversion\UNDEFINED
-% SLaTeX compat
-\let\scmkeyword\gobblegroup
-\let\scmbuiltin\gobblegroup
-\let\scmconstant\scmbuiltin
-\let\scmvariable\scmbuiltin
-\let\setbuiltin\scmbuiltin
-\let\setconstant\scmbuiltin
-\let\setkeyword\scmkeyword 
-\let\setvariable\scmvariable
-\def\schemedisplay{\begingroup
-  \verbsetup\verbavoidligs
-  \verbinsertskip
-  \schemedisplayI}%
-\def\schemeresponse{\begingroup
-  \verbsetup\verbavoidligs
-  \verbinsertskip
-  \schemeresponseI}%
-{\catcode`\|0 |catcode`|\12
-  |long|gdef|schemedisplayI#1\endschemedisplay{%
-    #1|endgroup}%
-  |long|gdef|schemeresponseI#1\endschemeresponse{%
-    #1|endgroup}}%
-\fi
-
-\let\slatexlikecomments\relax
-\let\noslatexlikecomments\relax
-
-% definitions (useful in reference manuals)
-
-\ifx\@@line\UnDeFiNeD
-\let\@@line\line
-\fi
-
-\def\defun#1{\def\defuntype{#1}%
-\medbreak
-\@@line\bgroup
-  \hbox\bgroup
-    \aftergroup\enddefun
-    \vrule width .5ex \thinspace
-    \vrule \enspace
-    \vbox\bgroup\setbox0=\hbox{\defuntype}%
-      \advance\hsize-\wd0
-      \advance\hsize-1em
-      \obeylines
-      \parindent=0pt
-      \aftergroup\egroup
-      \strut
-      \let\dummy=}
-
-\def\enddefun{\hfil\defuntype\egroup\smallskip}
-
-
-% Images
-
-\let\imgdef\def
-
-%\def\imgpreamble{\let\magnificationoutsideimgpreamble\magnification
-%  \def\magnification{\count255=}}
-%
-%\def\endimgpreamble{\let\magnification\magnificationoutsideimgpreamble}
-
-
-\let\imgpreamble\iffalse
-\let\endimgpreamble\fi
-
-\let\makehtmlimage\relax
-
-
-% Tally control sequences are cheap count
-% registers: they doesn't use up TeX's limited number of
-% real count registers.
-
-% A tally is a macro that expands to the
-% number kept track of.  Thus \edef\kount{0} defines a
-% tally \kount that currently contains 0.
-
-% \advancetally\kount n increments \kount by n.
-% \globaladvancetally increments the global \kount.
-% If \kount is not defined, the \[global]advancetally
-% macros define it to be 0 before proceeding with the
-% incrementation.
-
-\def\newtally#1{\edef#1{0}}
-
-\def\advancetallyhelper#1#2#3{%
-  \ifx#2\UNDEFINED
-    #1\edef#2{0}\fi
-  \edef\setcountCCLV{\count255=#2 }%
-  \setcountCCLV
-  \advance\count255 by #3
-  #1\edef#2{\the\count255 }}
-
-\def\advancetally{\advancetallyhelper\relax}
-\def\globaladvancetally{\advancetallyhelper\global}
-
-% plain's \beginsection splits pages too easily
-
-%\def\beginsection#1\par{\sectionhelp{1}{}{#1}}
-
-\def\beginsection{\vskip-\lastskip
-  \bigbreak\noindent
-  \bgroup\bf
-    \let\par\sectionafterskip}
-
-\def\beginsectionstar*{\beginsection}
-
-% plain's \{left,center,right}line can't handle catcode change
-% within their argument
-
-\def\leftline{\@@line\bgroup\bgroup
-  \aftergroup\leftlinefinish
-  \let\dummy=}
-
-\def\leftlinefinish{\hss\egroup}
-
-\def\centerline{\@@line\bgroup\bgroup
-  \aftergroup\leftlinefinish
-  \hss\let\dummy=}
-
-\def\rightline{\@@line\bgroup\hss\let\dummy=}
-
-%
-
-\let\strike\fiverm % can be much better!
-
-%
-
-\let\htmlpagebreak\relax
-
-\let\htmlpagelabel\gobblegroup
-
-\def\htmlpageref{\errmessage{Can't occur except inside
-  \string\htmlonly}}
-
-% Miscellaneous stuff
-
-%\def\hr{$$\hbox{---}$$}
-\def\hr{\medbreak\centerline{---}\medbreak}
-%\def\hr{\par\centerline{$*$}\par}
-%\def\hr{\smallskip\@@line{\leaders\hbox{~.~}\hfill}\smallskip}
-
-%Commonplace math that doesn't require image files.  (Avoiding $
-%here because $ triggers image-file generation.)
-
-\let\nohtmlmathimg\relax
-\let\nohtmlmathintextimg\relax
-\let\nohtmlmathdisplayimg\relax
-
-\let\htmlimageformat\gobblegroup
-\let\htmlimgmagnification\gobblegroup
-
-\let\externaltitle\gobblegroup
-
-\def\mathg{$\bgroup\aftergroup\closemathg\let\dummy=}
-\def\closemathg{$}
-
-\let\mathp\mathg
-
-\def\mathdg{$$\bgroup\aftergroup\closemathdg\let\dummy=}
-\def\closemathdg{$$}
-
-%
-
-
-\let\evalh\gobblegroup
-\let\evalq\gobblegroup
-
-% Backward compatible stuff
-
-\let\endgifpreamble\endimgpreamble
-\let\endhtmlgif\relax
-\let\endhtmlimg\relax
-\let\gifdef\imgdef
-\let\gifpreamble\imgpreamble
-%\let\href\urlh
-\let\htmlgif\relax
-\let\htmlimg\relax
-\let\htmlimgformat\htmlimageformat
-\let\n\noindent
-\let\p\verb
-\let\q\scm
-\let\schemeeval\eval
-\let\scmfile\scmdribble
-\let\scmfileonly\scmwrite
-\let\scmp\scm
-%\let\scmverbatim\scm
-\let\scmverbatimfile\scminput
-\let\setverbatimescapechar\verbescapechar
-%\let\verbatim\verb
-\let\verbatimfile\verbatiminput
-\let\verbinput\verbatiminput
-\let\verbfilename\verbwritefile
-\let\scmfilename\scmwritefile
-
-% uppercase version of \romannumeral
-
-\def\Romannumeral{\afterassignment\RomannumeralI\count255=}
-
-\def\RomannumeralI{\uppercase\expandafter{\romannumeral\the\count255 }}
-
-\def\f{\footnote}
-
-\ifx\label\UnDeFiNeD
-\else 
-\def\tag#1#2{\@bsphack
-  \protected@write\@auxout{}%
-    {\string\newlabel{#1}{{#2}{\thepage}}}%
-\@esphack}%
-\let\tagref\ref
-\fi
-
-\def\inputexternallabels#1 {\relax}
-\def\includeexternallabels#1 {\relax}
-
-% The rest of the file isn't needed for LaTeX
-
-\ifx\section\UnDeFiNeD
-\let\maybeloadfollowing\relax
-\else 
-\catcode`\@\atcatcodebeforetiip
-\let\maybeloadfollowing\endinput
-\fi\maybeloadfollowing
-
-% LaTeX stops loading here!
-
-% Title
-
-\newwrite\sectionscratchfileport
-
-\def\subject{%
-  \immediate\openout\sectionscratchfileport Z-sec-temp
-  \begingroup
-    \def\do##1{\catcode`##1=11 }\dospecials
-    \catcode`\{=1 \catcode`\}=2
-    \subjectI}
-
-\def\subjectI#1{\endgroup
-  \immediate\write\sectionscratchfileport {#1}%
-  \immediate\closeout\sectionscratchfileport
-  $$\vbox{\bf \def\\{\cr}%
-      \halign{\hfil##\hfil\cr
-        \input Z-sec-temp
-        \cr}}$$%
-  \medskip}
-
-\let\title\subject
-
-% Sections
-
-\def\tracksectionchangeatlevel#1{%
-  \expandafter\let\expandafter\thiscount\csname
-    sectionnumber#1\endcsname
-  \ifx\thiscount\relax
-    \expandafter\edef\csname sectionnumber#1\endcsname{0}%
-  \fi
-  \expandafter\advancetally
-    \csname sectionnumber#1\endcsname 1%
-  \ifx\doingappendix0%
-    \edef\recentlabel{\csname sectionnumber1\endcsname}%
-  \else
-    %\count255=\expandafter\csname sectionnumber1\endcsname
-    \edef\recentlabel{\char\csname sectionnumber1\endcsname}%
-  \fi
-  \count255=0
-  \loop
-    \advance\count255 by 1
-    \ifnum\count255=1
-    \else\edef\recentlabel{\recentlabel.\csname
-      sectionnumber\the\count255\endcsname}\fi
-  \ifnum\count255<#1%
-  \repeat
-  \loop
-    \advance\count255 by 1
-    \expandafter\let\expandafter\nextcount\csname
-      sectionnumber\the\count255\endcsname
-    \ifx\nextcount\relax
-      \let\continue0%
-    \else
-      \expandafter\edef\csname
-        sectionnumber\the\count255\endcsname{0}%
-      \let\continue1\fi
-  \ifx\continue1%
-  \repeat}
-
-% Vanilla section-header look -- change this macro for new look
-
-\newcount\secnumdepth
-
-\secnumdepth=10
-
-\def\sectiond#1{\count255=#1%
-  \ifx\usingchapters1\advance\count255 by 1 \fi
-  \edef\sectiondlvl{\the\count255 }%
-  \futurelet\sectionnextchar\sectiondispatch}
-
-\def\sectiondispatch{\ifx\sectionnextchar*%
-  \def\sectioncontinue{\sectionstar{\sectiondlvl}}\else
-  \ifnum\sectiondlvl>\secnumdepth
-  \def\sectioncontinue{\sectionhelp{\sectiondlvl}{}}\else
-  \tracksectionchangeatlevel{\sectiondlvl}
-  \def\sectioncontinue{\sectionhelp{\sectiondlvl}%
-    {\recentlabel\enspace}}\fi\fi
-  \sectioncontinue}
-
-\def\sectionstar#1*{\sectionhelp{#1}{}}
-
-
-\def\sectionhelp#1#2{%
-  \edef\sectiondepth{#1}%
-  \def\sectionnr{#2}%
-  \immediate\openout\sectionscratchfileport Z-sec-temp
-  \begingroup
-  \def\do##1{\catcode`##1=11 }\dospecials
-  \catcode`\{=1 \catcode`\}= 2
-  \sectionheader}
-
-\def\sectionheader#1{\endgroup
-  \immediate\write\sectionscratchfileport {#1}%
-  \immediate\closeout\sectionscratchfileport 
-  \vskip -\lastskip
-  \ifnum\sectiondepth>\tocdepth\else
-  \tocactivate
-  {\let\folio0%
-   \edef\temp{\write\tocout
-     {\string\tocentry{\sectiondepth}{\sectionnr}{#1}{\folio}}}%
-   \temp}\fi
-  \vskip1.5\bigskipamount
-\goodbreak %???
-  \noindent
-  \hbox{\vtop{\pretolerance 10000
-    \raggedright
-    \noindent\bf\sectionnr
-    \input Z-sec-temp }}%
-  \bgroup\let\par\sectionafterskip}
-
-% \edef\temp{\write\tocout{\string\hskip#1\space em\string\relax\space #2%
-%    \string\vtop{\string\hsize=.7\string\hsize
-%    \string\noindent\string\raggedright\space #3}\string\par}}\temp
-
-\def\sectionafterskip{\egroup\nobreak\par\noindent}
-
-\def\section{\sectiond1}
-\def\subsection{\sectiond2}
-\def\subsubsection{\sectiond3}
-\def\paragraph{\sectiond4}
-\def\subparagraph{\sectiond5}
-
-\let\usingchapters0
-
-\def\chapter{\global\let\usingchapters1%
-\futurelet\chapternextchar\chapterdispatch}
-
-\def\chapterdispatch{\ifx\chapternextchar*%
-  \let\chaptercontinue\chapterstar\else
-  \tracksectionchangeatlevel{1}%
-  \def\chaptercontinue{\chapterhelp{\recentlabel\enspace}}\fi
-  \chaptercontinue}
-
-\def\chapterstar*{\chapterhelp{}}
-
-\def\chapterhelp#1{%
-  % #1=number #2=heading-text
-  \def\chapternr{#1}%
-  \immediate\openout\sectionscratchfileport Z-sec-temp
-  \begingroup
-  \def\do##1{\catcode`##1=11 }\dospecials
-  \catcode`\{=1 \catcode`\}=2
-  \chapterheader}
-
-\def\chapterheader#1{\endgroup
-  \immediate\write\sectionscratchfileport {#1}%
-  \immediate\closeout\sectionscratchfileport
-  \tocactivate
-  {\let\folio0%
-   \edef\temp{\write\tocout{\string\tocentry{1}{\chapternr}{#1}{\folio}}}%
-   \temp}%
-  \vfill\eject
-  \null\vskip3em
-  \noindent
-  \ifx\chapternr\empty\hbox{~}\else
-  \ifx\doingappendix0%
-    \hbox{\bf Chapter \chapternr}\else
-  \hbox{\bf Appendix \chapternr}\fi\fi
-  \vskip 1em
-  \noindent
-  \hbox{\bf\vtop{%\hsize=.7\hsize
-    \pretolerance 10000
-    \noindent\raggedright\input Z-sec-temp }}%
-  \bgroup\let\par\chapterafterskip}
-
-\def\chapterafterskip{\egroup\nobreak\vskip3em \noindent}
-
-\let\doingappendix=0
-
-\def\appendix{\let\doingappendix=1%
-  \count255=`\A%
-  \advance\count255 by -1
-  \expandafter\edef\csname
-    sectionnumber1\endcsname{\the\count255 }}
-
-
-% toc
-
-\let\tocactive0
-
-\newcount\tocdepth
-
-\tocdepth=10
-
-\def\tocoutensure{\ifx\tocout\UNDEFINED
-  \csname newwrite\endcsname\tocout\fi}
-
-\def\tocactivate{\ifx\tocactive0%
-  \tocoutensure
-  \tocsave
-  \openout\tocout \jobname.toc
-  \global\let\tocactive1\fi}
-
-\def\tocspecials{\def\do##1{\catcode`##1=12 }\dospecials}
-
-\def\tocsave{\openin0=\jobname.toc
-  \ifeof0 \closein0 \else
-    \openout\tocout Z-T-\jobname.tex
-    \let\tocsaved 0%
-    \loop
-      \ifeof0 \closeout\tocout
-        \let\tocsaved1%
-      \else{\tocspecials
-         \read0 to \tocsaveline
-         \edef\temp{\write\tocout{\tocsaveline}}\temp}%
-      \fi
-    \ifx\tocsaved0%
-    \repeat
-  \fi
-  \closein0 }
-
-\def\tocentry#1#2{%
-  %#1=depth #2=secnum
-  \ifnum#1=1
-    \ifnum\tocdepth>2
-    \medbreak\begingroup\bf
-    \else\begingroup\fi
-  \else\begingroup\fi
-  \vtop\bgroup\raggedright
-  \noindent\hskip #1 em
-  #2%
-  \bgroup
-  \aftergroup\tocentryI
-  %read section title
-  \let\dummy=}
-
-\def\tocentryI#1{%
-  %#1=page nr
-  , #1\strut\egroup
-  \endgroup\par
-}
-
-\def\tableofcontents{%
-  \ifx\tocactive0%
-    \openin0 \jobname.toc
-    \ifeof0 \closein0 \else
-      \closein0 \input \jobname.toc
-    \fi
-    \tocoutensure
-    \openout\tocout \jobname.toc
-    \global\let\tocactive1%
-  \else
-    \input Z-T-\jobname.tex
-  \fi}
-
-% allow {thebibliography} to be used directly
-% in (plain-TeX) source document without 
-% generating it via BibTeX
-
-\ifx\thebibliography\UnDeFiNeD
-\def\thebibliography#1{\vskip-\lastskip
-  \begingroup
-  \def\endthebibliography{\endgroup\endgroup}%
-  \def\input##1 ##2{\relax}%
-  \setbox0=\hbox{\biblabelcontents{#1}}%
-  \biblabelwidth=\wd0
-  \@readbblfile}%
-\fi
-
-% Cross-references
-
-% \openxrefout loads all the TAG-VALUE associations in
-% \jobname.xrf and then opens \jobname.xrf as an
-% output channel that \tag can use
-
-\def\openxrefout{%
-  \openin0=\jobname.xrf
-  \ifeof0 \closein0 
-  \else \closein0 {\catcode`\\0 \input \jobname.xrf }%
-  \fi
-  \expandafter\csname newwrite\endcsname\xrefout
-  \openout\xrefout=\jobname.xrf
-}
-
-% I'd like to call \openxrefout lazily, but
-% unfortunately it produces a bug in MiKTeX.
-% So let's call it up front.
-
-\openxrefout
-
-% \tag{TAG}{VALUE} associates TAG with VALUE.
-% Hereafter, \ref{TAG} will output VALUE.
-% \tag stores its associations in \xrefout.
-% \tag calls \openxrefout if \jobname.xrf hasn't
-% already been opened
-
-\def\tag#1#2{\ifx\xrefout\UNDEFINED\openxrefout\fi
-  {\let\folio0%
-    \edef\temp{%
-     \write\xrefout{\string\expandafter\string\gdef
-        \string\csname\space XREF#1\string\endcsname
-        {#2}\string\relax}}%
-    \temp}}
-
-% \tagref{TAG} outputs VALUE, assuming \tag put such
-% an association into \xrefout.  \tagref calls
-% \openxrefout if \jobname.xrf hasn't already
-% been opened
-
-% Later, we will \let \ref = \tagref after making
-% sure we aren't in eplain, which uses the ctlseq
-% \ref differently
-
-\def\tagref#1{\ifx\xrefout\UNDEFINED\openxrefout\fi
-  \expandafter\ifx\csname XREF#1\endcsname\relax
-  %\message or \write16 ?
-  \message{\the\inputlineno: Unresolved label `#1'.}?\else
-  \csname XREF#1\endcsname\fi}
-
-% \label, as in LaTeX
-
-\let\recentlabel\relax
-
-% The sectioning commands
-% define \recentlabel so a subsequent call to \label will pick up the
-% right label.
-
-\def\label#1{\tag{#1}{\recentlabel}%
-  \tag{PAGE#1}{\folio}}
-
-% \pageref, as in LaTeX
-
-\def\pageref#1{\ref{PAGE#1}}
-
-% eplain users see the \ref they are used to.  Others
-% have \ref = \tagref
-
-\ifx\eplain\UnDeFiNeD
-\let\ref\tagref
-\fi
-
-%
-
-\ifx\IfFileExists\UnDeFiNeD
-\def\IfFileExists#1#2#3{%
-  \openin0 #1 %
-  \ifeof0 %
-    #3%
-  \else 
-    #2\fi
-  \closein0 }%
-\fi
-
-\ifx\InputIfFileExists\UnDeFiNeD
-\def\InputIfFileExists#1#2#3{%
-  \IfFileExists{#1}{#2\input #1 }{#3}}%
-\fi
-
-\let\iffileexists\IfFileExists
-
-%
-
-% dummy def to let load dvipsnam.def 
-
-\ifx\ProvidesFile\UnDeFiNeD
-\def\ProvidesFile#1[#2]{}%
-\fi
-
-%
-
-% Index generation
-%
-% Your TeX source contains \index{NAME} to
-% signal that NAME should be included in the index.
-% Check the makeindex documentation to see the various
-% ways NAME can be specified, eg, for subitems, for
-% explicitly specifying the alphabetization for a name
-% involving TeX control sequences, etc.
-%
-% The first run of TeX will create \jobname.idx.
-% makeindex on \jobname[.idx] will create the sorted
-% index \jobname.ind.
-%
-% Use \inputindex (without arguments) to include this
-% sorted index, typically somewhere to the end of your
-% document.  This will produce the items and subitems.
-% It won't produce a section heading however -- you
-% will have to typeset one yourself.
-%
-% Use \printindex instead of \inputindex if you want
-% the section heading ``Index'' automatically generated.
-
-\def\sanitizeidxletters{\def\do##1{\catcode`##1=11 }%
-  \do\\\do\$\do\&\do\#\do\^\do\_\do\%\do\~%
-  \do\@\do\"\do\!\do\|\do\-\do\ \do\'}
-
-\def\index{%\unskip
-  \ifx\indexout\UNDEFINED
-    \csname newwrite\endcsname\indexout
-    \openout\indexout \jobname.idx\fi
-  \begingroup
-    \sanitizeidxletters
-    \indexI}
-
-\def\indexI#1{\endgroup
-  \write\indexout{\string\indexentry{#1}{\folio}}%
-  \ignorespaces}
-
-% The following index style indents subitems on a
-% separate lines
-
-\def\theindex{\begingroup
-  \parskip0pt \parindent0pt
-  \def\indexitem##1{\par\hangindent30pt \hangafter1
-    \hskip ##1 }%
-  \def\item{\indexitem{0em}}%
-  \def\subitem{\indexitem{2em}}%
-  \def\subsubitem{\indexitem{4em}}%
-  \def\see{{\it see} \bgroup\aftergroup\gobblegroup\let\dummy=}%
-  \let\indexspace\medskip}
-
-\def\endtheindex{\endgroup}
-
-% \packindex declares that subitems be bundled into one
-% semicolon-separated paragraph
-
-\def\packindex{%
-  \def\theindex{\begingroup
-    \parskip0pt \parindent0pt
-    \def\item{\par\hangindent20pt \hangafter1 }%
-    \def\subitem{\unskip; }%
-    \def\subsubitem{\unskip; }%
-    \def\see{\bgroup\it see \aftergroup\gobblegroup\let\dummy=}%
-    \let\indexspace\medskip}}
-
-\def\inputindex{%
-  \openin0 \jobname.ind
-  \ifeof0 \closein0
-    \message{\jobname.ind missing.}%
-  \else\closein0
-    \begingroup
-      \def\begin##1{\csname##1\endcsname}%
-      \def\end##1{\csname end##1\endcsname}%
-      \input\jobname.ind
-    \endgroup\fi}
-
-\def\printindex{\csname beginsection\endcsname Index\par
-  \inputindex}
-
-%
-
-\def\italiccorrection{\futurelet\italiccorrectionI
-  \italiccorrectionII}
-
-\def\italiccorrectionII{%
-  \if\noexpand\italiccorrectionI,\else
-  \if\noexpand\italiccorrectionI.\else
-  \/\fi\fi}
-
-\def\em{\it\ifmmode\else\aftergroup\italiccorrection\fi}
-
-%\def\emph{\bgroup\it
-%  \ifmmode\else\aftergroup\italiccorrection\fi
-%  \let\dummy=}
-
-\def\quote{\bgroup\narrower\smallbreak}
-\def\endquote{\smallbreak\egroup}
-
-\def\begin#1{\begingroup
-  \def\end##1{\csname end#1\endcsname\endgroup}%
-  \csname #1\endcsname}
-
-\def\raggedleft{%
-  \leftskip 0pt plus 1fil
-  \parfillskip 0pt
-}
-
-\def\r#1{{\accent23 #1}}
-
-
-\ifx\strip@pt\UNDEFINED
-\begingroup
-  \catcode`P 12 \catcode`T 12
-  \lowercase{\endgroup
-    \gdef\strip@pt#1PT{#1}}%
-\fi
-
-% color
-
-\ifx\color\UnDeFiNeD 
-%
-\ifx\pdfoutput\UnDeFiNeD % PostScript
-%
-\def\colorCurrentColor{color cmyk 0 0 0 1}%
-%
-\def\colorRestoreCurrentColor{%
-\special{\colorCurrentColor}\egroup\egroup}%
-%
-\def\colorWithModelrgb#1{\bgroup
-\def\colorCurrentColor{color rgb #1}%
-\special{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor}%
-%
-\def\colorWithModelRGBaux#1 #2 #3\end{\bgroup
-\dimen0=#1pt \divide\dimen0 by 255
-\edef\red{\expandafter\strip@pt\the\dimen0 }%
-\dimen0=#2pt \divide\dimen0 by 255
-\edef\green{\expandafter\strip@pt\the\dimen0 }%
-\dimen0=#3pt \divide\dimen0 by 255
-\edef\blue{\expandafter\strip@pt\the\dimen0 }%
-\def\colorCurrentColor{color rgb \red\space \green\space \blue}%
-\special{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor
-\ignorespaces}
-%
-\def\colorWithModelcmyk#1{\bgroup
-\def\colorCurrentColor{color cmyk #1}%
-\special{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor}%
-%
-\def\colorWithModelgray#1{\bgroup
-\def\colorCurrentColor{color gray #1}%
-\special{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor}%
-%
-\def\colorWithModelnamed#1{\bgroup
-\edef\colorCurrentColor{\csname
-ColorNamed#1\endcsname}%
-\special{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor}%
-%
-\def\definecolorWithModelrgb#1#2{\egroup
-\expandafter\def\csname ColorNamed#1\endcsname
-{color rgb #2}}%
-%
-\def\definecolorWithModelcmyk#1#2{\egroup
-\expandafter\def\csname ColorNamed#1\endcsname
-{color cmyk #2}}%
-%
-\def\definecolorWithModelgray#1#2{\egroup
-\expandafter\def\csname ColorNamed#1\endcsname
-{color gray #2}}%
-%
-\else % PDF
-%
-\def\colorCurrentColor{0 0 0 1 k}%
-%
-\def\colorRestoreCurrentColor{%
-\pdfliteral{\colorCurrentColor}\egroup\egroup}%
-%
-\def\colorWithModelrgb#1{\bgroup
-\def\colorCurrentColor{#1 rg}%
-\pdfliteral{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor
-\ignorespaces}%
-%
-\def\colorWithModelRGBaux#1 #2 #3\end{\bgroup
-\dimen0=#1pt \divide\dimen0 by 255
-\edef\red{\expandafter\strip@pt\the\dimen0 }%
-\dimen0=#2pt \divide\dimen0 by 255
-\edef\green{\expandafter\strip@pt\the\dimen0 }%
-\dimen0=#3pt \divide\dimen0 by 255
-\edef\blue{\expandafter\strip@pt\the\dimen0 }%
-\def\colorCurrentColor{\red\space \green\space \blue\space rg}%
-\pdfliteral{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor
-\ignorespaces}
-%
-\def\colorWithModelcmyk#1{\bgroup
-\def\colorCurrentColor{#1 k}%
-\pdfliteral{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor
-\ignorespaces}%
-%
-\def\colorWithModelgray#1{\bgroup
-\def\colorCurrentColor{#1 g}%
-\pdfliteral{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor
-\ignorespaces}%
-%
-\def\colorWithModelnamed#1{\bgroup
-\edef\colorCurrentColor{\csname
-ColorNamed#1\endcsname}%
-\pdfliteral{\colorCurrentColor}%
-\aftergroup\colorRestoreCurrentColor
-\ignorespaces}%
-%
-\def\definecolorWithModelrgb#1#2{\egroup
-\expandafter\def\csname ColorNamed#1\endcsname
-{#2 rg}}%
-%
-\def\definecolorWithModelcmyk#1#2{\egroup
-\expandafter\def\csname ColorNamed#1\endcsname
-{#2 k}}%
-%
-\def\definecolorWithModelgray#1#2{\egroup
-\expandafter\def\csname ColorNamed#1\endcsname
-{#2 g}}%
-%
-\fi
-%
-\def\color{\futurelet\colorQpeekchar\colorQpossiblynamed}%
-%
-\def\colorQpossiblynamed{\bgroup
-\defcsactive\,{ }%
-\if\colorQpeekchar[%
-\let\colorQproceed\colorQexplicitmodel\else
-\let\colorQproceed\colorWithModelnamed\fi
-\colorQproceed}%
-%
-\def\colorQexplicitmodel[#1]{%
-\csname colorWithModel#1\endcsname}%
-%
-\def\colorWithModelRGB#1{%
-\colorWithModelRGBaux#1\end}%
-%
-\def\definecolor#1#2{\bgroup
-\defcsactive\,{ }%
-\csname definecolorWithModel#2\endcsname{#1}}%
-%
-% foll lets load texmf/tex/latex/graphics/dvipsnam.def
-\def\DefineNamedColor#1{\definecolor}%
-%
-% these colors are standard in latex
-\definecolor{red}{rgb}{1 0 0}%
-\definecolor{green}{rgb}{0 1 0}%
-\definecolor{blue}{rgb}{0 1 1}%
-\definecolor{cyan}{cmyk}{1 0 0 0}%
-\definecolor{magenta}{cmyk}{0 1 0 0}%
-\definecolor{yellow}{cmyk}{0 0 1 0}%
-\definecolor{black}{cmyk}{0 0 0 1}%
-\definecolor{white}{rgb}{1 1 1}%
-%
-\fi
-
-%the rest of the file isn't needed for eplain?
-
-\def\itemize{\par\begingroup
-  \advance\leftskip\parindent
-  \smallbreak
-  \def\item{\smallbreak\noindent
-  \llap{$\bullet$\enspace}\ignorespaces}}
-
-\def\enditemize{\smallbreak\smallbreak\endgroup\par}
-
-\newtally\enumeratelevel
-
-\def\enumerate{\par\begingroup
-  \advancetally\enumeratelevel1%
-  \newtally\enumeratenumber
-  \advance\leftskip\parindent
-  \smallbreak
-  \def\item{\smallbreak\noindent
-    \advancetally\enumeratenumber1%
-    \ifnum\enumeratelevel=1 
-      \edef\enumeratemark{\enumeratenumber}\else
-    \ifnum\enumeratelevel=2 
-      \count255=\enumeratenumber 
-      \advance\count255 by -1 \advance\count255 by `a
-      \edef\enumeratemark{\noexpand\char\the\count255 }\else
-    \ifnum\enumeratelevel=3 
-      \edef\enumeratemark{\romannumeral\enumeratenumber}\else
-    \ifnum\enumeratelevel=4
-      \count255=\enumeratenumber 
-      \advance\count255 by -1 \advance\count255 by `A
-      \edef\enumeratemark{\noexpand\char\the\count255 }\else
-    \edef\enumeratemark{\enumeratenumber}\fi\fi\fi\fi
-    \edef\recentlabel{\enumeratemark}% needed?
-    \llap{\enumeratemark.\enspace}\ignorespaces}}
-
-\def\endenumerate{\smallbreak\smallbreak\endgroup\par}
-
-% Numbered footnotes
-
-\ifx\plainfootnote\UNDEFINED
-  \let\plainfootnote\footnote
-\fi
-
-\newtally\footnotenumber
-
-\def\numfootnote{\globaladvancetally\footnotenumber 1%
-  \bgroup\csname footnotehook\endcsname
-    \plainfootnote{$^{\footnotenumber}$}\bgroup
-      \edef\recentlabel{\footnotenumber}%
-      \aftergroup\egroup
-      \let\dummy=}
-
-\let\f\numfootnote
-
-\ifx\frac\UnDeFiNeD
-\def\frac#1/#2{{#1\over#2}}%
-\fi
-
-% \path is like \verb except that its argument
-% can break across lines at `.' and `/'.
-
-\ifx\path\UnDeFiNeD
-\def\path{\begingroup\verbsetup
-  \pathfont
-  \defcsactive\.{\discretionary{\char`\.}{}{\char`\.}}%
-  \defcsactive\/{\discretionary{\char`\/}{}{\char`\/}}%
-  \verbI}%
-\fi
-
-\let\pathfont\relax
-
-\catcode`\@\atcatcodebeforetiip
-
-\endtexonly
-
-% end of file
diff --git a/plugins.cabal b/plugins.cabal
--- a/plugins.cabal
+++ b/plugins.cabal
@@ -1,6 +1,6 @@
 name:               plugins
-version:            1.5.1.4
-homepage:           http://code.haskell.org/~dons/code/hs-plugins
+version:            1.5.2.1
+homepage:           http://patch-tag.com/r/stepcut/plugins
 synopsis:           Dynamic linking for Haskell and C objects
 description:        Dynamic linking and runtime evaluation of Haskell,
                     and C, including dependency chasing and package resolution.
@@ -17,7 +17,7 @@
 license:            BSD3
 License-file:       LICENSE
 author:             Don Stewart 2004..2010
-maintainer:         Don Stewart <dons@galois.com>
+maintainer:         Jeremy Shaw <jeremy@seereason.com>
 cabal-version:      >= 1.6
 build-type:         Configure
 Tested-with:        GHC >= 6.12.1
@@ -57,3 +57,5 @@
                           ghc >= 6.10,
                           ghc-prim
 
+    if impl(ghc >= 7.2)
+        build-depends:    ghc-paths
diff --git a/scripts/Setup-with-ghc.lhs b/scripts/Setup-with-ghc.lhs
deleted file mode 100644
--- a/scripts/Setup-with-ghc.lhs
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/usr/bin/env runhaskell
-> module Main where
-> import Distribution.Simple
-> import Distribution.Setup   ( ConfigFlags (..) )
-> import System.Directory     ( findExecutable )
-> 
-> main :: IO ()
-> main = defaultMainWithHooks (defaultUserHooks { postConf = defaultPostConf })
->     where defaultPostConf args flags lbi {- xx -}
->               = do args' <- fmap (args++) (configToArgs flags)
->                    (postConf defaultUserHooks) args' flags lbi {- xx -}
-> 
-> -- need to pass with-ghc arg onto ./configure for non-standard ghcs
-> configToArgs :: ConfigFlags -> IO [String]
-> configToArgs (ConfigFlags { configHcPath = Just hcPath })
->     = do exec <- findExecutable hcPath
->          case exec of
->            Just realPath -> return ["--with-ghc="++realPath]
->            Nothing -> return ["--with-ghc="++hcPath]
-> configToArgs _ = return []
diff --git a/scripts/mkrelease.sh b/scripts/mkrelease.sh
deleted file mode 100644
--- a/scripts/mkrelease.sh
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-cd /tmp
-rm -rf hs-plugins-0.9.10*
-
-darcs get --partial --set-scripts-executable /home/dons/hs-plugins
-cd hs-plugins
-rm -rf _darcs
-cd ..
-mv hs-plugins hs-plugins-0.9.10
-tar czf hs-plugins-0.9.10.tar.gz hs-plugins-0.9.10
diff --git a/scripts/openbsd-port/Makefile b/scripts/openbsd-port/Makefile
deleted file mode 100644
--- a/scripts/openbsd-port/Makefile
+++ /dev/null
@@ -1,21 +0,0 @@
-# $OpenBSD$
-
-COMMENT=		"dynamic link library for Haskell"
-
-V=			0.9.10
-DISTNAME=		hs-plugins-${V}
-CATEGORIES=		devel
-MAINTAINER=		Don Stewart <dons@openbsd.org>
-HOMEPAGE= 		http://www.cse.unsw.edu.au/~dons/hs-plugins/
-MASTER_SITES=		${HOMEPAGE}
-
-MODULES=		ghc
-CONFIGURE_STYLE=	gnu dest
-
-# LGPL
-PERMIT_PACKAGE_CDROM=	Yes
-PERMIT_PACKAGE_FTP=	Yes
-PERMIT_DISTFILES_CDROM=	Yes
-PERMIT_DISTFILES_FTP=	Yes
-
-.include <bsd.port.mk>
diff --git a/scripts/openbsd-port/distinfo b/scripts/openbsd-port/distinfo
deleted file mode 100644
--- a/scripts/openbsd-port/distinfo
+++ /dev/null
@@ -1,3 +0,0 @@
-MD5 (hs-plugins-0.9.4.tar.gz) = 120f38ca532b187ee52798f5c36cc920
-RMD160 (hs-plugins-0.9.4.tar.gz) = 219eaf70e4bc0f1abc8a782d1bbd64ad2c5f8e86
-SHA1 (hs-plugins-0.9.4.tar.gz) = ad38b9f4e5b90c1361c6c96bd94e2a9270ad3d78
diff --git a/scripts/openbsd-port/pkg/DESCR b/scripts/openbsd-port/pkg/DESCR
deleted file mode 100644
--- a/scripts/openbsd-port/pkg/DESCR
+++ /dev/null
@@ -1,6 +0,0 @@
-hs-plugins is a library for dynamic loading and compilation of Haskell
-code. It provides typesafe "plugins" for Haskell.  The interface is
-general enough that it can be used to create conventional plugins,
-hmake-like Haskell interpreters embedded in applications, or to script
-an application with Haskell (or a Haskell EDSL) as the extension
-language.
diff --git a/scripts/openbsd-port/pkg/PLIST b/scripts/openbsd-port/pkg/PLIST
deleted file mode 100644
--- a/scripts/openbsd-port/pkg/PLIST
+++ /dev/null
@@ -1,28 +0,0 @@
-@comment $OpenBSD$
-lib/hs-plugins/imports/Plugins.hi
-lib/hs-plugins/imports/Plugins/BinIface.hi
-lib/hs-plugins/imports/Plugins/Binary.hi
-lib/hs-plugins/imports/Plugins/Consts.hi
-lib/hs-plugins/imports/Plugins/Env.hi
-lib/hs-plugins/imports/Plugins/FastMutInt.hi
-lib/hs-plugins/imports/Plugins/FastString.hi
-lib/hs-plugins/imports/Plugins/Iface.hi
-lib/hs-plugins/imports/Plugins/Load.hi
-lib/hs-plugins/imports/Plugins/Make.hi
-lib/hs-plugins/imports/Plugins/Package.hi
-lib/hs-plugins/imports/Plugins/ParsePkgConfLite.hi
-lib/hs-plugins/imports/Plugins/Parser.hi
-lib/hs-plugins/imports/Plugins/PrimPacked.hi
-lib/hs-plugins/imports/Plugins/Utils.hi
-lib/hs-plugins/include/hschooks.h
-lib/hs-plugins/libHSplugins.a
-lib/hs-plugins/libHSplugins_cbits.a
-lib/hs-plugins/plugins.conf.in
-@dirrm lib/hs-plugins/include
-@dirrm lib/hs-plugins/imports/Plugins
-@dirrm lib/hs-plugins/imports
-@dirrm lib/hs-plugins
-@exec /bin/cat %D/lib/hs-plugins/plugins.conf.in | /usr/bin/env PREFIX=%D %D/bin/ghc-pkg -u
-@exec /bin/rm -f %D/lib/ghc-6.2.1/package.conf.old
-@unexec %D/bin/ghc-pkg -r plugins
-@unexec /bin/rm -f %D/lib/ghc-6.2.1/package.conf.old
diff --git a/src/System/Plugins/Load.hs b/src/System/Plugins/Load.hs
--- a/src/System/Plugins/Load.hs
+++ b/src/System/Plugins/Load.hs
@@ -84,9 +84,20 @@
 import System.Directory         ( doesFileExist, removeFile )
 import Foreign.C.String         ( CString, withCString, peekCString )
 
+#if !MIN_VERSION_ghc(7,2,0)
 import GHC                      ( defaultCallbacks )
+#else
+import DynFlags                 (defaultDynFlags, initDynFlags)
+import GHC.Paths                (libdir)
+import SysTools                 (initSysTools)
+#endif
 import GHC.Ptr                  ( Ptr(..), nullPtr )
+#if !MIN_VERSION_ghc(7,4,1)
 import GHC.Exts                 ( addrToHValue# )
+#else
+import GHC.Exts                 ( addrToAny# )
+#endif
+
 import GHC.Prim                 ( unsafeCoerce# )
 
 #if DEBUG
@@ -99,7 +110,13 @@
 readBinIface' :: FilePath -> IO ModIface
 readBinIface' hi_path = do
     -- kludgy as hell
+#if MIN_VERSION_ghc(7,2,0)
+    mySettings <- initSysTools (Just libdir) -- how should we really set the top dir?
+    dflags <- initDynFlags (defaultDynFlags mySettings)
+    e <- newHscEnv dflags
+#else
     e <- newHscEnv defaultCallbacks undefined
+#endif
     initTcRnIf 'r' e undefined undefined (readBinIface IgnoreHiWay QuietBinIFaceReading hi_path)
 
 -- TODO need a loadPackage p package.conf :: IO () primitive
@@ -445,7 +462,11 @@
         ptr@(Ptr addr) <- withCString symbol c_lookupSymbol
         if (ptr == nullPtr)
             then return Nothing
+#if !MIN_VERSION_ghc(7,4,1)
             else case addrToHValue# addr of
+#else
+            else case addrToAny# addr of
+#endif
                 (# hval #) -> return ( Just hval )
 
 
@@ -679,7 +700,11 @@
 
                 -- and find some packages to load, as well.
                 let ps = dep_pkgs ds
+#if MIN_VERSION_ghc(7,2,0)
+                ps' <- filterM loaded . map packageIdString . nub $ map fst ps
+#else
                 ps' <- filterM loaded . map packageIdString . nub $ ps
+#endif
 
 #if DEBUG
                 when (not (null ps')) $
diff --git a/src/System/Plugins/Utils.hs b/src/System/Plugins/Utils.hs
--- a/src/System/Plugins/Utils.hs
+++ b/src/System/Plugins/Utils.hs
@@ -1,4 +1,4 @@
-{-# LANGUAGE CPP #-}
+{-# LANGUAGE CPP, ScopedTypeVariables #-}
 -- 
 -- Copyright (C) 2004 Don Stewart - http://www.cse.unsw.edu.au/~dons
 -- 
@@ -63,8 +63,10 @@
 import System.Plugins.Consts           ( objSuf, hiSuf, tmpDir )
 -- import qualified System.MkTemp ( mkstemps )
 
+import Control.Exception               (IOException, catch)
 import Data.Char
 import Data.List
+import Prelude hiding                  (catch)
 
 import System.IO
 import System.Environment           ( getEnv )
@@ -119,7 +121,7 @@
 -- bit like the mktemp shell utility
 --
 mkTemp :: IO (String,Handle)
-mkTemp = do tmpd  <- catch (getEnv "TMPDIR") (\_ -> return tmpDir)
+mkTemp = do tmpd  <- catch (getEnv "TMPDIR") (\ (_ :: IOException) -> return tmpDir)
             mkTempIn tmpd
 
 mkTempIn :: String -> IO (String, Handle)
diff --git a/testsuite/README b/testsuite/README
deleted file mode 100644
--- a/testsuite/README
+++ /dev/null
@@ -1,17 +0,0 @@
-These examples illustrate the various uses of hs-plugins.
-
-conf		a configuration file edsl using plugins
-dynload		dynamically typed load
-eval		runtime evaluation of haskell strings, from Haskell and C
-hmake		the 'plugs' haskell interpreter
-iface		test the interface file parser
-load		load a plugin
-make		build a Haskell file
-makewith	merge and build a Haskell file
-multi		load multiple plugins at once
-objc		load Haskell plugins into object C programs
-pkgconf		test package.conf parsing
-popen		test popen
-reload		reload a plugin when it changes
-shell		a simple string filter
-unload		test unloading of plugins
diff --git a/testsuite/TIMINGS b/testsuite/TIMINGS
deleted file mode 100644
--- a/testsuite/TIMINGS
+++ /dev/null
@@ -1,45 +0,0 @@
-Method:
-	* "pdynload" 
-		comes from pdynload/small
-	* "load + ghc" 
-		comes from pdynload/null, with lines 13-14
-		uncommented from prog/Main.hs
-	* "dynload" 
-		from dynload/simple
-	* "load, no check"
-		from pdynload/null, with lines 13-14 of prog/Main.hs
-		commented out
-
-For example, to run the "pdynload" test:
-	$ cd pdynload/small
-	$ make
-	$ make check	  # to prime caches, etc.
-	$ time make check
-	$ time make check
-	$ time make check # run 'time make check' until value converges
-
-The converged value is entered into the "Raw" timings, and then the
-scaled timing is calculated for each machine. These scaled values were
-then averaged over the number of machines, yielding the final
-"Average" scores -- the average over a number of machines and os.
-
-Raw timing:
-pdynload 	load+ghc	dynload		load, no check
-
-0.33		0.25		0.22		0.21	-- P4 2.6 ,  OpenBSD
-0.38		0.31		0.29		0.27	-- P4 2.66,  Linux
-0.84		0.77		0.64		0.55	-- Quad P4 2.4, Linux
-0.76		0.60		0.52		0.50	-- AMD 1.1G, Linux
-0.95            0.83            0.75            0.72    -- G5 2.0G,  Mac OS X
-							-- Quad Itanium 1,Linux
-
-Scaled:
-1.57		1.19		1.05		1
-1.40		1.15		1.07
-1.52		1.4		1.16
-1.52		1.2		1.04
-1.32            1.15            1.04
-
-Average:
-=1.46         =	1.218	      = 1.07
-					
diff --git a/testsuite/build.mk b/testsuite/build.mk
deleted file mode 100644
--- a/testsuite/build.mk
+++ /dev/null
@@ -1,40 +0,0 @@
-# how to build the default projects
-
-include $(TOP)/config.mk
-include $(TOP)/testsuite/check.mk
-
-BIN= 		prog/Main
-OBJ=		prog/Main.o
-SRC=		prog/Main.hs
-
-BINDIR=		prog
-REALBIN=	./Main
-
-API_OBJ=	api/API.o
-
-INCLUDES=   	-i$(TOP)/testsuite/$(TEST)/api
-GHCFLAGS=   	-O0 -cpp -fglasgow-exts
-
-.SUFFIXES : .o .hs .hi .lhs .hc .s
-
-all: $(BIN)
-
-$(BIN) : $(PRIOR_OBJS) $(API_OBJ) $(SRC) $(EXTRA_OBJS)
-	@rm -f $@
-	@$(GHC) --make -o $@ $(INCLUDES) $(PKGFLAGS) $(GHCFLAGS) $(EXTRAFLAGS) $(API) $(SRC)
-
-# Standard suffix rules
-.o.hi:
-	@:
-.hs.o:
-	@$(GHC) $(INCLUDES) $(PKGFLAGS) $(GHCFLAGS) $(EXTRAFLAGS) -c $<
-
-clean:
-	find . -name '*~' -exec rm {} \;
-	rm -rf *.{o,hi,dep}
-	rm -rf */*.{hi,o,old} */Main
-	rm -rf */*core
-	rm -rf */*.a
-	rm -rf */package.conf
-	rm -rf *.a
-
diff --git a/testsuite/check.mk b/testsuite/check.mk
deleted file mode 100644
--- a/testsuite/check.mk
+++ /dev/null
@@ -1,24 +0,0 @@
-include $(TOP)/config.mk
-
-check: $(BIN)
-	@(cd $(BINDIR) ;\
-	  expected="expected" ;\
-          if [ -f "expected" -o -f "expected.$(GLASGOW_HASKELL)" ] ;\
-	  then \
-		actual_out="/tmp/hs-plugins-actual.out.$$$$"	   ;\
-		diff_out="/tmp/hs-plugins.diff.$$$$"		   ;\
-		$(REALBIN) > $$actual_out  2>&1         || true ;\
-		if [ -f "expected.$(GLASGOW_HASKELL)" ] ; then \
-			expected="expected.$(GLASGOW_HASKELL)" ;\
-		fi ;\
-		diff -u $$expected $$actual_out > $$diff_out || true ;\
-		if [ -s "$$diff_out" ] ; then \
-			echo "failed with:"	;\
-			cat "$$diff_out" | sed '1,3d' ;\
-		else \
-			echo "ok." 	;\
-		fi ;\
-		rm $$actual_out $$diff_out	;\
-	 else \
-		$(REALBIN) 2>&1 || true ;\
-	 fi)
diff --git a/testsuite/conf/simple/Mailrc.conf b/testsuite/conf/simple/Mailrc.conf
deleted file mode 100644
--- a/testsuite/conf/simple/Mailrc.conf
+++ /dev/null
@@ -1,11 +0,0 @@
-import System.Directory
-
-resource = mail { 
---	editor = do b <- doesFileExist "/usr/bin/emacs"
---		    return $ if b then "emacs" else "vi" ,
-	editor = do b <- doesFileExist "/bin/sh"
-  		    return "sh",
-
-	attribution = \name -> "Today, "++name++" wrote :"
-}
-
diff --git a/testsuite/conf/simple/Mailrc.stub b/testsuite/conf/simple/Mailrc.stub
deleted file mode 100644
--- a/testsuite/conf/simple/Mailrc.stub
+++ /dev/null
@@ -1,28 +0,0 @@
-module Mailrc ( resource )  where
-
-import API
-
-resource :: Interface
-resource = mail
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/testsuite/conf/simple/Makefile b/testsuite/conf/simple/Makefile
deleted file mode 100644
--- a/testsuite/conf/simple/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=	conf/simple
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/conf/simple/api/API.hs b/testsuite/conf/simple/api/API.hs
deleted file mode 100644
--- a/testsuite/conf/simple/api/API.hs
+++ /dev/null
@@ -1,27 +0,0 @@
---
--- the configuration file interface.
---
-
-module API where
-
-data Color = Black | Grey | Green | Cyan | Yellow | Magenta | Red
-
-data Interface = Interface {
-        editor          :: IO String,
-        attribution     :: String -> String,
-        header_color    :: Color,
-        colorize        :: [String],
-        include         :: Bool
-     }
-
--- Default settings
-mail :: Interface
-mail = Interface { 
-        editor = return "vi",
-
-        attribution = (\user -> user ++ " wrote:"),
-        header_color = Grey,
-        colorize = [],
-        include = True
-     }
-
diff --git a/testsuite/conf/simple/prog/Main.hs b/testsuite/conf/simple/prog/Main.hs
deleted file mode 100644
--- a/testsuite/conf/simple/prog/Main.hs
+++ /dev/null
@@ -1,22 +0,0 @@
-
-import System.Plugins
-import API
-
-conf    = "../Mailrc.conf"
-stub    = "../Mailrc.stub"
-apipath = "../api"
-
-main = do
-        status <- makeWith conf stub ["-i"++apipath]
-        o <- case status of
-                MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess _ o -> return o
-        status <- load o [apipath] [] "resource"
-        v <- case status of
-                LoadFailure err   -> mapM_ putStrLn err >> error "no"
-                LoadSuccess _ v -> return v
-        
-        user_editor <- editor v
-        putStrLn user_editor
-        makeCleaner o
-
diff --git a/testsuite/conf/simple/prog/expected b/testsuite/conf/simple/prog/expected
deleted file mode 100644
--- a/testsuite/conf/simple/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-sh
diff --git a/testsuite/dynload/io/Makefile b/testsuite/dynload/io/Makefile
deleted file mode 100644
--- a/testsuite/dynload/io/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-TEST=dynload/io
-
-EXTRA_OBJS=TestIO.o
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/dynload/io/TestIO.hs b/testsuite/dynload/io/TestIO.hs
deleted file mode 100644
--- a/testsuite/dynload/io/TestIO.hs
+++ /dev/null
@@ -1,86 +0,0 @@
-{-# OPTIONS -fglasgow-exts -cpp #-}
---
--- Copyright (c) 2004 Don Stewart - http://www.cse.unsw.edu.au/~dons
--- LGPL version 2.1 or later (see http://www.gnu.org/copyleft/lesser.html)
---
-
-module TestIO ( resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-import System.IO
-import System.Posix.Types   ( ProcessID, Fd )
-import System.Posix.Process ( forkProcess, executeFile, getProcessID )
-import System.Posix.IO      ( createPipe, stdInput, 
-                              stdOutput, fdToHandle, closeFd, dupTo )
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
-
-resource :: TestIO
-resource = testio { field = date }
-
-
---
--- call a shell command , returning it's output
---
-date :: IO String
-date = do (hdl,_,_) <- catch (popen "/bin/date") (\_->error "popen failed")
-          hGetLine hdl 
-
-------------------------------------------------------------------------
---
--- my implementation of $val = `cmd`; (if this was perl)
---
--- provide similar functionality to popen(3), 
--- along with bidirectional ipc via pipes
--- return's the pid of the child process
---
--- there are two different forkProcess functions. the pre-620 was a
--- unix-fork style function, and the modern function has semantics more
--- like the Awkward-Squad paper. We provide implementations of popen
--- using both versions, depending on which GHC the user wants to try.
--- 
-
-popen :: FilePath -> IO (Handle, Handle, ProcessID)
-popen cmd = do
-        (pr, pw) <- createPipe
-        (cr, cw) <- createPipe    
-
-        -- parent --
-        let parent = do closeFd cw
-                        closeFd pr
-        -- child --
-        let child  = do closeFd pw
-                        closeFd cr 
-                        exec cmd (pr,cw)
-                        error "exec cmd failed!" -- typing only
-
--- if the parser front end understood cpp, this would work
--- #if __GLASGOW_HASKELL__ >= 601
-        pid <- forkProcess child -- fork child
-        parent                   -- and run parent code
--- #else
---          p   <- forkProcess
---          pid <- case p of
---                  Just pid -> parent >> return pid
---                  Nothing  -> child
--- #endif
-
-        hcr <- fdToHandle cr
-        hpw <- fdToHandle pw
-
-        return (hcr,hpw,pid)
-
---
--- execve cmd in the child process, dup'ing the file descriptors passed
--- as arguments to become the child's stdin and stdout.
---
-exec :: FilePath -> (Fd,Fd) -> IO ()
-exec cmd (pr,cw) = do
-        dupTo pr stdInput
-        dupTo cw stdOutput
-        executeFile cmd False [] Nothing
-
-------------------------------------------------------------------------
diff --git a/testsuite/dynload/io/api/API.hs b/testsuite/dynload/io/api/API.hs
deleted file mode 100644
--- a/testsuite/dynload/io/api/API.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Typeable
-
-data TestIO = TestIO { 
-                field :: IO String 
-        }
-
-instance Typeable TestIO where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf i = mkTyConApp (mkTyCon "API.TestIO") []
-#else
-    typeOf i = mkAppTy (mkTyCon "API.TestIO") []
-#endif
-
-testio :: TestIO
-testio = TestIO { field = return "default value" }
diff --git a/testsuite/dynload/io/prog/Main.hs b/testsuite/dynload/io/prog/Main.hs
deleted file mode 100644
--- a/testsuite/dynload/io/prog/Main.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-
-import System.Plugins
-import API
-
-main = do
-        m_v   <- dynload "../TestIO.o" ["../api"] 
-                                       [] "resource_dyn"
-        case m_v of
-                LoadFailure _   -> error "couldn't compile"
-                LoadSuccess _ v -> do 
-                        s <- field v
-                        if s /= [] then print True else print False
diff --git a/testsuite/dynload/io/prog/expected b/testsuite/dynload/io/prog/expected
deleted file mode 100644
--- a/testsuite/dynload/io/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-True
diff --git a/testsuite/dynload/poly/Makefile b/testsuite/dynload/poly/Makefile
deleted file mode 100644
--- a/testsuite/dynload/poly/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=dynload/poly
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/dynload/poly/Plugin.hs b/testsuite/dynload/poly/Plugin.hs
deleted file mode 100644
--- a/testsuite/dynload/poly/Plugin.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-module Plugin where
-
-import API
-import Data.Dynamic
-
-my_fun = plugin { 
-                equals = \x y -> (x /= y)  -- a strange equals function :)
-         }
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn my_fun
-
diff --git a/testsuite/dynload/poly/api/API.hs b/testsuite/dynload/poly/api/API.hs
deleted file mode 100644
--- a/testsuite/dynload/poly/api/API.hs
+++ /dev/null
@@ -1,24 +0,0 @@
-{-# OPTIONS -cpp #-}
-
-module API where
-
-import Data.Typeable
-
-data Interface = Interface { 
-        equals :: forall t. Eq t => t -> t -> Bool
-     }
-
---
--- see how it hides the internal type.. but to compile GHC still checks
--- the type.
---
-instance Typeable Interface where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf i = mkTyConApp (mkTyCon "API.Interface") []
-#else
-    typeOf i = mkAppTy (mkTyCon "API.Interface") []
-#endif
-
-plugin :: Interface
-plugin = Interface  { equals = (==) }
-
diff --git a/testsuite/dynload/poly/prog/Main.hs b/testsuite/dynload/poly/prog/Main.hs
deleted file mode 100644
--- a/testsuite/dynload/poly/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-{-# OPTIONS -cpp #-}
-
-#include "../../../../config.h"
-
-import System.Plugins
-import API
-
-main = do 
-        m_v <- dynload "../Plugin.o" ["../api"]
-                                     [] 
-                                     "resource_dyn"
-        case m_v of
-                LoadFailure _ -> error "didn't compile"
-                LoadSuccess _ (Interface eq) -> do
-                                 putStrLn $ show $   1 `eq` 2
-                                 putStrLn $ show $ 'a' `eq` 'b'
-
diff --git a/testsuite/dynload/poly/prog/expected b/testsuite/dynload/poly/prog/expected
deleted file mode 100644
--- a/testsuite/dynload/poly/prog/expected
+++ /dev/null
@@ -1,2 +0,0 @@
-True
-True
diff --git a/testsuite/dynload/should_fail/Makefile b/testsuite/dynload/should_fail/Makefile
deleted file mode 100644
--- a/testsuite/dynload/should_fail/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   dynload/should_fail
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/dynload/should_fail/Plugin.hs b/testsuite/dynload/should_fail/Plugin.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail/Plugin.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-module Plugin where
-
-import API
-import Data.Dynamic
-
-v :: Int
-v = 0xdeadbeef
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn v
-
diff --git a/testsuite/dynload/should_fail/api/API.hs b/testsuite/dynload/should_fail/api/API.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail/api/API.hs
+++ /dev/null
@@ -1,20 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Typeable
-
-data Interface = Interface { 
-        function :: String
-   }
-
-instance Typeable Interface where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf i = mkTyConApp (mkTyCon "API.Interface") []
-#else
-    typeOf i = mkAppTy (mkTyCon "API.Interface") []
-#endif
-
-plugin :: Interface
-plugin = Interface  { function = "goodbye" }
-
diff --git a/testsuite/dynload/should_fail/prog/Main.hs b/testsuite/dynload/should_fail/prog/Main.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail/prog/Main.hs
+++ /dev/null
@@ -1,14 +0,0 @@
-
-import System.Plugins
-import API
-
-main = do 
-    m_v   <- dynload "../Plugin.o" 
-                     ["../api"] 
-                     [] 
-                     "resource_dyn"
-
-    case m_v of
-        LoadFailure _    -> putStrLn "didn't compile"
-        LoadSuccess _ v  -> putStrLn $ function v
-
diff --git a/testsuite/dynload/should_fail/prog/expected b/testsuite/dynload/should_fail/prog/expected
deleted file mode 100644
--- a/testsuite/dynload/should_fail/prog/expected
+++ /dev/null
@@ -1,4 +0,0 @@
-Couldn't match `API.Interface' against `Int'
-	Expected type: API.Interface
-	Inferred type: Int
-didn't compile
diff --git a/testsuite/dynload/should_fail_1/Makefile b/testsuite/dynload/should_fail_1/Makefile
deleted file mode 100644
--- a/testsuite/dynload/should_fail_1/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   dynload/should_fail_1
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/dynload/should_fail_1/Plugin.hs b/testsuite/dynload/should_fail_1/Plugin.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail_1/Plugin.hs
+++ /dev/null
@@ -1,15 +0,0 @@
---
--- trying to be really mean.
---
-
-module Plugin where
-
-import API
-import Data.Dynamic
-
-v :: Int -> Int
-v = \x -> 0xdeadbeef
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn v
-
diff --git a/testsuite/dynload/should_fail_1/api/API.hs b/testsuite/dynload/should_fail_1/api/API.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail_1/api/API.hs
+++ /dev/null
@@ -1,20 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Typeable
-
-data Interface = Interface { 
-        function :: String
-   }
-
-instance Typeable Interface where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf i = mkTyConApp (mkTyCon "API.Interface") []
-#else
-    typeOf i = mkAppTy (mkTyCon "API.Interface") []
-#endif
-
-plugin :: Interface
-plugin = Interface  { function = "goodbye" }
-
diff --git a/testsuite/dynload/should_fail_1/prog/Main.hs b/testsuite/dynload/should_fail_1/prog/Main.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail_1/prog/Main.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-
-import System.Plugins
-import API
-
-main = do 
-    m_v   <- dynload "../Plugin.o" ["../api"] 
-                                   [] "resource_dyn"
-    case m_v of
-        LoadFailure _   -> putStrLn "didn't compile"
-        LoadSuccess _ v -> putStrLn $ (function v)
-
diff --git a/testsuite/dynload/should_fail_1/prog/expected b/testsuite/dynload/should_fail_1/prog/expected
deleted file mode 100644
--- a/testsuite/dynload/should_fail_1/prog/expected
+++ /dev/null
@@ -1,4 +0,0 @@
-Couldn't match `API.Interface' against `Int -> Int'
-	Expected type: API.Interface
-	Inferred type: Int -> Int
-didn't compile
diff --git a/testsuite/dynload/should_fail_2/Makefile b/testsuite/dynload/should_fail_2/Makefile
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=		dynload/should_fail_2
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/dynload/should_fail_2/Plugin.in b/testsuite/dynload/should_fail_2/Plugin.in
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/Plugin.in
+++ /dev/null
@@ -1,19 +0,0 @@
---
--- the plugin doesn't even make the resource_dyn a Dynamic.
---
--- let's hope that makeWith strips out the invalid declarations
---
-
-{-# OPTIONS -fglasgow-exts #-}
-
-module Plugin where
-
-import API
-import Data.Typeable
-import GHC.Base
-
-v :: Int
-v = 0xdeadbeef
-
-resource_dyn = (typeOf v, unsafeCoerce v)
-
diff --git a/testsuite/dynload/should_fail_2/Plugin.stub b/testsuite/dynload/should_fail_2/Plugin.stub
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/Plugin.stub
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module Plugin ( resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-resource = plugin
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
-
diff --git a/testsuite/dynload/should_fail_2/api/API.hs b/testsuite/dynload/should_fail_2/api/API.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/api/API.hs
+++ /dev/null
@@ -1,22 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Typeable
-import GHC.Base
-
-data Interface = Interface { 
-        function :: String
-   }
-        
-instance Typeable Interface where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf i = mkTyConApp (mkTyCon "API.Interface") []
-#else
-    typeOf i = mkAppTy (mkTyCon "API.Interface") []
-#endif
-
-plugin :: Interface
-plugin = Interface  { function = "goodbye" }
-
-unsafeCoerce = unsafeCoerce#
diff --git a/testsuite/dynload/should_fail_2/prog/Main.hs b/testsuite/dynload/should_fail_2/prog/Main.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
-import System.Plugins
-import API
-
-conf    = "../Plugin.in"
-stub    = "../Plugin.stub"
-
-main = do 
-        status <- makeWith conf stub ["-i../api", "-i../../../../src/altdata/"]
-        case status of
-         MakeFailure e   -> mapM_ putStrLn e >> putStrLn "failed"
-         MakeSuccess _ o -> do {
-              ; m_v <- dynload o ["../api"] [] "resource_dyn"
-              ; makeCleaner o
-              ; case m_v of
-                        LoadFailure _   -> putStrLn "didn't load"
-                        LoadSuccess _ v -> putStrLn $ (function v)
-         }
-
diff --git a/testsuite/dynload/should_fail_2/prog/expected b/testsuite/dynload/should_fail_2/prog/expected
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/prog/expected
+++ /dev/null
@@ -1,8 +0,0 @@
-
-../Plugin.in:18:
-    Couldn't match `Dynamic' against `(t, t1)'
-	Expected type: Dynamic
-	Inferred type: (t, t1)
-    In the definition of `resource_dyn':
-	resource_dyn = (typeOf v, unsafeCoerce v)
-failed
diff --git a/testsuite/dynload/should_fail_2/prog/expected.604 b/testsuite/dynload/should_fail_2/prog/expected.604
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/prog/expected.604
+++ /dev/null
@@ -1,7 +0,0 @@
-
-../Plugin.in:18:15:
-    Couldn't match `Dynamic' against `(a, b)'
-      Expected type: Dynamic
-      Inferred type: (a, b)
-    In the definition of `resource_dyn': resource_dyn = (typeOf v, unsafeCoerce v)
-failed
diff --git a/testsuite/dynload/should_fail_2/prog/expected.605 b/testsuite/dynload/should_fail_2/prog/expected.605
deleted file mode 100644
--- a/testsuite/dynload/should_fail_2/prog/expected.605
+++ /dev/null
@@ -1,7 +0,0 @@
-
-../Plugin.in:18:15:
-    Couldn't match `Dynamic' against `(a, b)'
-      Expected type: Dynamic
-      Inferred type: (a, b)
-    In the definition of `resource_dyn': resource_dyn = (typeOf v, unsafeCoerce v)
-failed
diff --git a/testsuite/dynload/should_fail_3/Makefile b/testsuite/dynload/should_fail_3/Makefile
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=		dynload/should_fail_3
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/dynload/should_fail_3/Plugin.in b/testsuite/dynload/should_fail_3/Plugin.in
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/Plugin.in
+++ /dev/null
@@ -1,19 +0,0 @@
---
--- the plugin doesn't even make the resource_dyn a Dynamic.
--- let's hope that makeWith strips out the invalid declarations
---
-
-{-# OPTIONS -fglasgow-exts #-}
-
-module Plugin where
-
-import API
-
-import Data.Typeable
-import GHC.Base
-
-v :: Int
-v = 0xdeadbeef
-
-resource_dyn = (typeOf plugin, unsafeCoerce v)
-
diff --git a/testsuite/dynload/should_fail_3/Plugin.stub b/testsuite/dynload/should_fail_3/Plugin.stub
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/Plugin.stub
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module Plugin ( resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-resource = plugin
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
-
diff --git a/testsuite/dynload/should_fail_3/api/API.hs b/testsuite/dynload/should_fail_3/api/API.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/api/API.hs
+++ /dev/null
@@ -1,22 +0,0 @@
-{-# OPTIONS -cpp -fglasgow-exts #-}
-
-module API where
-
-import Data.Typeable
-import GHC.Base
-
-data Interface = Interface { 
-        function :: String
-   }
-
-instance Typeable Interface where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf _ = mkTyConApp (mkTyCon "API.Interface") []
-#else
-    typeOf _ = mkAppTy (mkTyCon "API.Interface") []
-#endif
-
-plugin :: Interface
-plugin = Interface  { function = "goodbye" }
-
-unsafeCoerce = unsafeCoerce#
diff --git a/testsuite/dynload/should_fail_3/prog/Main.hs b/testsuite/dynload/should_fail_3/prog/Main.hs
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/prog/Main.hs
+++ /dev/null
@@ -1,18 +0,0 @@
-
-import System.Plugins
-import API
-
-conf    = "../Plugin.in"
-stub    = "../Plugin.stub"
-
-main = do 
-        status <- makeWith conf stub ["-i../api", "-i../../../../src/altdata"]
-        o <- case status of
-                MakeFailure e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess _ o -> return o
-        m_v <- dynload o ["../api"] [] "resource_dyn"
-        case m_v of
-                LoadFailure _   -> error "didn't compile"
-                LoadSuccess _ v -> do putStrLn $ (function v)
-                                      makeCleaner o
-
diff --git a/testsuite/dynload/should_fail_3/prog/expected b/testsuite/dynload/should_fail_3/prog/expected
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/prog/expected
+++ /dev/null
@@ -1,9 +0,0 @@
-
-../Plugin.in:18:
-    Couldn't match `Dynamic' against `(t, t1)'
-	Expected type: Dynamic
-	Inferred type: (t, t1)
-    In the definition of `resource_dyn':
-	resource_dyn = (typeOf plugin, unsafeCoerce v)
-
-Fail: failed
diff --git a/testsuite/dynload/should_fail_3/prog/expected.604 b/testsuite/dynload/should_fail_3/prog/expected.604
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/prog/expected.604
+++ /dev/null
@@ -1,8 +0,0 @@
-
-../Plugin.in:18:15:
-    Couldn't match `Dynamic' against `(a, b)'
-      Expected type: Dynamic
-      Inferred type: (a, b)
-    In the definition of `resource_dyn':
-	resource_dyn = (typeOf plugin, unsafeCoerce v)
-a.out: failed
diff --git a/testsuite/dynload/should_fail_3/prog/expected.605 b/testsuite/dynload/should_fail_3/prog/expected.605
deleted file mode 100644
--- a/testsuite/dynload/should_fail_3/prog/expected.605
+++ /dev/null
@@ -1,8 +0,0 @@
-
-../Plugin.in:18:15:
-    Couldn't match `Dynamic' against `(a, b)'
-      Expected type: Dynamic
-      Inferred type: (a, b)
-    In the definition of `resource_dyn':
-	resource_dyn = (typeOf plugin, unsafeCoerce v)
-a.out: failed
diff --git a/testsuite/dynload/simple/Makefile b/testsuite/dynload/simple/Makefile
deleted file mode 100644
--- a/testsuite/dynload/simple/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=dynload/simple
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/dynload/simple/Plugin.hs b/testsuite/dynload/simple/Plugin.hs
deleted file mode 100644
--- a/testsuite/dynload/simple/Plugin.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-module Plugin where
-
-import API
-import Data.Dynamic
-
-my_fun = plugin { function = "plugin says \"hello\"" }
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn my_fun
-
diff --git a/testsuite/dynload/simple/api/API.hs b/testsuite/dynload/simple/api/API.hs
deleted file mode 100644
--- a/testsuite/dynload/simple/api/API.hs
+++ /dev/null
@@ -1,20 +0,0 @@
-{-# OPTIONS -cpp #-}
-
-module API where
-
-import Data.Typeable
-
-data Interface = Interface { 
-        function :: String
-   }
-
-instance Typeable Interface where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf i = mkTyConApp (mkTyCon "API.Interface") []
-#else
-    typeOf i = mkAppTy (mkTyCon "API.Interface") []
-#endif
-
-plugin :: Interface
-plugin = Interface  { function = "goodbye" }
-
diff --git a/testsuite/dynload/simple/prog/Main.hs b/testsuite/dynload/simple/prog/Main.hs
deleted file mode 100644
--- a/testsuite/dynload/simple/prog/Main.hs
+++ /dev/null
@@ -1,15 +0,0 @@
-{-# OPTIONS -cpp #-}
-
-#include "../../../../config.h"
-
-import System.Plugins
-import API
-
-main = do 
-        m_v <- dynload "../Plugin.o" ["../api"]
-                                     []
-                                     "resource_dyn"
-        case m_v of
-                LoadFailure _   -> error "didn't compile"
-                LoadSuccess _ v -> putStrLn $ (function v)
-
diff --git a/testsuite/dynload/simple/prog/expected b/testsuite/dynload/simple/prog/expected
deleted file mode 100644
--- a/testsuite/dynload/simple/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-plugin says "hello"
diff --git a/testsuite/eval.mk b/testsuite/eval.mk
deleted file mode 100644
--- a/testsuite/eval.mk
+++ /dev/null
@@ -1,25 +0,0 @@
-include $(TOP)/config.mk
-include $(TOP)/testsuite/check.mk
-
-BIN=Main
-SRC=Main.hs
-
-BINDIR=		"."
-REALBIN=	./$(BIN)
-
-.SUFFIXES : .o .hs .hi .lhs .hc .s
-
-all: $(BIN)
-
-$(BIN): $(SRC) $(OBJS)
-	@rm -f $@
-	@$(GHC) --make -fglasgow-exts $(GHCFLAGS) $(PKGFLAGS) $(EXTRAFLAGS) $(SRC)
-
-# Standard suffix rules
-.o.hi:
-	@:
-.hs.o:
-	@$(GHC) $(INCLUDES) $(PKGFLAGS) $(GHCFLAGS) $(EXTRAFLAGS) -c $<
-
-clean: 
-	@rm -rf *.hi *.o *~ $(BIN)
diff --git a/testsuite/eval/eval1/Main.hs b/testsuite/eval/eval1/Main.hs
deleted file mode 100644
--- a/testsuite/eval/eval1/Main.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-
-import System.Eval.Haskell
-
-main = do i <- eval "1 + 6 :: Int" [] :: IO (Maybe Int)
-          if isJust i then putStrLn $ show (fromJust i) else return ()
diff --git a/testsuite/eval/eval1/Makefile b/testsuite/eval/eval1/Makefile
deleted file mode 100644
--- a/testsuite/eval/eval1/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/eval/eval1/expected b/testsuite/eval/eval1/expected
deleted file mode 100644
--- a/testsuite/eval/eval1/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-7
diff --git a/testsuite/eval/eval2/Main.hs b/testsuite/eval/eval2/Main.hs
deleted file mode 100644
--- a/testsuite/eval/eval2/Main.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-import System.Eval.Haskell
-
-main = do m_s <- eval "map toUpper \"haskell\"" ["Data.Char"]
-          case m_s of
-                Nothing -> putStrLn "typechecking failed"
-                Just s  -> putStrLn s
diff --git a/testsuite/eval/eval2/Makefile b/testsuite/eval/eval2/Makefile
deleted file mode 100644
--- a/testsuite/eval/eval2/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/eval/eval2/expected b/testsuite/eval/eval2/expected
deleted file mode 100644
--- a/testsuite/eval/eval2/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-HASKELL
diff --git a/testsuite/eval/eval3/Main.hs b/testsuite/eval/eval3/Main.hs
deleted file mode 100644
--- a/testsuite/eval/eval3/Main.hs
+++ /dev/null
@@ -1,38 +0,0 @@
-{-# OPTIONS -cpp #-}
---
--- Should evaluate to '3', unless something goes wrong.
---
--- Not so bad to use AltData, as it is already derived for all the basic
--- types. Then, just replace deriving Typeable, with hand-derived
--- instance of Typeable (see hs-plugins/testsuite/eval/eval_fn1/Poly.hs
---
---
-
-#include "../../../config.h"
-
-import System.Eval
-import Data.Dynamic
-
-main = do
-    a <- return $ toDyn (3::Integer)
-
-    -- so, we try to compile a function that takes a dyn.
-    -- looks like with GHC 6.4, we need to make sure the package.confs work:
-    m_b <- unsafeEval_ "\\dyn -> fromDyn dyn (7 :: Integer)"
-                ["Data.Dynamic"]
-                [ ]
-                [ ]
-                []
-
-    case m_b of 
-        Left s   -> mapM_ putStrLn s
-        Right b  -> putStrLn $ show (b a :: Integer) -- now apply it
-                
-{-
--- should work, but doesn't. type check fails 
--- (due to static vs dynamic typing issue)
-
-     m_b <- unsafeEval_ "\\dyn -> fromMaybe (7 :: Int) (fromDynamic dyn)"
-                                ["Data.Dynamic","Data.Maybe"] [] []
--}
-
diff --git a/testsuite/eval/eval3/Makefile b/testsuite/eval/eval3/Makefile
deleted file mode 100644
--- a/testsuite/eval/eval3/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/eval/eval3/expected b/testsuite/eval/eval3/expected
deleted file mode 100644
--- a/testsuite/eval/eval3/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-3
diff --git a/testsuite/eval/eval_/Main.hs b/testsuite/eval/eval_/Main.hs
deleted file mode 100644
--- a/testsuite/eval/eval_/Main.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-
-import System.Eval.Haskell
-
-main = do i <- eval_ "Just (7 :: Int)" 
-                     ["Data.Maybe"] 
-                     ["-fglasgow-exts"] 
-                     []
-                     [] :: IO (Either [String] (Maybe (Maybe Int)))
-          print i
diff --git a/testsuite/eval/eval_/Makefile b/testsuite/eval/eval_/Makefile
deleted file mode 100644
--- a/testsuite/eval/eval_/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/eval/eval_/expected b/testsuite/eval/eval_/expected
deleted file mode 100644
--- a/testsuite/eval/eval_/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-Right (Just (Just 7))
diff --git a/testsuite/eval/eval_fn/Main.hs b/testsuite/eval/eval_fn/Main.hs
deleted file mode 100644
--- a/testsuite/eval/eval_fn/Main.hs
+++ /dev/null
@@ -1,10 +0,0 @@
---
--- lambda abstraction!
---
---
--- needs unsafeEval because eval has a broken Dynamic check
---
-import System.Eval.Haskell
-
-main = do fn <- unsafeEval "(\\x -> (x,x::Int))" [] :: IO (Maybe (Int -> (Int,Int)))
-          when (isJust fn) $ putStrLn $ show $ (fromJust fn) 7
diff --git a/testsuite/eval/eval_fn/Makefile b/testsuite/eval/eval_fn/Makefile
deleted file mode 100644
--- a/testsuite/eval/eval_fn/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/eval/eval_fn/expected b/testsuite/eval/eval_fn/expected
deleted file mode 100644
--- a/testsuite/eval/eval_fn/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-(7,7)
diff --git a/testsuite/eval/eval_fn1/Main.hs b/testsuite/eval/eval_fn1/Main.hs
deleted file mode 100644
--- a/testsuite/eval/eval_fn1/Main.hs
+++ /dev/null
@@ -1,15 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
---
--- polymorphic eval!
---
-
-module Main where
-
-import Poly
-import System.Eval.Haskell
-
-main = do m_f <- eval "Fn (\\x y -> x == y)" ["Poly"]
-          when (isJust m_f) $ do
-                let (Fn f) = fromJust m_f
-                putStrLn $ show (f True True)
-                putStrLn $ show (f 1 2)
diff --git a/testsuite/eval/eval_fn1/Makefile b/testsuite/eval/eval_fn1/Makefile
deleted file mode 100644
--- a/testsuite/eval/eval_fn1/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/eval/eval_fn1/Poly.hs b/testsuite/eval/eval_fn1/Poly.hs
deleted file mode 100644
--- a/testsuite/eval/eval_fn1/Poly.hs
+++ /dev/null
@@ -1,16 +0,0 @@
-{-# OPTIONS -cpp -fglasgow-exts #-} 
-module Poly where
-
-import Data.Typeable
-
-data Fn = Fn {fn :: forall t. Eq t => t -> t -> Bool}
-
---
--- ignore type inside the Fn... is this correct?
---
-instance Typeable Fn where
-#if __GLASGOW_HASKELL__ >= 603
-    typeOf _ = mkTyConApp (mkTyCon "Poly.Fn") []
-#else
-    typeOf _ = mkAppTy (mkTyCon "Poly.Fn") []
-#endif
diff --git a/testsuite/eval/eval_fn1/expected b/testsuite/eval/eval_fn1/expected
deleted file mode 100644
--- a/testsuite/eval/eval_fn1/expected
+++ /dev/null
@@ -1,2 +0,0 @@
-True
-False
diff --git a/testsuite/eval/foreign_eval/Makefile b/testsuite/eval/foreign_eval/Makefile
deleted file mode 100644
--- a/testsuite/eval/foreign_eval/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../foreign.mk
diff --git a/testsuite/eval/foreign_eval/README b/testsuite/eval/foreign_eval/README
deleted file mode 100644
--- a/testsuite/eval/foreign_eval/README
+++ /dev/null
@@ -1,1 +0,0 @@
-run a string of Haskell code from a C program.
diff --git a/testsuite/eval/foreign_eval/dont_test b/testsuite/eval/foreign_eval/dont_test
deleted file mode 100644
--- a/testsuite/eval/foreign_eval/dont_test
+++ /dev/null
diff --git a/testsuite/eval/foreign_eval/expected b/testsuite/eval/foreign_eval/expected
deleted file mode 100644
--- a/testsuite/eval/foreign_eval/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-10946
diff --git a/testsuite/eval/foreign_eval/main.c b/testsuite/eval/foreign_eval/main.c
deleted file mode 100644
--- a/testsuite/eval/foreign_eval/main.c
+++ /dev/null
@@ -1,16 +0,0 @@
-#include <stdio.h>
-
-#include "EvalHaskell.h"
-
-int main(int argc, char *argv[])
-{
-  int *p;
-  hs_init(&argc, &argv);
-  p = hs_eval_i("let fibs = 1:1:zipWith (+) fibs (tail fibs) in fibs !! 20 :: Int");
-  if (p == NULL)
-	  printf("failed!\n");
-  else
-	  printf("%d\n",*p);
-  hs_exit();
-  return 0;
-}
diff --git a/testsuite/eval/foreign_eval1/Makefile b/testsuite/eval/foreign_eval1/Makefile
deleted file mode 100644
--- a/testsuite/eval/foreign_eval1/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../foreign.mk
diff --git a/testsuite/eval/foreign_eval1/dont_test b/testsuite/eval/foreign_eval1/dont_test
deleted file mode 100644
--- a/testsuite/eval/foreign_eval1/dont_test
+++ /dev/null
diff --git a/testsuite/eval/foreign_eval1/expected b/testsuite/eval/foreign_eval1/expected
deleted file mode 100644
--- a/testsuite/eval/foreign_eval1/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-10946
diff --git a/testsuite/eval/foreign_eval1/main.c b/testsuite/eval/foreign_eval1/main.c
deleted file mode 100644
--- a/testsuite/eval/foreign_eval1/main.c
+++ /dev/null
@@ -1,16 +0,0 @@
-#include <stdio.h>
-
-#include "EvalHaskell.h"
-
-int main(int argc, char *argv[])
-{
-  char *p;
-  hs_init(&argc, &argv);
-  p = hs_eval_s("show $ let fibs = 1:1:zipWith (+) fibs (tail fibs) in fibs !! 20");
-  if (p == NULL)
-  	  printf("failed!\n");
-  else
-	  printf("%s\n",p);
-  hs_exit();
-  return 0;
-}
diff --git a/testsuite/eval/foreign_should_fail/Makefile b/testsuite/eval/foreign_should_fail/Makefile
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../foreign.mk
diff --git a/testsuite/eval/foreign_should_fail/dont_test b/testsuite/eval/foreign_should_fail/dont_test
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail/dont_test
+++ /dev/null
diff --git a/testsuite/eval/foreign_should_fail/expected b/testsuite/eval/foreign_should_fail/expected
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail/expected
+++ /dev/null
@@ -1,2 +0,0 @@
-<eval>:1: parse error on input `in'
-failed!
diff --git a/testsuite/eval/foreign_should_fail/expected.604 b/testsuite/eval/foreign_should_fail/expected.604
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail/expected.604
+++ /dev/null
@@ -1,1 +0,0 @@
-failed!
diff --git a/testsuite/eval/foreign_should_fail/expected.605 b/testsuite/eval/foreign_should_fail/expected.605
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail/expected.605
+++ /dev/null
@@ -1,1 +0,0 @@
-failed!
diff --git a/testsuite/eval/foreign_should_fail/main.c b/testsuite/eval/foreign_should_fail/main.c
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail/main.c
+++ /dev/null
@@ -1,16 +0,0 @@
-#include <stdio.h>
-
-#include "EvalHaskell.h"
-
-int main(int argc, char *argv[])
-{
-  int *p;
-  hs_init(&argc, &argv);
-  p = hs_eval_i("show $ case 1 + 2 in{-wrong-} x -> x");
-  if (p == NULL)
-	  printf("failed!\n");
-  else
-	  printf("%d\n",*p);
-  hs_exit();
-  return 0;
-}
diff --git a/testsuite/eval/foreign_should_fail_illtyped/Makefile b/testsuite/eval/foreign_should_fail_illtyped/Makefile
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail_illtyped/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../foreign.mk
diff --git a/testsuite/eval/foreign_should_fail_illtyped/dont_test b/testsuite/eval/foreign_should_fail_illtyped/dont_test
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail_illtyped/dont_test
+++ /dev/null
diff --git a/testsuite/eval/foreign_should_fail_illtyped/expected b/testsuite/eval/foreign_should_fail_illtyped/expected
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail_illtyped/expected
+++ /dev/null
@@ -1,4 +0,0 @@
-Couldn't match `Int' against `[Char]'
-	Expected type: Int
-	Inferred type: [Char]
-failed!
diff --git a/testsuite/eval/foreign_should_fail_illtyped/expected.604 b/testsuite/eval/foreign_should_fail_illtyped/expected.604
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail_illtyped/expected.604
+++ /dev/null
@@ -1,1 +0,0 @@
-failed!
diff --git a/testsuite/eval/foreign_should_fail_illtyped/expected.605 b/testsuite/eval/foreign_should_fail_illtyped/expected.605
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail_illtyped/expected.605
+++ /dev/null
@@ -1,1 +0,0 @@
-failed!
diff --git a/testsuite/eval/foreign_should_fail_illtyped/main.c b/testsuite/eval/foreign_should_fail_illtyped/main.c
deleted file mode 100644
--- a/testsuite/eval/foreign_should_fail_illtyped/main.c
+++ /dev/null
@@ -1,16 +0,0 @@
-#include <stdio.h>
-
-#include "EvalHaskell.h"
-
-int main(int argc, char *argv[])
-{
-  int *p;
-  hs_init(&argc, &argv);
-  p = hs_eval_i("\"an ill-typed string\"");
-  if (p == NULL)
-	  printf("failed!\n");
-  else
-	  printf("%d\n",*p);
-  hs_exit();
-  return 0;
-}
diff --git a/testsuite/eval/unsafeidir/Main.hs b/testsuite/eval/unsafeidir/Main.hs
deleted file mode 100644
--- a/testsuite/eval/unsafeidir/Main.hs
+++ /dev/null
@@ -1,16 +0,0 @@
-
-import System.Plugins.Make
-import System.Eval.Haskell
-
-main = do make "a/Extra.hs" []
-        
-          i <- unsafeEval_ "show (Just (1 + 6 :: Int)) ++ extra" 
-                        ["Data.Maybe", "Extra"] 
-                        ["-ia"]      -- no make flags
-                        []           -- no package.confs
-                        ["a"]        -- include paths to load from
-                        :: IO (Either [String] String)
-               
-          case i of
-                Right i -> putStrLn $ show i
-                Left es -> mapM_ putStrLn es
diff --git a/testsuite/eval/unsafeidir/Makefile b/testsuite/eval/unsafeidir/Makefile
deleted file mode 100644
--- a/testsuite/eval/unsafeidir/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/eval/unsafeidir/a/Extra.hs b/testsuite/eval/unsafeidir/a/Extra.hs
deleted file mode 100644
--- a/testsuite/eval/unsafeidir/a/Extra.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Extra where
-
-extra = "an extra value"
diff --git a/testsuite/eval/unsafeidir/expected b/testsuite/eval/unsafeidir/expected
deleted file mode 100644
--- a/testsuite/eval/unsafeidir/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-"Just 7an extra value"
diff --git a/testsuite/foreign.mk b/testsuite/foreign.mk
deleted file mode 100644
--- a/testsuite/foreign.mk
+++ /dev/null
@@ -1,22 +0,0 @@
-include $(TOP)/config.mk
-include $(TOP)/testsuite/check.mk
-
-
-INCLUDES=   -I$(TOP)
-
-# compile with GHC to save us setting all the necessary include and
-# lib flags. use ghc -v to find out what these are if you wish to go
-# via gcc.
-BIN=./Main
-SRC=main.c
-
-BINDIR=		"."
-REALBIN=	$(BIN)
-
-all:  $(BIN)
-
-$(BIN): $(SRC)
-	$(GHC) -package plugins $(INCLUDES) $(PKGFLAGS) $(SRC)
-
-clean: 
-	rm -rf *.hi *.o *~ $(BIN)
diff --git a/testsuite/hier/hier1/Makefile b/testsuite/hier/hier1/Makefile
deleted file mode 100644
--- a/testsuite/hier/hier1/Makefile
+++ /dev/null
@@ -1,8 +0,0 @@
-TEST=   hier/hier1
-
-EXTRA_OBJS=Plugin.o
-PRIOR_OBJS=Modules/Flags.o
-EXTRAFLAGS=
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/hier/hier1/Modules/Flags.hs b/testsuite/hier/hier1/Modules/Flags.hs
deleted file mode 100644
--- a/testsuite/hier/hier1/Modules/Flags.hs
+++ /dev/null
@@ -1,15 +0,0 @@
---
--- A simple module
---
-
-module Modules.Flags where
-
-
-data FlagRec = FlagRec {
-        f1 :: Int,
-        f2 :: Int
-}
-
-
-foo :: FlagRec -> Int
-foo x = f1 x
diff --git a/testsuite/hier/hier1/Modules/Makefile b/testsuite/hier/hier1/Modules/Makefile
deleted file mode 100644
--- a/testsuite/hier/hier1/Modules/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-
-all:
-	ghc -O -c Flags.hs
-
-clean:
-	rm -f *.hi *.o
diff --git a/testsuite/hier/hier1/Plugin.hs b/testsuite/hier/hier1/Plugin.hs
deleted file mode 100644
--- a/testsuite/hier/hier1/Plugin.hs
+++ /dev/null
@@ -1,14 +0,0 @@
---
--- Plugin
---
-
-module Plugin where
-
-import API
-import Modules.Flags as Flags
-
-
-resource = plugin {
-        dbFunc = (\x -> Flags.f1 x)
-}
-
diff --git a/testsuite/hier/hier1/api/API.hs b/testsuite/hier/hier1/api/API.hs
deleted file mode 100644
--- a/testsuite/hier/hier1/api/API.hs
+++ /dev/null
@@ -1,16 +0,0 @@
---
--- API for plugin test
---
-
-module API where
-
-import Modules.Flags as Flags
-
-data Interface = Interface {
-        dbFunc :: Flags.FlagRec -> Int
-}
-
-
-plugin :: Interface
-plugin = Interface { dbFunc = (\x -> 1) }
-
diff --git a/testsuite/hier/hier1/prog/Main.hs b/testsuite/hier/hier1/prog/Main.hs
deleted file mode 100644
--- a/testsuite/hier/hier1/prog/Main.hs
+++ /dev/null
@@ -1,20 +0,0 @@
---
--- Test multiple plugins
---
-
-
-module Main where
-
-import System.Plugins
-import API
-import Modules.Flags as Flags
-
-record = Flags.FlagRec { Flags.f1 = 4, Flags.f2 = 10 }
-
-
-main = do
-        status <- load "../Plugin.o" ["../api",".."] [] "resource"
-        case status of
-                LoadFailure _ -> error "load failed"
-                LoadSuccess _ v -> do let func = dbFunc v
-                                      print (func record)
diff --git a/testsuite/hier/hier1/prog/expected b/testsuite/hier/hier1/prog/expected
deleted file mode 100644
--- a/testsuite/hier/hier1/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-4
diff --git a/testsuite/hier/hier2/A/B/C/Module.hs b/testsuite/hier/hier2/A/B/C/Module.hs
deleted file mode 100644
--- a/testsuite/hier/hier2/A/B/C/Module.hs
+++ /dev/null
@@ -1,8 +0,0 @@
---
--- A simple module
---
-
-module A.B.C.Module where
-
-symbol = "You found me"
-
diff --git a/testsuite/hier/hier2/A/Makefile b/testsuite/hier/hier2/A/Makefile
deleted file mode 100644
--- a/testsuite/hier/hier2/A/Makefile
+++ /dev/null
@@ -1,7 +0,0 @@
-
-all:
-	ghc -c B/C/Module.hs
-
-
-clean:
-	rm -f B/C/*.hi B/C/*.o
diff --git a/testsuite/hier/hier2/Makefile b/testsuite/hier/hier2/Makefile
deleted file mode 100644
--- a/testsuite/hier/hier2/Makefile
+++ /dev/null
@@ -1,7 +0,0 @@
-TEST=   hier/hier2
-
-PRIOR_OBJS=A/B/C/Module.o
-EXTRAFLAGS=
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/hier/hier2/api/API.hs b/testsuite/hier/hier2/api/API.hs
deleted file mode 100644
--- a/testsuite/hier/hier2/api/API.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module API where
-
--- just a dummy for the build system
-
diff --git a/testsuite/hier/hier2/prog/Main.hs b/testsuite/hier/hier2/prog/Main.hs
deleted file mode 100644
--- a/testsuite/hier/hier2/prog/Main.hs
+++ /dev/null
@@ -1,15 +0,0 @@
---
--- Test if we can load a module with a hierarchical name from some weird
--- path. Tests our the module name handling in the .hi file parser.
---
-
-
-module Main where
-
-import System.Plugins
-
-main = do
-        status <- load "../A/B/C/Module.o" [".."] [] "symbol"
-        case status of
-                LoadFailure ers -> mapM_ putStrLn ers
-                LoadSuccess _ v -> print (v :: String)
diff --git a/testsuite/hier/hier2/prog/expected b/testsuite/hier/hier2/prog/expected
deleted file mode 100644
--- a/testsuite/hier/hier2/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-"You found me"
diff --git a/testsuite/hier/hier3/Main.hs b/testsuite/hier/hier3/Main.hs
deleted file mode 100644
--- a/testsuite/hier/hier3/Main.hs
+++ /dev/null
@@ -1,25 +0,0 @@
-module Main where
-
-import System.Plugins
-
-main = do
-
-    makeAll "One.hs" []
-
-    load2 "Two.o"
-
-    load2 "./Two.o"         -- shouldn't load
-    load2 "../hier3/Two.o"  -- shouldn't load
-    load2 "././././Two.o"   -- shouldn't load
-
-    -- and this one pulls in "../hier3/Two.o" as a dep
-    y <- load "One.o" ["../hier3"] [] "resource"
-    case y of
-        LoadSuccess _ s -> putStrLn $ "One plugin: " ++ s
-        LoadFailure _   -> putStrLn "Failure: y"
-
-load2 f = do
-    x <- load f [".", "../hier3", ""] [] "resource"   -- depend on One.o
-    case x of
-        LoadSuccess _ s -> putStrLn $ "Two plugin: " ++ s
-        LoadFailure _   -> putStrLn "Failure: x"
diff --git a/testsuite/hier/hier3/Makefile b/testsuite/hier/hier3/Makefile
deleted file mode 100644
--- a/testsuite/hier/hier3/Makefile
+++ /dev/null
@@ -1,7 +0,0 @@
-TEST=   hier/hier3
-
-EXTRA_OBJS=One.o Two.o
-EXTRAFLAGS=
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/hier/hier3/One.hs b/testsuite/hier/hier3/One.hs
deleted file mode 100644
--- a/testsuite/hier/hier3/One.hs
+++ /dev/null
@@ -1,7 +0,0 @@
-
-module One where
-
-import qualified Two
-
-resource = "This is the sub-plugin of (" ++ Two.resource ++ ")"
-
diff --git a/testsuite/hier/hier3/Two.hs b/testsuite/hier/hier3/Two.hs
deleted file mode 100644
--- a/testsuite/hier/hier3/Two.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Two where
-
-resource = "This is the top plugin"
-
diff --git a/testsuite/hier/hier3/expected b/testsuite/hier/hier3/expected
deleted file mode 100644
--- a/testsuite/hier/hier3/expected
+++ /dev/null
@@ -1,5 +0,0 @@
-Two plugin: This is the top plugin
-Two plugin: This is the top plugin
-Two plugin: This is the top plugin
-Two plugin: This is the top plugin
-One plugin: This is the sub-plugin of (This is the top plugin)
diff --git a/testsuite/hier/hier4/A.hs b/testsuite/hier/hier4/A.hs
deleted file mode 100644
--- a/testsuite/hier/hier4/A.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-
--- now, the question is: is it possible to not depend on a module or
--- package, but nonetheless have an orphan to it? this could cause
--- problems....
-
-module A where
-
-import B
-
-u :: Int
-u = undefined
diff --git a/testsuite/hier/hier4/B.hs b/testsuite/hier/hier4/B.hs
deleted file mode 100644
--- a/testsuite/hier/hier4/B.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module B where
-
-import C () -- instances, to make available to those who use B
-
diff --git a/testsuite/hier/hier4/C.hs b/testsuite/hier/hier4/C.hs
deleted file mode 100644
--- a/testsuite/hier/hier4/C.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-
--- try to construct an orphan module == an instance decl-only module,
--- that uses classes and types not defined in this module
-
-module C (C) where
-
-import D
-
-instance C a => D (T a) where
-
-class C a where
-
diff --git a/testsuite/hier/hier4/D.hs b/testsuite/hier/hier4/D.hs
deleted file mode 100644
--- a/testsuite/hier/hier4/D.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-
-module D where
-
-class D a where
-
-data T a = T
diff --git a/testsuite/hier/hier4/Main.hs b/testsuite/hier/hier4/Main.hs
deleted file mode 100644
--- a/testsuite/hier/hier4/Main.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-module Main where
-
-import System.Plugins
-
-main = do
-
-    makeAll "A.hs" []
-
-    y <- load "A.o" ["."] [] "u"
-    case y of
-        LoadSuccess _ _ -> putStrLn $ "YES"
-        LoadFailure e   -> mapM_ putStrLn e
diff --git a/testsuite/hier/hier4/Makefile b/testsuite/hier/hier4/Makefile
deleted file mode 100644
--- a/testsuite/hier/hier4/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   hier/hier4
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/hier/hier4/expected b/testsuite/hier/hier4/expected
deleted file mode 100644
--- a/testsuite/hier/hier4/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-YES
diff --git a/testsuite/iface/null/A.hs b/testsuite/iface/null/A.hs
deleted file mode 100644
--- a/testsuite/iface/null/A.hs
+++ /dev/null
@@ -1,1 +0,0 @@
-module A where
diff --git a/testsuite/iface/null/B.hs b/testsuite/iface/null/B.hs
deleted file mode 100644
--- a/testsuite/iface/null/B.hs
+++ /dev/null
@@ -1,1 +0,0 @@
-module B where
diff --git a/testsuite/iface/null/Main.hs b/testsuite/iface/null/Main.hs
deleted file mode 100644
--- a/testsuite/iface/null/Main.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module Main ( main ) where
-
-import Language.Hi.Parser
-
-import A
-import B
-
-main = do iface <- readIface "Main.hi"
-          putStrLn (showIface iface)
diff --git a/testsuite/iface/null/Makefile b/testsuite/iface/null/Makefile
deleted file mode 100644
--- a/testsuite/iface/null/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/iface/null/expected b/testsuite/iface/null/expected
deleted file mode 100644
--- a/testsuite/iface/null/expected
+++ /dev/null
@@ -1,4 +0,0 @@
-interface "main" Main
-module dependencies: A, B
-package dependencies: base, plugins-1.0
-
diff --git a/testsuite/iface/null/expected.604 b/testsuite/iface/null/expected.604
deleted file mode 100644
--- a/testsuite/iface/null/expected.604
+++ /dev/null
@@ -1,5 +0,0 @@
-interface "unknown" Main
-module dependencies: A, B
-package dependencies: base-1.0, plugins-1.0
-import B
-import A
diff --git a/testsuite/iface/null/expected.605 b/testsuite/iface/null/expected.605
deleted file mode 100644
--- a/testsuite/iface/null/expected.605
+++ /dev/null
@@ -1,5 +0,0 @@
-interface "unknown" Main
-module dependencies: A, B
-package dependencies: base-1.0, plugins-1.0
-import B
-import A
diff --git a/testsuite/load/io/Makefile b/testsuite/load/io/Makefile
deleted file mode 100644
--- a/testsuite/load/io/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-TEST= load/io
-
-EXTRA_OBJS=TestIO.o
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/load/io/TestIO.hs b/testsuite/load/io/TestIO.hs
deleted file mode 100644
--- a/testsuite/load/io/TestIO.hs
+++ /dev/null
@@ -1,88 +0,0 @@
-{-# OPTIONS -cpp #-}
---
--- Copyright (c) 2004 Don Stewart - http://www.cse.unsw.edu.au/~dons
--- LGPL version 2.1 or later (see http://www.gnu.org/copyleft/lesser.html)
---
-
-module TestIO ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-import Distribution.Package
-import Language.Haskell.Parser
-import Network.HxWeb
-
-import System.IO
-import System.Posix.Types   ( ProcessID, Fd )
-import System.Posix.Process ( forkProcess, executeFile, getProcessID )
-import System.Posix.IO      ( createPipe, stdInput, 
-                              stdOutput, fdToHandle, closeFd, dupTo )
-
-resource = testio { field = date }
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
-
---
--- call a shell command , returning it's output
---
-date :: IO String
-date = do (hdl,_,_) <- catch (popen "/bin/date") (\_->error "popen failed")
-          hGetLine hdl 
-
-------------------------------------------------------------------------
---
--- my implementation of $val = `cmd`; (if this was perl)
---
--- provide similar functionality to popen(3), 
--- along with bidirectional ipc via pipes
--- return's the pid of the child process
---
--- there are two different forkProcess functions. the pre-620 was a
--- unix-fork style function, and the modern function has semantics more
--- like the Awkward-Squad paper. We provide implementations of popen
--- using both versions, depending on which GHC the user wants to try.
--- 
-
-popen :: FilePath -> IO (Handle, Handle, ProcessID)
-popen cmd = do
-        (pr, pw) <- createPipe
-        (cr, cw) <- createPipe    
-
-        -- parent --
-        let parent = do closeFd cw
-                        closeFd pr
-        -- child --
-        let child  = do closeFd pw
-                        closeFd cr 
-                        exec cmd (pr,cw)
-                        error "exec cmd failed!" -- typing only
-
--- if the parser front end understood cpp, this would work
--- #if __GLASGOW_HASKELL__ >= 601
-        pid <- forkProcess child -- fork child
-        parent                   -- and run parent code
--- #else
---          p   <- forkProcess
---          pid <- case p of
---                  Just pid -> parent >> return pid
---                  Nothing  -> child
--- #endif
-
-        hcr <- fdToHandle cr
-        hpw <- fdToHandle pw
-
-        return (hcr,hpw,pid)
-
---
--- execve cmd in the child process, dup'ing the file descriptors passed
--- as arguments to become the child's stdin and stdout.
---
-exec :: FilePath -> (Fd,Fd) -> IO ()
-exec cmd (pr,cw) = do
-        dupTo pr stdInput
-        dupTo cw stdOutput
-        executeFile cmd False [] Nothing
-
-------------------------------------------------------------------------
diff --git a/testsuite/load/io/api/API.hs b/testsuite/load/io/api/API.hs
deleted file mode 100644
--- a/testsuite/load/io/api/API.hs
+++ /dev/null
@@ -1,16 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data TestIO = TestIO { 
-                field :: IO String 
-        }
-   deriving (Typeable, Show)
-
-instance Show (IO String) where
-    show _ = "<<io action>>"
-
-testio :: TestIO
-testio = TestIO { field = return "default value" }
diff --git a/testsuite/load/io/prog/Main.hs b/testsuite/load/io/prog/Main.hs
deleted file mode 100644
--- a/testsuite/load/io/prog/Main.hs
+++ /dev/null
@@ -1,15 +0,0 @@
-{-# OPTIONS -cpp #-}
-
-#include "../../../../config.h"
-
-import System.Plugins
-import API
-
-main :: IO ()
-main = do
-        m_v <- load "../TestIO.o" ["../api"] [] "resource"
-        v <- case m_v of
-                LoadFailure _   -> error "load failed"
-                LoadSuccess _ v -> return v
-        s <- field v
-        if null s then print False else print True
diff --git a/testsuite/load/io/prog/expected b/testsuite/load/io/prog/expected
deleted file mode 100644
--- a/testsuite/load/io/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-True
diff --git a/testsuite/load/load_0/Makefile b/testsuite/load/load_0/Makefile
deleted file mode 100644
--- a/testsuite/load/load_0/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-TEST= load/load_0
-
-EXTRA_OBJS=Test.o
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/load/load_0/Test.hs b/testsuite/load/load_0/Test.hs
deleted file mode 100644
--- a/testsuite/load/load_0/Test.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-
-module Test where
-
-import API
-
-resource = test { field = "success" }
diff --git a/testsuite/load/load_0/api/API.hs b/testsuite/load/load_0/api/API.hs
deleted file mode 100644
--- a/testsuite/load/load_0/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module API where
-
-data Test = Test { 
-                field :: String 
-        }
-
-test :: Test
-test = Test { field = "default value" }
diff --git a/testsuite/load/load_0/prog/Main.hs b/testsuite/load/load_0/prog/Main.hs
deleted file mode 100644
--- a/testsuite/load/load_0/prog/Main.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-
-import System.Plugins
-import API
-
-main = do
-        m_v <- load_ "../Test.o" ["../api"] "resource"
-        v <- case m_v of
-                LoadFailure _   -> error "load failed"
-                LoadSuccess _ v -> return v
-        let s = field v
-        print s
diff --git a/testsuite/load/load_0/prog/expected b/testsuite/load/load_0/prog/expected
deleted file mode 100644
--- a/testsuite/load/load_0/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-"success"
diff --git a/testsuite/load/loadpkg/Main.hs b/testsuite/load/loadpkg/Main.hs
deleted file mode 100644
--- a/testsuite/load/loadpkg/Main.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-
-import System.Plugins
-
-main = loadPackageWith "posix" []
diff --git a/testsuite/load/loadpkg/Makefile b/testsuite/load/loadpkg/Makefile
deleted file mode 100644
--- a/testsuite/load/loadpkg/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST= load/loadpkg
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/load/loadpkg/expected b/testsuite/load/loadpkg/expected
deleted file mode 100644
--- a/testsuite/load/loadpkg/expected
+++ /dev/null
diff --git a/testsuite/load/null/Makefile b/testsuite/load/null/Makefile
deleted file mode 100644
--- a/testsuite/load/null/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST= load/null
-EXTRA_OBJS=Null.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/load/null/Null.hs b/testsuite/load/null/Null.hs
deleted file mode 100644
--- a/testsuite/load/null/Null.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-module Null ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-import Prelude hiding (null)
-
-resource = null
-
--- ! this has to be special: it can't be overridden by the user.
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/load/null/api/API.hs b/testsuite/load/null/api/API.hs
deleted file mode 100644
--- a/testsuite/load/null/api/API.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data Null = Null { a, b :: Int }
-   deriving (Typeable, Show)
-
-null :: Null
-null = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/load/null/prog/Main.hs b/testsuite/load/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/load/null/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-{-# OPTIONS -cpp #-}
-
-#include "../../../../config.h"
-
-import System.Plugins
-import API
-
--- an example where we just want to load an object and run it
-
-main = do 
-    let includes = [TOP ++ "/testsuite/load/null/api"]
-    m_v <- load "../Null.o" includes [] "resource"
-    v <- case m_v of
-        LoadSuccess _ v -> return v
-        _               -> error "load failed"
-                
-    putStrLn ( show (a v) )
diff --git a/testsuite/load/null/prog/expected b/testsuite/load/null/prog/expected
deleted file mode 100644
--- a/testsuite/load/null/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-42
diff --git a/testsuite/load/thiemann0/Makefile b/testsuite/load/thiemann0/Makefile
deleted file mode 100644
--- a/testsuite/load/thiemann0/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-TEST= load/thiemann0
-
-#EXTRA_OBJS=Test.o
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/load/thiemann0/Test.hs b/testsuite/load/thiemann0/Test.hs
deleted file mode 100644
--- a/testsuite/load/thiemann0/Test.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-
--- P.Thiemann reports that 'import Char' leads to undefined symbol for
--- __stginit_Char_.
-
-module Test where
-
-import API
-import Char
-
-resource = test { field = map toUpper "success" }
-
diff --git a/testsuite/load/thiemann0/api/API.hs b/testsuite/load/thiemann0/api/API.hs
deleted file mode 100644
--- a/testsuite/load/thiemann0/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module API where
-
-data Test = Test { 
-                field :: String 
-        }
-
-test :: Test
-test = Test { field = "default value" }
diff --git a/testsuite/load/thiemann0/prog/Main.hs b/testsuite/load/thiemann0/prog/Main.hs
deleted file mode 100644
--- a/testsuite/load/thiemann0/prog/Main.hs
+++ /dev/null
@@ -1,16 +0,0 @@
-
-import System.Plugins
-import API
-
-main = do
-        status <- make "../Test.hs" ["-i../api"]
-        obj    <- case status of
-                    MakeSuccess _ o -> return o
-                    MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-
-        m_v <- load_ obj ["../api"] "resource"
-        v <- case m_v of
-                LoadFailure _   -> error "load failed"
-                LoadSuccess _ v -> return v
-        let s = field v
-        print s
diff --git a/testsuite/load/thiemann0/prog/expected b/testsuite/load/thiemann0/prog/expected
deleted file mode 100644
--- a/testsuite/load/thiemann0/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-"SUCCESS"
diff --git a/testsuite/load/thiemann2/C.hs b/testsuite/load/thiemann2/C.hs
deleted file mode 100644
--- a/testsuite/load/thiemann2/C.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-module C where
-
-import API
-import qualified A
-
-resource = let Test s = A.resource in Test { field = s }
diff --git a/testsuite/load/thiemann2/Makefile b/testsuite/load/thiemann2/Makefile
deleted file mode 100644
--- a/testsuite/load/thiemann2/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-TEST= load/thiemann2
-EXTRAFLAGS+=-iprog
-
-TOP=../../..
-include ../../build.mk
-
diff --git a/testsuite/load/thiemann2/api/API.hs b/testsuite/load/thiemann2/api/API.hs
deleted file mode 100644
--- a/testsuite/load/thiemann2/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module API where
-
-data Test = Test { 
-                field :: String 
-        }
-
-test :: Test
-test = Test { field = "default value" }
diff --git a/testsuite/load/thiemann2/prog/A.hs b/testsuite/load/thiemann2/prog/A.hs
deleted file mode 100644
--- a/testsuite/load/thiemann2/prog/A.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module A where
-
-import API
-
-import qualified B
-
-resource = Test { field = B.resource }
-
diff --git a/testsuite/load/thiemann2/prog/B.hs b/testsuite/load/thiemann2/prog/B.hs
deleted file mode 100644
--- a/testsuite/load/thiemann2/prog/B.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module B where
-
-resource = "i'm in b"
diff --git a/testsuite/load/thiemann2/prog/Main.hs b/testsuite/load/thiemann2/prog/Main.hs
deleted file mode 100644
--- a/testsuite/load/thiemann2/prog/Main.hs
+++ /dev/null
@@ -1,20 +0,0 @@
-
-import System.Plugins
-import API
-
-import A
-
-main = do
-        -- compile C (A and B are already compiled)
-        status <- makeAll "../C.hs" ["-i../api"]
-        obj    <- case status of
-                    MakeSuccess _ o -> return o
-                    MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-
-        -- should load C
-        m_v <- load_ obj ["../api","."] "resource"
-        v <- case m_v of
-                LoadFailure _   -> error "load failed"
-                LoadSuccess _ v -> return v
-        let s = field v
-        print s
diff --git a/testsuite/load/thiemann2/prog/expected b/testsuite/load/thiemann2/prog/expected
deleted file mode 100644
--- a/testsuite/load/thiemann2/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-"i'm in b"
diff --git a/testsuite/load/unloadpkg/Main.hs b/testsuite/load/unloadpkg/Main.hs
deleted file mode 100644
--- a/testsuite/load/unloadpkg/Main.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-
-import System.Plugins
-
-main = do loadPackage "posix"
-          unloadPackage  "posix"
-          loadPackage "posix"
diff --git a/testsuite/load/unloadpkg/Makefile b/testsuite/load/unloadpkg/Makefile
deleted file mode 100644
--- a/testsuite/load/unloadpkg/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST= load/unloadpkg
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/load/unloadpkg/expected b/testsuite/load/unloadpkg/expected
deleted file mode 100644
--- a/testsuite/load/unloadpkg/expected
+++ /dev/null
diff --git a/testsuite/loadCLib/null/Makefile b/testsuite/loadCLib/null/Makefile
deleted file mode 100644
--- a/testsuite/loadCLib/null/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   loadCLib/null
-EXTRA_OBJS=Null.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/loadCLib/null/Null.hs b/testsuite/loadCLib/null/Null.hs
deleted file mode 100644
--- a/testsuite/loadCLib/null/Null.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-module Null ( resource )  where
-
-import API
-import Data.Dynamic
-import Prelude hiding (null)
-import Graphics.Rendering.OpenGL
-
-resource = null
-
--- ! this has to be special: it can't be overridden by the user.
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/loadCLib/null/api/API.hs b/testsuite/loadCLib/null/api/API.hs
deleted file mode 100644
--- a/testsuite/loadCLib/null/api/API.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data Null = Null { a, b :: Int }
-   deriving (Typeable, Show)
-
-null :: Null
-null = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/loadCLib/null/prog/Main.hs b/testsuite/loadCLib/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/loadCLib/null/prog/Main.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-
-import System.Plugins
-import API
-
--- an example where we just want to load an object and run it
-
-main = do 
-    m_v   <- load_ "../Null.o" ["../api",".."] "resource"
-    case m_v of
-        LoadFailure err -> error (unlines err)
-        LoadSuccess m v -> do putStrLn ( show (a v) ) ; unload m
diff --git a/testsuite/loadCLib/null/prog/expected b/testsuite/loadCLib/null/prog/expected
deleted file mode 100644
--- a/testsuite/loadCLib/null/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-42
diff --git a/testsuite/make/makeall001/A.hs b/testsuite/make/makeall001/A.hs
deleted file mode 100644
--- a/testsuite/make/makeall001/A.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module A where
-
-a = "a"
diff --git a/testsuite/make/makeall001/B.hs b/testsuite/make/makeall001/B.hs
deleted file mode 100644
--- a/testsuite/make/makeall001/B.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module B where
-
-b = "b"
diff --git a/testsuite/make/makeall001/C.hs b/testsuite/make/makeall001/C.hs
deleted file mode 100644
--- a/testsuite/make/makeall001/C.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module C where
-
-c = "c"
diff --git a/testsuite/make/makeall001/Makefile b/testsuite/make/makeall001/Makefile
deleted file mode 100644
--- a/testsuite/make/makeall001/Makefile
+++ /dev/null
@@ -1,3 +0,0 @@
-TEST=   make/makeall001
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/make/makeall001/Tiny.hs b/testsuite/make/makeall001/Tiny.hs
deleted file mode 100644
--- a/testsuite/make/makeall001/Tiny.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-module Tiny ( resource )  where
-
-import API
-
-import A
-import B
-import C
-
-resource = tiny { 
-
-    field = a ++ b ++ c
-    
-}
diff --git a/testsuite/make/makeall001/api/API.hs b/testsuite/make/makeall001/api/API.hs
deleted file mode 100644
--- a/testsuite/make/makeall001/api/API.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
--- ^ needed to derive Typeable
-
-module API where
-
-import Data.Dynamic
-
-data Tiny = Tiny { field :: String }
-   deriving (Typeable, Show)
-
-tiny :: Tiny
-tiny = Tiny { field = "default value" }
-
diff --git a/testsuite/make/makeall001/prog/Main.hs b/testsuite/make/makeall001/prog/Main.hs
deleted file mode 100644
--- a/testsuite/make/makeall001/prog/Main.hs
+++ /dev/null
@@ -1,18 +0,0 @@
-
--- little more complex. use the path to the obj file we get back from
--- 'make'. load() uses this to find the .hi file
-
-import System.Plugins
-import API
-
-main = do
-        status  <- makeAll "../Tiny.hs" ["-i../api"]
-        o <- case status of
-                MakeSuccess _ o -> return o
-                MakeFailure e -> mapM_ putStrLn e >> error "failed"
-        m_v   <- load o [".."] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ field v 
-
diff --git a/testsuite/make/makeall001/prog/expected b/testsuite/make/makeall001/prog/expected
deleted file mode 100644
--- a/testsuite/make/makeall001/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-abc
diff --git a/testsuite/make/null/Makefile b/testsuite/make/null/Makefile
deleted file mode 100644
--- a/testsuite/make/null/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   make/null
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/make/null/Null.hs b/testsuite/make/null/Null.hs
deleted file mode 100644
--- a/testsuite/make/null/Null.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-module Null ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-import Prelude hiding (null)
-
-resource = null
-
--- ! this has to be special: it can't be overridden by the user.
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/make/null/api/API.hs b/testsuite/make/null/api/API.hs
deleted file mode 100644
--- a/testsuite/make/null/api/API.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data Null = Null { a, b :: Int }
-   deriving (Typeable, Show)
-
-null :: Null
-null = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/make/null/prog/Main.hs b/testsuite/make/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/make/null/prog/Main.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-
--- an example where we want to compile and load a file
-
-import System.Plugins
-import API
-
-main = do 
-    make "../Null.hs" ["-i../api"]
-    m_v  <- load "../Null.o" ["../api"] [] "resource"
-    v <- case m_v of
-        LoadSuccess _ v -> return v
-        _               -> error "load failed"
-    putStrLn ( show (a v) )
diff --git a/testsuite/make/null/prog/expected b/testsuite/make/null/prog/expected
deleted file mode 100644
--- a/testsuite/make/null/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-42
diff --git a/testsuite/make/o/Makefile b/testsuite/make/o/Makefile
deleted file mode 100644
--- a/testsuite/make/o/Makefile
+++ /dev/null
@@ -1,3 +0,0 @@
-TEST=make/o
-TOP =../../..
-include ../../build.mk
diff --git a/testsuite/make/o/Plugin.hs b/testsuite/make/o/Plugin.hs
deleted file mode 100644
--- a/testsuite/make/o/Plugin.hs
+++ /dev/null
@@ -1,7 +0,0 @@
-module Plugin ( resource )  where
-
-import API
-
-resource = plugin { 
-    field = "hello out there"
-}
diff --git a/testsuite/make/o/api/API.hs b/testsuite/make/o/api/API.hs
deleted file mode 100644
--- a/testsuite/make/o/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module API where
-
-data Interface = Interface {
-       field :: String 
-}
-
-plugin :: Interface
-plugin = Interface { field = undefined }
diff --git a/testsuite/make/o/prog/Main.hs b/testsuite/make/o/prog/Main.hs
deleted file mode 100644
--- a/testsuite/make/o/prog/Main.hs
+++ /dev/null
@@ -1,28 +0,0 @@
-import System.Plugins
-import API
-
-import System.Directory
-
--- note: the name of the original *source* module is used to find
--- symbols in the *object* file. load works out what the source file
--- name was by looking at the object file name, i.e. it assumes they
--- have the same name. so, if you are going to store objects in a
--- tmpdir, you should make a tmp directory, and store them inside that,
--- rather than mkstemp'ing the name of the object file yourself.
---
--- this should go away once we can read .hi files.
-
-main = do
-#if __GLASGOW_HASKELL__ >= 604
-        tmpDir <- getTemporaryDirectory
-#else
-        let tmpDir = "/tmp"
-#endif
-        make "../Plugin.hs" [ "-i../api", "-o", (tmpDir ++ "/Plugin.o") ]
-        m_v   <- load (tmpDir ++ "/Plugin.o") ["../api"] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ field v 
-
-        mapM_ removeFile [ (tmpDir ++ "/Plugin.hi"), (tmpDir ++ "/Plugin.o") ]
diff --git a/testsuite/make/o/prog/expected b/testsuite/make/o/prog/expected
deleted file mode 100644
--- a/testsuite/make/o/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-hello out there
diff --git a/testsuite/make/odir/Makefile b/testsuite/make/odir/Makefile
deleted file mode 100644
--- a/testsuite/make/odir/Makefile
+++ /dev/null
@@ -1,3 +0,0 @@
-TEST=   make/odir
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/make/odir/Plugin.hs b/testsuite/make/odir/Plugin.hs
deleted file mode 100644
--- a/testsuite/make/odir/Plugin.hs
+++ /dev/null
@@ -1,7 +0,0 @@
-module Plugin ( resource )  where
-
-import API
-
-resource = plugin { 
-    field = "hello out there"
-}
diff --git a/testsuite/make/odir/api/API.hs b/testsuite/make/odir/api/API.hs
deleted file mode 100644
--- a/testsuite/make/odir/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module API where
-
-data Interface = Interface {
-       field :: String 
-}
-
-plugin :: Interface
-plugin = Interface { field = undefined }
diff --git a/testsuite/make/odir/prog/Main.hs b/testsuite/make/odir/prog/Main.hs
deleted file mode 100644
--- a/testsuite/make/odir/prog/Main.hs
+++ /dev/null
@@ -1,21 +0,0 @@
-import System.Plugins
-import API
-import System.Directory
-
-main = do
-#if __GLASGOW_HASKELL__ >= 604
-        tmpDir <- getTemporaryDirectory
-#else
-        let tmpDir = "/tmp"
-#endif
-        status <- make "../Plugin.hs" [ "-i../api", "-odir", tmpDir ]
-        o <- case status of
-                MakeSuccess _ o -> return o
-                MakeFailure e -> mapM_ putStrLn e >> error "didn't compile"
-        m_v     <- load o ["../api"] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ field v 
-        mapM_ removeFile [(tmpDir ++ "/Plugin.hi"), (tmpDir ++ "/Plugin.o") ]
-
diff --git a/testsuite/make/odir/prog/expected b/testsuite/make/odir/prog/expected
deleted file mode 100644
--- a/testsuite/make/odir/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-hello out there
diff --git a/testsuite/make/remake001/Bar.hs b/testsuite/make/remake001/Bar.hs
deleted file mode 100644
--- a/testsuite/make/remake001/Bar.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Bar where
-
-bar = undefined
diff --git a/testsuite/make/remake001/Foo.hs b/testsuite/make/remake001/Foo.hs
deleted file mode 100644
--- a/testsuite/make/remake001/Foo.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Foo where
-
-foo = undefined
diff --git a/testsuite/make/remake001/Main.hs b/testsuite/make/remake001/Main.hs
deleted file mode 100644
--- a/testsuite/make/remake001/Main.hs
+++ /dev/null
@@ -1,36 +0,0 @@
---
--- expected output:
--- $ ./a.out 
--- True
--- False
--- True
--- False
---
-
-import System.Plugins
-import System.Directory
-   
-main = do
-        status <- make "Foo.hs" [] -- should make
-        print status
-
-        status <- make "Foo.hs" [] -- shouldn't make
-        print status
-   
-        status <- merge "Foo.hs" "Bar.hs"
-        case status of
-                MergeFailure e    -> error $ show e
-                MergeSuccess _ _ fp -> do {
-
-        ;status <- make fp []       -- should make
-        ;() <- case status of 
-                MakeSuccess c _ -> print c
-                MakeFailure e   -> error $ show e
-
-        ;status <- make fp []       -- shouldn't make
-        ;case status of 
-                MakeSuccess c _ -> print c
-                MakeFailure e   -> error $ show e
-        ;removeFile "Foo.o"
-        }
-
diff --git a/testsuite/make/remake001/Makefile b/testsuite/make/remake001/Makefile
deleted file mode 100644
--- a/testsuite/make/remake001/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   merge/remake001
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/make/remake001/expected b/testsuite/make/remake001/expected
deleted file mode 100644
--- a/testsuite/make/remake001/expected
+++ /dev/null
@@ -1,4 +0,0 @@
-MakeSuccess ReComp "Foo.o"
-MakeSuccess NotReq "Foo.o"
-ReComp
-NotReq
diff --git a/testsuite/make/remake001_should_fail/Bar.hs b/testsuite/make/remake001_should_fail/Bar.hs
deleted file mode 100644
--- a/testsuite/make/remake001_should_fail/Bar.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Bar where
-
-bar = undef {- error -}
diff --git a/testsuite/make/remake001_should_fail/Foo.hs b/testsuite/make/remake001_should_fail/Foo.hs
deleted file mode 100644
--- a/testsuite/make/remake001_should_fail/Foo.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Foo where
-
-foo = undefined
diff --git a/testsuite/make/remake001_should_fail/Main.hs b/testsuite/make/remake001_should_fail/Main.hs
deleted file mode 100644
--- a/testsuite/make/remake001_should_fail/Main.hs
+++ /dev/null
@@ -1,31 +0,0 @@
-
-import System.Plugins
-
-import System.Directory
-   
-main = do
-        status <- make "Foo.hs" [] -- should make
-        print status
-
-        status <- make "Foo.hs" [] -- shouldn't make
-        print status
-   
-        status  <- merge "Foo.hs" "Bar.hs"
-        case status of
-                MergeFailure e    -> error $ show e
-                MergeSuccess _ _ fp -> do {
-
-        ;status <- make fp []       -- should make
-        ;() <- case status of 
-                MakeSuccess c _ -> print c
-                MakeFailure _   -> print "make failure"
-
-        ;status <- make fp []       -- shouldn't make
-        ;case status of 
-                MakeSuccess c _ -> print c
-                MakeFailure _   -> print "make failure"
-
-        ;removeFile "Foo.o" -- make test deterministic
-        }
-
-
diff --git a/testsuite/make/remake001_should_fail/Makefile b/testsuite/make/remake001_should_fail/Makefile
deleted file mode 100644
--- a/testsuite/make/remake001_should_fail/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   make/remake001_should_fail
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/make/remake001_should_fail/expected b/testsuite/make/remake001_should_fail/expected
deleted file mode 100644
--- a/testsuite/make/remake001_should_fail/expected
+++ /dev/null
@@ -1,4 +0,0 @@
-MakeSuccess ReComp "Foo.o"
-MakeSuccess NotReq "Foo.o"
-"make failure"
-"make failure"
diff --git a/testsuite/make/simple/Makefile b/testsuite/make/simple/Makefile
deleted file mode 100644
--- a/testsuite/make/simple/Makefile
+++ /dev/null
@@ -1,3 +0,0 @@
-TEST=   make/simple
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/make/simple/Tiny.hs b/testsuite/make/simple/Tiny.hs
deleted file mode 100644
--- a/testsuite/make/simple/Tiny.hs
+++ /dev/null
@@ -1,14 +0,0 @@
-module Tiny ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-resource = tiny { 
-
-    field = "hello strange world"
-    
-}
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
-
diff --git a/testsuite/make/simple/api/API.hs b/testsuite/make/simple/api/API.hs
deleted file mode 100644
--- a/testsuite/make/simple/api/API.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
--- ^ needed to derive Typeable
-
-module API where
-
-import Data.Dynamic
-
-data Tiny = Tiny { field :: String }
-   deriving (Typeable, Show)
-
-tiny :: Tiny
-tiny = Tiny { field = "default value" }
-
diff --git a/testsuite/make/simple/prog/Main.hs b/testsuite/make/simple/prog/Main.hs
deleted file mode 100644
--- a/testsuite/make/simple/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
--- little more complex. use the path to the obj file we get back from
--- 'make'. load() uses this to find the .hi file
-
-import System.Plugins
-import API
-
-main = do
-        status  <- make "../Tiny.hs" ["-i../api"]
-        o <- case status of
-                MakeSuccess _ o -> return o
-                MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-
-        m_v   <- load o ["../api"] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ field v 
-
diff --git a/testsuite/make/simple/prog/expected b/testsuite/make/simple/prog/expected
deleted file mode 100644
--- a/testsuite/make/simple/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-hello strange world
diff --git a/testsuite/makewith/global_pragma/Makefile b/testsuite/makewith/global_pragma/Makefile
deleted file mode 100644
--- a/testsuite/makewith/global_pragma/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=makewith/global_pragma
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/makewith/global_pragma/Plugin.hs b/testsuite/makewith/global_pragma/Plugin.hs
deleted file mode 100644
--- a/testsuite/makewith/global_pragma/Plugin.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-{-# GLOBALOPTIONS -package mtl #-}
-
-module M ( resource ) where
-
-import API
-import System.IO.Unsafe
-import System.Process
-import System.IO
-
-resource = tiny { field = date }
-
-date :: String
-date = unsafePerformIO $ do
-            (_,outh,_,proc) <- runInteractiveProcess "echo" ["hello"] Nothing Nothing		
-    	    waitForProcess proc
-            s <- hGetContents outh
-            return s
diff --git a/testsuite/makewith/global_pragma/api/API.hs b/testsuite/makewith/global_pragma/api/API.hs
deleted file mode 100644
--- a/testsuite/makewith/global_pragma/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-
-module API where
-
-data Tiny = Tiny { field :: String }
-
-tiny :: Tiny
-tiny = Tiny { field = "default value" }
-
diff --git a/testsuite/makewith/global_pragma/prog/Main.hs b/testsuite/makewith/global_pragma/prog/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/global_pragma/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
-import System.Plugins
-import API
-
-conf    = "../Plugin.hs"
-apipath = "../api"
-
-main = do
-        status <- makeWith conf conf ["-i"++apipath]
-        o <- case status of
-                MakeFailure e   -> mapM_ putStrLn e >> error "compile failed"
-                MakeSuccess _ o -> return o
-        m_v   <- load o [apipath] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            LoadFailure ers -> mapM_ putStrLn ers >> error "load failed"
-        putStr $ field v 
-        makeCleaner o
-
diff --git a/testsuite/makewith/global_pragma/prog/expected b/testsuite/makewith/global_pragma/prog/expected
deleted file mode 100644
--- a/testsuite/makewith/global_pragma/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-hello
diff --git a/testsuite/makewith/io/Makefile b/testsuite/makewith/io/Makefile
deleted file mode 100644
--- a/testsuite/makewith/io/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=makewith/io
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/makewith/io/README b/testsuite/makewith/io/README
deleted file mode 100644
--- a/testsuite/makewith/io/README
+++ /dev/null
@@ -1,2 +0,0 @@
-An example using IO monad fields in the .conf file.
-
diff --git a/testsuite/makewith/io/TestIO.stub b/testsuite/makewith/io/TestIO.stub
deleted file mode 100644
--- a/testsuite/makewith/io/TestIO.stub
+++ /dev/null
@@ -1,10 +0,0 @@
-
-module TestIO ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-resource = testio
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/makewith/io/api/API.hs b/testsuite/makewith/io/api/API.hs
deleted file mode 100644
--- a/testsuite/makewith/io/api/API.hs
+++ /dev/null
@@ -1,16 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data TestIO = TestIO { 
-                field :: IO String 
-        }
-   deriving (Typeable, Show)
-
-instance Show (IO String) where
-    show _ = "<<io action>>"
-
-testio :: TestIO
-testio = TestIO { field = return "default value" }
diff --git a/testsuite/makewith/io/prog/Main.hs b/testsuite/makewith/io/prog/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/io/prog/Main.hs
+++ /dev/null
@@ -1,21 +0,0 @@
-
-import System.Plugins
-import API
-
-conf    = "../TestIO.conf"
-stub    = "../TestIO.stub"
-apipath = "../api"
-
-main = do
-        status <- makeWith conf stub ["-i"++apipath]
-        o <- case status of
-                MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess _ o -> return o
-        m_v   <- load o [apipath] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        s <- field v
-
-        makeCleaner o
-        if null s then print False else print True
diff --git a/testsuite/makewith/io/prog/expected b/testsuite/makewith/io/prog/expected
deleted file mode 100644
--- a/testsuite/makewith/io/prog/expected
+++ /dev/null
@@ -1,6 +0,0 @@
-merge failed:
-
-parse error in ../TestIO.conf
-line: 17, col: 1
-
-Main: failed
diff --git a/testsuite/makewith/merge00/Bar.hs b/testsuite/makewith/merge00/Bar.hs
deleted file mode 100644
--- a/testsuite/makewith/merge00/Bar.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Bar where
-
-resource :: Int
diff --git a/testsuite/makewith/merge00/Foo.hs b/testsuite/makewith/merge00/Foo.hs
deleted file mode 100644
--- a/testsuite/makewith/merge00/Foo.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Foo where
-
-resource :: Integer
-resource = 0xBAD
diff --git a/testsuite/makewith/merge00/Main.hs b/testsuite/makewith/merge00/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/merge00/Main.hs
+++ /dev/null
@@ -1,38 +0,0 @@
-
-import System.Plugins
-
-import System.Directory
-
-a    = "Foo.hs" -- uesr code
-b    = "Bar.hs" -- trusted code. Result is "Bar.o"
-
-main = do
-        status <- merge a b 
-        f <- case status of
-                MergeFailure e     -> error "merge failure"
-                MergeSuccess _ _ f -> return f
-
-        status <- merge a b 
-        f' <- case status of
-                MergeFailure e          -> error "merge failure"
-                MergeSuccess ReComp _ f -> error "unnec. merge"
-                MergeSuccess NotReq _ f -> return f
-
-        print ( f == f' )
-
-        status <- make f' []
-        o <- case status of
-                  MakeFailure   e -> error "make failed"
-                  MakeSuccess _ o -> return o
-
-        m_v   <- load o [] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ show $ (v :: Int)
-
-        removeFile o
-        return ()
-
-        makeCleaner f
-
diff --git a/testsuite/makewith/merge00/Makefile b/testsuite/makewith/merge00/Makefile
deleted file mode 100644
--- a/testsuite/makewith/merge00/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=makewith/merge00
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/makewith/merge00/expected b/testsuite/makewith/merge00/expected
deleted file mode 100644
--- a/testsuite/makewith/merge00/expected
+++ /dev/null
@@ -1,2 +0,0 @@
-True
-2989
diff --git a/testsuite/makewith/mergeto0/Bar.hs b/testsuite/makewith/mergeto0/Bar.hs
deleted file mode 100644
--- a/testsuite/makewith/mergeto0/Bar.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Bar where
-
-resource :: Int
diff --git a/testsuite/makewith/mergeto0/Foo.hs b/testsuite/makewith/mergeto0/Foo.hs
deleted file mode 100644
--- a/testsuite/makewith/mergeto0/Foo.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Foo where
-
-resource :: Integer
-resource = 0xBAD
diff --git a/testsuite/makewith/mergeto0/Main.hs b/testsuite/makewith/mergeto0/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/mergeto0/Main.hs
+++ /dev/null
@@ -1,37 +0,0 @@
-
-import System.Plugins
-
-import System.Directory
-
-a    = "Foo.hs" -- uesr code
-b    = "Bar.hs" -- trusted code. Result is "Bar.o"
-c    = "Out.hs"
-
-main = do
-        status <- mergeTo a b c
-        f <- case status of
-                MergeFailure e     -> error "mergeto failure"
-                MergeSuccess _ _ f -> return f
-        print $ f == c
-
-        status <- mergeTo a b c
-        f' <- case status of
-                MergeFailure e          -> error "mergeto failure"
-                MergeSuccess ReComp _ f -> error "unnec. mergeto"
-                MergeSuccess NotReq _ f -> return f -- good, not req
-
-        print $ f == f' && f == c
-
-        status <- make f' []
-        o <- case status of
-                  MakeFailure   e -> error "make failed"
-                  MakeSuccess _ o -> return o
-
-        m_v   <- load o [] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ show $ (v :: Int)
-
-        makeCleaner c
-
diff --git a/testsuite/makewith/mergeto0/Makefile b/testsuite/makewith/mergeto0/Makefile
deleted file mode 100644
--- a/testsuite/makewith/mergeto0/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=makewith/mergeto0
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/makewith/mergeto0/expected b/testsuite/makewith/mergeto0/expected
deleted file mode 100644
--- a/testsuite/makewith/mergeto0/expected
+++ /dev/null
@@ -1,3 +0,0 @@
-True
-True
-2989
diff --git a/testsuite/makewith/module_name/Bar.hs b/testsuite/makewith/module_name/Bar.hs
deleted file mode 100644
--- a/testsuite/makewith/module_name/Bar.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Bar where
-
-resource :: Int
diff --git a/testsuite/makewith/module_name/Foo.hs b/testsuite/makewith/module_name/Foo.hs
deleted file mode 100644
--- a/testsuite/makewith/module_name/Foo.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Foo where
-
-resource :: Integer
-resource = 1
diff --git a/testsuite/makewith/module_name/Main.hs b/testsuite/makewith/module_name/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/module_name/Main.hs
+++ /dev/null
@@ -1,33 +0,0 @@
-
-import System.Plugins
-
-import System.Directory
-
-a    = "Foo.hs" -- uesr code
-b    = "Bar.hs" -- trusted code. Result is "Bar.o"
-
-main = do
-        status <- makeWith a b []
-        s <- case status of
-                MakeFailure   e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess n s -> print n >> return s
-
-        status <- makeWith a b []
-        s' <- case status of
-                MakeFailure   e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess n s -> print n >> return s
-
-        status <- makeWith a b []
-        s'' <- case status of
-                MakeFailure   e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess n s -> print n >> return s
-
-        print $ (s == s') && (s' == s'')
-
-        m_v   <- load s [] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ show $ (v :: Int)
-
-        makeCleaner s''
diff --git a/testsuite/makewith/module_name/Makefile b/testsuite/makewith/module_name/Makefile
deleted file mode 100644
--- a/testsuite/makewith/module_name/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=makewith/module_name
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/makewith/module_name/expected b/testsuite/makewith/module_name/expected
deleted file mode 100644
--- a/testsuite/makewith/module_name/expected
+++ /dev/null
@@ -1,5 +0,0 @@
-ReComp
-NotReq
-NotReq
-True
-1
diff --git a/testsuite/makewith/multi_make/Bar.hs b/testsuite/makewith/multi_make/Bar.hs
deleted file mode 100644
--- a/testsuite/makewith/multi_make/Bar.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Bar where
-
-resource :: Int
-resource = 2
diff --git a/testsuite/makewith/multi_make/Foo.hs b/testsuite/makewith/multi_make/Foo.hs
deleted file mode 100644
--- a/testsuite/makewith/multi_make/Foo.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Foo where
-
-resource :: Integer
-resource = 1
diff --git a/testsuite/makewith/multi_make/Main.hs b/testsuite/makewith/multi_make/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/multi_make/Main.hs
+++ /dev/null
@@ -1,37 +0,0 @@
-
-import System.Plugins
-
-import System.Directory
-
-a    = "Foo.hs" -- user code
-b    = "Bar.hs" -- more user code
-z    = "Stub.hs" -- and a stub
-
-main = do
-        status <- makeWith a z []
-        s <- case status of
-                MakeFailure   e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess n s -> print n >> return s
-
-        status <- makeWith b z []
-        s' <- case status of
-                MakeFailure   e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess n s -> print n >> return s
-
-        -- shouldn't need to remerge (a,z)
-        status <- makeWith a z []
-        t <- case status of
-                MakeFailure   e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess n s -> print n >> return s
-
-        -- shouldn't need to remerge (b,z)
-        status <- makeWith b z []
-        t' <- case status of
-                MakeFailure   e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess n s -> print n >> return s
-
-        print $ s /= s' -- test we got unique modules
-        print $ t /= t' -- test we got unique modules
-
-        mapM_ makeCleaner [s,s']
-
diff --git a/testsuite/makewith/multi_make/Makefile b/testsuite/makewith/multi_make/Makefile
deleted file mode 100644
--- a/testsuite/makewith/multi_make/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=makewith/multi_make
-
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/makewith/multi_make/Stub.hs b/testsuite/makewith/multi_make/Stub.hs
deleted file mode 100644
--- a/testsuite/makewith/multi_make/Stub.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Stub where
-
-resource :: Int
-
diff --git a/testsuite/makewith/multi_make/expected b/testsuite/makewith/multi_make/expected
deleted file mode 100644
--- a/testsuite/makewith/multi_make/expected
+++ /dev/null
@@ -1,6 +0,0 @@
-ReComp
-ReComp
-NotReq
-NotReq
-True
-True
diff --git a/testsuite/makewith/should_fail_0/Makefile b/testsuite/makewith/should_fail_0/Makefile
deleted file mode 100644
--- a/testsuite/makewith/should_fail_0/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=makewith/should_fail_0
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/makewith/should_fail_0/Plugin.in b/testsuite/makewith/should_fail_0/Plugin.in
deleted file mode 100644
--- a/testsuite/makewith/should_fail_0/Plugin.in
+++ /dev/null
@@ -1,3 +0,0 @@
-module Plugin where
-
-resource = 0xBAD :: Int
diff --git a/testsuite/makewith/should_fail_0/Plugin.stub b/testsuite/makewith/should_fail_0/Plugin.stub
deleted file mode 100644
--- a/testsuite/makewith/should_fail_0/Plugin.stub
+++ /dev/null
@@ -1,6 +0,0 @@
-module Plugin ( resource ) where
-
-import API
-
-resource :: Interface
-resource = plugin
diff --git a/testsuite/makewith/should_fail_0/api/API.hs b/testsuite/makewith/should_fail_0/api/API.hs
deleted file mode 100644
--- a/testsuite/makewith/should_fail_0/api/API.hs
+++ /dev/null
@@ -1,10 +0,0 @@
-
-module API where
-
-data Interface = Interface { 
-        function :: String
-   }
-
-plugin :: Interface
-plugin = Interface  { function = "goodbye" }
-
diff --git a/testsuite/makewith/should_fail_0/prog/Main.hs b/testsuite/makewith/should_fail_0/prog/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/should_fail_0/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
-import System.Plugins
-import API
-
-conf    = "../Plugin.in"
-stub    = "../Plugin.stub"
-
-main = do 
-        status <- makeWith conf stub ["-i../api"]
-        case status of
-                MakeFailure e    -> putStrLn "make failed"
-                MakeSuccess _  o ->  do
-                        m_v   <- load o ["../api"] [] "resource"
-                        v     <- case m_v of
-                                    LoadSuccess _ v -> return v
-                                    _               -> error "load failed"
-                        putStrLn $ (function v)
-                        makeCleaner o
-
diff --git a/testsuite/makewith/should_fail_0/prog/expected b/testsuite/makewith/should_fail_0/prog/expected
deleted file mode 100644
--- a/testsuite/makewith/should_fail_0/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-make failed
diff --git a/testsuite/makewith/tiny/Makefile b/testsuite/makewith/tiny/Makefile
deleted file mode 100644
--- a/testsuite/makewith/tiny/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=makewith/tiny
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/makewith/tiny/Tiny.conf b/testsuite/makewith/tiny/Tiny.conf
deleted file mode 100644
--- a/testsuite/makewith/tiny/Tiny.conf
+++ /dev/null
@@ -1,8 +0,0 @@
-resource = tiny { 
-
-    field = "hello strange world"
-    
-}
-
-
-
diff --git a/testsuite/makewith/tiny/Tiny.stub b/testsuite/makewith/tiny/Tiny.stub
deleted file mode 100644
--- a/testsuite/makewith/tiny/Tiny.stub
+++ /dev/null
@@ -1,31 +0,0 @@
-module Tiny ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-resource = tiny
-
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/testsuite/makewith/tiny/api/API.hs b/testsuite/makewith/tiny/api/API.hs
deleted file mode 100644
--- a/testsuite/makewith/tiny/api/API.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
--- ^ needed to derive Typeable
-
-module API where
-
-import Data.Dynamic
-
-data Tiny = Tiny { field :: String }
-   deriving (Typeable, Show)
-
-tiny :: Tiny
-tiny = Tiny { field = "default value" }
-
diff --git a/testsuite/makewith/tiny/prog/Main.hs b/testsuite/makewith/tiny/prog/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/tiny/prog/Main.hs
+++ /dev/null
@@ -1,21 +0,0 @@
-
-import System.Plugins
-import API
-import Data.Either
-
-conf    = "../Tiny.conf"
-stub    = "../Tiny.stub"
-apipath = "../api"
-
-main = do
-        status <- makeWith conf stub ["-i"++apipath]
-        o <- case status of
-                MakeFailure e   -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess _ o -> return o
-        m_v   <- load o [apipath] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        putStrLn $ field v 
-        makeCleaner o
-
diff --git a/testsuite/makewith/tiny/prog/expected b/testsuite/makewith/tiny/prog/expected
deleted file mode 100644
--- a/testsuite/makewith/tiny/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-hello strange world
diff --git a/testsuite/makewith/unsafeio/Makefile b/testsuite/makewith/unsafeio/Makefile
deleted file mode 100644
--- a/testsuite/makewith/unsafeio/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=makewith/unsafeio
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/makewith/unsafeio/README b/testsuite/makewith/unsafeio/README
deleted file mode 100644
--- a/testsuite/makewith/unsafeio/README
+++ /dev/null
@@ -1,3 +0,0 @@
-hmm. on 6.3  we need to add 'mtl' to a package dependency, other
-HSlang complains of a missing symbol. Is this a bug in the
-package.conf for HSlang?
diff --git a/testsuite/makewith/unsafeio/Unsafe.stub b/testsuite/makewith/unsafeio/Unsafe.stub
deleted file mode 100644
--- a/testsuite/makewith/unsafeio/Unsafe.stub
+++ /dev/null
@@ -1,13 +0,0 @@
-
-module Unsafe ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-
-resource = unsafe
-
---
--- special
---
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/makewith/unsafeio/api/API.hs b/testsuite/makewith/unsafeio/api/API.hs
deleted file mode 100644
--- a/testsuite/makewith/unsafeio/api/API.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data Unsafe = Unsafe { 
-                field :: String 
-        }
-   deriving (Typeable, Show)
-
-unsafe :: Unsafe
-unsafe = Unsafe { field = "default value" }
diff --git a/testsuite/makewith/unsafeio/prog/Main.hs b/testsuite/makewith/unsafeio/prog/Main.hs
deleted file mode 100644
--- a/testsuite/makewith/unsafeio/prog/Main.hs
+++ /dev/null
@@ -1,20 +0,0 @@
-import System.Plugins
-import API
-import Data.Either
-
-conf    = "../Unsafe.conf"
-stub    = "../Unsafe.stub"
-apipath = "../api"
-
-main = do
-        status <- makeWith conf stub ["-i"++apipath]
-        o <- case status of
-                MakeFailure e -> mapM_ putStrLn e >> error "failed"
-                MakeSuccess _ o -> return o
-        m_v   <- load o [apipath] [] "resource"
-        v <- case m_v of
-            LoadSuccess _ v -> return v
-            _               -> error "load failed"
-        let s = field v
-        makeCleaner o
-        if null s then print False else print True
diff --git a/testsuite/makewith/unsafeio/prog/README b/testsuite/makewith/unsafeio/prog/README
deleted file mode 100644
--- a/testsuite/makewith/unsafeio/prog/README
+++ /dev/null
@@ -1,8 +0,0 @@
-this is an example of an application that uses the HSConf library to
-dynamically load compiled conf files.
-
-We use the .conf file in the parent directory, and communicate with
-the plugin via the API in the api_package/ directory.
-
-The plugin is a .o file
-The api is a GHC package archive
diff --git a/testsuite/makewith/unsafeio/prog/expected b/testsuite/makewith/unsafeio/prog/expected
deleted file mode 100644
--- a/testsuite/makewith/unsafeio/prog/expected
+++ /dev/null
@@ -1,6 +0,0 @@
-merge failed:
-
-parse error in ../Unsafe.conf
-line: 13, col: 1
-
-Main: failed
diff --git a/testsuite/misc/mkstemps/Main.hs b/testsuite/misc/mkstemps/Main.hs
deleted file mode 100644
--- a/testsuite/misc/mkstemps/Main.hs
+++ /dev/null
@@ -1,69 +0,0 @@
- 
-import System.MkTemp
-
-import Data.Maybe
-
-import System.IO
-import System.Directory
-
-main = do
-        createDirectory "t"
-
-        ------------------------------------------------------------------------
-        -- Try mkstemp with simple template
-        --
-        ts <- mapM (\_ -> mkstemp "t/t.X" ) [0..(26+26)] -- 1+26+26 files
-        () <- if (not $ all isJust ts)
-              then putStrLn $ "mkstemp couldn't create all expected files"
-              else putStrLn $ "created "++(show $ length $ catMaybes ts)++" files"
-        closeAll ts
-
-        -- next one shouldn't be possible
-        t <- mkstemp "t/t.X"
-        () <- if (not $ isNothing t)
-              then putStrLn $ "shouldn't have been able to create this file"
-              else putStrLn $ "correctly ran out of permutations"
-        closeAll [t]
-
-        rmAll (t:ts)
-
-        ------------------------------------------------------------------------
-        -- Try again with large tmp
-        --
-        ts <- mapM (\_->do v <- mkstemp "t/t.XXXXXXXXXX" 
-                           case v of Just (t,h) -> hClose h >> return v
-                                     _ -> return v ) [1..10000]
-
-        () <- if (not $ all isJust ts)
-              then putStrLn $ "mkstemp couldn't create all expected files"
-              else putStrLn $ "mkstemp: created "++(show $ length $ catMaybes ts)++" files"
-        rmAll ts
-
-        ------------------------------------------------------------------------
-        -- test mkstemps
-        --
-        ts <- mapM (\_->do v <- mkstemps "t/t.XXXXXXXXXX.hs" 3
-                           case v of Just (t,h) -> hClose h >> return v
-                                     _ -> return v ) [1..2000]
-        () <- if (not $ all isJust ts)
-              then putStrLn $ "mkstemps couldn't create all expected files"
-              else putStrLn $ "mkstemps: created "++(show $ length $ catMaybes ts)++" files"
-        rmAll ts
-
-        ------------------------------------------------------------------------
-        -- mkdtemp
-        --
-        ts <- mapM (\_ -> mkdtemp "t/XXXXXXXXXX") [1..2000]
-        () <- if (not $ all isJust ts)
-              then putStrLn $ "mkdtemp: couldn't create all expected directories"
-              else putStrLn $ "mkdtemp: created "++(show $ length $ catMaybes ts)++" directories"
-        rmAllDirs ts
-    
-        ------------------------------------------------------------------------
-
-        removeDirectory "t"
-
-    where
-        closeAll  ts = mapM_ hClose $ map snd $ catMaybes ts
-        rmAll     ts = mapM_ removeFile $ map fst $ catMaybes ts
-        rmAllDirs ts = mapM_ removeDirectory $ catMaybes ts
diff --git a/testsuite/misc/mkstemps/Makefile b/testsuite/misc/mkstemps/Makefile
deleted file mode 100644
--- a/testsuite/misc/mkstemps/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/misc/mkstemps/expected b/testsuite/misc/mkstemps/expected
deleted file mode 100644
--- a/testsuite/misc/mkstemps/expected
+++ /dev/null
@@ -1,5 +0,0 @@
-created 53 files
-correctly ran out of permutations
-mkstemp: created 10000 files
-mkstemps: created 2000 files
-mkdtemp: created 2000 directories
diff --git a/testsuite/multi/3plugins/Makefile b/testsuite/multi/3plugins/Makefile
deleted file mode 100644
--- a/testsuite/multi/3plugins/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-TEST=   multi/3plugins
-
-EXTRA_OBJS=Plugin1.o  Plugin2.o  Plugin3.o
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/multi/3plugins/Plugin1.hs b/testsuite/multi/3plugins/Plugin1.hs
deleted file mode 100644
--- a/testsuite/multi/3plugins/Plugin1.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module Plugin1 where
-
-import API
-import Data.Char
-
-resource = plugin {
-        valueOf = map toUpper
-}
diff --git a/testsuite/multi/3plugins/Plugin2.hs b/testsuite/multi/3plugins/Plugin2.hs
deleted file mode 100644
--- a/testsuite/multi/3plugins/Plugin2.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module Plugin2 where
-
-import API
-import Data.Char
-
-resource = plugin {
-        valueOf = \s -> show $ map ord s
-}
-
diff --git a/testsuite/multi/3plugins/Plugin3.hs b/testsuite/multi/3plugins/Plugin3.hs
deleted file mode 100644
--- a/testsuite/multi/3plugins/Plugin3.hs
+++ /dev/null
@@ -1,7 +0,0 @@
-module Plugin3 where
-
-import API
-
-resource = plugin {
-        valueOf = reverse
-}
diff --git a/testsuite/multi/3plugins/api/API.hs b/testsuite/multi/3plugins/api/API.hs
deleted file mode 100644
--- a/testsuite/multi/3plugins/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module API where
-
-data Interface = Interface { 
-        valueOf :: String -> String 
-}
-
-plugin :: Interface 
-plugin = Interface { valueOf = id }
-
diff --git a/testsuite/multi/3plugins/prog/Main.hs b/testsuite/multi/3plugins/prog/Main.hs
deleted file mode 100644
--- a/testsuite/multi/3plugins/prog/Main.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-import System.Plugins
-import API
-
-main = do
-        let plist = ["../Plugin1.o", "../Plugin2.o", "../Plugin3.o"]
-        plugins <- mapM (\p -> load p ["../api"] [] "resource") plist
-        let functions = map (valueOf . fromLoadSuc) plugins
-
-        -- apply the function from each plugin in turn
-        mapM_ (\f -> putStrLn $ f "haskell is for hackers") functions
-
-fromLoadSuc (LoadFailure _)   = error "load failed"
-fromLoadSuc (LoadSuccess _ v) = v
diff --git a/testsuite/multi/3plugins/prog/expected b/testsuite/multi/3plugins/prog/expected
deleted file mode 100644
--- a/testsuite/multi/3plugins/prog/expected
+++ /dev/null
@@ -1,3 +0,0 @@
-HASKELL IS FOR HACKERS
-[104,97,115,107,101,108,108,32,105,115,32,102,111,114,32,104,97,99,107,101,114,115]
-srekcah rof si lleksah
diff --git a/testsuite/objc/expression_parser/ArithmeticExpressionParser.hs b/testsuite/objc/expression_parser/ArithmeticExpressionParser.hs
deleted file mode 100644
--- a/testsuite/objc/expression_parser/ArithmeticExpressionParser.hs
+++ /dev/null
@@ -1,30 +0,0 @@
-module ArithmeticExpressionParser where
-
-import Text.ParserCombinators.Parsec
-import Text.ParserCombinators.Parsec.Expr
-
-resource :: String -> IO String
-resource text = do
-  parsedText <- mapM parseString (lines text)
-  return (unlines parsedText)
-
-parseString s = do
-  case (parse expr "" s) of
-    Left err -> return ("Error " ++ show err)
-    Right num -> return (show num)
-
-expr :: Parser Integer
-expr = buildExpressionParser table factor <?> "expression"
-
-table = [ [op "*" (*) AssocLeft, op "/" div AssocLeft]
-        , [op "+" (+) AssocLeft, op "-" (-) AssocLeft] ]
-  where
-    op s f assoc = Infix (do { string s; return f }) assoc
-
-factor = do { char '('; x <- expr; char ')'; return x }
-         <|> number
-         <?> "simple expression"
-
-number :: Parser Integer
-number = do { ds <- many1 digit; return (read ds) } <?> "number"
-
diff --git a/testsuite/objc/expression_parser/English.lproj/Credits.rtf b/testsuite/objc/expression_parser/English.lproj/Credits.rtf
deleted file mode 100644
--- a/testsuite/objc/expression_parser/English.lproj/Credits.rtf
+++ /dev/null
@@ -1,29 +0,0 @@
-{\rtf0\ansi{\fonttbl\f0\fswiss Helvetica;}
-{\colortbl;\red255\green255\blue255;}
-\paperw9840\paperh8400
-\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural
-
-\f0\b\fs24 \cf0 Engineering:
-\b0 \
-	Some people\
-\
-
-\b Human Interface Design:
-\b0 \
-	Some other people\
-\
-
-\b Testing:
-\b0 \
-	Hopefully not nobody\
-\
-
-\b Documentation:
-\b0 \
-	Whoever\
-\
-
-\b With special thanks to:
-\b0 \
-	Mom\
-}
diff --git a/testsuite/objc/expression_parser/English.lproj/InfoPlist.strings b/testsuite/objc/expression_parser/English.lproj/InfoPlist.strings
deleted file mode 100644
Binary files a/testsuite/objc/expression_parser/English.lproj/InfoPlist.strings and /dev/null differ
diff --git a/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/classes.nib b/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/classes.nib
deleted file mode 100644
--- a/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/classes.nib
+++ /dev/null
@@ -1,4 +0,0 @@
-{
-    IBClasses = ({CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }); 
-    IBVersion = 1; 
-}
diff --git a/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/info.nib b/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/info.nib
deleted file mode 100644
--- a/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/info.nib
+++ /dev/null
@@ -1,21 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>IBDocumentLocation</key>
-	<string>116 123 356 240 0 0 1600 1178 </string>
-	<key>IBEditorPositions</key>
-	<dict>
-		<key>29</key>
-		<string>117 405 318 44 0 0 1600 1178 </string>
-	</dict>
-	<key>IBFramework Version</key>
-	<string>328.0</string>
-	<key>IBOpenObjects</key>
-	<array>
-		<integer>29</integer>
-	</array>
-	<key>IBSystem Version</key>
-	<string>7B8</string>
-</dict>
-</plist>
diff --git a/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/objects.nib b/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/objects.nib
deleted file mode 100644
Binary files a/testsuite/objc/expression_parser/English.lproj/MainMenu.nib/objects.nib and /dev/null differ
diff --git a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/classes.nib b/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/classes.nib
deleted file mode 100644
--- a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/classes.nib
+++ /dev/null
@@ -1,13 +0,0 @@
-{
-    IBClasses = (
-        {CLASS = FirstResponder; LANGUAGE = ObjC; SUPERCLASS = NSObject; }, 
-        {
-            ACTIONS = {chooseParser = id; evaluateExpression = id; }; 
-            CLASS = MyDocument; 
-            LANGUAGE = ObjC; 
-            OUTLETS = {evaluation = id; expressionEntry = id; parser = id; }; 
-            SUPERCLASS = NSDocument; 
-        }
-    ); 
-    IBVersion = 1; 
-}
diff --git a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/info.nib b/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/info.nib
deleted file mode 100644
--- a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/info.nib
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>IBDocumentLocation</key>
-	<string>79 43 356 240 0 0 1280 832 </string>
-	<key>IBFramework Version</key>
-	<string>349.0</string>
-	<key>IBOpenObjects</key>
-	<array>
-		<integer>21</integer>
-	</array>
-	<key>IBSystem Version</key>
-	<string>7F44</string>
-</dict>
-</plist>
diff --git a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/keyedobjects.nib b/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/keyedobjects.nib
deleted file mode 100644
Binary files a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/keyedobjects.nib and /dev/null differ
diff --git a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/objects.nib b/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/objects.nib
deleted file mode 100644
Binary files a/testsuite/objc/expression_parser/English.lproj/MyDocument.nib/objects.nib and /dev/null differ
diff --git a/testsuite/objc/expression_parser/Info.plist b/testsuite/objc/expression_parser/Info.plist
deleted file mode 100644
--- a/testsuite/objc/expression_parser/Info.plist
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>CFBundleDevelopmentRegion</key>
-	<string>English</string>
-	<key>CFBundleDocumentTypes</key>
-	<array>
-		<dict>
-			<key>CFBundleTypeExtensions</key>
-			<array>
-				<string>????</string>
-			</array>
-			<key>CFBundleTypeIconFile</key>
-			<string></string>
-			<key>CFBundleTypeName</key>
-			<string>DocumentType</string>
-			<key>CFBundleTypeOSTypes</key>
-			<array>
-				<string>????</string>
-			</array>
-			<key>CFBundleTypeRole</key>
-			<string>Editor</string>
-			<key>NSDocumentClass</key>
-			<string>MyDocument</string>
-		</dict>
-	</array>
-	<key>CFBundleExecutable</key>
-	<string>PluginExpressionParser</string>
-	<key>CFBundleIconFile</key>
-	<string></string>
-	<key>CFBundleIdentifier</key>
-	<string>com.apple.yourCocoaDocApp</string>
-	<key>CFBundleInfoDictionaryVersion</key>
-	<string>6.0</string>
-	<key>CFBundlePackageType</key>
-	<string>APPL</string>
-	<key>CFBundleSignature</key>
-	<string>????</string>
-	<key>CFBundleVersion</key>
-	<string>0.1</string>
-	<key>NSMainNibFile</key>
-	<string>MainMenu</string>
-	<key>NSPrincipalClass</key>
-	<string>NSApplication</string>
-</dict>
-</plist>
diff --git a/testsuite/objc/expression_parser/KeyValueParser.hs b/testsuite/objc/expression_parser/KeyValueParser.hs
deleted file mode 100644
--- a/testsuite/objc/expression_parser/KeyValueParser.hs
+++ /dev/null
@@ -1,33 +0,0 @@
-module KeyValueParser where
-
-import Text.ParserCombinators.Parsec
-
-parseKeyValue = do
-  key <- parseKey
-  char '='
-  value <- parseValue
-  return (key, value)
-
-parseKey = many1 letter
-
-parseValue =
-  do
-    openQuote <- char '"' <|> char '\''
-    value <- many1 letter
-    char openQuote
-    return value
-  <|>
-  do
-    value <- many1 letter
-    return value
-
-parseString s = do
-  case (parse parseKeyValue "" s) of
-    Left err -> return ("Error " ++ show err)
-    Right (key, value) -> return ("Key: " ++ key ++ ", Value: " ++ value)
-
-resource :: String -> IO String
-resource text = do
-  parsedText <- mapM parseString (lines text)
-  return (unlines parsedText)
-
diff --git a/testsuite/objc/expression_parser/Makefile b/testsuite/objc/expression_parser/Makefile
deleted file mode 100644
--- a/testsuite/objc/expression_parser/Makefile
+++ /dev/null
@@ -1,67 +0,0 @@
-APP_DIR = build/PluginExpressionParser.app
-APP_CONTENTS_DIR = $(APP_DIR)/Contents
-APP_ARCH_EXEC_DIR = $(APP_CONTENTS_DIR)/MacOS
-APP_RESOURCES_DIR = $(APP_CONTENTS_DIR)/Resources
-EXECUTABLE = $(APP_ARCH_EXEC_DIR)/PluginExpressionParser
-
-OBJECT_FILES = main.o MyDocument.o PluginEvalAux.o
-BUILD_OBJECT_FILES = $(addprefix build/,$(OBJECT_FILES)) \
-		     build/PluginEvalAux_stub.o
-
-HOST = $(shell uname)
-
-ifeq ($(HOST),Darwin)
-default: app
-else
-default: no_app
-endif
-
-app: $(APP_CONTENTS_DIR) $(APP_RESOURCES_DIR) $(EXECUTABLE)
-
-#
-
-$(EXECUTABLE): $(APP_ARCH_EXEC_DIR) $(BUILD_OBJECT_FILES)
-	ghc \
-	  -o "$(EXECUTABLE)" \
-	  -framework Cocoa \
-	  -package-conf ../../../plugins.conf.inplace \
-	  -package plugins \
-	  -no-hs-main \
-	  $(BUILD_OBJECT_FILES)
-
-build/MyDocument.o: MyDocument.m MyDocument.h
-	gcc -c -o "$@" -Wall -I`ghc --print-libdir`/include "$<"
-
-build/main.o: main.m
-	gcc -c -o "$@" -Wall -I`ghc --print-libdir`/include "$<"
-
-build/PluginEvalAux.o: PluginEvalAux.hs
-	ghc --make \
-	  -package-conf ../../../plugins.conf.inplace \
-	  -package plugins \
-	  -odir build/ \
-	  -hidir build/ \
-	  "$<"
-
-#
-
-$(APP_DIR):
-	mkdir -p "$@"
-
-$(APP_ARCH_EXEC_DIR): $(APP_DIR)
-	mkdir -p "$@"
-
-$(APP_CONTENTS_DIR): $(APP_DIR) Info.plist
-	mkdir -p "$(APP_CONTENTS_DIR)"
-	cp Info.plist "$@"
-	echo -n 'APPL????' > "$@"/PkgInfo
-
-$(APP_RESOURCES_DIR): $(APP_DIR) English.lproj
-	mkdir -p "$(APP_RESOURCES_DIR)"
-	cp -R English.lproj "$@"
-
-#
-
-clean:
-	-rm -rf build *_stub.?
-
diff --git a/testsuite/objc/expression_parser/MyDocument.h b/testsuite/objc/expression_parser/MyDocument.h
deleted file mode 100644
--- a/testsuite/objc/expression_parser/MyDocument.h
+++ /dev/null
@@ -1,16 +0,0 @@
-/* MyDocument */
-
-#import <Cocoa/Cocoa.h>
-
-#include "RunHaskell.h"
-
-@interface MyDocument : NSDocument
-{
-    IBOutlet id evaluation;
-    IBOutlet id expressionEntry;
-    IBOutlet id parser;
-}
-- (IBAction)chooseParser:(id)sender;
-- (IBAction)evaluateExpression:(id)sender;
-
-@end
diff --git a/testsuite/objc/expression_parser/MyDocument.m b/testsuite/objc/expression_parser/MyDocument.m
deleted file mode 100644
--- a/testsuite/objc/expression_parser/MyDocument.m
+++ /dev/null
@@ -1,52 +0,0 @@
-#import "MyDocument.h"
-
-@implementation MyDocument
-
-- (NSString *)windowNibName {
-    return @"MyDocument";
-}
-
-- (NSData *)dataRepresentationOfType:(NSString *)type {
-    return nil;
-}
-
-- (BOOL)loadDataRepresentation:(NSData *)data ofType:(NSString *)type {
-    return NO;
-}
-
-
-- (IBAction)chooseParser:(id)sender
-{
-    int result;
-    NSArray *fileTypes = [NSArray arrayWithObject:@"hs"];
-    NSOpenPanel *oPanel = [NSOpenPanel openPanel];
-    
-    result = [oPanel runModalForDirectory:nil file:nil types:fileTypes];
-    if (result == NSOKButton)
-    {
-        NSArray *filesToOpen = [oPanel filenames];
-        [parser setStringValue:[filesToOpen objectAtIndex:0]];
-    }
-}
-
-- (IBAction)evaluateExpression:(id)sender
-{
-    NSLog(@"evaluateExpression");
-    NSString *filePathNSS = [parser stringValue];
-    char *filePath = [filePathNSS cString];
-    
-    NSString *expressionNSS = [[expressionEntry textStorage] string];
-    char *expression = [expressionNSS cString];
-    
-    NSLog (@"filePath:%s expression:%s", filePath, expression);
-    
-    char *result = evalhaskell_CString(filePath, expression);
-    NSString *resultNSS = [NSString stringWithCString:result];
-    NSAttributedString *resultNSAS = [[NSAttributedString alloc]
-	                              initWithString:resultNSS
-				          attributes:nil];
-    [[evaluation textStorage] setAttributedString:resultNSAS];
-
-}
-
-@end
diff --git a/testsuite/objc/expression_parser/PluginEvalAux.hs b/testsuite/objc/expression_parser/PluginEvalAux.hs
deleted file mode 100644
--- a/testsuite/objc/expression_parser/PluginEvalAux.hs
+++ /dev/null
@@ -1,43 +0,0 @@
-{-# OPTIONS -fglasgow-exts -fffi #-}
-
-module PluginEvalAux where
-
-import System.Plugins.Make
-import System.Plugins.Load
-import System.Plugins.Utils
-
-import Foreign.C
-import Control.Exception        ( evaluate )
-import System.IO
-import System.Directory         ( renameFile, removeFile )
-
-symbol = "resource"
-
-evalWithStringResult :: FilePath -> String -> IO String
-evalWithStringResult srcFile s = do
-  status <- make srcFile ["-O0"]
-  case status of
-      MakeFailure err   -> putStrLn "error occured" >> return (show err)
-      MakeSuccess _ obj -> load' obj
-  where
-    load' obj = do
-      loadResult <- load obj [] [] symbol
-      case loadResult of
-        LoadFailure errs -> putStrLn "load error" >> return (show errs)
-	LoadSuccess m (rsrc :: String -> IO String) -> do
-	  v' <- rsrc s
-	  unload m
-	  mapM_ removeFile [ obj, replaceSuffix obj ".hi" ]
-	  return v'
-
-foreign export ccall evalhaskell_CString :: CString -> CString -> IO CString
-
-evalhaskell_CString :: CString -> CString -> IO CString
-evalhaskell_CString filePathCS sCS = do
-  s <- peekCString sCS
-  filePath <- peekCString filePathCS
-  retval <- evalWithStringResult filePath s
-  newCString retval
-
--- vi:sw=2 sts=2
-
diff --git a/testsuite/objc/expression_parser/PluginExpressionParser.xcode/project.pbxproj b/testsuite/objc/expression_parser/PluginExpressionParser.xcode/project.pbxproj
deleted file mode 100644
--- a/testsuite/objc/expression_parser/PluginExpressionParser.xcode/project.pbxproj
+++ /dev/null
@@ -1,602 +0,0 @@
-// !$*UTF8*$!
-{
-	archiveVersion = 1;
-	classes = {
-	};
-	objectVersion = 39;
-	objects = {
-		089C165FFE840EACC02AAC07 = {
-			children = (
-				089C1660FE840EACC02AAC07,
-			);
-			isa = PBXVariantGroup;
-			name = InfoPlist.strings;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		089C1660FE840EACC02AAC07 = {
-			fileEncoding = 10;
-			isa = PBXFileReference;
-			lastKnownFileType = text.plist.strings;
-			name = English;
-			path = English.lproj/InfoPlist.strings;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-//080
-//081
-//082
-//083
-//084
-//100
-//101
-//102
-//103
-//104
-		1058C7A6FEA54F5311CA2CBB = {
-			children = (
-				1058C7A7FEA54F5311CA2CBB,
-			);
-			isa = PBXGroup;
-			name = "Linked Frameworks";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		1058C7A7FEA54F5311CA2CBB = {
-			fallbackIsa = PBXFileReference;
-			isa = PBXFrameworkReference;
-			lastKnownFileType = wrapper.framework;
-			name = Cocoa.framework;
-			path = /System/Library/Frameworks/Cocoa.framework;
-			refType = 0;
-			sourceTree = "<absolute>";
-		};
-		1058C7A8FEA54F5311CA2CBB = {
-			children = (
-				2A37F4C5FDCFA73011CA2CEA,
-				2A37F4C4FDCFA73011CA2CEA,
-			);
-			isa = PBXGroup;
-			name = "Other Frameworks";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-//100
-//101
-//102
-//103
-//104
-//190
-//191
-//192
-//193
-//194
-		19C28FB0FE9D524F11CA2CBB = {
-			children = (
-				8D15AC370486D014006FF6A4,
-			);
-			isa = PBXGroup;
-			name = Products;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-//190
-//191
-//192
-//193
-//194
-//2A0
-//2A1
-//2A2
-//2A3
-//2A4
-		2A37F4A9FDCFA73011CA2CEA = {
-			buildSettings = {
-			};
-			buildStyles = (
-				4A9504D0FFE6A4CB11CA0CBA,
-				4A9504D1FFE6A4CB11CA0CBA,
-			);
-			hasScannedForEncodings = 1;
-			isa = PBXProject;
-			mainGroup = 2A37F4AAFDCFA73011CA2CEA;
-			projectDirPath = "";
-			targets = (
-				8D15AC270486D014006FF6A4,
-				7B5F81A4067389B000AC9FA4,
-			);
-		};
-		2A37F4AAFDCFA73011CA2CEA = {
-			children = (
-				7B5F81A1067383A700AC9FA4,
-				7B5F81980673839D00AC9FA4,
-				2A37F4ABFDCFA73011CA2CEA,
-				2A37F4AFFDCFA73011CA2CEA,
-				2A37F4B8FDCFA73011CA2CEA,
-				2A37F4C3FDCFA73011CA2CEA,
-				19C28FB0FE9D524F11CA2CBB,
-			);
-			isa = PBXGroup;
-			name = PluginExpressionParser;
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4ABFDCFA73011CA2CEA = {
-			children = (
-				2A37F4AEFDCFA73011CA2CEA,
-				2A37F4ACFDCFA73011CA2CEA,
-			);
-			isa = PBXGroup;
-			name = Classes;
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4ACFDCFA73011CA2CEA = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.c.objc;
-			path = MyDocument.m;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4AEFDCFA73011CA2CEA = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.c.h;
-			path = MyDocument.h;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4AFFDCFA73011CA2CEA = {
-			children = (
-				7B5F81990673839D00AC9FA4,
-				32DBCF750370BD2300C91783,
-				7B5F819506737AAC00AC9FA4,
-				2A37F4B0FDCFA73011CA2CEA,
-			);
-			isa = PBXGroup;
-			name = "Other Sources";
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4B0FDCFA73011CA2CEA = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.c.objc;
-			path = main.m;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4B4FDCFA73011CA2CEA = {
-			children = (
-				2A37F4B5FDCFA73011CA2CEA,
-			);
-			isa = PBXVariantGroup;
-			name = MyDocument.nib;
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4B5FDCFA73011CA2CEA = {
-			isa = PBXFileReference;
-			lastKnownFileType = wrapper.nib;
-			name = English;
-			path = English.lproj/MyDocument.nib;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4B6FDCFA73011CA2CEA = {
-			children = (
-				2A37F4B7FDCFA73011CA2CEA,
-			);
-			isa = PBXVariantGroup;
-			name = MainMenu.nib;
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4B7FDCFA73011CA2CEA = {
-			isa = PBXFileReference;
-			lastKnownFileType = wrapper.nib;
-			name = English;
-			path = English.lproj/MainMenu.nib;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4B8FDCFA73011CA2CEA = {
-			children = (
-				2A37F4B9FDCFA73011CA2CEA,
-				2A37F4B6FDCFA73011CA2CEA,
-				2A37F4B4FDCFA73011CA2CEA,
-				8D15AC360486D014006FF6A4,
-				089C165FFE840EACC02AAC07,
-			);
-			isa = PBXGroup;
-			name = Resources;
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4B9FDCFA73011CA2CEA = {
-			children = (
-				2A37F4BAFDCFA73011CA2CEA,
-			);
-			isa = PBXVariantGroup;
-			name = Credits.rtf;
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4BAFDCFA73011CA2CEA = {
-			isa = PBXFileReference;
-			lastKnownFileType = text.rtf;
-			name = English;
-			path = English.lproj/Credits.rtf;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4C3FDCFA73011CA2CEA = {
-			children = (
-				1058C7A6FEA54F5311CA2CBB,
-				1058C7A8FEA54F5311CA2CBB,
-			);
-			isa = PBXGroup;
-			name = Frameworks;
-			path = "";
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		2A37F4C4FDCFA73011CA2CEA = {
-			fallbackIsa = PBXFileReference;
-			isa = PBXFrameworkReference;
-			lastKnownFileType = wrapper.framework;
-			name = AppKit.framework;
-			path = /System/Library/Frameworks/AppKit.framework;
-			refType = 0;
-			sourceTree = "<absolute>";
-		};
-		2A37F4C5FDCFA73011CA2CEA = {
-			fallbackIsa = PBXFileReference;
-			isa = PBXFrameworkReference;
-			lastKnownFileType = wrapper.framework;
-			name = Foundation.framework;
-			path = /System/Library/Frameworks/Foundation.framework;
-			refType = 0;
-			sourceTree = "<absolute>";
-		};
-//2A0
-//2A1
-//2A2
-//2A3
-//2A4
-//320
-//321
-//322
-//323
-//324
-		32DBCF750370BD2300C91783 = {
-			fileEncoding = 4;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.c.h;
-			path = PluginExpressionParser_Prefix.pch;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-//320
-//321
-//322
-//323
-//324
-//4A0
-//4A1
-//4A2
-//4A3
-//4A4
-		4A9504D0FFE6A4CB11CA0CBA = {
-			buildRules = (
-			);
-			buildSettings = {
-				COPY_PHASE_STRIP = NO;
-				DEBUGGING_SYMBOLS = YES;
-				GCC_DYNAMIC_NO_PIC = NO;
-				GCC_ENABLE_FIX_AND_CONTINUE = YES;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = YES;
-				GCC_OPTIMIZATION_LEVEL = 0;
-				OPTIMIZATION_CFLAGS = "-O0";
-				ZERO_LINK = YES;
-			};
-			isa = PBXBuildStyle;
-			name = Development;
-		};
-		4A9504D1FFE6A4CB11CA0CBA = {
-			buildRules = (
-			);
-			buildSettings = {
-				COPY_PHASE_STRIP = YES;
-				GCC_ENABLE_FIX_AND_CONTINUE = NO;
-				ZERO_LINK = NO;
-			};
-			isa = PBXBuildStyle;
-			name = Deployment;
-		};
-//4A0
-//4A1
-//4A2
-//4A3
-//4A4
-//7B0
-//7B1
-//7B2
-//7B3
-//7B4
-		7B5F819506737AAC00AC9FA4 = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.c.h;
-			path = RunHaskell.h;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		7B5F819606737AAC00AC9FA4 = {
-			fileRef = 7B5F819506737AAC00AC9FA4;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		7B5F81970673839D00AC9FA4 = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.haskell;
-			path = KeyValueParser.hs;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		7B5F81980673839D00AC9FA4 = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.make;
-			path = Makefile;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		7B5F81990673839D00AC9FA4 = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.haskell;
-			path = PluginEvalAux.hs;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		7B5F819A0673839D00AC9FA4 = {
-			fileRef = 7B5F81970673839D00AC9FA4;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		7B5F819B0673839D00AC9FA4 = {
-			fileRef = 7B5F81980673839D00AC9FA4;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		7B5F819C0673839D00AC9FA4 = {
-			fileRef = 7B5F81990673839D00AC9FA4;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		7B5F819D067383A400AC9FA4 = {
-			fileEncoding = 30;
-			isa = PBXFileReference;
-			lastKnownFileType = sourcecode.haskell;
-			path = ArithmeticExpressionParser.hs;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		7B5F819E067383A400AC9FA4 = {
-			fileRef = 7B5F819D067383A400AC9FA4;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		7B5F81A1067383A700AC9FA4 = {
-			children = (
-				7B5F819D067383A400AC9FA4,
-				7B5F81970673839D00AC9FA4,
-			);
-			isa = PBXGroup;
-			name = Parsers;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		7B5F81A4067389B000AC9FA4 = {
-			buildArgumentsString = "$(ACTION)";
-			buildPhases = (
-			);
-			buildSettings = {
-				OPTIMIZATION_CFLAGS = "";
-				OTHER_CFLAGS = "";
-				OTHER_LDFLAGS = "";
-				OTHER_REZFLAGS = "";
-				PRODUCT_NAME = "PluginExpressionParser (GNU make)";
-				SECTORDER_FLAGS = "";
-				WARNING_CFLAGS = "-Wmost -Wno-four-char-constants -Wno-unknown-pragmas";
-			};
-			buildToolPath = /usr/bin/make;
-			dependencies = (
-			);
-			isa = PBXLegacyTarget;
-			name = "PluginExpressionParser (GNU make)";
-			passBuildSettingsInEnvironment = 1;
-			productName = "PluginExpressionParser (GNU make)";
-		};
-//7B0
-//7B1
-//7B2
-//7B3
-//7B4
-//8D0
-//8D1
-//8D2
-//8D3
-//8D4
-		8D15AC270486D014006FF6A4 = {
-			buildPhases = (
-				8D15AC280486D014006FF6A4,
-				8D15AC2B0486D014006FF6A4,
-				8D15AC300486D014006FF6A4,
-				8D15AC330486D014006FF6A4,
-			);
-			buildRules = (
-			);
-			buildSettings = {
-				FRAMEWORK_SEARCH_PATHS = "";
-				GCC_ENABLE_TRIGRAPHS = NO;
-				GCC_GENERATE_DEBUGGING_SYMBOLS = NO;
-				GCC_PRECOMPILE_PREFIX_HEADER = YES;
-				GCC_PREFIX_HEADER = PluginExpressionParser_Prefix.pch;
-				GCC_WARN_ABOUT_MISSING_PROTOTYPES = NO;
-				GCC_WARN_FOUR_CHARACTER_CONSTANTS = NO;
-				GCC_WARN_UNKNOWN_PRAGMAS = NO;
-				HEADER_SEARCH_PATHS = "";
-				INFOPLIST_FILE = Info.plist;
-				INSTALL_PATH = "$(HOME)/Applications";
-				LIBRARY_SEARCH_PATHS = "";
-				OTHER_CFLAGS = "";
-				OTHER_LDFLAGS = "";
-				PRODUCT_NAME = PluginExpressionParser;
-				SECTORDER_FLAGS = "";
-				WARNING_CFLAGS = "-Wmost -Wno-four-char-constants -Wno-unknown-pragmas";
-				WRAPPER_EXTENSION = app;
-			};
-			dependencies = (
-			);
-			isa = PBXNativeTarget;
-			name = PluginExpressionParser;
-			productInstallPath = "$(HOME)/Applications";
-			productName = PluginExpressionParser;
-			productReference = 8D15AC370486D014006FF6A4;
-			productType = "com.apple.product-type.application";
-		};
-		8D15AC280486D014006FF6A4 = {
-			buildActionMask = 2147483647;
-			files = (
-				8D15AC290486D014006FF6A4,
-				8D15AC2A0486D014006FF6A4,
-				7B5F819606737AAC00AC9FA4,
-			);
-			isa = PBXHeadersBuildPhase;
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-		8D15AC290486D014006FF6A4 = {
-			fileRef = 32DBCF750370BD2300C91783;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		8D15AC2A0486D014006FF6A4 = {
-			fileRef = 2A37F4AEFDCFA73011CA2CEA;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		8D15AC2B0486D014006FF6A4 = {
-			buildActionMask = 2147483647;
-			files = (
-				8D15AC2C0486D014006FF6A4,
-				8D15AC2D0486D014006FF6A4,
-				8D15AC2E0486D014006FF6A4,
-				8D15AC2F0486D014006FF6A4,
-				7B5F819A0673839D00AC9FA4,
-				7B5F819B0673839D00AC9FA4,
-				7B5F819C0673839D00AC9FA4,
-				7B5F819E067383A400AC9FA4,
-			);
-			isa = PBXResourcesBuildPhase;
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-		8D15AC2C0486D014006FF6A4 = {
-			fileRef = 2A37F4B9FDCFA73011CA2CEA;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		8D15AC2D0486D014006FF6A4 = {
-			fileRef = 2A37F4B6FDCFA73011CA2CEA;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		8D15AC2E0486D014006FF6A4 = {
-			fileRef = 2A37F4B4FDCFA73011CA2CEA;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		8D15AC2F0486D014006FF6A4 = {
-			fileRef = 089C165FFE840EACC02AAC07;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		8D15AC300486D014006FF6A4 = {
-			buildActionMask = 2147483647;
-			files = (
-				8D15AC310486D014006FF6A4,
-				8D15AC320486D014006FF6A4,
-			);
-			isa = PBXSourcesBuildPhase;
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-		8D15AC310486D014006FF6A4 = {
-			fileRef = 2A37F4ACFDCFA73011CA2CEA;
-			isa = PBXBuildFile;
-			settings = {
-				ATTRIBUTES = (
-				);
-			};
-		};
-		8D15AC320486D014006FF6A4 = {
-			fileRef = 2A37F4B0FDCFA73011CA2CEA;
-			isa = PBXBuildFile;
-			settings = {
-				ATTRIBUTES = (
-				);
-			};
-		};
-		8D15AC330486D014006FF6A4 = {
-			buildActionMask = 2147483647;
-			files = (
-				8D15AC340486D014006FF6A4,
-			);
-			isa = PBXFrameworksBuildPhase;
-			runOnlyForDeploymentPostprocessing = 0;
-		};
-		8D15AC340486D014006FF6A4 = {
-			fileRef = 1058C7A7FEA54F5311CA2CBB;
-			isa = PBXBuildFile;
-			settings = {
-			};
-		};
-		8D15AC360486D014006FF6A4 = {
-			fileEncoding = 4;
-			isa = PBXFileReference;
-			lastKnownFileType = text.plist;
-			path = Info.plist;
-			refType = 4;
-			sourceTree = "<group>";
-		};
-		8D15AC370486D014006FF6A4 = {
-			explicitFileType = wrapper.application;
-			includeInIndex = 0;
-			isa = PBXFileReference;
-			path = PluginExpressionParser.app;
-			refType = 3;
-			sourceTree = BUILT_PRODUCTS_DIR;
-		};
-	};
-	rootObject = 2A37F4A9FDCFA73011CA2CEA;
-}
diff --git a/testsuite/objc/expression_parser/PluginExpressionParser_Prefix.pch b/testsuite/objc/expression_parser/PluginExpressionParser_Prefix.pch
deleted file mode 100644
--- a/testsuite/objc/expression_parser/PluginExpressionParser_Prefix.pch
+++ /dev/null
@@ -1,7 +0,0 @@
-//
-// Prefix header for all source files of the 'PluginExpressionParser' target in the 'PluginExpressionParser' project
-//
-
-#ifdef __OBJC__
-    #import <Cocoa/Cocoa.h>
-#endif
diff --git a/testsuite/objc/expression_parser/README b/testsuite/objc/expression_parser/README
deleted file mode 100644
--- a/testsuite/objc/expression_parser/README
+++ /dev/null
@@ -1,6 +0,0 @@
-This little application is an example of using hs-plugins to embed a Haskell
-'interpreter' inside an Objective-C, Cocoa-based program.  You will need Mac OS
-X for this to be of any use!
-
-To build it, type 'make', which will build a .app bundle in the build/ directory.  Or, 'open *.xcode', and hit the build button in there.
-
diff --git a/testsuite/objc/expression_parser/RunHaskell.h b/testsuite/objc/expression_parser/RunHaskell.h
deleted file mode 100644
--- a/testsuite/objc/expression_parser/RunHaskell.h
+++ /dev/null
@@ -1,4 +0,0 @@
-#include "HsFFI.h"
-
-extern HsPtr evalhaskell_CString(HsPtr a1, HsPtr a2);
-
diff --git a/testsuite/objc/expression_parser/dont_test b/testsuite/objc/expression_parser/dont_test
deleted file mode 100644
--- a/testsuite/objc/expression_parser/dont_test
+++ /dev/null
diff --git a/testsuite/objc/expression_parser/main.m b/testsuite/objc/expression_parser/main.m
deleted file mode 100644
--- a/testsuite/objc/expression_parser/main.m
+++ /dev/null
@@ -1,26 +0,0 @@
-//
-//  main.m
-//  PluginExpressionParser
-//
-//  Created by Andr Pang on Mon Jun 07 2004.
-//  Copyright (c) 2004 __MyCompanyName__. All rights reserved.
-//
-
-#import <Cocoa/Cocoa.h>
-
-#include "HsFFI.h"
-
-extern void __stginit_PluginEvalAux (void);
-
-int main(int argc, char *argv[])
-{
-    hs_init(&argc, &argv);
-    hs_add_root(__stginit_PluginEvalAux);
-    const char *c_argv = (const char *) argv;
-    int retval = NSApplicationMain(argc, &c_argv);
-    hs_exit();
-    return retval;
-}
-
-/* vi:sw=4 */
-
diff --git a/testsuite/objc/expression_parser/version.plist b/testsuite/objc/expression_parser/version.plist
deleted file mode 100644
--- a/testsuite/objc/expression_parser/version.plist
+++ /dev/null
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
-<plist version="1.0">
-<dict>
-	<key>BuildVersion</key>
-	<string>17</string>
-	<key>CFBundleShortVersionString</key>
-	<string>0.1</string>
-	<key>CFBundleVersion</key>
-	<string>0.1</string>
-	<key>ProjectName</key>
-	<string>NibPBTemplates</string>
-	<key>SourceVersion</key>
-	<string>1150000</string>
-</dict>
-</plist>
diff --git a/testsuite/pdynload/badint/Makefile b/testsuite/pdynload/badint/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/badint/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=pdynload/badint
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/badint/Plugin.hs b/testsuite/pdynload/badint/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/badint/Plugin.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Plugin where
-
-resource :: Num t => t
-resource = 0xBAD
diff --git a/testsuite/pdynload/badint/api/API.hs b/testsuite/pdynload/badint/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/badint/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module API where
-
-data Interface = Interface { 
-                transform :: String -> String
-     }
-
-rsrc :: Interface
-rsrc = Interface { transform = id }
-
diff --git a/testsuite/pdynload/badint/prog/Main.hs b/testsuite/pdynload/badint/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/badint/prog/Main.hs
+++ /dev/null
@@ -1,18 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e-> mapM_ putStrLn e
-                
-   where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-                case v of
-                  LoadSuccess _ a -> putStrLn $ (transform a) "foo"
-                  _               -> putStrLn "wrong types"
-
diff --git a/testsuite/pdynload/badint/prog/expected b/testsuite/pdynload/badint/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/badint/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-wrong types
diff --git a/testsuite/pdynload/bayley1/Load.hs b/testsuite/pdynload/bayley1/Load.hs
deleted file mode 100644
--- a/testsuite/pdynload/bayley1/Load.hs
+++ /dev/null
@@ -1,42 +0,0 @@
-module Load where
-
-import API
-import System.Plugins
-
---
--- load doesn't seem to behave nicely when using dirname on hier names
---
--- make, and maybe other places, use dirname to work out various names
--- from paths, which is invalid when hier names are used..
---
-
-testload = do
-
-  s  <- make "../Plugin1.hs"     ["-i../api"]
-  o1 <- case s of
-    MakeSuccess _ o -> return o
-    MakeFailure e   -> mapM_ putStrLn e >> fail "o1"
-    
-  s  <- make "../Sub/Plugin2.hs" ["-i../api","-hidir.."] -- !
-  o2 <- case s of
-    MakeSuccess _ o -> return o
-    MakeFailure e   -> mapM_ putStrLn e >> fail "o2"
-
-  fc <- pdynload o1 ["..","../api"] [] "API.PluginAPI" "action"
-
-  case fc of
-    LoadFailure msg -> mapM_ putStrLn msg 
-    LoadSuccess modul proc -> do
-      let ac :: API.PluginAPI; ac = proc
-      let s = proc 42
-      print s
-
-  -- will reqeust  'Plugin2', but module is actually 'Sub.Plugin2'
-  print o2
-  fc <- pdynload (o2) ["..","../api"] [] "API.PluginAPI" "action"
-  case fc of
-    LoadFailure msg -> mapM_ putStrLn msg 
-    LoadSuccess modul proc -> do
-      let ac :: API.PluginAPI; ac = proc
-      let s = proc 42
-      print s
diff --git a/testsuite/pdynload/bayley1/Makefile b/testsuite/pdynload/bayley1/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/bayley1/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=pdynload/bayley1
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/bayley1/Plugin1.hs b/testsuite/pdynload/bayley1/Plugin1.hs
deleted file mode 100644
--- a/testsuite/pdynload/bayley1/Plugin1.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-module Plugin1 where
-
-import qualified API
-action :: API.PluginAPI
-action i = show i
-
diff --git a/testsuite/pdynload/bayley1/Sub/Plugin2.hs b/testsuite/pdynload/bayley1/Sub/Plugin2.hs
deleted file mode 100644
--- a/testsuite/pdynload/bayley1/Sub/Plugin2.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-module Sub.Plugin2 where
-
-import qualified API
-action :: API.PluginAPI
-action i = show i
-
diff --git a/testsuite/pdynload/bayley1/api/API.hs b/testsuite/pdynload/bayley1/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/bayley1/api/API.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-module API where
-
-type PluginAPI = Int -> String
-action :: PluginAPI
-action i = show i
-
diff --git a/testsuite/pdynload/bayley1/prog/Main.hs b/testsuite/pdynload/bayley1/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/bayley1/prog/Main.hs
+++ /dev/null
@@ -1,4 +0,0 @@
-module Main where
-import Load
-main = testload
-
diff --git a/testsuite/pdynload/null/Makefile b/testsuite/pdynload/null/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/null/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-
-TEST=   pdynload/null
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/null/Plugin.hs b/testsuite/pdynload/null/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/null/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-module Plugin where
-
-import API
-
-resource = D 1
diff --git a/testsuite/pdynload/null/api/API.hs b/testsuite/pdynload/null/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/null/api/API.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-
-module API where
-
-data Num t => Interface t = D t
-
diff --git a/testsuite/pdynload/null/prog/Main.hs b/testsuite/pdynload/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/null/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
-import System.Plugins
--- import System.Plugins.Utils
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e-> mapM_ putStrLn e
-
-   where f = do v     <- load "../Plugin.o" ["../api"] [] "resource"
-                --  (i,_) <- exec "ghc" ["--numeric-version"]
-                --  mapM_ putStrLn i
-                putStrLn "done."
-
diff --git a/testsuite/pdynload/null/prog/expected b/testsuite/pdynload/null/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/null/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-done.
diff --git a/testsuite/pdynload/numclass/Makefile b/testsuite/pdynload/numclass/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/numclass/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-
-TEST=   pdynload/numclass
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/numclass/Plugin.hs b/testsuite/pdynload/numclass/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/numclass/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-module Plugin where
-
--- import API
-
-resource = "error"
diff --git a/testsuite/pdynload/numclass/api/API.hs b/testsuite/pdynload/numclass/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/numclass/api/API.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-
-module API where
-
-data Num t => Interface t = D t
-
diff --git a/testsuite/pdynload/numclass/prog/Main.hs b/testsuite/pdynload/numclass/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/numclass/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeFailure _   -> putStrLn "make failed"
-                MakeSuccess _ _ -> do {
-
-       ;v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface Integer" "resource"
-       ;case v of
-          LoadSuccess _ a -> let D i = snd a in putStrLn $ show i
-          _               -> putStrLn "wrong types"
-
-       }
diff --git a/testsuite/pdynload/numclass/prog/expected b/testsuite/pdynload/numclass/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/numclass/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-wrong types
diff --git a/testsuite/pdynload/poly/Makefile b/testsuite/pdynload/poly/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/poly/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=pdynload/poly
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/poly/Plugin.hs b/testsuite/pdynload/poly/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/poly/Plugin.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-module Plugin where
-
-import Data.Typeable
-import Data.Generics.Aliases
-import Data.Generics.Schemes
-
-import API
-
-resource = rsrc { 
-     field = id listify :: Typeable r => (r -> Bool) -> GenericQ [r]
-}
diff --git a/testsuite/pdynload/poly/api/API.hs b/testsuite/pdynload/poly/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/poly/api/API.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
--- a really nasty type:
-
-module API where
-
-import Data.Generics
-
-data Interface = Interface { field :: Typeable r => (r -> Bool) -> GenericQ [r] }
-
-rsrc :: Interface
-rsrc = Interface { field = listify }
-
diff --git a/testsuite/pdynload/poly/prog/Main.hs b/testsuite/pdynload/poly/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/poly/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e   -> mapM_ putStrLn e
-
-  where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-               case v of
-                 LoadSuccess _ a  -> putStrLn "loaded .. yay!"
-                 _                -> putStrLn "wrong types"
diff --git a/testsuite/pdynload/poly/prog/expected b/testsuite/pdynload/poly/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/poly/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-loaded .. yay!
diff --git a/testsuite/pdynload/poly1/Makefile b/testsuite/pdynload/poly1/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/poly1/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   pdynload/poly1
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/poly1/Plugin.hs b/testsuite/pdynload/poly1/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/poly1/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-module Plugin where
-
-import API
-
-resource = plugin { function = (+) }
diff --git a/testsuite/pdynload/poly1/api/API.hs b/testsuite/pdynload/poly1/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/poly1/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module API where
-
-data Interface = Interface { 
-        function :: (Num a) => a -> a -> a
-}
-
-plugin :: Interface
-plugin = Interface  { function = error "no function defined" }
-
diff --git a/testsuite/pdynload/poly1/prog/Main.hs b/testsuite/pdynload/poly1/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/poly1/prog/Main.hs
+++ /dev/null
@@ -1,18 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e -> mapM_ putStrLn e
-
-   where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-                case v of
-                  LoadSuccess _ a -> let fn = function a in putStrLn $ show $ 1 `fn` 2
-                  _               -> putStrLn "wrong types"
-
diff --git a/testsuite/pdynload/poly1/prog/expected b/testsuite/pdynload/poly1/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/poly1/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-3
diff --git a/testsuite/pdynload/should_fail0/Makefile b/testsuite/pdynload/should_fail0/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/should_fail0/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   pdynload/should_fail0
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/should_fail0/Plugin.hs b/testsuite/pdynload/should_fail0/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/should_fail0/Plugin.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module Plugin where
-
-import API
-
-resource = 0xBAD :: Int
-
--- resource = tiny { 
---     field = "hello strange world"
--- }
diff --git a/testsuite/pdynload/should_fail0/api/API.hs b/testsuite/pdynload/should_fail0/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/should_fail0/api/API.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
--- ^ needed to derive Typeable
-
-module API where
-
-import Data.Dynamic
-
-data Interface = Interface { field :: String }
-   deriving (Show)
-
-rsrc :: Interface
-rsrc = Interface { field = "default value" }
-
diff --git a/testsuite/pdynload/should_fail0/prog/Main.hs b/testsuite/pdynload/should_fail0/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/should_fail0/prog/Main.hs
+++ /dev/null
@@ -1,18 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e -> mapM_ putStrLn e
-    where 
-       f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-              case v of
-                LoadSuccess _ a  -> putStrLn "loaded .. yay!"
-                _              -> putStrLn "wrong types"
-
diff --git a/testsuite/pdynload/should_fail0/prog/expected b/testsuite/pdynload/should_fail0/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/should_fail0/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-wrong types
diff --git a/testsuite/pdynload/should_fail1/Makefile b/testsuite/pdynload/should_fail1/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/should_fail1/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-# Missing class constraint... can't do that in Clean
-
-TEST=   pdynload/should_fail1
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/should_fail1/Plugin.hs b/testsuite/pdynload/should_fail1/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/should_fail1/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-module Plugin where
-
-data I = I Int
-
-resource = I 1
diff --git a/testsuite/pdynload/should_fail1/api/API.hs b/testsuite/pdynload/should_fail1/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/should_fail1/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-
-module API where
-
-newtype Interface = I Int
-
-rsrc :: Interface
-rsrc = I 1
-
diff --git a/testsuite/pdynload/should_fail1/prog/Main.hs b/testsuite/pdynload/should_fail1/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/should_fail1/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e -> mapM_ putStrLn e
-
-   where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-                case v of
-                  LoadSuccess _ a -> putStrLn "loaded .. yay!"
-                  _               -> putStrLn "wrong types"
diff --git a/testsuite/pdynload/should_fail1/prog/expected b/testsuite/pdynload/should_fail1/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/should_fail1/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-wrong types
diff --git a/testsuite/pdynload/small/Makefile b/testsuite/pdynload/small/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/small/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   pdynload/small
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/small/Plugin.hs b/testsuite/pdynload/small/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/small/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-module Plugin where
-
-import API
-
-resource = plugin { function = "good" }
diff --git a/testsuite/pdynload/small/api/API.hs b/testsuite/pdynload/small/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/small/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module API where
-
-data Interface = Interface { 
-        function :: String
-}
-
-plugin :: Interface
-plugin = Interface  { function = "goodbye" }
-
diff --git a/testsuite/pdynload/small/prog/Main.hs b/testsuite/pdynload/small/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/small/prog/Main.hs
+++ /dev/null
@@ -1,18 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e -> mapM_ putStrLn e
-
-   where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-                case v of
-                  LoadSuccess _ a  -> putStrLn "loaded .. yay!"
-                  _                -> putStrLn "wrong types"
-
diff --git a/testsuite/pdynload/small/prog/expected b/testsuite/pdynload/small/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/small/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-loaded .. yay!
diff --git a/testsuite/pdynload/spj1/Makefile b/testsuite/pdynload/spj1/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/spj1/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=pdynload/spj1
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/spj1/Plugin.hs b/testsuite/pdynload/spj1/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj1/Plugin.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-module Plugin where
-
--- user doesn't import the API
--- and provides a polymorphic value
-
--- import API
--- resource :: Interface
-
---
--- should pass type check, and dump core
---
--- resource :: Num a => a
-
--- import API
-
-resource :: Num a => a
-resource = 7
diff --git a/testsuite/pdynload/spj1/api/API.hs b/testsuite/pdynload/spj1/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj1/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-
-module API where
-
--- data Interface = Interface { field :: Int }
-
--- newtype Interface = Interface Int
-
-type Interface = Int
-
diff --git a/testsuite/pdynload/spj1/dont_test b/testsuite/pdynload/spj1/dont_test
deleted file mode 100644
--- a/testsuite/pdynload/spj1/dont_test
+++ /dev/null
diff --git a/testsuite/pdynload/spj1/prog/Main.hs b/testsuite/pdynload/spj1/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj1/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e   -> mapM_ putStrLn e
-
-  where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-               case v of
-                 LoadSuccess _ (a :: Interface) -> print $ a -- will crash
-                 LoadFailure es     -> putStrLn $ show es
diff --git a/testsuite/pdynload/spj1/prog/expected b/testsuite/pdynload/spj1/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/spj1/prog/expected
+++ /dev/null
diff --git a/testsuite/pdynload/spj2/Makefile b/testsuite/pdynload/spj2/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/spj2/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=pdynload/spj1
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/spj2/Plugin.hs b/testsuite/pdynload/spj2/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj2/Plugin.hs
+++ /dev/null
@@ -1,13 +0,0 @@
-module Plugin where
-
--- user doesn't import the API
--- and provides a polymorphic value
-
-import API
-resource :: Interface
-
---
--- should pass type check, and dump core
---
--- resource :: Num a => a
-resource = 7
diff --git a/testsuite/pdynload/spj2/api/API.hs b/testsuite/pdynload/spj2/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj2/api/API.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-
-module API where
-
--- simple type
-type Interface = Int
-
diff --git a/testsuite/pdynload/spj2/prog/Main.hs b/testsuite/pdynload/spj2/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj2/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e   -> mapM_ putStrLn e
-
-  where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-               case v of
-                 LoadSuccess _ (a :: Interface) -> putStrLn $ show a -- will crash
-                 LoadFailure es     -> putStrLn $ show es
diff --git a/testsuite/pdynload/spj2/prog/expected b/testsuite/pdynload/spj2/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/spj2/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-7
diff --git a/testsuite/pdynload/spj3/Makefile b/testsuite/pdynload/spj3/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/spj3/Makefile
+++ /dev/null
@@ -1,3 +0,0 @@
-TEST=   pdynload/spj3
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/spj3/Plugin.hs b/testsuite/pdynload/spj3/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj3/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-module Plugin where
-
-import API
-
-resource = plugin { function = (+) :: Int -> Int -> Int }
diff --git a/testsuite/pdynload/spj3/api/API.hs b/testsuite/pdynload/spj3/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj3/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module API where
-
-data Interface = Interface { 
-        function :: (Num a) => a -> a -> a
-}
-
-plugin :: Interface
-plugin = Interface  { function = error "no function defined" }
-
diff --git a/testsuite/pdynload/spj3/prog/Main.hs b/testsuite/pdynload/spj3/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj3/prog/Main.hs
+++ /dev/null
@@ -1,18 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e -> mapM_ putStrLn e
-
-   where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-                case v of
-                  LoadSuccess _ a -> let fn = function a in putStrLn $ show $ 1 `fn` 2
-                  _               -> putStrLn "wrong types"
-
diff --git a/testsuite/pdynload/spj3/prog/expected b/testsuite/pdynload/spj3/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/spj3/prog/expected
+++ /dev/null
@@ -1,8 +0,0 @@
-
-../Plugin.hs:5:
-    Cannot unify the type-signature variable `a' with the type `Int'
-	Expected type: a -> a -> a
-	Inferred type: Int -> Int -> Int
-    When checking the type signature of the expression:
-	  (+) :: Int -> Int -> Int
-    In the `function' field of a record
diff --git a/testsuite/pdynload/spj3/prog/expected.604 b/testsuite/pdynload/spj3/prog/expected.604
deleted file mode 100644
--- a/testsuite/pdynload/spj3/prog/expected.604
+++ /dev/null
@@ -1,9 +0,0 @@
-
-../Plugin.hs:5:31:
-    Couldn't match the rigid variable `a' against `Int'
-      `a' is bound by the polymorphic type `forall a. (Num a) => a -> a -> a'
-			at ../Plugin.hs:5:11-56
-      Expected type: a -> a -> a
-      Inferred type: Int -> Int -> Int
-    In the expression: (+) :: Int -> Int -> Int
-    In the `function' field of a record
diff --git a/testsuite/pdynload/spj3/prog/expected.605 b/testsuite/pdynload/spj3/prog/expected.605
deleted file mode 100644
--- a/testsuite/pdynload/spj3/prog/expected.605
+++ /dev/null
@@ -1,9 +0,0 @@
-
-../Plugin.hs:5:31:
-    Couldn't match the rigid variable `a' against `Int'
-      `a' is bound by the polymorphic type `forall a. (Num a) => a -> a -> a'
-			at ../Plugin.hs:5:11-56
-      Expected type: a -> a -> a
-      Inferred type: Int -> Int -> Int
-    In the expression: (+) :: Int -> Int -> Int
-    In the `function' field of a record
diff --git a/testsuite/pdynload/spj4/Makefile b/testsuite/pdynload/spj4/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/spj4/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-
-TEST=pdynload/spj4
-
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/spj4/Plugin.hs b/testsuite/pdynload/spj4/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj4/Plugin.hs
+++ /dev/null
@@ -1,16 +0,0 @@
-module Plugin where
-
--- user doesn't import the API
--- and provides a polymorphic value
-
--- import API
--- resource :: Interface
-
---
--- should pass type check, and dump core
---
--- resource :: Num a => a
-
-import API
-
-resource = Interface { field = 7 :: Num a => a }
diff --git a/testsuite/pdynload/spj4/api/API.hs b/testsuite/pdynload/spj4/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj4/api/API.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-
-module API where
-
-newtype Interface = Interface { field :: Int }
-
diff --git a/testsuite/pdynload/spj4/prog/Main.hs b/testsuite/pdynload/spj4/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/spj4/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e   -> error "there was a type error"
-
-  where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-               case v of
-                 LoadSuccess _ (a :: Interface) -> print $ field a -- will crash
-                 LoadFailure es  -> mapM_ putStrLn es
diff --git a/testsuite/pdynload/spj4/prog/expected b/testsuite/pdynload/spj4/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/spj4/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-7
diff --git a/testsuite/pdynload/typealias/Makefile b/testsuite/pdynload/typealias/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/typealias/Makefile
+++ /dev/null
@@ -1,5 +0,0 @@
-# Missing class constraint... can't do that in Clean
-
-TEST=   pdynload/typealias
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/typealias/Plugin.hs b/testsuite/pdynload/typealias/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/typealias/Plugin.hs
+++ /dev/null
@@ -1,3 +0,0 @@
-module Plugin where
-
-resource = 1 :: Int
diff --git a/testsuite/pdynload/typealias/api/API.hs b/testsuite/pdynload/typealias/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/typealias/api/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-
-module API where
-
-type Interface = Int
-
-rsrc :: Interface
-rsrc = 1
-
diff --git a/testsuite/pdynload/typealias/prog/Main.hs b/testsuite/pdynload/typealias/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/typealias/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e -> mapM_ putStrLn e
-
-  where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-               case v of
-                  LoadSuccess _ a  -> putStrLn "loaded .. yay!"
-                  _           -> putStrLn "wrong types"
-
-
diff --git a/testsuite/pdynload/typealias/prog/expected b/testsuite/pdynload/typealias/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/typealias/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-loaded .. yay!
diff --git a/testsuite/pdynload/univquant/Makefile b/testsuite/pdynload/univquant/Makefile
deleted file mode 100644
--- a/testsuite/pdynload/univquant/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   pdynload/univquant
-EXTRA_OBJS=Plugin.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/pdynload/univquant/Plugin.hs b/testsuite/pdynload/univquant/Plugin.hs
deleted file mode 100644
--- a/testsuite/pdynload/univquant/Plugin.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module Plugin where
-
-import API
-
-resource = plugin { function = my_id }
-
-my_id :: forall a. a -> a
-my_id x = x
diff --git a/testsuite/pdynload/univquant/api/API.hs b/testsuite/pdynload/univquant/api/API.hs
deleted file mode 100644
--- a/testsuite/pdynload/univquant/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-module API where
-
-data Interface = Interface { 
-        function :: forall a. a -> a
-}
-
-plugin :: Interface
-plugin = Interface  { function = id }
-
diff --git a/testsuite/pdynload/univquant/prog/Main.hs b/testsuite/pdynload/univquant/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pdynload/univquant/prog/Main.hs
+++ /dev/null
@@ -1,17 +0,0 @@
-
-import System.Plugins
-import API
-
-src     = "../Plugin.hs"
-wrap    = "../Wrapper.hs"
-apipath = "../api"
-
-main = do status <- make src ["-i"++apipath]
-          case status of
-                MakeSuccess _ _ -> f
-                MakeFailure e   -> mapM_ putStrLn e
-
-   where f = do v <- pdynload "../Plugin.o" ["../api"] [] "API.Interface" "resource"
-                case v of
-                  LoadSuccess _ a  -> putStrLn "loaded .. yay!"
-                  _             -> putStrLn "wrong types"
diff --git a/testsuite/pdynload/univquant/prog/expected b/testsuite/pdynload/univquant/prog/expected
deleted file mode 100644
--- a/testsuite/pdynload/univquant/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-loaded .. yay!
diff --git a/testsuite/pkgconf/null/Makefile b/testsuite/pkgconf/null/Makefile
deleted file mode 100644
--- a/testsuite/pkgconf/null/Makefile
+++ /dev/null
@@ -1,16 +0,0 @@
-all:
-	@echo "test disabled"
-
-#true_api::
-#	( cd api ;\
-#	$(GHC) -Onot $(EXTRAFLAGS) -c $(API).hs ;\
-#	$(RM) -f libHSapi.a ;\
-#	$(AR) cq libHSapi.a API.o ;\
-#	$(RANLIB) libHSapi.a ;\
-#	$(LD) -r $(LD_X) $(WHOLE_ARCHIVE_FLAG) -o HSapi.o libHSapi.a ;\
-#	rm API.o ;\
-#	echo [] > package.conf ;\
-#	env PREFIX=`pwd` $(GHC_PKG) -f package.conf -u < package.conf.in )
-#	$(GHC) -package-conf ${TOP}/plugins.conf.inplace -package plugins \
-#		-package-conf api/package.conf            -package api \
-#		-O $(EXTRAFLAGS) -c Null.hs
diff --git a/testsuite/pkgconf/null/Null.hs b/testsuite/pkgconf/null/Null.hs
deleted file mode 100644
--- a/testsuite/pkgconf/null/Null.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-module Null ( resource )  where
-
-import API
-
-resource = plugin { a = 7 }
-
diff --git a/testsuite/pkgconf/null/api/API.hs b/testsuite/pkgconf/null/api/API.hs
deleted file mode 100644
--- a/testsuite/pkgconf/null/api/API.hs
+++ /dev/null
@@ -1,10 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-data Null = Null { a, b :: Int }
-   deriving Show
-
-plugin :: Null
-plugin = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/pkgconf/null/api/package.conf.in b/testsuite/pkgconf/null/api/package.conf.in
deleted file mode 100644
--- a/testsuite/pkgconf/null/api/package.conf.in
+++ /dev/null
@@ -1,18 +0,0 @@
-Package {
-        name            = "api",
-        auto            = False,
-
-        import_dirs     = [ "${PREFIX}" ],
-        library_dirs    = [ "${PREFIX}" ],
-        hs_libraries    = [ "HSapi" ],
-
-        include_dirs    = [],
-        c_includes      = [],
-        source_dirs     = [],
-        extra_libraries = [],
-        package_deps    = [],
-        extra_ghc_opts  = [],
-        extra_cc_opts   = [],
-        extra_ld_opts   = []
-}
-
diff --git a/testsuite/pkgconf/null/dont_test b/testsuite/pkgconf/null/dont_test
deleted file mode 100644
--- a/testsuite/pkgconf/null/dont_test
+++ /dev/null
diff --git a/testsuite/pkgconf/null/prog/Main.hs b/testsuite/pkgconf/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/pkgconf/null/prog/Main.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -cpp #-}
-
-#include "../../../../config.h"
-
-import System.Plugins
-import API
-
-main = do 
-    let includes = TOP ++ "/testsuite/load/null/api"
-    (_,v) <- load "../Null.o" ["."] ["../api/package.conf"] "resource"
-    putStrLn ( show (a v) )
-
diff --git a/testsuite/plugs/plugs/Main.hs b/testsuite/plugs/plugs/Main.hs
deleted file mode 100644
--- a/testsuite/plugs/plugs/Main.hs
+++ /dev/null
@@ -1,69 +0,0 @@
---
--- Copyright (c) 2004 Don Stewart - http://www.cse.unsw.edu.au/~dons
--- GPL version 2 or later (see http://www.gnu.org/copyleft/gpl.html)
---
-
-import System.Eval.Haskell
-import System.Plugins.Load
-
-import System.Exit              ( ExitCode(..), exitWith )
-import System.IO
-import System.Console.Readline  ( readline, addHistory )
-
-symbol = "resource"
-
-main = do
-        putStrLn banner 
-        putStr "Loading package base" >> hFlush stdout
-        loadPackage "base" 
-        putStr " ... linking ... " >> hFlush stdout
-        resolveObjs (return ())
-        putStrLn "done"
-
-        shell []
-
-shell :: [String] -> IO ()
-shell imps = do 
-        s <- readline "plugs> "
-        cmd <- case s of 
-                Nothing          -> exitWith ExitSuccess
-                Just (':':'q':_) -> exitWith ExitSuccess
-                Just s           -> addHistory s >> return s
-        imps' <- run cmd imps
-        shell imps'
-
-run :: String -> [String] -> IO [String]
-run ""   is = return is
-run ":?" is = putStrLn help >> return is
-
-run ":l" _             = return []
-run (':':'l':' ':m) is = return (m:is)
-
-run (':':'t':' ':s) is = do 
-        ty <- typeOf s is
-        when (not $ null ty) (putStrLn $ s ++ " :: " ++ ty)
-        return is
-
-run (':':_) is = putStrLn help >> return is
-
-run s is = do 
-        s <- unsafeEval ("show $ "++s) is
-        when (isJust s) (putStrLn (fromJust s))
-        return is
-
-banner = "\ 
-\           __                          \n\
-\    ____  / /_  ______ ______          \n\
-\   / __ \\/ / / / / __ `/ ___/     PLugin User's GHCi System, for Haskell 98\n\
-\  / /_/ / / /_/ / /_/ (__  )      http://www.cse.unsw.edu.au/~dons/hs-plugins\n\
-\ / .___/_/\\__,_/\\__, /____/       Type :? for help     \n\
-\/_/            /____/                  \n"
-
-help = "\
-\Commands :\n\ 
-\  <expr>               evaluate expression\n\ 
-\  :t <expr>            show type of expression (monomorphic only)\n\ 
-\  :l module            bring module in to scope\n\ 
-\  :l                   clear module list\n\ 
-\  :quit                quit\n\ 
-\  :?                   display this list of commands"
diff --git a/testsuite/plugs/plugs/Makefile b/testsuite/plugs/plugs/Makefile
deleted file mode 100644
--- a/testsuite/plugs/plugs/Makefile
+++ /dev/null
@@ -1,28 +0,0 @@
-GHCFLAGS=   -O
-PKGFLAGS+=  -package plugins -package readline
-
-all: build
-
-build:
-	@$(GHC) $(GHCFLAGS) $(PKGFLAGS) $(EXTRAFLAGS) Main.hs -o plugs
-check: build
-	@(if [ -f "expected" ] ;\
-	  then \
-		actual_out="/tmp/hs-plugins-actual.out.$$$$"	   ;\
-		diff_out="/tmp/hs-plugins.diff.$$$$"		   ;\
-		cat test.in | ./plugs > $$actual_out  2>&1 || true ;\
-		diff -u expected $$actual_out > $$diff_out || true ;\
-		if [ -s "$$diff_out" ] ; then \
-			echo "failed with:"	;\
-			cat "$$diff_out" | sed '1,3d' ;\
-		else \
-			echo "ok." 	;\
-		fi ;\
-		rm $$actual_out 	;\
-	 else \
-		cat test.in | ./plugs 2>&1 || true ;\
-	 fi)
-clean:
-	rm -rf *.hi *.o *~ *.dep ./plugs
-
-include ../../../config.mk
diff --git a/testsuite/plugs/plugs/expected b/testsuite/plugs/plugs/expected
deleted file mode 100644
--- a/testsuite/plugs/plugs/expected
+++ /dev/null
@@ -1,9 +0,0 @@
-           __                          
-    ____  / /_  ______ ______          
-   / __ \/ / / / / __ `/ ___/     PLugin User's GHCi System, for Haskell 98
-  / /_/ / / /_/ / /_/ (__  )      http://www.cse.unsw.edu.au/~dons/hs-plugins
- / .___/_/\__,_/\__, /____/       Type :? for help     
-/_/            /____/                  
-
-Loading package base ... linking ... plugs> plugs> done
-453973694165307953197296969697410619233826
diff --git a/testsuite/plugs/plugs/test.in b/testsuite/plugs/plugs/test.in
deleted file mode 100644
--- a/testsuite/plugs/plugs/test.in
+++ /dev/null
@@ -1,2 +0,0 @@
-let fibs = 1 : 1 : zipWith (+) fibs (tail fibs) in fibs !! 200
-:quit
diff --git a/testsuite/plugs/runplugs/Main.hs b/testsuite/plugs/runplugs/Main.hs
deleted file mode 100644
--- a/testsuite/plugs/runplugs/Main.hs
+++ /dev/null
@@ -1,57 +0,0 @@
---
--- Copyright (c) 2004 Don Stewart - http://www.cse.unsw.edu.au/~dons
--- GPL version 2 or later (see http://www.gnu.org/copyleft/gpl.html)
---
-
---
--- | Runplugs: use hs-plugins to run a Haskell expression under
--- controlled conditions.
---
-import System.Eval.Haskell             (unsafeEval)
-
-import Data.Char                (chr)
-import Data.Maybe               (isJust, fromJust)
-import Control.Monad
-
-import System.Random
-import System.Exit              (exitWith, ExitCode(ExitSuccess))
-import System.IO                (getContents, putStrLn)
-import System.Posix.Resource    (setResourceLimit,
-			         Resource(ResourceCPUTime), 
-                                 ResourceLimits(ResourceLimits),
-			         ResourceLimit(ResourceLimit))
-
-import qualified Control.Exception (catch)
-
-rlimit = ResourceLimit 3
-
-context = prehier ++ datas ++ qualifieds ++ controls
-
-prehier = ["Char", "List", "Maybe", "Numeric", "Random" ]
-
-qualifieds = ["qualified Data.Map as M"
-             ,"qualified Data.Set as S"
-             ,"qualified Data.IntSet as I"]
-
-datas   = map ("Data." ++) [
-                "Bits", "Bool", "Char", "Dynamic", "Either", 
-                "Graph", "Int", "Ix", "List",
-                "Maybe", "Ratio", "Tree", "Tuple", "Typeable", "Word" 
-              ]
-
-controls = map ("Control." ++) ["Monad", "Monad.Reader", "Monad.Fix", "Arrow"]
-
-main = do
-    setResourceLimit ResourceCPUTime (ResourceLimits rlimit rlimit)
-    s <- getLine
-    when (not . null $ s) $ do
-        x <- sequence (take 3 (repeat $ getStdRandom (randomR (97,122)) >>= return . chr))
-        s <- unsafeEval ("let { "++x++
-                         " = \n# 1 \"<irc>\"\n"++s++
-                         "\n} in take 2048 (show "++x++
-                         ")") context
-        when (isJust s) $ Control.Exception.catch 
-                    (putStrLn $ fromJust s)
-                    (\e -> putStrLn $ "Exception: " ++ show e )
-    exitWith ExitSuccess
-
diff --git a/testsuite/plugs/runplugs/Makefile b/testsuite/plugs/runplugs/Makefile
deleted file mode 100644
--- a/testsuite/plugs/runplugs/Makefile
+++ /dev/null
@@ -1,30 +0,0 @@
-GHCFLAGS=   -O0 $(GHC_EXTRA_OPTS)
-PKGFLAGS=   -package posix
-PKGFLAGS+=  -package plugins
-
-all: build
-
-build:
-	@$(GHC) $(GHCFLAGS) $(PKGFLAGS) $(EXTRAFLAGS) Main.hs -o runplugs
-include ../../../config.mk
-check: build
-	@(if [ -f "expected" ] ;\
-	  then \
-		actual_out="/tmp/hs-plugins-actual.out.$$$$"	   ;\
-		diff_out="/tmp/hs-plugins.diff.$$$$"		   ;\
-		cat test.in | ./runplugs > $$actual_out  2>&1 || true ;\
-		diff -u expected $$actual_out > $$diff_out || true ;\
-		if [ -s "$$diff_out" ] ; then \
-			echo "failed with:"	;\
-			cat "$$diff_out" | sed '1,3d' ;\
-		else \
-			echo "ok." 	;\
-		fi ;\
-		rm $$actual_out 	;\
-	 else \
-		cat test.in | ./runplugs 2>&1 || true ;\
-	 fi)
-clean:
-	rm -rf *.hi *.o *~ *.dep ./runplugs
-
-include ../../../config.mk
diff --git a/testsuite/plugs/runplugs/expected b/testsuite/plugs/runplugs/expected
deleted file mode 100644
--- a/testsuite/plugs/runplugs/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-453973694165307953197296969697410619233826
diff --git a/testsuite/plugs/runplugs/test.in b/testsuite/plugs/runplugs/test.in
deleted file mode 100644
--- a/testsuite/plugs/runplugs/test.in
+++ /dev/null
@@ -1,1 +0,0 @@
-let fibs = 1 : 1 : zipWith (+) fibs (tail fibs) in fibs !! 200
diff --git a/testsuite/reload/null/Makefile b/testsuite/reload/null/Makefile
deleted file mode 100644
--- a/testsuite/reload/null/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   reload/null
-EXTRA_OBJS=Null.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/reload/null/Null.hs b/testsuite/reload/null/Null.hs
deleted file mode 100644
--- a/testsuite/reload/null/Null.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-module Null ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-import Prelude hiding (null)
-
-resource = null
-
--- ! this has to be special: it can't be overridden by the user.
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/reload/null/api/API.hs b/testsuite/reload/null/api/API.hs
deleted file mode 100644
--- a/testsuite/reload/null/api/API.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data Null = Null { a, b :: Int }
-   deriving (Typeable, Show)
-
-null :: Null
-null = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/reload/null/prog/Main.hs b/testsuite/reload/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/reload/null/prog/Main.hs
+++ /dev/null
@@ -1,19 +0,0 @@
-
-import System.Plugins
-import API
-
--- an example where we just want to load an object and run it
-
-main = do 
-    m_v <- load "../Null.o" ["../api"] [] "resource"
-    (m,v) <- case m_v of
-        LoadSuccess m v -> return (m,v)
-        _               -> error "load failed"
-    putStrLn ( show (a v) )
-
-    m_v <- reload m "resource"   -- get a new version
-    v' <- case m_v of
-        LoadSuccess _ v -> return v
-        _               -> error "load failed"
-    putStrLn ( show (a v') )
-
diff --git a/testsuite/reload/null/prog/expected b/testsuite/reload/null/prog/expected
deleted file mode 100644
--- a/testsuite/reload/null/prog/expected
+++ /dev/null
@@ -1,2 +0,0 @@
-42
-42
diff --git a/testsuite/shell/shell/API.hs b/testsuite/shell/shell/API.hs
deleted file mode 100644
--- a/testsuite/shell/shell/API.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module API where
-
--- the interface between the app and the plugin
-data Interface = Interface { function :: String -> String }
-
--- default values for the interface
-plugin :: Interface
-plugin = Interface { function = id }
diff --git a/testsuite/shell/shell/Main.hs b/testsuite/shell/shell/Main.hs
deleted file mode 100644
--- a/testsuite/shell/shell/Main.hs
+++ /dev/null
@@ -1,85 +0,0 @@
---
--- a simple shell for loading plugins and evaluating their functions
--- 
-
-import System.Plugins
-import API
-
-import Data.Either
-import Data.Char
-import Control.Monad            ( when )
-import System.Console.Readline  ( readline )
-import System.Exit              ( ExitCode(..), exitWith )
-
-
-source = "Plugin.hs"
-stub   = "Plugin.stub"
-
-sym = "resource"
-
-main = do
-        status <- makeWith source stub []
-        p <- case status of
-                MakeFailure e -> mapM_ putStrLn e >> error "failed to compile"
-                MakeSuccess _ obj -> do
-                        m_v <- load obj ["."] [] sym
-                        case m_v of
-                                LoadSuccess m v -> return (m,v)
-                                LoadFailure e   -> do mapM_ putStrLn e
-                                                      error "failed to load"
-        shell p
-
-    where
-        shell p@(m,v) = do 
-
-            s <- readline "> "
-            cmd <- case s of 
-                Nothing   -> exitWith ExitSuccess
-                Just ":q" -> exitWith ExitSuccess
-                Just s    -> return (chomp s)
-
-            status <- makeWith source stub []   
-            case status of 
-                MakeFailure e -> do 
-                    mapM_ putStrLn e
-                    shell p     -- print error and back to prompt
-
-                MakeSuccess NotReq o ->  do
-                    p' <- eval cmd p
-                    shell p'    -- eval str again
-
-                MakeSuccess ReComp o -> do
-                    m_v' <- reload m sym
-                    case m_v' of
-                        LoadFailure e    -> mapM_ putStrLn e >> error "failed to load"
-                        LoadSuccess _ v' -> do
-                                let p' = (m,v')
-                                p'' <- eval cmd p'
-                                shell p''
-
---
--- shell commands
---
-eval "" p = return p
-
-eval ":clear" p = do
-        let loop i = when (i < 40) (do putStr "\n" ; loop $! i+1)
-        loop 0
-        return p
-
-eval ":?"  p     = do
-        putStrLn$"\":?\"\n"       ++
-                 "\":quit\"\n"    ++
-                 "\":clear\"\n"   ++
-                 "\"foo\""
-        return p
-
-eval s (m,v) = putStrLn ((function v) s) >> return (m,v)
-
---
--- strip trailing whitespace
---
-chomp :: String -> String
-chomp [] = []
-chomp s | isSpace (last s) = chomp $! init s
-        | otherwise        = s
diff --git a/testsuite/shell/shell/Makefile b/testsuite/shell/shell/Makefile
deleted file mode 100644
--- a/testsuite/shell/shell/Makefile
+++ /dev/null
@@ -1,2 +0,0 @@
-TOP=../../..
-include ../../eval.mk
diff --git a/testsuite/shell/shell/Plugin.hs b/testsuite/shell/shell/Plugin.hs
deleted file mode 100644
--- a/testsuite/shell/shell/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-
-resource = plugin { 
-        function = map toUpper
-}
-
diff --git a/testsuite/shell/shell/Plugin.stub b/testsuite/shell/shell/Plugin.stub
deleted file mode 100644
--- a/testsuite/shell/shell/Plugin.stub
+++ /dev/null
@@ -1,19 +0,0 @@
---
--- this is a "stub" file, containing default syntax we don't
--- want the user to have to write
---
--- for example, it constrains the module name and force the API to be
--- imported
-
-module Plugin ( resource ) where
-
-import API
-import Data.Char
-import Data.List
-
--- this is a default definition of 'resource'. it will be overridden
--- by anything the user writes. useful for default values
-
-resource :: Interface
-resource = plugin
-
diff --git a/testsuite/shell/shell/README b/testsuite/shell/shell/README
deleted file mode 100644
--- a/testsuite/shell/shell/README
+++ /dev/null
@@ -1,23 +0,0 @@
-$ make
-$ ./a.out 
-Compiling plugin ... done
-Loading package base ... linking ... done
-Loading objects API Plugin ... done
-> ?
-"?"
-"quit"
-"clear"
-"filter foo"
-> filter adf adsf
-fsda fda
-> filter asd faSDFADSF
-FSDAFDSaf dsa
-
--- at this point I edit the plugin and save the source
-
-> filter asfdaSDFASD
-Compiling plugin ... done
-Reloading Plugin ... done
-DSAFDSADFSA
-
--- it compiled and reloaded it for me. nice.
diff --git a/testsuite/shell/shell/dont_test b/testsuite/shell/shell/dont_test
deleted file mode 100644
--- a/testsuite/shell/shell/dont_test
+++ /dev/null
diff --git a/testsuite/shell/simple/Main.hs b/testsuite/shell/simple/Main.hs
deleted file mode 100644
--- a/testsuite/shell/simple/Main.hs
+++ /dev/null
@@ -1,41 +0,0 @@
-import System.Plugins
-import StringProcessorAPI
-import System.Console.Readline
-import System.Exit
-
-source = "Plugin.hs"
-stub   = "Plugin.stub"
-symbol = "resource"
-
-main = do s <- makeWith source stub []
-          o <- case s of
-                MakeSuccess _ obj -> do
-                        ls <- load obj ["."] [] symbol
-                        case ls of LoadSuccess m v -> return (m,v)
-                                   LoadFailure err -> error "load failed"
-                MakeFailure e -> mapM_ putStrLn e >> error "compile failed"
-          shell o
-
-shell o@(m,plugin) = do 
-        s <- readline "> "
-        cmd <- case s of 
-                Nothing          -> exitWith ExitSuccess
-                Just (':':'q':_) -> exitWith ExitSuccess
-                Just s           -> addHistory s >> return s
-
-        s  <- makeWith source stub []   -- maybe recompile the source
-        o' <- case s of
-                MakeSuccess ReComp o -> do 
-                        ls <- reload m symbol
-                        case ls of LoadSuccess m' v' -> return (m',v')
-                                   LoadFailure err   -> error "reload failed"
-                MakeSuccess NotReq _ -> return o
-                MakeFailure e -> mapM_ putStrLn e >> shell o
-        eval cmd o'
-        shell o'
-
-eval ":?" _ = putStrLn ":?\n:q\n<string>"
-
-eval s (_,plugin) = let fn = (stringProcessor plugin) in putStrLn (fn s)
-
-
diff --git a/testsuite/shell/simple/Makefile b/testsuite/shell/simple/Makefile
deleted file mode 100644
--- a/testsuite/shell/simple/Makefile
+++ /dev/null
@@ -1,6 +0,0 @@
-OBJS=StringProcessorAPI.o
-TOP=../../..
-include ../../eval.mk
-
-#all:
-#	@echo test disabled
diff --git a/testsuite/shell/simple/Plugin.hs b/testsuite/shell/simple/Plugin.hs
deleted file mode 100644
--- a/testsuite/shell/simple/Plugin.hs
+++ /dev/null
@@ -1,5 +0,0 @@
-import Char
-
-resource = plugin { 
-        stringProcessor = map toUpper
-}
diff --git a/testsuite/shell/simple/Plugin.stub b/testsuite/shell/simple/Plugin.stub
deleted file mode 100644
--- a/testsuite/shell/simple/Plugin.stub
+++ /dev/null
@@ -1,19 +0,0 @@
---
--- this is a "stub" file, containing default syntax we don't
--- want the user to have to write
---
--- for example, it constrains the module name and force the API to be
--- imported
-
-module Plugin ( resource ) where
-
-import StringProcessorAPI
-import Data.Char
-import Data.List
-
--- this is a default definition of 'resource'. it will be overridden
--- by anything the user writes. useful for default values
-
-resource :: Interface
-resource = plugin
-
diff --git a/testsuite/shell/simple/README b/testsuite/shell/simple/README
deleted file mode 100644
--- a/testsuite/shell/simple/README
+++ /dev/null
@@ -1,23 +0,0 @@
-$ make
-$ ./a.out 
-Compiling plugin ... done
-Loading package base ... linking ... done
-Loading objects API Plugin ... done
-> ?
-"?"
-"quit"
-"clear"
-"filter foo"
-> filter adf adsf
-fsda fda
-> filter asd faSDFADSF
-FSDAFDSaf dsa
-
--- at this point I edit the plugin and save the source
-
-> filter asfdaSDFASD
-Compiling plugin ... done
-Reloading Plugin ... done
-DSAFDSADFSA
-
--- it compiled and reloaded it for me. nice.
diff --git a/testsuite/shell/simple/StringProcessorAPI.hs b/testsuite/shell/simple/StringProcessorAPI.hs
deleted file mode 100644
--- a/testsuite/shell/simple/StringProcessorAPI.hs
+++ /dev/null
@@ -1,8 +0,0 @@
-module StringProcessorAPI where
-
-data Interface = Interface { 
-        stringProcessor :: String -> String 
-}
-
-plugin :: Interface
-plugin = Interface { stringProcessor = id }
diff --git a/testsuite/shell/simple/dont_test b/testsuite/shell/simple/dont_test
deleted file mode 100644
--- a/testsuite/shell/simple/dont_test
+++ /dev/null
diff --git a/testsuite/unload/null/Makefile b/testsuite/unload/null/Makefile
deleted file mode 100644
--- a/testsuite/unload/null/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   unload/null
-EXTRA_OBJS=Null.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/unload/null/Null.hs b/testsuite/unload/null/Null.hs
deleted file mode 100644
--- a/testsuite/unload/null/Null.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-module Null ( resource, resource_dyn )  where
-
-import API
-import Data.Dynamic
-import Prelude hiding (null)
-
-resource = null
-
--- ! this has to be special: it can't be overridden by the user.
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/unload/null/api/API.hs b/testsuite/unload/null/api/API.hs
deleted file mode 100644
--- a/testsuite/unload/null/api/API.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data Null = Null { a, b :: Int }
-   deriving (Typeable, Show)
-
-null :: Null
-null = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/unload/null/prog/Main.hs b/testsuite/unload/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/unload/null/prog/Main.hs
+++ /dev/null
@@ -1,11 +0,0 @@
-
-import System.Plugins
-import API
-
--- an example where we just want to load an object and run it
-
-main = do 
-    m_v   <- load "../Null.o" ["../api"] [] "resource"
-    case m_v of
-        LoadFailure _   -> error "load failed"
-        LoadSuccess m v -> do putStrLn ( show (a v) ) ; unload m
diff --git a/testsuite/unload/null/prog/expected b/testsuite/unload/null/prog/expected
deleted file mode 100644
--- a/testsuite/unload/null/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-42
diff --git a/testsuite/unload/sjwtrap/Makefile b/testsuite/unload/sjwtrap/Makefile
deleted file mode 100644
--- a/testsuite/unload/sjwtrap/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   unload/sjwtrap
-EXTRA_OBJS=Null.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/unload/sjwtrap/Null.hs b/testsuite/unload/sjwtrap/Null.hs
deleted file mode 100644
--- a/testsuite/unload/sjwtrap/Null.hs
+++ /dev/null
@@ -1,6 +0,0 @@
-module Null where
-
-import qualified Prelude
-import API
-
-resource = null
diff --git a/testsuite/unload/sjwtrap/api/API.hs b/testsuite/unload/sjwtrap/api/API.hs
deleted file mode 100644
--- a/testsuite/unload/sjwtrap/api/API.hs
+++ /dev/null
@@ -1,9 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-data Null = Null { a, b :: Int }
-
-null :: Null
-null = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/unload/sjwtrap/prog/Main.hs b/testsuite/unload/sjwtrap/prog/Main.hs
deleted file mode 100644
--- a/testsuite/unload/sjwtrap/prog/Main.hs
+++ /dev/null
@@ -1,15 +0,0 @@
-
-import System.Plugins
-import API
-
---
--- what happens if we try to use code that has been unloaded?
---
-
-main = do 
-    m_v   <- load "../Null.o" ["../api"] [] "resource"
-    (m,v) <- case m_v of
-        LoadSuccess m v -> return (m,v)
-        _               -> error "load failed"
-    putStrLn ( show (a v) )
-    unload m
diff --git a/testsuite/unload/sjwtrap/prog/expected b/testsuite/unload/sjwtrap/prog/expected
deleted file mode 100644
--- a/testsuite/unload/sjwtrap/prog/expected
+++ /dev/null
@@ -1,1 +0,0 @@
-42
diff --git a/testsuite/unloadAll/null/Dep.hs b/testsuite/unloadAll/null/Dep.hs
deleted file mode 100644
--- a/testsuite/unloadAll/null/Dep.hs
+++ /dev/null
@@ -1,7 +0,0 @@
-module Dep ( resource )  where
-
-import API
-import Data.Dynamic
-import Prelude hiding (null)
-
-resource = null
diff --git a/testsuite/unloadAll/null/Makefile b/testsuite/unloadAll/null/Makefile
deleted file mode 100644
--- a/testsuite/unloadAll/null/Makefile
+++ /dev/null
@@ -1,4 +0,0 @@
-TEST=   unloadAll/null
-EXTRA_OBJS=Dep.o Null.o
-TOP=../../..
-include ../../build.mk
diff --git a/testsuite/unloadAll/null/Null.hs b/testsuite/unloadAll/null/Null.hs
deleted file mode 100644
--- a/testsuite/unloadAll/null/Null.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-module Null ( resource )  where
-
-import API
-import Data.Dynamic
-import Prelude hiding (null)
-import qualified Dep
-
-resource = Dep.resource
-
--- ! this has to be special: it can't be overridden by the user.
-resource_dyn :: Dynamic
-resource_dyn = toDyn resource
diff --git a/testsuite/unloadAll/null/api/API.hs b/testsuite/unloadAll/null/api/API.hs
deleted file mode 100644
--- a/testsuite/unloadAll/null/api/API.hs
+++ /dev/null
@@ -1,12 +0,0 @@
-{-# OPTIONS -fglasgow-exts #-}
-
-module API where
-
-import Data.Dynamic
-
-data Null = Null { a, b :: Int }
-   deriving (Typeable, Show)
-
-null :: Null
-null = Null { a = 42 , b = 1 }
-
diff --git a/testsuite/unloadAll/null/prog/Main.hs b/testsuite/unloadAll/null/prog/Main.hs
deleted file mode 100644
--- a/testsuite/unloadAll/null/prog/Main.hs
+++ /dev/null
@@ -1,15 +0,0 @@
-
-import System.Plugins
-import API
-
--- an example where we just want to load an object and run it
-
-main = do 
-    m_v   <- load_ "../Null.o" ["../api",".."] "resource"
-    t     <- load_ "../Dep.o" ["../api"] "resource"
-    case m_v of
-        LoadFailure err -> error (unlines err)
-        LoadSuccess m v -> do putStrLn ( show (a v) ) ; unloadAll m -- unloads Null.o but not Dep.o since we're still using it.
-    case t of
-        LoadFailure err -> error (unlines err)
-        LoadSuccess m v -> do putStrLn ( show (a v) ) ; unloadAll m
diff --git a/testsuite/unloadAll/null/prog/expected b/testsuite/unloadAll/null/prog/expected
deleted file mode 100644
--- a/testsuite/unloadAll/null/prog/expected
+++ /dev/null
@@ -1,2 +0,0 @@
-42
-42
