--- ray/src/gen/mkillum.c 2005/05/25 04:44:25 2.24 +++ ray/src/gen/mkillum.c 2005/09/19 11:30:10 2.26 @@ -1,5 +1,5 @@ #ifndef lint -static const char RCSid[] = "$Id: mkillum.c,v 2.24 2005/05/25 04:44:25 greg Exp $"; +static const char RCSid[] = "$Id: mkillum.c,v 2.26 2005/09/19 11:30:10 schorsch Exp $"; #endif /* * Make illum sources for optimizing rendering process @@ -157,6 +157,10 @@ main( /* compute illum distributions using rtrace */ quit(0); } + +#ifndef SIGALRM +#define SIGALRM SIGTERM +#endif static void killpersist(void) /* kill persistent rtrace process */ { @@ -170,6 +174,7 @@ killpersist(void) /* kill persistent rtrace process fclose(fp); } + int done_rprocs(struct rtproc *rtp) { @@ -213,7 +218,14 @@ init(int np) /* start rtrace and set up buffers */ ofun[OBJ_SPHERE].funp = o_sphere; ofun[OBJ_RING].funp = o_ring; /* set up signal handling */ -#ifdef SIGPIPE /* not present on Windows */ + signal(SIGINT, quit); +#ifdef SIGHUP + signal(SIGHUP, quit); +#endif +#ifdef SIGTERM + signal(SIGTERM, quit); +#endif +#ifdef SIGPIPE signal(SIGPIPE, quit); #endif rtp = &rt0; /* start rtrace process(es) */