%N mirsubsd %F $MIR/src/scripts/mirsubsd.clone
%D Debugging script for miriad subroutines
%P mjs
%: programmer tool
%B
Debugging script for miriad subroutines.  Compile miriad
subroutines and output a dot-o file.  -DMIRDEBUG is defined (so
compilation is with the -g option and ratty/intf2c output is
retained).  Users may define -DTESTBED prior to invocation.

$MIRSUBS is searched for include files, as is $MIRINC.

Users are expected to put source code in a private directory and
work from that directory; input source code is expected to be in
the current working directory, and all output will be placed
there.

  Usage:  mirsubsd  [-O] <subr-name>

If the -O flag is given, the compile is optimized (making the
code generally unuseful for stepping through a program/subroutine
with dbx); omitting this flag produces unoptimized code.

Filename extensions (.for, .f, .f2c, .c) are required.

Sample session:

  mkdir mydir
  cd mydir
  cp $MIRSUBS/wrap.f2c $MIRSUBS/uvio.c $MIRSUBS/key.for .
  mirsubsd wrap.f2c
  mirsubsd uvio.c
  mirsubsd key.for
  cp $MIRSUBS/key.h .
  mirsubsd key.for
  mirsubsd key.f
  mirsubsd wrap.c
  cp $MIR/borrow/pgplot/src/pgbeg.f .
  cp $MIR/borrow/pgplot/src/pgplot.inc .
  mirsubsd pgbeg.f
