Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!seismo!husc6!cmcl2!rutgers!ucla-cs!zen!ucbvax!decvax!ima!haddock!karl From: karl@haddock.ISC.COM (Karl Heuer) Newsgroups: comp.emacs Subject: Re: GNU exists on IBM RT running AIX Message-ID: <775@haddock.ISC.COM> Date: Tue, 21-Jul-87 20:06:15 EDT Article-I.D.: haddock.775 Posted: Tue Jul 21 20:06:15 1987 Date-Received: Thu, 23-Jul-87 06:46:38 EDT References: <640@haddock.UUCP> <711@haddock.ISC.COM> <721@haddock.ISC.COM> Reply-To: karl@haddock.ima.isc.com (Karl Heuer) Distribution: world Organization: Interactive Systems, Boston Lines: 198 Summary: Part 3: src/s-aix.h This is s-aix.h, the third installment of the AIX patches. I chose to make a new s- file rather than using s-usg5-2-2.h and hacking config.h; there seemed to be enough differences to justify calling it a separate flavor of UNIX. I defined the cpp symbol USG because it is a SysV derivative, and also defined the symbol AIX for more specific testing. The lisp variable system-type is set to 'aix, which may or may not be a good idea. Old versions of AIX don't have a select system call. (You can check for it by typing "ar t /lib/libc.a select.o".) If you don't have it, you should turn off HAVE_SELECT. Do this in config.h (see next posting), not s-aix.h. If you do have select, make sure it isn't being clobbered by the bogus select in libcurses. To test this, type "cd /tmp; ar x /usr/lib/libcurses.a select.o && size select.o"; if you get a non-zero result you have a problem. You should get rid of the bogus routine with "ar d /usr/lib/libcurses.a select.o" if you have root permission, otherwise just make a local copy of libcurses and hack the Makefile to load it instead of the one in /usr/lib. Karl W. Z. Heuer (ima!haddock!karl or karl@haddock.isc.com), The Walking Lint ---- cut here ---- #!/bin/sh cat <<\EOF >s-aix.h /* Definitions file for GNU Emacs running on AIX Copyright (C) 1985, 1986 Free Software Foundation, Inc. This file is part of GNU Emacs. GNU Emacs is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY. No author or distributor accepts responsibility to anyone for the consequences of using it or for whether it serves any particular purpose or works at all, unless he says so in writing. Refer to the GNU Emacs General Public License for full details. Everyone is granted permission to copy, modify and redistribute GNU Emacs, but only under the conditions described in the GNU Emacs General Public License. A copy of this license is supposed to have been given to you along with GNU Emacs so you can know your rights and responsibilities. It should be in a file named COPYING. Among other things, the copyright notice and this notice must be preserved on all copies. */ /* * Define symbols to identify the version of Unix this is. * Define all the symbols that apply correctly. */ #define AIX #define USG /* Close enough */ #define USG5 /* SYSTEM_TYPE should indicate the kind of system you are using. It sets the Lisp variable system-type. */ #define SYSTEM_TYPE "aix" /* nomultiplejobs should be defined if your system's shell does not have "job control" (the ability to stop a program, run some other program, then continue the first one). */ #define NOMULTIPLEJOBS /* Default is to set interrupt_input to 0: don't do input buffering within Emacs */ /* #define INTERRUPT_INPUT */ /* Letter to use in finding device name of first pty, if system supports pty's. 'p' means it is /dev/ptyp0 */ #define FIRST_PTY_LETTER 'p' /* * Define HAVE_TERMIO if the system provides sysV-style ioctls * for terminal control. */ #define HAVE_TERMIO /* * Define HAVE_TIMEVAL if the system supports the BSD style clock values. * Look infor a timeval structure. */ /* #define HAVE_TIMEVAL */ /* * Define HAVE_SELECT if the system supports the `select' system call. */ #define HAVE_SELECT /* * Define HAVE_PTYS if the system supports pty devices. */ /* #define HAVE_PTYS */ /* Define HAVE_SOCKETS if system supports 4.2-compatible sockets. */ /* #define HAVE_SOCKETS */ /* * Define NONSYSTEM_DIR_LIBRARY to make Emacs emulate * The 4.2 opendir, etc., library functions. */ #define NONSYSTEM_DIR_LIBRARY /* Define this symbol if your system has the functions bcopy, etc. */ #define BSTRING /* we can emulate them as follows: */ #define bcopy(src, dst, len) (void)memcpy(dst, src, len) #define bzero(buf, len) (void)memset(buf, '\0', len) #define bcmp memcmp /* subprocesses should be defined if you want to have code for asynchronous subprocesses (as used in M-x compile and M-x shell). This is supposed to work now on system V release 2. */ #define subprocesses /* If your system uses COFF (Common Object File Format) then define the preprocessor symbol "COFF". */ #define GPOFF /* This is almost like COFF */ /* define MAIL_USE_FLOCK if the mailer uses flock to interlock access to /usr/spool/mail/$USER. The alternative is that a lock file named /usr/spool/mail/$USER.lock. */ /* #define MAIL_USE_FLOCK */ /* Define CLASH_DETECTION if you want lock files to be written so that Emacs can tell instantly when you try to modify a file that someone else has modified in his Emacs. */ /* #define CLASH_DETECTION */ /* Define SHORTNAMES if the C compiler can distinguish only short names. It means that the stuff in ../shortnames must be run to convert the long names to short ones. */ /* #define SHORTNAMES */ /* We use the Berkeley (and usg5.2.2) interface to nlist. */ #define NLIST_STRUCT /* The file containing the kernel's symbol table is called /unix. */ #define KERNEL_FILE "/unix" /* The symbol in the kernel where the load average is found is named avenrun. */ #define LDAV_SYMBOL "avenrun" /* Special hacks needed to make Emacs run on this system. */ /* setjmp and longjmp can safely replace _setjmp and _longjmp, but they will run slower. */ #define _setjmp setjmp #define _longjmp longjmp /* On USG-based systems the system calls are interruptable by signals that the user program has elected to catch. Thus the system call must be retried in these cases. To handle this without massive changes in the source code, we remap the standard system call names to names for our own functions in sysdep.c that do the system call with retries. */ #define read sys_read #define open sys_open #define write sys_write #define INTERRUPTABLE_OPEN #define INTERRUPTABLE_IO /* On USG-based systems these have different names */ #define index strchr #define rindex strrchr /* AIX handles static bss correctly */ /* #define static */ /* Either this definition or the default should generate the same code */ #define ADDR_CORRECT(x) (x) /* Use terminfo instead of termcap. */ #define TERMINFO EOF exit 0