meulenbr@cstw01.UUCP (Frans Meulenbroeks) (11/18/88)
Hi! Here are patches which will get the BSD 4.3 curses running under minix. According to the header files the BSD 4.3 curses may be distributed freely, and is (apart from the BSD tape) also available on the 1987 SUG (Sun User Group) tape. (from which I got mine) Otherwise: ask a friendly university nearby. Get a copy somewhere. Don't ask me to post it. I just think posting this here is not a good idea. I've offered Rich Salz the stuff for comp.sources.unix, but he thinks they are widely enough available. I will also not mail the stuff to you unless you're only a few hops away and cannot get it in some other way. The following changes were made: cr_put.c: added a static. cr_tty.c: I didn't have a lcase. Hacked something around it. printw.c: made a very ugly kludge here, but it seems to work scanw.c: adapted it to use _doscanf Note: use at own risk I've only tested this under minix ST You'll need some of the EFTH reports. (At least the one about varargs. I'll try to come up with diffs for gnuchess 2 and wanderer somewhere next week. Enjoy, Frans. # This is a shell archive. # Remove everything above and including the cut line. # Then run the rest of the file through sh. -----cut here-----cut here-----cut here-----cut here----- #!/bin/sh # shar: Shell Archiver # Run the following text with /bin/sh to create: # cr_put.c.cdiff # cr_tty.c.cdiff # printw.c.cdiff # scanw.c.cdiff # This archive created: Fri Nov 18 10:46:44 1988 sed 's/^X//' << \SHAR_EOF > cr_put.c.cdiff X*** ../../../src/SUG/freeunix/curses/cr_put.c Tue Jul 28 08:56:49 1987 X--- ./cr_put.c Thu Nov 17 15:01:23 1988 X*************** X*** 32,38 **** X X static int outcol, outline, destcol, destline; X X! WINDOW *_win; X X mvcur(ly, lx, y, x) X int ly, lx, y, x; { X--- 32,38 ---- X X static int outcol, outline, destcol, destline; X X! static WINDOW *_win; X X mvcur(ly, lx, y, x) X int ly, lx, y, x; { SHAR_EOF sed 's/^X//' << \SHAR_EOF > cr_tty.c.cdiff X*** ../../../src/SUG/freeunix/curses/cr_tty.c Wed Jul 29 04:22:14 1987 X--- ./cr_tty.c Thu Nov 17 14:31:02 1988 X*************** X*** 63,69 **** X--- 63,73 ---- X _tty.sg_flags = _res_flg; X ospeed = _tty.sg_ospeed; X _res_flg = _tty.sg_flags; X+ #ifdef LCASE X UPPERCASE = (_tty.sg_flags & LCASE) != 0; X+ #else LCASE X+ UPPERCASE = 0; X+ #endif LCASE X GT = ((_tty.sg_flags & XTABS) == 0); X NONL = ((_tty.sg_flags & CRMOD) == 0); X _tty.sg_flags &= ~XTABS; SHAR_EOF sed 's/^X//' << \SHAR_EOF > printw.c.cdiff X*** ../../../src/SUG/freeunix/curses/printw.c Tue Jul 28 10:26:55 1987 X--- ./printw.c Thu Nov 17 15:12:37 1988 X*************** X*** 71,76 **** X { X char buf[512]; /* Bogus, but what are we to do? */ X X! (void) vsprintf(buf, fmt, *args); X return waddstr(win, buf); X } X--- 71,76 ---- X { X char buf[512]; /* Bogus, but what are we to do? */ X X! (void) sprintf(buf, fmt, *args); X return waddstr(win, buf); X } SHAR_EOF sed 's/^X//' << \SHAR_EOF > scanw.c.cdiff X*** ../../../src/SUG/freeunix/curses/scanw.c Tue Jul 28 08:57:01 1987 X--- ./scanw.c Thu Nov 17 15:09:31 1988 X*************** X*** 49,54 **** X char *fmt; X int *args; X { X! fprintf(stderr, "NEED TO FIX SCANW()\n"); X! exit(-1); X } X--- 49,56 ---- X char *fmt; X int *args; X { X! char buf[256]; X! if (wgetstr(win, buf) == ERR) X! return ERR; X! return _doscanf(1, buf, fmt, args); X } SHAR_EOF # End of shell archive exit 0 -- Frans Meulenbroeks (meulenbr@cst.prl.philips.nl) Centre for Software Technology ( or try: ...!mcvax!philmds!prle!cst!meulenbr)