/* ------------------- cmd.h ----------------*/ #ifdef CMD_H #include #include #include #include #include #include #include "defs.h" #include "gettoken.h" #include "sign.h" #else extern void redirect(int srcfd, char *srcfile, int dstfd, char *dstfile, int errfd, char * errfile, BOOLEAN append, BOOLEAN bckgrnd); /* I/O - redirection */ extern int invoke(int argc, char *argv[], int srcfd, char *srcfile, int dstfd, char *dstfile, int errfd, char *errfile, BOOLEAN append, BOOLEAN bckgrnd); /* invoke() - execute simple command */ extern TOKEN command(int *waitpid); /* collect a simple command from stdin * by calling gettoken() - do redirection * if necessary by redirect() and execute * command by invoke() */ #endif