news@coldbeer.UUCP (news) (01/02/88)
Hello world, Enclosed is the patch I made to change the source of vn 8/87 that Bob Mcqueer recently posted to alt.sources so that it would run on my SCO Xenix system. If you haven't tried Bob's 'vn' news reader I strongly suggest you give it a try. I find it quite a time saver. It lets me quickly skim over a large number of news articles, read the good stuff, and skip the dross. The system here is SCO XENIX SYS V REL 2.2. The development system is XENIX SYS V Development System Release 2.1.3 My comments in my posting about bringing up vn on a SYS V Rel. 2.0 ATT 3B5 pretty much apply here with the following extra comments. In pagefile.c and stat.c I had to comment out the line #include <sys/file.h>. In the Makefile I removed the -O option. All the modules expect sessions.c compiled with the -O option. The compiler complained that sessions.c was too big for the post-optimiser. You can compile all the modules with -O expect sessions.c and then compile sessions.c without it. I decided I didn't want to complicate the Makefile for a minor increase in performance. I added the machine flags -M2l to CFLAGS and the linking phase. Users running news on an XT should remove the 2. I use -F 8000 in the link phase to set a fixed stack size of 32K bytes. A fixed stack size is necessary here because of a bug in certain versions of the Xenix development system. If the default variable stack is selected with my system, vn core dumps immediately and adb says it blew up in procedure _stkgro. I've seen this bug before and it can be avoided by using a fixed size stack. A fixed stack of 32K is probably overkill. I don't know how to determine the optimum stack size. Comparing the performance of vn on my Xenix vis-a-vis the 3B5 at work I note that vn starts up a lot slower on the Xenix system. The bottle neck is the slower disk access due to slow winchesters and having the whole file system on one disk. Once started, vn presents the screens a rapid manner. Love your news reader Bob! Thanks! Patch follows. ############## patch starts here ########################### Index: Makefile 49,51c49,51 < #LIBS = -ltermcap < #EXTRAOBJS = tmpnam.o < #CFLAGS = -O -DSYSV -Dregfree=free -Dindex=strchr -Drindex=strrchr --- > LIBS = -ltermcap > EXTRAOBJS = tmpnam.o > CFLAGS = -M2l -DSYSV -Dregfree=free -Dindex=strchr -Drindex=strrchr 75,78c75,76 < vn: < @echo "PLEASE READ THE MAKEFILE" < #vn: $(VNOBJS) $(EXTRAOBJS) $(SERVEROBJS) < # cc -o vn $(VNOBJS) $(EXTRAOBJS) $(SERVEROBJS) $(LIBS) --- > vn: $(VNOBJS) $(EXTRAOBJS) $(SERVEROBJS) > cc -M2l -F 8000 -o vn $(VNOBJS) $(EXTRAOBJS) $(SERVEROBJS) $(LIBS) Index: config.h 9c9 < #define DEF_ED "/usr/ucb/vi" /* editor to use if no EDITOR variable */ --- > #define DEF_ED "/usr/bin/vi" /* editor to use if no EDITOR variable */ 13c13 < #define DEF_PRINT "/usr/ucb/lpr" /* print command */ --- > #define DEF_PRINT "/usr/bin/lp" /* print command */ 24c24 < #define QUIT_ANSWER "yes" --- > #define QUIT_ANSWER "" 61,62d60 < ** < ** #define USEVS 63a62,63 > #define USEVS > Index: config_std.h 25,26d24 < ** < #define MAILCHOOSE 27a26,27 > #define MAILCHOOSE > /* Index: std.c 16a17 > #define MAXPATHLEN 240 Index: svart.c 144c144,151 < if (mkdir(dir,0755) != 0) --- > #ifdef SYSV > (void) sprintf(msg,"mkdir %s",dir); > if (system(msg) == 0) > (void) chmod(dir,0755); > else > #else > if (mkdir(dir,0755) != 0) > #endif Index: pagefile.c 16,17c16,17 < #include <sys/file.h> < --- > /* #include <sys/file.h> > */ Index: stat.c 13c13,14 < #include <sys/file.h> --- > /* #include <sys/file.h> > */ -- Dennis Roth @ CENTEL Information Systems, Inc. 5515 Security Lane, Rockville, Maryland, 20852, (301) 984-3636 abUSENET {decuac, grebyn, netsys}!macom1!roth DZY DZY 001E - ABEND ERROR 01 S 14F4 302C AABF ABORT <-- punch line to an old joke