/*===========================================================================*/
/*   (Llib/process.scm)                                                      */
/*   Bigloo (2.6b)                                                           */
/*   Inria -- Sophia Antipolis (c)       Mon Dec 15 12:14:36 CET 2003        */
/*===========================================================================*/
/* COMPILATION: (/users/serrano/prgm/project/bigloo/bin/bigloo -O4 -mklib -cc gcc-2.95 -fsharing -q -s -copt -DBGL_NO_PIC -unsafe -c Llib/process.scm -indent -o objs/obj_u/Llib/process.c)*/
/* GC selection */
#define THE_GC BOEHM_GC

#include <bigloo.h>
#include <signal.h>

BGL_EXPORTED_DECL obj_t BGl_runzd2processzd2zz__processz00(obj_t, obj_t);
static obj_t BGl__processzd2sendzd2signal1811z00zz__processz00(obj_t, obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_modulezd2initializa7ationz75zz__processz00(long, char *);
extern obj_t BGl_modulezd2initializa7ationz75zz__errorz00(long, char *);
extern bool_t c_process_alivep(obj_t);
static obj_t BGl__processzd2exitzd2status1809z00zz__processz00(obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_processzd2exitzd2statusz00zz__processz00(obj_t);
BGL_EXPORTED_DECL obj_t BGl_processzd2stopzd2zz__processz00(obj_t);
static obj_t BGl__processzd2alivezf31805z21zz__processz00(obj_t, obj_t);
extern obj_t BGl_reversez12z12zz__r4_pairs_and_lists_6_3z00(obj_t);
extern obj_t close_output_port(obj_t);
BGL_EXPORTED_DECL bool_t BGl_processzf3zf3zz__processz00(obj_t);
static obj_t BGl_list1858z00zz__processz00 = BUNSPEC;
extern obj_t c_process_wait(obj_t);
BGL_EXPORTED_DECL bool_t BGl_processzd2alivezf3z21zz__processz00(obj_t);
extern obj_t c_process_continue(obj_t);
extern obj_t c_process_send_signal(obj_t, int);
BGL_EXPORTED_DECL obj_t BGl_processzd2continuezd2zz__processz00(obj_t);
static obj_t BGl__processzf3zf3zz__processz00(obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_processzd2sendzd2signalz00zz__processz00(obj_t, int);
static obj_t BGl_cnstzd2initzd2zz__processz00();
BGL_EXPORTED_DECL bool_t BGl_processzd2waitzd2zz__processz00(obj_t);
static obj_t BGl__unregisterzd2process1824zd2zz__processz00(obj_t, obj_t);
static obj_t BGl__processzd2listzd2zz__processz00(obj_t);
BGL_EXPORTED_DECL obj_t BGl_closezd2processzd2portsz00zz__processz00(obj_t);
extern obj_t c_process_stop(obj_t);
extern obj_t close_input_port(obj_t);
static obj_t BGl__processzd2stop1815zd2zz__processz00(obj_t, obj_t);
static obj_t BGl_keyword1860z00zz__processz00 = BUNSPEC;
static obj_t BGl_keyword1859z00zz__processz00 = BUNSPEC;
static obj_t BGl_keyword1863z00zz__processz00 = BUNSPEC;
static obj_t BGl_keyword1864z00zz__processz00 = BUNSPEC;
static obj_t BGl_keyword1865z00zz__processz00 = BUNSPEC;
static obj_t BGl_keyword1866z00zz__processz00 = BUNSPEC;
BGL_EXPORTED_DECL obj_t BGl_unregisterzd2processzd2zz__processz00(obj_t);
static obj_t BGl_keyword1867z00zz__processz00 = BUNSPEC;
static obj_t BGl_keyword1868z00zz__processz00 = BUNSPEC;
static obj_t BGl_keyword1869z00zz__processz00 = BUNSPEC;
extern obj_t c_run_process(obj_t, obj_t, obj_t, obj_t, obj_t, obj_t, obj_t, obj_t, obj_t);
static obj_t BGl__processzd2errorzd2port1803z00zz__processz00(obj_t, obj_t);
static obj_t BGl__runzd2process1820zd2zz__processz00(obj_t, obj_t, obj_t);
static obj_t BGl_importedzd2moduleszd2initz00zz__processz00();
static obj_t BGl__processzd2outputzd2port1799z00zz__processz00(obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_processzd2errorzd2portz00zz__processz00(obj_t);
extern obj_t c_process_list();
static obj_t BGl__processzd2inputzd2port1801z00zz__processz00(obj_t, obj_t);
extern obj_t c_process_xstatus(obj_t);
BGL_EXPORTED_DECL obj_t BGl_processzd2outputzd2portz00zz__processz00(obj_t);
static obj_t BGl_requirezd2initializa7ationz75zz__processz00 = BUNSPEC;
BGL_EXPORTED_DECL obj_t BGl_processzd2inputzd2portz00zz__processz00(obj_t);
extern obj_t BGl_memqz00zz__r4_pairs_and_lists_6_3z00(obj_t, obj_t);
static obj_t BGl__processzd2pid1797zd2zz__processz00(obj_t, obj_t);
BGL_EXPORTED_DECL obj_t BGl_processzd2killzd2zz__processz00(obj_t);
extern obj_t c_process_kill(obj_t);
static obj_t BGl__closezd2processzd2ports1822z00zz__processz00(obj_t, obj_t);
static obj_t BGl__processzd2kill1813zd2zz__processz00(obj_t, obj_t);
static obj_t BGl__processzd2continue1817zd2zz__processz00(obj_t, obj_t);
extern obj_t string_to_keyword(char *);
extern bool_t BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(obj_t, obj_t);
extern obj_t c_unregister_process(obj_t);
BGL_EXPORTED_DECL obj_t BGl_processzd2listzd2zz__processz00();
static obj_t BGl__processzd2wait1807zd2zz__processz00(obj_t, obj_t);
BGL_EXPORTED_DECL int BGl_processzd2pidzd2zz__processz00(obj_t);
static obj_t *__cnst;


DEFINE_EXPORT_PROCEDURE( BGl_processzd2pidzd2envz00zz__processz00, BgL_bgl__processza7d2pid1797za7d2za7za7__processza7001875za7, BGl__processzd2pid1797zd2zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2killzd2envz00zz__processz00, BgL_bgl__processza7d2kill1813za7d2za7za7__processza7001876za7, BGl__processzd2kill1813zd2zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2errorzd2portzd2envzd2zz__processz00, BgL_bgl__processza7d2errorza7d2port1803za700za7za7__processza7001877z00, BGl__processzd2errorzd2port1803z00zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2sendzd2signalzd2envzd2zz__processz00, BgL_bgl__processza7d2sendza7d2signal1811za700za7za7__processza7001878z00, BGl__processzd2sendzd2signal1811z00zz__processz00, 0L, 2 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2exitzd2statuszd2envzd2zz__processz00, BgL_bgl__processza7d2exitza7d2status1809za700za7za7__processza7001879z00, BGl__processzd2exitzd2status1809z00zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2alivezf3zd2envzf3zz__processz00, BgL_bgl__processza7d2aliveza7f31805za721za7za7__processza7001880z00, BGl__processzd2alivezf31805z21zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2listzd2envz00zz__processz00, BgL_bgl__processza7d2listza7d2za7za7__processza7001881za7, BGl__processzd2listzd2zz__processz00, 0L, 0 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2continuezd2envz00zz__processz00, BgL_bgl__processza7d2continue1817za7d2za7za7__processza7001882za7, BGl__processzd2continue1817zd2zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzf3zd2envz21zz__processz00, BgL_bgl__processza7f3za7f3za7za7__processza7001883za7, BGl__processzf3zf3zz__processz00, 0L, 1 );
DEFINE_STRING( BGl_string1862z00zz__processz00, BgL_bgl_string1862za700za7za7__processza7001884z00, "Illegal argument", 16 );
DEFINE_STRING( BGl_string1861z00zz__processz00, BgL_bgl_string1861za700za7za7__processza7001885z00, "run-process", 11 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2waitzd2envz00zz__processz00, BgL_bgl__processza7d2wait1807za7d2za7za7__processza7001886za7, BGl__processzd2wait1807zd2zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2outputzd2portzd2envzd2zz__processz00, BgL_bgl__processza7d2outputza7d2port1799za700za7za7__processza7001887z00, BGl__processzd2outputzd2port1799z00zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_closezd2processzd2portszd2envzd2zz__processz00, BgL_bgl__closeza7d2processza7d2ports1822za700za7za7__processza7001888z00, BGl__closezd2processzd2ports1822z00zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_unregisterzd2processzd2envz00zz__processz00, BgL_bgl__unregisterza7d2process1824za7d2za7za7__processza7001889za7, BGl__unregisterzd2process1824zd2zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2stopzd2envz00zz__processz00, BgL_bgl__processza7d2stop1815za7d2za7za7__processza7001890za7, BGl__processzd2stop1815zd2zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_processzd2inputzd2portzd2envzd2zz__processz00, BgL_bgl__processza7d2inputza7d2port1801za700za7za7__processza7001891z00, BGl__processzd2inputzd2port1801z00zz__processz00, 0L, 1 );
DEFINE_EXPORT_PROCEDURE( BGl_runzd2processzd2envz00zz__processz00, BgL_bgl__runza7d2process1820za7d2za7za7__processza7001892za7, va_generic_entry, BGl__runzd2process1820zd2zz__processz00, -2 );



/* module-initialization */
BGL_EXPORTED_DEF obj_t BGl_modulezd2initializa7ationz75zz__processz00(long BgL_checksumz00_704, char * BgL_fromz00_705)
{ AN_OBJECT;
{ 
if(
CBOOL(BGl_requirezd2initializa7ationz75zz__processz00))
{ 
BGl_requirezd2initializa7ationz75zz__processz00 = 
BBOOL(((bool_t)0)); 
BGl_cnstzd2initzd2zz__processz00(); 
BGl_importedzd2moduleszd2initz00zz__processz00(); 
return BUNSPEC;}  else 
{ 
return BUNSPEC;} } 
}



/* cnst-init */
obj_t BGl_cnstzd2initzd2zz__processz00()
{ AN_OBJECT;
{ /* ./Llib/process.scm 15 */
BGl_keyword1859z00zz__processz00 = 
string_to_keyword("pipe:"); 
BGl_list1858z00zz__processz00 = 
MAKE_PAIR(BGl_keyword1859z00zz__processz00, BNIL); 
BGl_keyword1860z00zz__processz00 = 
string_to_keyword("wait:"); 
BGl_keyword1863z00zz__processz00 = 
string_to_keyword("fork:"); 
BGl_keyword1864z00zz__processz00 = 
string_to_keyword("input:"); 
BGl_keyword1865z00zz__processz00 = 
string_to_keyword("output:"); 
BGl_keyword1866z00zz__processz00 = 
string_to_keyword("null:"); 
BGl_keyword1867z00zz__processz00 = 
string_to_keyword("error:"); 
BGl_keyword1868z00zz__processz00 = 
string_to_keyword("host:"); 
return ( 
BGl_keyword1869z00zz__processz00 = 
string_to_keyword("env:"), BUNSPEC) ;} 
}



/* process? */
BGL_EXPORTED_DEF bool_t BGl_processzf3zf3zz__processz00(obj_t BgL_objz00_1)
{ AN_OBJECT;
{ /* ./Llib/process.scm 114 */
return 
PROCESSP(BgL_objz00_1);} 
}



/* _process? */
obj_t BGl__processzf3zf3zz__processz00(obj_t BgL_envz00_657, obj_t BgL_objz00_658)
{ AN_OBJECT;
{ /* ./Llib/process.scm 114 */
{ /* ./Llib/process.scm 115 */
bool_t BgL_auxz00_722;
BgL_auxz00_722 = 
PROCESSP(BgL_objz00_658); 
return 
BBOOL(BgL_auxz00_722);} } 
}



/* process-pid */
BGL_EXPORTED_DEF int BGl_processzd2pidzd2zz__processz00(obj_t BgL_procz00_2)
{ AN_OBJECT;
{ /* ./Llib/process.scm 120 */
return 
PROCESS_PID(BgL_procz00_2);} 
}



/* _process-pid1797 */
obj_t BGl__processzd2pid1797zd2zz__processz00(obj_t BgL_envz00_659, obj_t BgL_procz00_660)
{ AN_OBJECT;
{ /* ./Llib/process.scm 120 */
{ /* ./Llib/process.scm 121 */
int BgL_auxz00_726;
BgL_auxz00_726 = 
PROCESS_PID(BgL_procz00_660); 
return 
BINT(BgL_auxz00_726);} } 
}



/* process-output-port */
BGL_EXPORTED_DEF obj_t BGl_processzd2outputzd2portz00zz__processz00(obj_t BgL_procz00_3)
{ AN_OBJECT;
{ /* ./Llib/process.scm 126 */
return 
PROCESS_OUTPUT_PORT(BgL_procz00_3);} 
}



/* _process-output-port1799 */
obj_t BGl__processzd2outputzd2port1799z00zz__processz00(obj_t BgL_envz00_661, obj_t BgL_procz00_662)
{ AN_OBJECT;
{ /* ./Llib/process.scm 126 */
return 
PROCESS_OUTPUT_PORT(BgL_procz00_662);} 
}



/* process-input-port */
BGL_EXPORTED_DEF obj_t BGl_processzd2inputzd2portz00zz__processz00(obj_t BgL_procz00_4)
{ AN_OBJECT;
{ /* ./Llib/process.scm 132 */
return 
PROCESS_INPUT_PORT(BgL_procz00_4);} 
}



/* _process-input-port1801 */
obj_t BGl__processzd2inputzd2port1801z00zz__processz00(obj_t BgL_envz00_663, obj_t BgL_procz00_664)
{ AN_OBJECT;
{ /* ./Llib/process.scm 132 */
return 
PROCESS_INPUT_PORT(BgL_procz00_664);} 
}



/* process-error-port */
BGL_EXPORTED_DEF obj_t BGl_processzd2errorzd2portz00zz__processz00(obj_t BgL_procz00_5)
{ AN_OBJECT;
{ /* ./Llib/process.scm 138 */
return 
PROCESS_ERROR_PORT(BgL_procz00_5);} 
}



/* _process-error-port1803 */
obj_t BGl__processzd2errorzd2port1803z00zz__processz00(obj_t BgL_envz00_665, obj_t BgL_procz00_666)
{ AN_OBJECT;
{ /* ./Llib/process.scm 138 */
return 
PROCESS_ERROR_PORT(BgL_procz00_666);} 
}



/* process-alive? */
BGL_EXPORTED_DEF bool_t BGl_processzd2alivezf3z21zz__processz00(obj_t BgL_procz00_6)
{ AN_OBJECT;
{ /* ./Llib/process.scm 144 */
return 
c_process_alivep(BgL_procz00_6);} 
}



/* _process-alive?1805 */
obj_t BGl__processzd2alivezf31805z21zz__processz00(obj_t BgL_envz00_667, obj_t BgL_procz00_668)
{ AN_OBJECT;
{ /* ./Llib/process.scm 144 */
{ /* ./Llib/process.scm 145 */
bool_t BgL_auxz00_736;
BgL_auxz00_736 = 
c_process_alivep(BgL_procz00_668); 
return 
BBOOL(BgL_auxz00_736);} } 
}



/* process-wait */
BGL_EXPORTED_DEF bool_t BGl_processzd2waitzd2zz__processz00(obj_t BgL_procz00_7)
{ AN_OBJECT;
{ /* ./Llib/process.scm 150 */
if(
c_process_alivep(BgL_procz00_7))
{ /* ./Llib/process.scm 151 */
obj_t BgL_auxz00_741;
BgL_auxz00_741 = 
c_process_wait(BgL_procz00_7); 
return 
CBOOL(BgL_auxz00_741);}  else 
{ /* ./Llib/process.scm 151 */
return ((bool_t)0);} } 
}



/* _process-wait1807 */
obj_t BGl__processzd2wait1807zd2zz__processz00(obj_t BgL_envz00_669, obj_t BgL_procz00_670)
{ AN_OBJECT;
{ /* ./Llib/process.scm 150 */
{ /* ./Llib/process.scm 151 */
bool_t BgL_auxz00_744;
if(
c_process_alivep(BgL_procz00_670))
{ /* ./Llib/process.scm 151 */
obj_t BgL_auxz00_747;
BgL_auxz00_747 = 
c_process_wait(BgL_procz00_670); 
BgL_auxz00_744 = 
CBOOL(BgL_auxz00_747); }  else 
{ /* ./Llib/process.scm 151 */
BgL_auxz00_744 = ((bool_t)0)
; } 
return 
BBOOL(BgL_auxz00_744);} } 
}



/* process-exit-status */
BGL_EXPORTED_DEF obj_t BGl_processzd2exitzd2statusz00zz__processz00(obj_t BgL_procz00_8)
{ AN_OBJECT;
{ /* ./Llib/process.scm 157 */
return 
c_process_xstatus(BgL_procz00_8);} 
}



/* _process-exit-status1809 */
obj_t BGl__processzd2exitzd2status1809z00zz__processz00(obj_t BgL_envz00_671, obj_t BgL_procz00_672)
{ AN_OBJECT;
{ /* ./Llib/process.scm 157 */
return 
c_process_xstatus(BgL_procz00_672);} 
}



/* process-send-signal */
BGL_EXPORTED_DEF obj_t BGl_processzd2sendzd2signalz00zz__processz00(obj_t BgL_procz00_9, int BgL_signalz00_10)
{ AN_OBJECT;
{ /* ./Llib/process.scm 163 */
return 
c_process_send_signal(BgL_procz00_9, BgL_signalz00_10);} 
}



/* _process-send-signal1811 */
obj_t BGl__processzd2sendzd2signal1811z00zz__processz00(obj_t BgL_envz00_673, obj_t BgL_procz00_674, obj_t BgL_signalz00_675)
{ AN_OBJECT;
{ /* ./Llib/process.scm 163 */
{ /* ./Llib/process.scm 164 */
int BgL_auxz00_754;
BgL_auxz00_754 = 
CINT(BgL_signalz00_675); 
return 
c_process_send_signal(BgL_procz00_674, BgL_auxz00_754);} } 
}



/* process-kill */
BGL_EXPORTED_DEF obj_t BGl_processzd2killzd2zz__processz00(obj_t BgL_procz00_11)
{ AN_OBJECT;
{ /* ./Llib/process.scm 169 */
c_process_kill(BgL_procz00_11); 
return 
BGl_closezd2processzd2portsz00zz__processz00(BgL_procz00_11);} 
}



/* _process-kill1813 */
obj_t BGl__processzd2kill1813zd2zz__processz00(obj_t BgL_envz00_676, obj_t BgL_procz00_677)
{ AN_OBJECT;
{ /* ./Llib/process.scm 169 */
c_process_kill(BgL_procz00_677); 
return 
BGl_closezd2processzd2portsz00zz__processz00(BgL_procz00_677);} 
}



/* process-stop */
BGL_EXPORTED_DEF obj_t BGl_processzd2stopzd2zz__processz00(obj_t BgL_procz00_12)
{ AN_OBJECT;
{ /* ./Llib/process.scm 176 */
return 
c_process_stop(BgL_procz00_12);} 
}



/* _process-stop1815 */
obj_t BGl__processzd2stop1815zd2zz__processz00(obj_t BgL_envz00_678, obj_t BgL_procz00_679)
{ AN_OBJECT;
{ /* ./Llib/process.scm 176 */
return 
c_process_stop(BgL_procz00_679);} 
}



/* process-continue */
BGL_EXPORTED_DEF obj_t BGl_processzd2continuezd2zz__processz00(obj_t BgL_procz00_13)
{ AN_OBJECT;
{ /* ./Llib/process.scm 182 */
return 
c_process_continue(BgL_procz00_13);} 
}



/* _process-continue1817 */
obj_t BGl__processzd2continue1817zd2zz__processz00(obj_t BgL_envz00_680, obj_t BgL_procz00_681)
{ AN_OBJECT;
{ /* ./Llib/process.scm 182 */
return 
c_process_continue(BgL_procz00_681);} 
}



/* process-list */
BGL_EXPORTED_DEF obj_t BGl_processzd2listzd2zz__processz00()
{ AN_OBJECT;
{ /* ./Llib/process.scm 188 */
return 
c_process_list();} 
}



/* _process-list */
obj_t BGl__processzd2listzd2zz__processz00(obj_t BgL_envz00_682)
{ AN_OBJECT;
{ /* ./Llib/process.scm 188 */
return 
c_process_list();} 
}



/* run-process */
BGL_EXPORTED_DEF obj_t BGl_runzd2processzd2zz__processz00(obj_t BgL_commandz00_14, obj_t BgL_restz00_15)
{ AN_OBJECT;
{ /* ./Llib/process.scm 197 */
{ /* ./Llib/process.scm 198 */
obj_t BgL_forkz00_365;obj_t BgL_waitz00_366;obj_t BgL_inputz00_367;obj_t BgL_outputz00_368;obj_t BgL_errorz00_369;obj_t BgL_hostz00_370;obj_t BgL_pipesz00_371;obj_t BgL_argsz00_372;obj_t BgL_envz00_373;
BgL_forkz00_365 = BTRUE; 
BgL_waitz00_366 = BFALSE; 
BgL_inputz00_367 = BUNSPEC; 
BgL_outputz00_368 = BUNSPEC; 
BgL_errorz00_369 = BUNSPEC; 
BgL_hostz00_370 = BUNSPEC; 
BgL_pipesz00_371 = BGl_list1858z00zz__processz00; 
BgL_argsz00_372 = BNIL; 
BgL_envz00_373 = BNIL; 
{ 
obj_t BgL_restz00_375;
BgL_restz00_375 = BgL_restz00_15; 
BgL_loopz00_376:
if(
NULLP(BgL_restz00_375))
{ /* ./Llib/process.scm 211 */
{ /* ./Llib/process.scm 214 */
obj_t BgL_arg1023z00_378;
BgL_arg1023z00_378 = 
BGl_reversez12z12zz__r4_pairs_and_lists_6_3z00(BgL_argsz00_372); 
return 
c_run_process(BgL_hostz00_370, BgL_forkz00_365, BgL_waitz00_366, BgL_inputz00_367, BgL_outputz00_368, BgL_errorz00_369, BgL_commandz00_14, BgL_arg1023z00_378, BgL_envz00_373);} }  else 
{ /* ./Llib/process.scm 215 */
bool_t BgL_test1026z00_379;
{ /* ./Llib/process.scm 215 */
bool_t BgL_testz00_771;
{ /* ./Llib/process.scm 215 */
obj_t BgL_auxz00_772;
BgL_auxz00_772 = 
CAR(BgL_restz00_375); 
BgL_testz00_771 = 
KEYWORDP(BgL_auxz00_772); } 
if(BgL_testz00_771)
{ /* ./Llib/process.scm 215 */
obj_t BgL_auxz00_775;
BgL_auxz00_775 = 
CDR(BgL_restz00_375); 
BgL_test1026z00_379 = 
PAIRP(BgL_auxz00_775); }  else 
{ /* ./Llib/process.scm 215 */
BgL_test1026z00_379 = ((bool_t)0); } } 
if(BgL_test1026z00_379)
{ /* ./Llib/process.scm 215 */
{ /* ./Llib/process.scm 216 */
obj_t BgL_valz00_380;
{ /* ./Llib/process.scm 216 */
obj_t BgL_auxz00_779;
BgL_auxz00_779 = 
CDR(BgL_restz00_375); 
BgL_valz00_380 = 
CAR(BgL_auxz00_779); } 
{ /* ./Llib/process.scm 217 */
obj_t BgL_casezd2valuezd2_381;
BgL_casezd2valuezd2_381 = 
CAR(BgL_restz00_375); 
if(
BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(BgL_casezd2valuezd2_381, BGl_keyword1860z00zz__processz00))
{ /* ./Llib/process.scm 217 */
if(
BOOLEANP(BgL_valz00_380))
{ /* ./Llib/process.scm 219 */
BgL_waitz00_366 = BgL_valz00_380; }  else 
{ /* ./Llib/process.scm 219 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} }  else 
{ /* ./Llib/process.scm 217 */
if(
BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(BgL_casezd2valuezd2_381, BGl_keyword1863z00zz__processz00))
{ /* ./Llib/process.scm 217 */
if(
BOOLEANP(BgL_valz00_380))
{ /* ./Llib/process.scm 223 */
BgL_forkz00_365 = BgL_valz00_380; }  else 
{ /* ./Llib/process.scm 223 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} }  else 
{ /* ./Llib/process.scm 217 */
if(
BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(BgL_casezd2valuezd2_381, BGl_keyword1864z00zz__processz00))
{ /* ./Llib/process.scm 227 */
bool_t BgL_test1036z00_387;
if(
STRINGP(BgL_valz00_380))
{ /* ./Llib/process.scm 227 */
BgL_test1036z00_387 = ((bool_t)1); }  else 
{ /* ./Llib/process.scm 227 */
obj_t BgL_auxz00_797;
BgL_auxz00_797 = 
BGl_memqz00zz__r4_pairs_and_lists_6_3z00(BgL_valz00_380, BgL_pipesz00_371); 
BgL_test1036z00_387 = 
CBOOL(BgL_auxz00_797); } 
if(BgL_test1036z00_387)
{ /* ./Llib/process.scm 227 */
BgL_inputz00_367 = BgL_valz00_380; }  else 
{ /* ./Llib/process.scm 227 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} }  else 
{ /* ./Llib/process.scm 217 */
if(
BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(BgL_casezd2valuezd2_381, BGl_keyword1865z00zz__processz00))
{ /* ./Llib/process.scm 231 */
bool_t BgL_test1042z00_390;
if(
STRINGP(BgL_valz00_380))
{ /* ./Llib/process.scm 231 */
BgL_test1042z00_390 = ((bool_t)1); }  else 
{ /* ./Llib/process.scm 231 */
bool_t BgL_testz00_806;
{ /* ./Llib/process.scm 231 */
obj_t BgL_auxz00_807;
BgL_auxz00_807 = 
BGl_memqz00zz__r4_pairs_and_lists_6_3z00(BgL_valz00_380, BgL_pipesz00_371); 
BgL_testz00_806 = 
CBOOL(BgL_auxz00_807); } 
if(BgL_testz00_806)
{ /* ./Llib/process.scm 231 */
BgL_test1042z00_390 = ((bool_t)1); }  else 
{ /* ./Llib/process.scm 231 */
BgL_test1042z00_390 = 
(BgL_valz00_380==BGl_keyword1866z00zz__processz00); } } 
if(BgL_test1042z00_390)
{ /* ./Llib/process.scm 231 */
BgL_outputz00_368 = BgL_valz00_380; }  else 
{ /* ./Llib/process.scm 231 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} }  else 
{ /* ./Llib/process.scm 217 */
if(
BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(BgL_casezd2valuezd2_381, BGl_keyword1867z00zz__processz00))
{ /* ./Llib/process.scm 235 */
bool_t BgL_test1050z00_394;
if(
STRINGP(BgL_valz00_380))
{ /* ./Llib/process.scm 235 */
BgL_test1050z00_394 = ((bool_t)1); }  else 
{ /* ./Llib/process.scm 235 */
bool_t BgL_testz00_817;
{ /* ./Llib/process.scm 235 */
obj_t BgL_auxz00_818;
BgL_auxz00_818 = 
BGl_memqz00zz__r4_pairs_and_lists_6_3z00(BgL_valz00_380, BgL_pipesz00_371); 
BgL_testz00_817 = 
CBOOL(BgL_auxz00_818); } 
if(BgL_testz00_817)
{ /* ./Llib/process.scm 235 */
BgL_test1050z00_394 = ((bool_t)1); }  else 
{ /* ./Llib/process.scm 235 */
BgL_test1050z00_394 = 
(BgL_valz00_380==BGl_keyword1866z00zz__processz00); } } 
if(BgL_test1050z00_394)
{ /* ./Llib/process.scm 235 */
BgL_errorz00_369 = BgL_valz00_380; }  else 
{ /* ./Llib/process.scm 235 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} }  else 
{ /* ./Llib/process.scm 217 */
if(
BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(BgL_casezd2valuezd2_381, BGl_keyword1868z00zz__processz00))
{ /* ./Llib/process.scm 217 */
if(
STRINGP(BgL_valz00_380))
{ /* ./Llib/process.scm 239 */
BgL_hostz00_370 = BgL_valz00_380; }  else 
{ /* ./Llib/process.scm 239 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} }  else 
{ /* ./Llib/process.scm 217 */
if(
BGl_eqvzf3zf3zz__r4_equivalence_6_2z00(BgL_casezd2valuezd2_381, BGl_keyword1869z00zz__processz00))
{ /* ./Llib/process.scm 217 */
if(
STRINGP(BgL_valz00_380))
{ /* ./Llib/process.scm 243 */
BgL_envz00_373 = 
MAKE_PAIR(BgL_valz00_380, BgL_envz00_373); }  else 
{ /* ./Llib/process.scm 243 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} }  else 
{ /* ./Llib/process.scm 217 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} } } } } } } } 
{ 
obj_t BgL_restz00_836;
{ /* ./Llib/process.scm 248 */
obj_t BgL_auxz00_837;
BgL_auxz00_837 = 
CDR(BgL_restz00_375); 
BgL_restz00_836 = 
CDR(BgL_auxz00_837); } 
BgL_restz00_375 = BgL_restz00_836; 
goto BgL_loopz00_376;} } }  else 
{ /* ./Llib/process.scm 249 */
bool_t BgL_testz00_840;
{ /* ./Llib/process.scm 249 */
obj_t BgL_auxz00_841;
BgL_auxz00_841 = 
CAR(BgL_restz00_375); 
BgL_testz00_840 = 
STRINGP(BgL_auxz00_841); } 
if(BgL_testz00_840)
{ /* ./Llib/process.scm 249 */
{ /* ./Llib/process.scm 250 */
obj_t BgL_arg1085z00_404;
BgL_arg1085z00_404 = 
CAR(BgL_restz00_375); 
BgL_argsz00_372 = 
MAKE_PAIR(BgL_arg1085z00_404, BgL_argsz00_372); } 
{ 
obj_t BgL_restz00_846;
BgL_restz00_846 = 
CDR(BgL_restz00_375); 
BgL_restz00_375 = BgL_restz00_846; 
goto BgL_loopz00_376;} }  else 
{ /* ./Llib/process.scm 249 */
FAILURE(BGl_string1861z00zz__processz00,BGl_string1862z00zz__processz00,BgL_restz00_375);} } } } } } 
}



/* _run-process1820 */
obj_t BGl__runzd2process1820zd2zz__processz00(obj_t BgL_envz00_683, obj_t BgL_commandz00_684, obj_t BgL_restz00_685)
{ AN_OBJECT;
{ /* ./Llib/process.scm 197 */
return 
BGl_runzd2processzd2zz__processz00(BgL_commandz00_684, BgL_restz00_685);} 
}



/* close-process-ports */
BGL_EXPORTED_DEF obj_t BGl_closezd2processzd2portsz00zz__processz00(obj_t BgL_procz00_16)
{ AN_OBJECT;
{ /* ./Llib/process.scm 258 */
{ /* ./Llib/process.scm 259 */
bool_t BgL_testz00_850;
{ /* ./Llib/process.scm 259 */
obj_t BgL_auxz00_851;
BgL_auxz00_851 = 
PROCESS_INPUT_PORT(BgL_procz00_16); 
BgL_testz00_850 = 
OUTPUT_PORTP(BgL_auxz00_851); } 
if(BgL_testz00_850)
{ /* ./Llib/process.scm 260 */
obj_t BgL_auxz00_854;
BgL_auxz00_854 = 
PROCESS_INPUT_PORT(BgL_procz00_16); 
close_output_port(BgL_auxz00_854); }  else 
{ /* ./Llib/process.scm 259 */BFALSE; } } 
{ /* ./Llib/process.scm 261 */
bool_t BgL_testz00_857;
{ /* ./Llib/process.scm 261 */
obj_t BgL_auxz00_858;
BgL_auxz00_858 = 
PROCESS_ERROR_PORT(BgL_procz00_16); 
BgL_testz00_857 = 
INPUT_PORTP(BgL_auxz00_858); } 
if(BgL_testz00_857)
{ /* ./Llib/process.scm 262 */
obj_t BgL_auxz00_861;
BgL_auxz00_861 = 
PROCESS_INPUT_PORT(BgL_procz00_16); 
close_input_port(BgL_auxz00_861); }  else 
{ /* ./Llib/process.scm 261 */BFALSE; } } 
{ /* ./Llib/process.scm 263 */
bool_t BgL_testz00_864;
{ /* ./Llib/process.scm 263 */
obj_t BgL_auxz00_865;
BgL_auxz00_865 = 
PROCESS_OUTPUT_PORT(BgL_procz00_16); 
BgL_testz00_864 = 
INPUT_PORTP(BgL_auxz00_865); } 
if(BgL_testz00_864)
{ /* ./Llib/process.scm 264 */
obj_t BgL_auxz00_868;
BgL_auxz00_868 = 
PROCESS_OUTPUT_PORT(BgL_procz00_16); 
return 
close_input_port(BgL_auxz00_868);}  else 
{ /* ./Llib/process.scm 263 */
return BFALSE;} } } 
}



/* _close-process-ports1822 */
obj_t BGl__closezd2processzd2ports1822z00zz__processz00(obj_t BgL_envz00_686, obj_t BgL_procz00_687)
{ AN_OBJECT;
{ /* ./Llib/process.scm 258 */
return 
BGl_closezd2processzd2portsz00zz__processz00(BgL_procz00_687);} 
}



/* unregister-process */
BGL_EXPORTED_DEF obj_t BGl_unregisterzd2processzd2zz__processz00(obj_t BgL_procz00_17)
{ AN_OBJECT;
{ /* ./Llib/process.scm 269 */
return 
c_unregister_process(BgL_procz00_17);} 
}



/* _unregister-process1824 */
obj_t BGl__unregisterzd2process1824zd2zz__processz00(obj_t BgL_envz00_688, obj_t BgL_procz00_689)
{ AN_OBJECT;
{ /* ./Llib/process.scm 269 */
return 
c_unregister_process(BgL_procz00_689);} 
}



/* imported-modules-init */
obj_t BGl_importedzd2moduleszd2initz00zz__processz00()
{ AN_OBJECT;
{ /* ./Llib/process.scm 15 */
return 
BGl_modulezd2initializa7ationz75zz__errorz00(((long)11084), "__process");} 
}

