From: HENRY::IN%"carl%cithex.caltech.edu%sri-kl.ARPA%relay.cs.net@rca.com" 22-MAR-1987 07:53 To: munnari!murdu.oz!u3369429@seismo.css.gov, info-vax@cithex.caltech.edu Subj: Re: bigsis > Our JPIDEF.H looks probably different from yours, but that can be fixed by > commenting your JPI define`s. But I cant't find PCBDEF.H nor any PCB-symbols > in any library. What am I missing? You need to extract and edit the module $PCBDEF from SYS$SHARE:LIB.MLB. If you'd rather not edit it by hand, the following procedure is a crude MACRO to C include file converter (i.e., it simply takes the definitions in the macro code and converts them to C #defines; it doesn't attempt to define the appropriate structures/unions. Maybe someday there will be a shareable image to enable the use of SDL to do such things for C [anybody from DEC listening? If so, this is part of my wishlist, as is documentation for SDL]) $!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! $ set noon $ IF "''F$SEARCH("TMPFILE.TMP")'" .NES. "" THEN delete tmpfile.tmp;* $ on error then goto oops $ library/extract='p1'/output=tmpfile.tmp/macro sys$share:starlet $ goto form $ oops: on error then exit $ library/extract='p1'/output=tmpfile.tmp/macro sys$share:lib $ form: ON ERROR THEN GOTO DONE $ OPEN/READ INFILE tmpfile.tmp $ DELETE TMPFILE.TMP; $ OPEN/WRIT OUFILE TMPFILE.TMP $ MAXLEN = 0 $ LOOP: READ/ERRO=SORT INFILE SYM $ sym = f$edit(sym,"COMPRESS,TRIM") $ if f$element(0," ", sym) .nes. "$EQU" then goto LOOP $ token = f$element(1," ",sym) $ IF F$LEN(TOKEN) .GT. MAXLEN THEN MAXLEN = F$LEN(TOKEN) $ value = F$FAO("!XL",f$integer(f$element(2," ",sym))) $ WRITE OUFILE VALUE,TOKEN $ IF "''P2'" .NES. "" THEN WRITE 'P2' VALUE,TOKEN $ GOTO LOOP $ SORT: CLOSE INFILE $ CLOSE OUFILE $ SORT/KEY=(POS=9,SIZ='MAXLEN') TMPFILE.TMP TMPFILE.TMP $ OPEN/READ INFILE TMPFILE.TMP $ DELETE TMPFILE.TMP;* $ OPEN/WRITE OUFILE 'P1'.H $ SPACES = F$FAO("!#* ", MAXLEN + 1) $ MAXLEN = MAXLEN + 9 $ NICE: READ/ERR=DONE INFILE SYM $ VALUE = F$EXTRACT(0,8,SYM) $ SYM = SYM - VALUE + F$EXTR(0, MAXLEN-F$LEN(SYM), SPACES) + "0x" + VALUE $ WRITE OUFILE "#define ", SYM $ IF "''P2'" .NES. "" THEN WRITE 'P2' "#define ", SYM $ GOTO NICE $ DONE: CLOSE INFILE $ CLOSE OUFILE $ IF "''F$SEARCH("TMPFILE.TMP")'" .NES. "" THEN delete tmpfile.tmp;* $!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!