-/* Copyright (C) 1997, 1998, 2000 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 1998, 2000, 2001 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* If you do not wish that, delete this exception notice. */
\f
#include <stdio.h>
+#include <errno.h>
#include <limits.h>
#include <string.h>
-#include "_scm.h"
-#include "async.h"
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
+#include "libguile/_scm.h"
+#include "libguile/async.h"
-#include "iselect.h"
+#include "libguile/iselect.h"
#ifdef GUILE_ISELECT
-#include "coop-threads.h"
+#include "libguile/coop-threads.h"
#ifdef MISSING_BZERO_DECL
extern void bzero (void *, size_t);
#if LONG_MAX >> 16 == 0
#define SCM_NLONGBITS(p) (bc[((unsigned char *)(p))[0]]\
+ bc[((unsigned char *)(p))[1]])
-#elif LONG_MAX >> 32 == 0
+#elif LONG_MAX >> 32 == 0 || LONG_MAX == 2147483647L /* bug in Sun CC 4.2 */
#define SCM_NLONGBITS(p) (bc[((unsigned char *)(p))[0]]\
+ bc[((unsigned char *)(p))[1]]\
+ bc[((unsigned char *)(p))[2]]\
+ bc[((unsigned char *)(p))[5]]\
+ bc[((unsigned char *)(p))[6]]\
+ bc[((unsigned char *)(p))[7]])
+#else
+#error Could not determine suitable definition for SCM_NLONGBITS
#endif
#ifdef HAVE_BZERO
if (t->exceptfds != NULL && ((ulongptr) t->exceptfds)[i] != 0)
((ulongptr) &gexceptfds)[i] |= ((ulongptr) t->exceptfds)[i];
cont_except:
+ ;
}
}
timeout0.tv_usec = 0;
#endif
init_bc (0x80, 0, 0);
-#include "iselect.x"
+#ifndef SCM_MAGIC_SNARFER
+#include "libguile/iselect.x"
+#endif
}
#endif /* GUILE_ISELECT */
return coop_global_curr->retval;
#endif /* GUILE_ISELECT */
}
+
+/*
+ Local Variables:
+ c-file-style: "gnu"
+ End:
+*/