timer_ef = get_timer_event_flag ();
/* LIB$GET_EF (&timer_ef); */
SYS$CLREF (timer_ef);
+#if 0
if (!process_ef)
{
LIB$GET_EF (&process_ef);
}
if (input_ef / 32 != process_ef / 32)
croak ("Input and process event flags in different clusters.");
+#endif
if (input_ef / 32 != timer_ef / 32)
- croak ("Input and process event flags in different clusters.");
+ croak ("Input and timer event flags in different clusters.");
+#if 0
input_eflist = ((unsigned) 1 << (input_ef % 32)) |
((unsigned) 1 << (process_ef % 32));
+#endif
timer_eflist = ((unsigned) 1 << (input_ef % 32)) |
((unsigned) 1 << (timer_ef % 32));
#ifndef VMS4_4
queue_kbd_input ()
{
int status;
+ extern kbd_input_ast ();
+
waiting_for_ast = 0;
stop_input = 0;
status = SYS$QIO (0, input_fd, IO$_READVBLK,
#endif
if (! stop_input)
queue_kbd_input ();
-/* I don't know what this is doing! The variables buf, cbuf and i are
- not declared. This is new from version 18, what does it do?
if (c >= 0)
{
struct input_event e;
e.kind = ascii_keystroke;
- XSET (buf[i].code, Lisp_Int, cbuf[i]);
- e.frame = selected_frame;
+ XSET (e.code, Lisp_Int, c);
+#ifdef MULTI_FRAME
+ XSET(e.frame_or_window, Lisp_Frame, selected_frame);
+#else
+ e.frame_or_window = Qnil;
+#endif
kbd_buffer_store_event (&e);
}
-*/
if (input_available_clear_time)
EMACS_SET_SECS_USECS (*input_available_clear_time, 0, 0);
errno = old_errno;
#endif /* not USG, not 4.1 */
#endif /* not USG */
}
+
+#ifdef VMS
+#ifndef HAVE_GETHOSTNAME
+void gethostname(buf, len)
+ char *buf;
+ int len;
+{
+ char *s;
+ s = getenv ("SYS$NODE");
+ if (s == NULL)
+ buf[0] = '\0';
+ else {
+ strncpy (buf, s, len - 2);
+ buf[len - 1] = '\0';
+ } /* else */
+} /* static void gethostname */
+#endif /* ! HAVE_GETHOSTNAME */
+#endif /* VMS */
+
\f
#ifndef VMS
#ifndef HAVE_SELECT
char *pathname;
{
char *ptr;
- strcpy (pathname, egetenv ("PATH"));
+ extern char *getcwd ();
- ptr = pathname;
- while (*ptr)
- {
- if ('a' <= *ptr && *ptr <= 'z')
- *ptr -= 040;
- ptr++;
- }
- return pathname;
+#define MAXPATHLEN 1024
+
+ ptr = malloc (MAXPATHLEN);
+ getcwd (ptr, MAXPATHLEN);
+ strcpy (pathname, ptr);
+ free (ptr);
+
+ return pathname;
}
getppid ()
extern long timezone;
#endif
+#ifdef VMS
+#ifdef VAXC
+#include "vmstime.h"
+#endif
+#endif
+
\f
/* EMACS_TIME is the type to use to represent temporal intervals -
struct timeval on some systems, int on others. It can be passed as
#ifndef EMACS_CURRENT_TIME_ZONE
/* System V derivatives have a timezone global variable. */
-#ifdef USG
+#if defined(USG) || defined(VMS)
#define EMACS_GET_TZ_OFFSET(offset) \
do { \
tzset (); \
/* The following sane systems have a tzname array. The timezone() function
is a stupid idea; timezone names can only be determined geographically,
not by Greenwich offset. */
-#if defined (ultrix) || defined (hpux) || defined (_AIX) || defined (USG)
+#if defined (ultrix) || defined (hpux) || defined (_AIX) || defined (USG) || defined(VMS)
#define EMACS_GET_TZ_NAMES(standard, savings) \
do { \
/* The default search path for Lisp function "load".
This sets load-path. */
-#define PATH_LOADSEARCH "EMACS_LIBRARY:[LISP]"
+#define PATH_LOADSEARCH "EMACS_LIBRARY:[LOCAL-LISP],EMACS_LIBRARY:[LISP]"
/* Like PATH_LOADSEARCH, but used only when Emacs is dumping. This
path is usually identical to PATH_LOADSEARCH except that the entry
variable exec-path and the first file name in it sets the Lisp
variable exec-directory. exec-directory is used for finding
executables and other architecture-dependent files. */
-#define PATH_EXEC "EMACS_LIBRARY:[ETC]"
+#define PATH_EXEC "EMACS_LIBRARY:[LIB-SRC]"
/* Where Emacs should look for its architecture-independent data
files, like the docstring file. The lisp variable data-directory