diff options
author | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
commit | e0c6872cf40896c7be36b11dcc744620f10adf1d (patch) | |
tree | 60335e10d2f4354b0674ec22d7b53f0f8abee672 /systems/os2 |
Initial commit
Diffstat (limited to 'systems/os2')
47 files changed, 5279 insertions, 0 deletions
diff --git a/systems/os2/README.commontex b/systems/os2/README.commontex new file mode 100644 index 0000000000..d2bf651bd1 --- /dev/null +++ b/systems/os2/README.commontex @@ -0,0 +1,77 @@ +This is a port of Common TeX 3.3 for OS/2 using EMX-0.8f.
+
+See the file COPYING for rights, responsibilities, and limitations.
+
+One of the best TeX implementations around is EmTeX. However, it has
+one "feature" that doesn't utilize the full capabilities of OS/2,
+especially when HPFS is used: long file names are not accepted. This
+port of Common TeX does not have this restriction.
+
+Features and Limitations
+------------------------
+
+Some limitations of Common Tex:
+
+ o Parts from EmTeX like the tfm and tex input files are
+ needed. The DVI programs from EmTeX will also be need if
+ you want to see actual output.
+
+
+Here are some basic features of Common TeX:
+
+ o Supports long file names on HPFS partitions.
+ o Will not give "TeX out of memory" errors until you run out
+ of virtual memory.
+ o Preloads formats, which (marginally) speeds up loading.
+ o Doesn't need TeX format files.
+ o Runs about twice as fast as btexp.
+
+Installation
+------------
+Be sure to put the dll directory of this archive in your LIBPATH!!!
+You can install the executables anywhere. Then set the environment
+variables TEXFONTS and TEXINPUTS. If you have EmTeX, make TEXINPUTS
+the same as TEXINPUT and TEXFONTS the same as TEXTFM. However, you
+must include the drive letter and replace all backslashes with forward
+slashes. For example, if you have
+
+ set EMTEXDRV=f
+ set TEXINPUT=.;\emtex\texinput
+ set TEXTFM=.;\emtex\tfm;\emtex\fonts\tfm
+
+then do
+
+ set TEXINPUTS=.;f:/emtex/texinput
+ set TEXFONTS=.;f:/emtex/tfm;f:/emtex/fonts/tfm
+
+Usage
+-----
+
+If you want to run LaTeX, use
+
+ latex texfile
+
+You do not need to specify "^&lplain". Typically, the equivalent
+EmTeX command would be "btexp ^&lplain texfile".
+
+For TeX plain format, use "tex". This is equivalent to "btexp
+^&plain" in EmTeX.
+
+To create (or update) your own formats, give the following commands:
+
+ initex mystyle \dump
+ emxbind -x initex.exe a.out
+ emxbind -ccore /emx/bin/emxl.exe mytex.exe
+ del core
+ del a.out
+
+Your format is "mystyle" and the resulting command is "mytex.exe"
+which will have "mystyle" preloaded. Of course, to do this you need
+emxbind to do this.
+
+Recommendations
+---------------
+
+Get a copy of EmTeX first. Follow the instructions that come with
+EmTeX and make it work first. Then install Common TeX.
+
diff --git a/systems/os2/bbibtex.zooos2 b/systems/os2/bbibtex.zooos2 Binary files differnew file mode 100644 index 0000000000..ce9dde3843 --- /dev/null +++ b/systems/os2/bbibtex.zooos2 diff --git a/systems/os2/binaries/dvi2tty.txt b/systems/os2/binaries/dvi2tty.txt new file mode 100644 index 0000000000..6680f680e8 --- /dev/null +++ b/systems/os2/binaries/dvi2tty.txt @@ -0,0 +1,15 @@ +Archive Name: dvi2tty.zip +Program Description: dvi file viewer for tty output devices, like + text mode sessions (probably via telnet), or line printers. + +Operating System Versions: OS/2 2.1 and OS/2 Warp + (this version's binaries have been compiled on Warp, but they do compile + on OS/2 2.1, too, so I guess they will run there as well.) + +Program Source: included, from CTAN site ftp.shsu.edu +Replaces: A huge gap + +Your name: Stefan A. Deutscher +Your email address: sad@utkux.utk.edu + +Proposed directory for placement: /tex-archive/systems/os2/binaries diff --git a/systems/os2/binaries/maketexpk.cmd b/systems/os2/binaries/maketexpk.cmd new file mode 100644 index 0000000000..f15b738bae --- /dev/null +++ b/systems/os2/binaries/maketexpk.cmd @@ -0,0 +1,394 @@ +/*
+
+Translated from Piet Tutelaar's Unix shell script
+into Rexx by Sebastian Rahtz, 15.8.92 (spqr@minster.york.ac.uk)
+
+last change: 28.12.92
+
+ This script file makes a new TeX PK font, because one wasn't
+ found. Parameters are:
+
+ name dpi bdpi magnification [[mode] subdir]
+
+ `name' is the name of the font, such as `cmr10'. `dpi' is
+ the resolution the font is needed at. `bdpi' is the base
+ resolution, useful for figuring out the mode to make the font
+ in. `magnification' is a string to pass to MF as the
+ magnification. `mode', if supplied, is the mode to use.
+
+ Note that this file must execute MetaFont (and then gftopk) or
+ ps2pk, and place the result in the correct location for the
+ PostScript driver to find it subsequently. If this doesn't work,
+ it will be evident because the program will be invoked over and over again.
+
+ If no MetaFont source is available for `name' and the fontname
+ starts with a `r' or is available in $TEXCONFIG/adobe then the
+ program tries to find a type1 font. If such a font is located
+ ps2pk will be used to render the font.
+
+ Of course, it needs to be set up for your site with regard to paths etc
+*/
+
+PARSE Arg all_args
+argc=words(all_args)
+if ( argc < 4 | argc > 6 ) then
+do
+ say "Usage: maketexpk fontname dpi bdpi magnification [[mode] subdir]"
+ exit 1
+end
+
+call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
+call SysLoadFuncs
+os2env='OS2ENVIRONMENT'
+
+/* destination of pk files */
+DESTDIR='d:\texfonts\pixel.lj'
+
+/* Where we look for METAFONT sources */
+OLDMFINPUT=value('MFINPUT',,os2env)
+if OLDMFINPUT='' then
+do
+ OLDMFINPUT='d:\emtex\mfinput'
+end
+MFINPUT=OLDMFINPUT
+/*
+look for subdirs to add to path;
+should find, eg, cm concrete dc euler pandora punk wasy
+*/
+call SysFileTree OLDMFINPUT"\*.*",'fam','D'
+do i=1 to fam.0
+ MFINPUT=MFINPUT';'word(fam.i,5)
+end
+MFINPUT=value('MFINPUT',MFINPUT,os2env)
+MFINPUT=value('MFINPUT',,os2env)
+/* say 'search path: ' MFINPUT */
+
+/* Where we look for Type1 fonts and AFM files */
+T1INPUTS=value('T1INPUTS',,os2env)
+if T1INPUTS='' then
+do
+ T1INPUTS='d:\emtex\ps'
+ T1INPUTS=value('T1INPUTS',T1INPUTS,os2env)
+ T1INPUTS=value('T1INPUTS',,os2env)
+end
+
+/* Where we look for dvips stuff */
+TEXCONFIG='d:\emtex\ps'
+
+listoftype1files=TEXCONFIG'\fontname'
+
+/*
+ TEMPDIR needs to be unique for each process because of the possibility
+ of simultaneous processes running this script.
+*/
+TEMPDIR=SysTempFileName("d:/tmp/mtpk.???")
+
+NAME=word(all_args,1)
+DPI=word(all_args,2)
+BDPI=word(all_args,3)
+MAG=word(all_args,4)
+if argc > 4 then
+ MODE=word(all_args,5)
+else
+ if BDPI = 300 then
+ MODE='hplaser'
+ else if BDPI = 1270 then
+ MODE='linohi'
+ else if BDPI = 2540 then
+ MODE='linosuper'
+ else
+ do
+ say 'I do not know the mode for ' BDPI
+ say 'update this MakeTeXPK script'
+ exit 1
+ end
+
+if argc > 5 then
+ SUBDIR=word(all_args,6)
+else
+ SUBDIR=BDPI'dpi'
+
+
+PKNAME=NAME'.pk'
+DESTDIR=DESTDIR'\'DPI'DPI'
+
+say 'making for ' MODE ' in ' DESTDIR SUBDIR
+/*
+say 'temporary output file is 'TEMPDIR'\'PKNAME
+*/
+call sysfiletree DESTDIR ,'test', 'OD'
+if test.0=0 then
+ call SysMkDir DESTDIR
+/*
+else
+ say 'directory' DESTDIR 'exists'
+*/
+destpk=DESTDIR'\'PKNAME
+fname = stream(destpk , 'C', 'QUERY EXISTS')
+if \ (fname ='') then
+ do
+ say DESTDIR'\'PKNAME 'already exists!'
+ exit 0
+ end
+
+/* OK, try to make the font by some means */
+
+/* first try Adobe Type1 fonts
+
+ What encoding scheme do we use for Type1 text fonts?
+
+ Strip off the first letter and last letters
+ and see if that gives us a hint
+*/
+
+DEF_TEXT_ENCODING=' '
+PREFIX=left(NAME,1)
+SUFFIX=right(NAME,1)
+
+select
+when PREFIX='r' then
+ do
+ VNAME=substr(NAME,2)
+ DEF_TEXT_ENCODING=' '
+ end
+when SUFFIX='0' then
+ do
+ VNAME=left(NAME,length(NAME)-1)
+ DEF_TEXT_ENCODING="-eEC.enc" /* (Extended Computer Modern) */
+ end
+otherwise
+ VNAME=NAME
+end
+
+call sysfilesearch VNAME' ',listoftype1files, 'FILE.','C'
+
+/* if that succeeded, the variable FILE contains the
+matching lines in the file describing the fonts */
+
+if rc=3 then
+do
+ say 'You should install file ' listoftype1files
+ exit 0
+end
+FULLNAME='!'
+slant=""
+VVNAME=VNAME
+if FILE.0>0 then
+ do i=1 to file.0
+ if word(file.i,1)=VNAME then
+ do
+ FULLNAME=word(file.i,2)
+ if words(file.i) > 2 then
+ do
+ slant="-S "||word(file.i,3)
+ VVNAME=left(VNAME,length(VNAME)-1)
+ end
+ leave
+ end
+ end
+if FULLNAME='!' then /* failed to locate a name in the list
+
+ Do we have a METAFONT source for this typeface?
+*/
+ do
+ if substr(NAME,1,3)='fmv' then
+ mfname=malvern(NAME) /* Malvern font */
+ else
+ mfname=syssearchpath('MFINPUT',NAME'.mf')
+ say 'Result of MF search: 'mfname
+ if mfname='' then
+ do
+ say 'Sorry, no PostScript font or Metafont font found'
+ exit 1
+ end
+ job='@mfp \mode:='MODE'; mag:='MAG'; scrollmode; input 'name
+/*
+really no need to use a temporary directory, I think, in this environment
+
+ curdir=directory()
+ call SysMkDir TEMPDIR
+ newdir= directory(TEMPDIR)
+*/
+ job
+ if substr(NAME,1,3)='fmv' then /* Malvern font */
+ x=sysfiledelete(NAME||'.mf')
+ GFNAME=NAME'.'DPI
+/* if (stream( GFNAME, 'C', 'QUERY EXISTS') = '') then
+ do
+ say 'Metafont failed for some reason on 'GFNAME' ('NAME')'
+ exit 1
+ end
+ */
+ '@gftopk' GFNAME PKNAME
+ '@copy' PKNAME destpk
+ x=sysfiledelete(GFNAME)
+ x=sysfiledelete(PKNAME)
+ x=sysfiledelete(NAME'.log')
+ /* x=sysfiledelete(NAME'.tfm') */
+ exit 0
+ MFINPUT=value('MFINPUT',OLDMFINPUT,os2env)
+ end
+else
+/* we have a Type1 font (at any rate, its in the list!) */
+ afmname=syssearchpath('T1INPUTS',VVNAME'.afm')
+ if afmname='' then
+ do
+ say 'Failed to find afm file for' VVNAME ' in 'T1INPUTS
+ exit 1
+ end
+/* If we don't use default AFM encoding then we have to check
+ if we can apply this encoding (text fonts only)
+*/
+ENCODING=DEF_TEXT_ENCODING
+ if \ (DEF_TEXT_ENCODING = '') then
+ do
+ /* What is encoding scheme that the AFM file uses? */
+ call sysfilesearch 'EncodingScheme',afmname, 'FILE.','C'
+ if file.0=0 then
+ do
+ say afmname': Invalid AFM file! No Encoding line.'
+ exit 0
+ end
+ if length(file.1) > 100 then
+ do
+ say afmname': Invalid AFM file! Encoding line too long.'
+ exit 0
+ end
+ EXT_END=word(file.1,2)
+ select
+ when substr(ext_end,1,6)='AdobeS' then ENCODING=DEF_TEXT_ENCODING
+ when substr(ext_end,1,3)='ISO' then ENCODING=DEF_TEXT_ENCODING
+ otherwise
+ ENCODING=''
+ end
+ end
+/*
+ if substr(NAME,1,3)='hlc' then
+ do
+ ENCODING="-eEC.enc"
+ say 'applying EC encoding'
+ end
+*/
+ pfbname=syssearchpath('T1INPUTS',VVNAME'.pfa')
+ if pfbname='' then
+ do
+ pfbname=syssearchpath('T1INPUTS',VVNAME'.pfb')
+ if pfbname='' then
+ do
+ say 'Source for font' VVNAME 'not found on path 'T1INPUTS
+ exit 1
+ end
+ end
+ job='@ps2pk -X'DPI ENCODING SLANT filespec('name',pfbname) destpk
+ say job
+ job
+exit 0
+
+malvern: procedure
+arg fontname
+/* Malvern generation
+#
+# The font name is of the form
+#
+# fmvWVV## Karl Berry's standard font names
+#
+# where W denotes a weight (one of t, i, l, k, r, d, b, x, c)
+# VV denotes a "variation" (one of <empty>, rn, re, i, in, ie)
+# ## is the design size, in points
+#
+# or
+# maXXx## my nonstandard font names
+#
+# where XX is 2 digits giving a style in the tradition of Univers
+# x is a suffix describing the character set of the font
+# ## is the design size, in points (with p as decimal point)
+#
+# Examples:
+#
+# fmvr10 ma55a10 Malvern 55 10-pt
+# fmvd10 ma65a10 Malvern 65 demibold 10-pt
+# fmvbix18 ma74a18 Malvern 74 bold extended italic 18-pt
+# fmvric7 ma58a7 Malvern 58 condensed italic 7-pt
+#
+# The fmv- fonts all use the Cork encoding.
+#
+*/
+weights.=''
+weights.1= 'weight = 1/4;' /* ultra-light */
+weights.2= 'weight = 1/2;' /* extra-light */
+weights.3= 'weight = 3/4;' /* light */
+weights.4= 'weight = 7/8;' /* book */
+weights.5= 'weight = 1;' /* medium */
+weights.6= 'weight = 1.5;' /* demi */
+weights.7= 'weight = 2;' /* bold */
+weights.8= 'weight = 3;' /* extra */
+weights.9= 'weight = 4;' /* ultra */
+
+weights.t= 'weight = 1/4;' /* thin [ultra-light] */
+weights.i= 'weight = 1/2;' /* extra-lIght */
+weights.l= 'weight = 3/4;' /* Light */
+weights.k= 'weight = 7/8;' /* booK */
+weights.r= 'weight = 1;' /* Regular */
+weights.d= 'weight = 1.5;' /* Demi */
+weights.b= 'weight = 2;' /* Bold */
+weights.x= 'weight = 3;' /* eXtra */
+weights.u= 'weight = 4;' /* Ultra */
+
+styles.=''
+
+styles.9='hratio = 0.3;'
+styles.0='hratio = 0.3; slant := 1/8; italicness = 1;'
+styles.7='hratio = 0.6;'
+styles.8='hratio = 0.6; slant := 1/8; italicness = 1;'
+styles.5='hratio = 1;'
+styles.6='hratio = 1; slant := 1/8; italicness = 1;'
+styles.3='hratio = 1.15;'
+styles.4='hratio = 1.15; slant := 1/8; italicness = 1;'
+styles.1='hratio = 1.30;'
+styles.2='hratio = 1.30; slant := 1/8; italicness = 1;'
+
+styles.i='italicness = 1; slant := 1/8;' /* italic */
+styles.u='italicness = 1;' /* vertical italic */
+styles.o='slant := 1/8;' /* oblique */
+
+/* Berry's system has expansion after variant rather than before: */
+styles.o='hratio = 0.3;' /* narrow (extra condensed) */
+styles.c='hratio = 0.6;' /* compressed */
+styles.x='hratio = 1.15;' /* expanded */
+styles.w='hratio = 1.30;' /* wide (extra expanded) */
+
+/* not used here
+-J 's=encoding=0' # Standard TeX text (like cmr)
+-J 'x=encoding=-200' # Cork (TUGboat 11#4)
+-J 'mi=encoding=-1' # maths (like cmmi)
+-J 'sy=encoding=-2' # symbol (like cmsy)
+-J 'ps=encoding=-1000' # the AdobeStandardEncoding encoding
+-J 'so=encoding=-1010' # the ISOLatin1Encoding encoding
+
+# Malvern encodings:
+-J 'a=encoding=1' # Malvern A (simple letters)
+-J 'b=encoding=2' # Malvern B (strange symbols)
+-J 'c=encoding=3' # Malvern C (composites)
+*/
+rf=reverse(fontname)
+parse var rf n1 +1 n2 +1 .
+if datatype(n2,'N')=1 then
+ size=n2||n1
+else
+ size=n1
+parse var fontname basename (size) .
+parse var basename base +3 weight +1 style +1 expansion
+if style\=' ' then
+ y=value(style)
+else
+ y=''
+if expansion\=' ' then
+ z=value(expansion)
+else
+ z=''
+x=value(weight)
+fontfile=value(fontname)||'.mf'
+call lineout fontfile,'font_size 'size'pt#; 'weights.x styles.y styles.z 'input maltex;bye.'
+call lineout fontfile
+say 'generated Malvern file ' fontfile
+return fontfile
diff --git a/systems/os2/doc/TeX-Math/README b/systems/os2/doc/TeX-Math/README new file mode 120000 index 0000000000..00d9312f86 --- /dev/null +++ b/systems/os2/doc/TeX-Math/README @@ -0,0 +1 @@ +Read.Me
\ No newline at end of file diff --git a/systems/os2/doc/TeX-Math/Read.Me b/systems/os2/doc/TeX-Math/Read.Me new file mode 100644 index 0000000000..bf16a915b0 --- /dev/null +++ b/systems/os2/doc/TeX-Math/Read.Me @@ -0,0 +1,15 @@ +English:
+
+There's not much to tell about TeX-Math.INF, which is intended to help people typesetting
+mathematical formulae. More general advice is available in the first chapter
+"Introduction." To view the file, enter "view tex-math" on any OS/2 shell.
+
+Or create a book in your "Information" folder on your desktop using the following
+procedure:
+a) Drag a "program" template from the "Templates" folder into the "Information" folder.
+b) Enter "view.exe" in the "Path and file name:" box and
+ the full path and file name of the TeX-Math.INF file in the "Parameter:" box.
+c) Select the "General" tab and enter any title you like, e.g. "Math with LaTeX"
+d) Close the "Settings" notebook.
+e) Start with reading the "Introduction" chapter.
+
\ No newline at end of file diff --git a/systems/os2/doc/TeX-Math/TeX-Math.inf b/systems/os2/doc/TeX-Math/TeX-Math.inf Binary files differnew file mode 100644 index 0000000000..039c3e16fb --- /dev/null +++ b/systems/os2/doc/TeX-Math/TeX-Math.inf diff --git a/systems/os2/dviware/hp-deskjet/bitmap.h b/systems/os2/dviware/hp-deskjet/bitmap.h new file mode 100644 index 0000000000..be0d1bd7fc --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/bitmap.h @@ -0,0 +1,65 @@ +/*********************************************************************** +With non-segmented memory, we just allocate the bitmap as a large 2-D +array. Access to elements is concealed in the macro BITMAP(y,x) which +returns the address of the word at the (y,x) position. On segmented +memory machines (Intel iAPX) this can still be done if the bitmap fits +in one segment, and SEGMEM will have been defined accordingly in +dvixxx.c. + +For segmented memories, not all compilers support pointer addressing of +objects larger than a segment, so we implement the bitmap as a vector of +pointers to raster lines, each of which is allocated dynamically. +Element access is again concealed in BITMAP(y,x), but the code has to +ensure that no pointer is ever advanced outside of a raster line. This +affects functions makechar() and prtbmap(). Bitmap access in +dispchar(), fillrect(), and prxbmap() is already restricted to single +raster lines, so no changes are necessary there. + +getbmap() handles the necessary allocation for either of these, so +devinit() in each dvixxx remains ignorant of the details. +***********************************************************************/ + +#if SEGMEM + +UNSIGN32* bitmap[YBIT] = +{ + (UNSIGN32*)NULL /* only first entry need be initialized */ +}; +#if (IBM_PC_MICROSOFT & !OS_IBMOS2) +#define BITMAP(y,x) ((UNSIGN32*)normaddr(bitmap[y],(x)<<2)) +#define FP_SEG(fp) (*((unsigned *)&(fp) + 1)) +#define FP_OFF(fp) (*((unsigned *)&(fp))) + +char* +normaddr(p,byte_offset) /* return address p+byte_offset */ +char *p; +int byte_offset; /* byte_offset may be positive or negative */ +{ + long address; + char *q; + + /* Reconstruct 32-bit address from SEGMENT*16 + OFFSET + byte_offset */ + + address = (long)FP_SEG(p); /* long <- unsigned by zero extend */ + address <<= 4; /* segment real memory address */ + address += (long)FP_OFF(p); /* *p real memory address */ + address += (long)byte_offset;/* *(p+byte_offset) real memory address */ + + /* Renormalize address to OFFSET in 0..15 */ + + FP_OFF(q) = (unsigned)(address & 0x0f); + FP_SEG(q) = (unsigned)(address >> 4); + + return (q); +} +#else /* NOT IBM_PC_MICROSOFT OR OS_IBMOS2 */ +#define BITMAP(y,x) (bitmap[y] + (UNSIGN16)(x)) +#endif /* IBM_PC_MICROSOFT */ + +#else /* NOT SEGMEM */ + +UNSIGN32* bitmap = (UNSIGN32*)NULL; +#define BITMAP(y,x) (bitmap + ((UNSIGN32)XBIT*(UNSIGN32)(y)) + (UNSIGN32)(x)) + +#endif /* SEGMEM */ + diff --git a/systems/os2/dviware/hp-deskjet/dog.dvi b/systems/os2/dviware/hp-deskjet/dog.dvi Binary files differnew file mode 100644 index 0000000000..18e168fb45 --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/dog.dvi diff --git a/systems/os2/dviware/hp-deskjet/doga.dvi b/systems/os2/dviware/hp-deskjet/doga.dvi Binary files differnew file mode 100644 index 0000000000..aeca50e449 --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/doga.dvi diff --git a/systems/os2/dviware/hp-deskjet/dvihpdj.c b/systems/os2/dviware/hp-deskjet/dvihpdj.c new file mode 100644 index 0000000000..cbb2bb88fd --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/dvihpdj.c @@ -0,0 +1,335 @@ +/* -*-C-*- dvijet.c */ +/*-->dvijet*/ +/**********************************************************************/ +/******************************* dvijet *******************************/ +/**********************************************************************/ + +#include "dvihead.h" + +/**********************************************************************/ +/************************ Device Definitions ************************/ +/**********************************************************************/ + +/* All output-device-specific definitions go here. This section must +be changed when modifying a dvi driver for use on a new device */ + +#undef HPLASERJET +#define HPLASERJET 1 /* conditional compilation flag */ + +#define VERSION_NO "2.10" /* DVI driver version number */ + +#define DEVICE_ID "Hewlett-Packard 2686A Laser Jet laser printer" + /* this string is printed at runtime */ + +#define OUTFILE_EXT "jet" + +#define DEFAULT_RESOLUTION 300 /* default dots/inch on HP Laser Jet */ + +#define BYTE_SIZE 8 /* output file byte size */ + +#undef STDRES +#define STDRES 0 /* 0 for low-resolution devices */ + +#define XDPI 300 /* HP DeskJet horizontal dots/inch */ +#define XPSIZE 8 /* horizontal paper size in inches */ + +#define XSIZE (((XDPI*XPSIZE+2*HOST_WORD_SIZE-1)/\ + (2*HOST_WORD_SIZE))*(2*HOST_WORD_SIZE)) + /* number of horizontal dots; */ + /* MUST BE multiple of */ + /* 2*HOST_WORD_SIZE */ +#define XWORDS ((XSIZE + HOST_WORD_SIZE - 1)/HOST_WORD_SIZE) + /* number of words in rows */ + /* of bitmap array */ + +#define YDPI 300 /* HP DeskJet vertical dots/inch */ + +#define YPSIZE 11 /* vertical paper size in inches */ +#define YSIZE (YDPI*YPSIZE) /* number of vertical dots */ + +/* The printer bit map (must have an even number of columns). */ + +#define XBIT ((1+2*XWORDS)/2) +#define YBIT YSIZE +#if (IBM_PC_LATTICE | IBM_PC_MICROSOFT | IBM_PC_WIZARD) +#undef SEGMEM +#define SEGMEM 1 /* ( ((long)XBIT * (long)YBIT) > 65536L ) */ +#endif + +#include "bitmap.h" + +#include "main.h" +#include "abortrun.h" +#include "actfact.h" +#include "alldone.h" +#include "chargf.h" +#include "charpk.h" +#include "charpxl.h" +#include "clrbmap.h" +#include "clrrow.h" +#include "dbgopen.h" + +/*-->devinit*/ +/**********************************************************************/ +/****************************** devinit *******************************/ +/**********************************************************************/ + +void +devinit(argc,argv) /* initialize device */ +int argc; +char *argv[]; +{ + (void)getbmap(); + OUTF("\033E\033*t%dR",(int)hpres); /* printer reset, resolution */ +} + +/*-->devterm*/ +/**********************************************************************/ +/****************************** devterm *******************************/ +/**********************************************************************/ + +void +devterm() /* terminate device */ +{ +} + +#include "dvifile.h" +#include "dviinit.h" +#include "dviterm.h" +#include "dispchar.h" +#include "f20open.h" +#include "fatal.h" +#include "fillrect.h" +#include "findpost.h" +#include "fixpos.h" +#include "fontfile.h" +#include "fontsub.h" +#include "getbmap.h" +#include "getbytes.h" +#include "getfntdf.h" +#include "getpgtab.h" +#include "initglob.h" +#include "inch.h" +#include "loadchar.h" +#include "movedown.h" +#include "moveover.h" +#include "moveto.h" +#include "nosignex.h" +#include "openfont.h" +#include "option.h" + +/*-->outline*/ +/**********************************************************************/ +/****************************** outline *******************************/ +/**********************************************************************/ + +void +outline(pbit) +UNSIGN32 *pbit; /* pointer to raster line */ + +/************************************************************************* +Use machine-specific coding here for efficiency. For TOPS-20, we encode +9 bytes from every pair of 36-bit words. + +For each raster line on the paper, the Laser Jet expects a binary 8-bit +byte stream of the form + + <ESC>*bnnnWxxxxxxx ... xxxxxxx + <--- nnn bytes ---> + +where each byte contains, in order from high to low bit, a left-to-right +bit pattern. No end-of-line marker is required; the escape sequence +automatically causes a new raster line to be started. +*************************************************************************/ + +{ + register UNSIGN32 w_even,w_odd; + register UNSIGN32 *p; + register BYTE *pbuf; + BYTE buf[1+(XSIZE+7)/8]; /* space for EOS + n 8-bit bytes */ + register INT16 i,last_word; + + +#if (IBM_PC_MICROSOFT & !OS_IBMOS2) + for (last_word = XBIT - 1; + (last_word >= 1) && (*(UNSIGN32*)normaddr(pbit,last_word) == 0); + --last_word) + ; /* trim white space a word at a time */ +#else + p = pbit + XBIT - 1; /* point to last word on line */ + for (last_word = XBIT - 1; (last_word >= 1) && (*p == 0); --last_word) + --p; /* trim white space a word at a time */ +#endif + + p = pbit; + pbuf = &buf[0]; + for (i = 0; i <= last_word; i += 2) /* loop over trimmed raster */ + { + w_even = (*p++); + w_odd = (*p++); + +#if (HOST_WORD_SIZE == 36) + *pbuf++ = (BYTE)( (w_even >> 28) & 0xff); + *pbuf++ = (BYTE)( (w_even >> 20) & 0xff); + *pbuf++ = (BYTE)( (w_even >> 12) & 0xff); + *pbuf++ = (BYTE)( (w_even >> 4) & 0xff); + *pbuf++ = (BYTE)( ((w_even << 4) | (w_odd >> 32)) & 0xff); + *pbuf++ = (BYTE)( (w_odd >> 24) & 0xff); + *pbuf++ = (BYTE)( (w_odd >> 16) & 0xff); + *pbuf++ = (BYTE)( (w_odd >> 8) & 0xff); + *pbuf++ = (BYTE)( (w_odd ) & 0xff); +#else /* HOST_WORD_SIZE == 32 */ + /* encode 8 bytes at a time on 32-bit machines */ + *pbuf++ = (BYTE)( (w_even >> 24) & 0xff); + *pbuf++ = (BYTE)( (w_even >> 16) & 0xff); + *pbuf++ = (BYTE)( (w_even >> 8) & 0xff); + *pbuf++ = (BYTE)( (w_even ) & 0xff); + *pbuf++ = (BYTE)( (w_odd >> 24) & 0xff); + *pbuf++ = (BYTE)( (w_odd >> 16) & 0xff); + *pbuf++ = (BYTE)( (w_odd >> 8) & 0xff); + *pbuf++ = (BYTE)( (w_odd ) & 0xff); +#endif + + } + + *pbuf = '\0'; /* trailing EOS marker */ + + last_word |= 1; /* make last_word ODD */ + for (i = ((last_word+1)*HOST_WORD_SIZE)/8; + (*(--pbuf) == '\0') && (i > 1); --i) + ; /* trim trailing zero bytes, leaving at least one */ + last_word = i; + + /* Raster header for DeskJet ????? */ + OUTF("\033*b%dW",(int)last_word); + pbuf = &buf[0]; /* cannot use fprintf with %s format because of + NUL's in string, and it is slow anyway */ + for (i = 0; i < last_word; ++pbuf,++i) + OUTC(*pbuf); +} + +/*-->prtbmap*/ +/**********************************************************************/ +/****************************** prtbmap *******************************/ +/**********************************************************************/ + +void +prtbmap() + +{ + register UNSIGN32 *p; + register INT16 j,k,ybottom,ytop; + + if (DBGOPT(DBG_PAGE_DUMP)) + { + INT16 k1,k2,k3; + + for (k3 = 0; k3 < XBIT; (k3 += 7, ++p)) + { /* print bitmap 7 words at a pass */ + k1 = k3; + k2 = MIN(XBIT,k1+7); + (void)printf("prtbmap()...bitmap words %d..%d",k1,k2-1); + NEWLINE(stdout); + (void)printf(" "); + for (k = k1; k < k2; ++k) + (void)printf("%10d",k*HOST_WORD_SIZE); + NEWLINE(stdout); + for (j = YBIT-1; j >= 0; --j) + { + p = BITMAP(j,0); + for (k = 0; k < XBIT; (++k,++p)) + { + if (*p) /* print non-blank raster line */ + { + p = BITMAP(j,k1); + (void)printf("%5d:",j); + for (k = k1; k < k2; (++k,++p)) + (void)printf(" %09lx",*p); + NEWLINE(stdout); + break; /* exit loop over k */ + } + } + } + } + } + + (void)clearerr(plotfp); + +#if ZAPTHISOUT + k = -1; /* find top non-zero raster */ + for (j = YBIT-1; (j > 0) && (k < 0); --j) /* loop over raster lines */ + { + p = BITMAP(j,XBIT-1); + for (k = XBIT - 1; ((k >= 0) && (*p == 0)); --k) + --p; /* trim white space */ + } + ytop = j; +#else + ytop = YBIT-1; +#endif + + k = -1; /* find bottom non-zero raster */ + for (j = 0; (j < ytop) && (k < 0); ++j) /* loop over raster lines */ + { + +#if IBM_PC_MICROSOFT + for (k = XBIT - 1;((k >= 0) && (*BITMAP(j,k) == 0));--k) + ; /* trim white space */ +#else + p = BITMAP(j,XBIT-1); + for (k = XBIT - 1; ((k >= 0) && (*p == 0)); --k) + --p; /* trim white space */ +#endif + + } + ybottom = MAX(0,j-1); + +#if ZAPTHISOUT + for (j = ytop; (j >= ybottom); --j) + { + OUTF("%5d:",(int)j); + for (k = 0; k < XBIT; ++k) + OUTF(" %9x",*BITMAP(j,k)); + NEWLINE(plotfp); + } +#endif + + OUTF("\033&l%dX",(int)copies); /* number of copies */ + + OUTS("\033*r1A"); /* start plot at current position */ + + for (j = ytop; (j >= ybottom) ; --j) /* loop over raster lines */ + outline(BITMAP(j,0)); + + OUTS("\033*rB\f"); /* end raster graphics, eject page */ + + (void)fflush(plotfp); + if (DISKFULL(plotfp)) + (void)fatal("Output error -- disk storage probably full"); +} + +#include "outrow.h" +#include "prtpage.h" +#include "readfont.h" +#include "readgf.h" +#include "readpk.h" +#include "readpost.h" +#include "readpxl.h" +#include "reldfont.h" +#include "rulepxl.h" +#include "setchar.h" +#include "setfntnm.h" +#include "setrule.h" +#include "signex.h" +#include "skgfspec.h" +#include "skipfont.h" +#include "skpkspec.h" +#include "special.h" +#include "strchr.h" +#include "strcm2.h" +#include "strid2.h" +#include "strrchr.h" +#include "tctos.h" +#include "usage.h" +#include "warning.h" + diff --git a/systems/os2/dviware/hp-deskjet/dviinit.h b/systems/os2/dviware/hp-deskjet/dviinit.h new file mode 100644 index 0000000000..58423e7fff --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/dviinit.h @@ -0,0 +1,375 @@ +/* -*-C-*- dviinit.h */ +/*-->dviinit*/ +/**********************************************************************/ +/****************************** dviinit *******************************/ +/**********************************************************************/ + +void +dviinit(filestr) /* initialize DVI file processing */ +char *filestr; /* command line filename string */ +{ + int i; /* temporary */ + INT16 k; /* index in curpath[] and curname[] */ + char* tcp; /* temporary string pointers */ + char* tcp1; /* temporary string pointers */ + +#if OS_UNIX +/*********************************************************************** +Unix allows binary I/O on stdin and stdout; most other operating systems +do not. In order to support this, we use the convention that a null +filestr (NOT a (char*)NULL) means the dvifile is on stdin, and the +translated output is on stdout. Error logging will be to dvixxx.err or +dvixxx.dvi-err. Because random access is required of the dvifile, stdin +may NOT be a pipe; it must be a disk file. +***********************************************************************/ +#define NO_FILENAME (filestr[0] == '\0') +#endif + +#if CANON_A2 + +#ifdef CANON_TEST + char modestring[10]; /* for dynamic fopen() mode string */ +#endif /* CANON_TEST */ + +#endif + +#if (OS_TOPS20 | OS_VAXVMS) + char* tcp2; /* temporary string pointers */ +#endif + + for (k = 0; k < 10; ++k) + tex_counter[k] = (INT32)0L; + + fontptr = (struct font_entry *)NULL; + hfontptr = (struct font_entry *)NULL; + pfontptr = (struct font_entry *)NULL; + fontfp = (FILE *)NULL; + cache_size = 0; + nopen = 0; + + /*********************************************************** + Set up file names and open dvi and plot files. Simple + filename parsing assumes forms like: + + Unix: name + name.ext + /dir/subdir/.../subdir/name + /dir/subdir/.../subdir/name.ext + TOPS-20: any Unix style (supported by PCC-20) + <directory>name + <directory>name.ext + <directory>name.ext.gen + device:<directory>name + device:<directory>name.ext + device:<directory>name.ext.gen + [directory]name + [directory]name.ext + [directory]name.ext.gen + device:[directory]name + device:[directory]name.ext + device:[directory]name.ext.gen + logname:name + logname:name.ext + logname:name.ext.gen + + The Unix style should work under IBM PC DOS (backslash can + usually be replaced for forward slash), and the TOPS-20 + style contains VAX VMS as a subset. Fancier TOPS-20 names + are possible (control-V quoting of arbitrary characters, and + attributes), but they are rare enough that we do not support + them. For TOPS-20 and VAX VMS, generation numbers are + recognized as a digit following the last dot, and they are + preserved for the DVI file only. For the output files, the + highest generation will always be assumed. This is for + convenience with the TOPS-20 TeX implementation, which on + completion types in a command "TeXspool: foo.dvi.13" and + waits for the user to type a carriage return. + + We only need to extract the directory path, name, and + extension, so the parsing is simple-minded. + + ***********************************************************/ + + tcp = strrchr(filestr,'/'); /* find end of Unix file path */ + +#if (OS_ATARI | OS_PCDOS | OS_IBMOS2) + if (tcp == (char*)NULL) /* no Unix-style file path */ + tcp = strrchr(filestr, '\\'); /* try \dos\path\ */ +#endif + +#if OS_TOPS20 + if (tcp == (char*)NULL) /* no Unix-style file path */ + { + tcp = strrchr(filestr, '>'); /* try <dir> */ + if (tcp == (char*)NULL) /* no <dir> */ + tcp = strrchr(filestr, ']'); /* try [dir] */ + if (tcp == (char*)NULL) /* no [dir] */ + tcp = strrchr(filestr, ':'); /* try logname: */ + } +#endif + +#if OS_VAXVMS + if (tcp == (char*)NULL) /* no Unix-style file path */ + { + tcp = strrchr(filestr, ']'); /* try [dir] */ + if (tcp == (char*)NULL) /* no [dir] */ + tcp = strrchr(filestr, ':'); /* try logname: */ + } +#endif + + if (tcp == (char*)NULL) /* no file path */ + { + curpath[0] = '\0'; /* empty path */ + tcp = filestr; /* point to start of name */ + } + else /* save path for later use */ + { + k = (INT16)(tcp-filestr+1); + (void)strncpy(curpath, filestr, (int)k); + curpath[k] = '\0'; + tcp++; /* point to start of name */ + } + + tcp1 = strrchr(tcp, '.'); /* find last dot in filename */ + +#if (OS_TOPS20 | OS_VAXVMS) + if ((tcp1 != (char*)NULL) && isdigit(*(tcp1+1))) + { /* then assume generation number */ + tcp2 = tcp1; /* remember dot position */ + *tcp1 = '\0'; /* discard generation number */ + tcp1 = strrchr(tcp,'.');/* find last dot in filename */ + *tcp2 = '.'; /* restore dot */ + } +#endif + + if (tcp1 == (char*)NULL) + { /* no dot, so name has no extension */ + (void)strcpy(curname, tcp); /* save name */ + tcp1 = strchr(tcp, '\0'); /* set empty extension */ + } + else /* save name part */ + { + k = (INT16)(tcp1-tcp); + (void)strncpy(curname, tcp, (int)k); + curname[k] = '\0'; + } + + (void)strcpy(curext, tcp1); /* save extension */ + + + /* DVI file must always have extension DVIEXT; supply one if + necessary (e.g /u/jones/foo.dvi) */ + + (void)strcpy(dviname, curpath); + (void)strcat(dviname, curname); + if (curext[0] == '\0') + (void)strcat(dviname, DVIEXT); + else + (void)strcat(dviname, curext); + + /* Device output file is PATH NAME . DVIPREFIX OUTFILE_EXT (e.g. + /u/jones/foo.dvi-alw) */ + + (void)strcpy(dvoname, curpath); + (void)strcat(dvoname, curname); + (void)strcat(dvoname, "."); + (void)strcat(dvoname, DVIPREFIX); + (void)strcat(dvoname, OUTFILE_EXT); + + /* Font substitution file is PATH NAME SUBEXT (e.g. + /u/jones/foo.sub). We do not tell user (via stderr) + about it until it is needed. */ + + if (subfile[0] == '\0') /* no -fsubfile; make default */ + { + (void)strcpy(subfile, curpath); + (void)strcat(subfile, curname); + (void)strcat(subfile, subext); + } + + +#if OS_UNIX + if (NO_FILENAME) + { + dvifp = stdin; /* already open, so no DEBUG_OPEN call */ + if (fseek(dvifp,0L,0)) + { + (void)fprintf(stderr, + "%s: Unable to fseek() on stdin--was it a pipe?\n", + g_progname); + (void)EXIT(1); + } + } + else + { + dvifp = FOPEN(dviname,RB_OPEN); + DEBUG_OPEN(dvifp,dviname,RB_OPEN); + } +#else + + dvifp = FOPEN(dviname,RB_OPEN); + DEBUG_OPEN(dvifp,dviname,RB_OPEN); +#endif + + if (dvifp == (FILE*)NULL) + { + (void)sprintf(message,"dviinit(): %s: can't open [%s]", + g_progname, dviname); + (void)fatal(message); + } + + /* We try both + PATH NAME . DVIPREFIX OUTFILE_EXT and + NAME . DVIPREFIX OUTFILE_EXT, + in case the user does not have write access to the directory PATH */ + for (i = 1; i <= 2; ++i) /* two tries here */ + { + +#if BBNBITGRAPH + strcpy(dvoname,"stdout"); /* BitGraph always goes to stdout */ + plotfp = stdout; +#else /* NOT BBNBITGRAPH */ + +#if OS_VAXVMS + +#if POSTSCRIPT + plotfp = FOPEN(dvoname,WB_OPEN); +#else + /* Create binary files for other devices; they cause less trouble + with VMS spooler programs. */ + plotfp = FOPEN(dvoname,WB_OPEN,"rfm=fix","bls=512","mrs=512"); +#endif /* POSTSCRIPT */ + +#else /* NOT OS_VAXVMS */ + +#if OS_UNIX + plotfp = NO_FILENAME ? stdout : FOPEN(dvoname,WB_OPEN); +#else + plotfp = FOPEN(dvoname,WB_OPEN); +#endif /* OS_UNIX */ + +#endif /* OS_VAXVMS */ + +#endif /* BBNBITGRAPH */ + +#if OS_UNIX + if (!NO_FILENAME) +#endif + + DEBUG_OPEN(plotfp,dvoname,WB_OPEN); + if (plotfp != (FILE*)NULL) + break; /* open okay */ + if (i == 2) + { + (void)strcpy(dvoname, curname); + (void)strcat(dvoname, "."); + (void)strcat(dvoname, DVIPREFIX); + (void)strcat(dvoname, OUTFILE_EXT); + } + } + + if (plotfp == (FILE*)NULL) + { + (void)sprintf(message,"dviinit(): %s: can't open [%s]", + g_progname, dvoname); + (void)fatal(message); + } + +#if OS_TOPS20 + /* Because of the PCC-20 arithmetic (instead of logical) + shift bug wherein a constant expression (1<<35) evaluates + to 0 instead of 400000,,000000, we must set CF_nud using a + variable, instead of just using a constant */ + /* "ac1 = makefield(CF_nud,1);" */ + ac1 = 1; + ac1 = makefield(CF_nud,ac1); + setfield(ac1,CF_jfn,jfnof(fileno(plotfp))); /* jfn */ + setfield(ac1,CF_dsp,FBbyv); /* generation number index in fdb */ + ac2 = makefield(FB_ret,-1); + ac3 = makefield(FB_ret,0); /* set generation count to 0 (infinite) */ + (void)jsys(JSchfdb,acs); /* ignore any errors */ +#endif /* OS_TOPS20 */ + +#if CANON_A2 + +#ifdef CANON_TEST + +#if OS_ATARI + strcpy(tmoname,"\\ca2XXX\."); +#else + strcpy(tmoname,"ca2XXXXXX"); +#endif + + mktemp(tmoname); + savefp = plotfp; + (void)sprintf(modestring,"%s+",WB_OPEN); + plotfp = FOPEN(tmoname, modestring); + stor_total = 0; +#endif /* CANON_TEST */ + +#endif /* CANON_A2 */ + + if (!quiet + +#if OS_UNIX + && !NO_FILENAME +#endif + + ) + { + (void)fprintf(stderr,"[Input from DVI file %s]",dviname); + NEWLINE(stderr); + (void)fprintf(stderr,"[Output on file %s]",dvoname); + NEWLINE(stderr); + } + + if (strncmp(curpath,dvoname,strlen(curpath)) == 0) + (void)strcpy(g_logname, curpath); /* used PATH on output file */ + else + g_logname[0] = '\0'; /* no PATH on output file */ + +#if OS_UNIX + if (NO_FILENAME) /* use dvixxx as file prefix */ + { + (void)strcpy(g_logname, "dvi"); + (void)strcat(g_logname, OUTFILE_EXT); + } +#endif + + (void)strcat(g_logname, curname); + (void)strcat(g_logname, "."); + (void)strcat(g_logname, DVIPREFIX); + +#if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_UNIX) + (void)strcat(g_logname, "err"); +#endif + +#if (OS_TOPS20 | OS_VAXVMS) + /* Force new generation; otherwise fopen(,"w+") reuses existing file */ + (void)strcat(g_logname, "err.-1"); +#endif + + lmargin = (COORDINATE)(leftmargin*((float)XDPI)); + tmargin = (COORDINATE)(topmargin*((float)YDPI)); + +#if (CANON_A2 | IMPRESS | HPJETPLUS) + /* Printer has (0,0) origin at (XORIGIN,YORIGIN) near, but not at, + upper left corner */ + lmargin -= XORIGIN; + tmargin -= YORIGIN; +#endif /* (CANON_A2 | IMPRESS | HPJETPLUS) */ + + if ((BYTE)nosignex(dvifp,(BYTE)1) != PRE) + (void)fatal("dviinit(): PRE doesn't occur first--are you sure \ +this is a DVI file?"); + + i = (int)signex(dvifp,(BYTE)1); + if (i != DVIFORMAT) + { + (void)sprintf(message, + "dviinit(): DVI format = %d, can only process DVI format %d files.", + i, (int)DVIFORMAT); + (void)fatal(message); + } +} + diff --git a/systems/os2/dviware/hp-deskjet/dvios2.doc b/systems/os2/dviware/hp-deskjet/dvios2.doc new file mode 100644 index 0000000000..ea948866ae --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/dvios2.doc @@ -0,0 +1,22 @@ +File D:\DVI\BITMAP.H: +28 #if (IBM_PC_MICROSOFT & !OS_IBMOS2) +55 #else /* NOT IBM_PC_MICROSOFT OR OS_IBMOS2 */ +File D:\DVI\DVIINIT.H: +95 #if (OS_ATARI | OS_PCDOS | OS_IBMOS2) +343 #if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_UNIX) +File D:\DVI\FONTFILE.H: +92 #if (OS_ATARI | OS_PCDOS | OS_IBMOS2) +File D:\DVI\GENDEFS.H: +68 #if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_TOPS20) +File D:\DVI\INITGLOB.H: +113 #if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_UNIX) +File D:\DVI\MACHDEFS.H: +93 OS_IBMOS2 -- IBM (and clones) IBM OS/2 and MS OS/2 +223 #define OS_IBMOS2 0 +287 #undef OS_IBMOS2 +289 #define OS_IBMOS2 1 +303 #if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_TOPS20 | OS_UNIX | OS_VAXVMS) +364 #if (OS_PCDOS | OS_IBMOS2) +441 #endif /* OS_PCDOS | OS_IBMOS2*/ +File D:\DVI\DVIHPDJ.C: +153 #if (IBM_PC_MICROSOFT & !OS_IBMOS2) diff --git a/systems/os2/dviware/hp-deskjet/fontfile.h b/systems/os2/dviware/hp-deskjet/fontfile.h new file mode 100644 index 0000000000..f86a2219c5 --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/fontfile.h @@ -0,0 +1,242 @@ + /* -*-C-*- fontfile.h */ +/*-->fontfile*/ +/**********************************************************************/ +/****************************** fontfile ******************************/ +/**********************************************************************/ + +void +fontfile(filelist,font_path,font_name,magnification) +char *filelist[MAXFORMATS]; /* output filename list */ +char *font_path; /* host font file pathname */ +char *font_name; /* TeX font_name */ +int magnification; /* magnification value */ +{ + + /* + Given a TeX font_name and a magnification value, construct a list of + system-dependent host filenames, returning them in the first + argument. The files are not guaranteed to exist. The font names by + default contains names for the PK, GF, and PXL font files, but the + selection, and search order, may be changed at run time by defining + a value for the environment variable FONTLIST. See initglob() for + details. + */ + + register int m; /* index into filelist[] */ + register INT16 k; /* loop index */ + float fltdpi; /* dots/inch */ + int dpi; /* dots/inch for filename */ + +#if OS_VAXVMS + char *tcp; /* temporary character pointer */ + char *tcp2; /* temporary character pointer */ + char temp_name[MAXFNAME]; /* temporary filename */ +#endif + + /* + We need to convert an old-style ROUNDED integer magnification based + on 1000 units = 200 dpi to an actual rounded dpi value. + + We have + magnification = round(real_mag) = trunc(real_mag + 0.5) + which implies + float(magnification) - 0.5 <= real_mag < float(magnification) + 0.5 + + We want + dpi = round(real_mag/5.0) + which implies + float(dpi) - 0.5 <= real_mag/5.0 < float(dpi) + 0.5 + or + 5.0*float(dpi) - 2.5 <= real_mag < 5.0*float(dpi) + 2.5 + + We can combine the two to conclude that + 5.0*float(dpi) - 2.5 < float(magnification) + 0.5 + or + 5.0*float(dpi) - 3 < float(magnification) + which gives the STRICT inequality + float(dpi) < (float(magnification) + 3.0)/5.0 + */ + + fltdpi = (((float)magnification) + 3.0)/5.0; + dpi = (int)fltdpi; + if (fltdpi == (float)dpi) + dpi--; /* enforce inequality */ + + for (k = 0; k < MAXFORMATS; ++k) /* loop over possible file types */ + *filelist[k] = '\0'; /* Initially, all filenames are empty */ + + m = 0; /* index in filelist[] */ + for (k = 0; k < MAXFORMATS; ++k) /* loop over possible file types */ + { + +#if OS_TOPS20 + + /* Typical results: + texfonts:amr10.300gf + texfonts:amr10.300pk + texfonts:amr10.1500pxl + */ + + if (k == gf_index) + (void)sprintf(filelist[m++], "%s%s.%dgf", + font_path, font_name, dpi); + else if (k == pk_index) + (void)sprintf(filelist[m++], "%s%s.%dpk", + font_path, font_name, dpi); + else if (k == pxl_index) + (void)sprintf(filelist[m++], "%s%s.%dpxl", + font_path, font_name, magnification); + +#endif /* OS_TOPS20 */ + +#if (OS_ATARI | OS_PCDOS | OS_IBMOS2) + + /* Typical results: + d:\tex\fonts\300\amr10.gf + d:\tex\fonts\300\amr10.pk + d:\tex\fonts\1500\amr10.pxl + */ + + if (k == gf_index) + (void)sprintf(filelist[m++], "%s%d\\%s.gf", + font_path, dpi, font_name); + else if (k == pk_index) + (void)sprintf(filelist[m++], "%s%d\\%s.pk", + font_path, dpi, font_name); + else if (k == pxl_index) + (void)sprintf(filelist[m++], "%s%d\\%s.pxl", + font_path, magnification, font_name); + +#endif /* OS_PCDOS */ + +#if OS_UNIX + + /* Typical results (both naming styles are tried): + /usr/lib/tex/fonts/300/amr10.gf + /usr/lib/tex/fonts/amr10.300gf + /usr/lib/tex/fonts/300/amr10.pk + /usr/lib/tex/fonts/1500/amr10.pxl + /usr/lib/tex/fonts/amr10.1500pxl + /usr/lib/tex/fonts/amr10.300pk + */ + + if (k == gf_index) + { + (void)sprintf(filelist[m++], "%s%d/%s.gf", + font_path, dpi, font_name); + (void)sprintf(filelist[m++], "%s%s.%dgf", + font_path, font_name, dpi); + } + else if (k == pk_index) + { + (void)sprintf(filelist[m++], "%s%d/%s.pk", + font_path, dpi, font_name); + (void)sprintf(filelist[m++], "%s%s.%dpk", + font_path, font_name, dpi); + } + else if (k == pxl_index) + { + (void)sprintf(filelist[m++], "%s%d/%s.pxl", + font_path, magnification, font_name); + (void)sprintf(filelist[m++], "%s%s.%dpxl", + font_path, font_name, magnification); + } + /*(void)fprintf(stderr,"In fontfile: Path = %s\n",filelist[m - 1]);*/ + +#endif /* OS_UNIX */ + + +#if OS_VAXVMS + + /* Typical results (both naming styles are tried): + [tex.fonts.300]amr10.gf + [tex.fonts]amr10.300gf + [tex.fonts.300]amr10.pk + [tex.fonts]amr10.300pk + [tex.fonts.1500]amr10.pxl + [tex.fonts]amr10.1500pxl + + + We try a translation of a logical name here if what we have in + fontpath[] is not a directory specification like + "device:[tex.fonts]" or a rooted logical name like "tex_fonts:" + translating to something like "device:[tex.fonts.]" + */ + + + /* Use a straightforward expansion first, in case fontpath is + a search list. */ + if (k == gf_index) + { + (void)sprintf(filelist[m++], "%s[%d]%s.gf", fontpath, + dpi, font_name); + (void)sprintf(filelist[m++], "%s%s.%dgf", fontpath, + font_name, dpi); + } + else if (k == pk_index) + { + (void)sprintf(filelist[m++], "%s[%d]%s.pk", fontpath, + dpi, font_name); + (void)sprintf(filelist[m++], "%s%s.%dpk", fontpath, + font_name, dpi); + } + else if (k == pxl_index) + { + (void)sprintf(filelist[m++], "%s[%d]%s.pxl", fontpath, + magnification, font_name); + (void)sprintf(filelist[m++], "%s%s.%dpxl", fontpath, + font_name, magnification); + } + + (void)strcpy(temp_name,fontpath); + tcp = strrchr(temp_name,']'); /* search for last right bracket */ + if (tcp == (char *)NULL) /* then try logical name translation */ + { + tcp = GETENV(fontpath); + if (tcp != (char *)NULL) + { + tcp2 = strrchr(tcp,']'); + if (tcp2 == (char *)NULL) + tcp = (char *)NULL; /* translates to another logical name */ + else + { + if (*(tcp2-1) == '.') + tcp = (char *)NULL; /* looks like rooted logical name */ + else /* looks like directory name */ + { + (void)strcpy(temp_name,tcp); + tcp = strrchr(temp_name,']'); + } + } + } + } + if (tcp != (char *)NULL) + { /* fontpath is something like [tex.fonts] */ + *tcp = '\0'; /* clobber right bracket */ + if (k == gf_index) + { + (void)sprintf(filelist[m++], "%s.%d]%s.gf", temp_name, + dpi, font_name); + (void)sprintf(filelist[m++], "%s]%s.%dgf", temp_name, + font_name, dpi); + } + else if (k == pk_index) + { + (void)sprintf(filelist[m++], "%s.%d]%s.pk", temp_name, + dpi, font_name); + (void)sprintf(filelist[m++], "%s]%s.%dpk", temp_name, + font_name, dpi); + } + else if (k == pxl_index) + { + (void)sprintf(filelist[m++], "%s.%d]%s.pxl", temp_name, + magnification, font_name); + (void)sprintf(filelist[m++], "%s]%s.%dpxl", temp_name, + font_name, magnification); + } + } +#endif /* OS_VAXVMS */ + } + +} + diff --git a/systems/os2/dviware/hp-deskjet/gendefs.h b/systems/os2/dviware/hp-deskjet/gendefs.h new file mode 100644 index 0000000000..fd08579aa4 --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/gendefs.h @@ -0,0 +1,113 @@ + /* -*-C-*- gendefs.h */ +/*-->gendefs*/ +/**********************************************************************/ +/****************************** gendefs *******************************/ +/**********************************************************************/ + +/**********************************************************************/ +/************************ General Definitions ***********************/ +/**********************************************************************/ + +/*********************************************************************** +This section should not require modification for either new hosts or new +output devices. +***********************************************************************/ + +#define ABS(x) ((x) < 0 ? -(x) : (x)) +#define DBGOPT(flag) (debug_code & (flag)) +#define DBG_PAGE_DUMP 0x0001 +#define DBG_CHAR_DUMP 0x0002 +#define DBG_POS_CHAR 0x0004 +#define DBG_OKAY_OPEN 0x0008 +#define DBG_FAIL_OPEN 0x0010 +#define DBG_OFF_PAGE 0x0020 +#define DBG_FONT_CACHE 0x0040 +#define DBG_SET_TEXT 0x0080 +#define DEBUG_OPEN(fp,fname,openmode) dbgopen(fp,fname,openmode) +#define DVIFORMAT 2 +#define FIRSTPXLCHAR 0 +#define FT_GF 0 +#define FT_PK 1 +#define FT_PXL 2 +#define IN(a,b,c) (((a) <= (b)) && ((b) <= (c))) + +/* Computer Modern has 128 characters (0..127), but Japanese fonts and +extended European Computer Moderns may have up to 256 (0..255) +characters */ +#define LASTPXLCHAR 255 + +#define MAGSIZE(f) ((UNSIGN32)(1000.0*(f) + 0.5)) + +#ifdef MAX +#undef MAX +#endif + +#define MAX(a,b) ((a) > (b) ? (a) : (b)) +#define MAXFONTS 32 /* number of fonts per job (HPLJ, Canon A2) */ +#define MAXMSG 1024 /* message[] size--big enough for 2 file names*/ +#define MAXPAGE 999 /* limit on number of pages in a DVI file */ +#define MAXREQUEST 256 /* limit on number of explicit page print + requests */ +#define MAXSPECIAL 500 /* limit on \special{} string size; it need not + be larger than TeX's compile-time parameter + buf_siz, which is 500 in Standard TeX-82 */ +#define MAXSTR 257 /* DVI file text string size */ + +#define MAXFORMATS 12 /* number of font file naming formats */ +#define MIN_M -500 /* GF character image extents */ +#define MAX_M 1500 +#define MIN_N -500 +#define MAX_N 1500 + +#ifdef MIN +#undef MIN +#endif + +#define MIN(a,b) ((a) < (b) ? (a) : (b)) + +#if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_TOPS20) +#define NEWLINE(fp) {(void)putc((char)'\r',fp);(void)putc((char)'\n',fp);} + /* want <CR><LF> for these systems */ +#else +#define NEWLINE(fp) (void)putc((char)'\n',fp) /* want bare <LF> */ +#endif + +#define NPXLCHARS 256 +#define ONES ~0 /* a word of all one bits */ +#define OUTC(c) (void)putc((char)(c),plotfp) +#define OUTF(fmt,v) (void)fprintf(plotfp,fmt,v) +#define OUTF2(fmt,u,v) (void)fprintf(plotfp,fmt,u,v) +#define OUTF3(fmt,u,v,w) (void)fprintf(plotfp,fmt,u,v,w) +#define OUTS(s) (void)fputs(s,plotfp) + +#if CANON_A2 + +#ifdef CANON_TEST +#define FOUTC(c) (void)putc((char)(c),savefp); +#define FOUTS(s) (void)fputs(s,savefp) +#endif /* CANON_TEST */ + +#endif + +#define PIXROUND(n,c) ((COORDINATE)(((float)(n))*(c) + 0.5)) + +#undef PXLID +#define PXLID 1001 + +#define SETBIT(m) img_row[(m-min_m) >> 5] |= img_mask[(m-min_m) & 0x1f] +#define TESTBIT(m) img_row[(m-min_m) >> 5] & img_mask[(m-min_m) & 0x1f] + +#if STDRES +#define STDMAG 1000 +#else +#define STDMAG 603 /* 1500/(1.2**5) to stay in magstep family */ +#endif + +#define RESOLUTION (((float)STDMAG)/5.0) /* dots per inch */ +#define STACKSIZE 100 + +#undef USEGLOBALMAG +#define USEGLOBALMAG 1 /* allow dvi global magnification */ + +#define VISIBLE(t) ((t->wp > 0) && (t->hp > 0)) + /* true if both pixel height and width are non-zero */ diff --git a/systems/os2/dviware/hp-deskjet/hpdj.cmd b/systems/os2/dviware/hp-deskjet/hpdj.cmd new file mode 100644 index 0000000000..bbdc5d4fed --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/hpdj.cmd @@ -0,0 +1 @@ +dvihpdj -eTEXFONTS=d:\pctex\pixel\pxl -m1500 -d8 %1.dvi diff --git a/systems/os2/dviware/hp-deskjet/initglob.h b/systems/os2/dviware/hp-deskjet/initglob.h new file mode 100644 index 0000000000..f80df4bb89 --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/initglob.h @@ -0,0 +1,122 @@ + /* -*-C-*- initglob.h */ +/*-->initglob*/ +/**********************************************************************/ +/****************************** initglob ******************************/ +/**********************************************************************/ + +void +initglob() /* initialize global variables */ +{ + register INT16 i; /* loop index */ + register char* tcp; /* temporary character pointer */ + +/*********************************************************************** + Set up masks such that rightones[k] has 1-bits at the right end of + the word from k .. HOST_WORD_SIZE-1, where bits are numbered from + left (high-order) to right (lower-order), 0 .. HOST_WORD_SIZE-1. + + img_mask[k] has a 1-bit in position k, bits numbered as above. + power[k] is 1 << k, and gpower[k] is 2**k-1 (i.e. 1-bits in + low-order k positions). These 3 require only 32 entries each since + they deal with 32-bit words from the PK and GF font files. + + These are set at run-time, rather than compile time to avoid (a) + problems with C preprocessors which sometimes do not handle large + constants correctly, and (b) host byte-order dependence. +***********************************************************************/ + + rightones[HOST_WORD_SIZE-1] = 1; + for (i = HOST_WORD_SIZE-2; (i >= 0); --i) + rightones[i] = (rightones[i+1] << 1) | 1; + + img_mask[31] = 1; + for (i = 30; i >= 0; --i) + img_mask[i] = img_mask[i+1] << 1; + + power[0] = 1; + for (i = 1; i <= 31; ++i) + power[i] = power[i-1] << 1; + + gpower[0] = 0; /* NB: we have gpower[0..32], not [0..31] */ + for (i = 1; i <= 32; ++i) + gpower[i] = power[i-1] | gpower[i-1]; + + debug_code = 0; + runmag = STDMAG; /* default runtime magnification */ + +#if HPLASERJET + hpres = DEFAULT_RESOLUTION; /* default output resolution */ +#endif /* HPLASERJET */ + +#if HPJETPLUS + size_limit = 255; /* largest character size */ +#endif + + +#if CANON_A2 + /* + This should really be 64, but there are serious problems with the + Canon A2 downloaded font mechanism--characters are randomly dropped + from the output. Setting the size limit to 0 forces each character + to be loaded as a raster bitmap, which blows the output file size up + by more than a factor of 10, sigh.... + */ + size_limit = 0; + +#ifdef CANON_TEST + size_limit = 64; /* largest character size */ + stor_limit = STOR_LIMIT; + merit_fact = MERIT_FACT; + stor_fonts = STOR_FONTS; +#endif /* CANON_TEST */ + +#endif + + +#if POSTSCRIPT + size_limit = PS_SIZELIMIT; /* characters larger than this */ + /* get loaded each time with */ + /* surrounding save/restore to */ + /* get around PostScript bugs */ + ps_vmbug = FALSE; /* do not reload fonts on each page */ +#endif /* POSTSCRIPT */ + + npage = 0; + copies = 1; /* number of copies of each page */ + topmargin = 1.0; /* DVI driver standard default */ + leftmargin = 1.0; /* DVI driver standard default */ + + subfile[0] = '\0'; + +#if VIRTUAL_FONTS + virt_font = FALSE; +#endif + + /* + Copy default file fields into global variables, then replace by any + runtime environment variable definitions. We need not do this for + TOPS-20 and VAX VMS, since SUBPATH and FONTPATH are already + initialized to logical names which the operating system will + translate at file open time. + */ + + (void)strcpy(helpcmd,DVIHELP); + (void)strcpy(subpath,SUBPATH); + (void)strcpy(subname,SUBNAME); + (void)strcpy(subext,SUBEXT); + (void)strcpy(fontpath,FONTPATH); + (void)strcpy(fontlist,FONTLIST); + + if ((tcp = GETENV("DVIHELP")) != (char *)NULL) + (void)strcpy(helpcmd,tcp); + +#if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_UNIX) + if ((tcp = GETENV(TEXINPUTS)) != (char *)NULL) + (void)strcpy(subpath,tcp); + if ((tcp = GETENV(TEXFONTS)) != (char *)NULL) + (void)strcpy(fontpath,tcp); +#endif + + if ((tcp = GETENV("FONTLIST")) != (char *)NULL) + (void)strcpy(fontlist,tcp); +} diff --git a/systems/os2/dviware/hp-deskjet/m.cmd b/systems/os2/dviware/hp-deskjet/m.cmd new file mode 100644 index 0000000000..06ef19bddf --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/m.cmd @@ -0,0 +1 @@ +cl -Lp -AL -Ot -DANSI_LIBRARY -l/ST:8000 %1.c diff --git a/systems/os2/dviware/hp-deskjet/machdefs.h b/systems/os2/dviware/hp-deskjet/machdefs.h new file mode 100644 index 0000000000..3a0a1bbeb2 --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/machdefs.h @@ -0,0 +1,842 @@ + /* -*-C-*- machdefs.h */ +/*-->machdefs*/ +/**********************************************************************/ +/****************************** machdefs ******************************/ +/**********************************************************************/ + +/*********************************************************************** + +!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! +This file should contain definitions for symbols used for all operating +system / implementation dependencies, and if the driver family has +already been implemented on you machine, this should be the only file +requiring changes. + +How to change this file: + * locate the operating system and implementation definitions; + they are surrounded by "=====" comment strings. + * comment out the definitions you do not want, and select the + ones for your system + * if adding a new operating system, create a new symbol OS_xxx + for it and add a new #if OS_xxx ... #endif section for its + changes. + * if adding a new implementation for an existing operating + system, create a new symbol for it and add appropriate + conditionals inside its #if OS_xxx ... #end section. + * if you must replace a standard C library function, replace + instances of its use in the source code with an upper-case + equivalent (e.g. ungetc --> UNGETC), then define the + upper-case name below in the generic section, plus the + operating-system section. + +!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +List of symbols actually used for #if's [14-Aug-87] + +Flags and strings: + ALLOW_INTERRUPT -- allow interactive interrupt + ANSI_PROTOTYPES -- draft ANSI C function prototype declarations are + supported + ANSI_LIBRARY -- draft ANSI C library functions conformance + ARITHRSHIFT -- implementation uses arithmetic (not logical) right + shift + DVIHELP -- how to find documentation (for usage()) + DVIPREFIX -- prefix to standard 3-character extension of output + and log files + FASTZERO -- fast bitmap zeroing by external assembly language + routine + FONTLIST -- font type search list (PK, GF, PXL) + FONTPATH -- font directory path + HIRES -- high resolution variant of bitmap output + HOST_WORD_SIZE -- host integer word size in bits + PS_MAXWIDTH -- approximate line width limit for PostScript output + PS_SHORTLINES -- shorter output lines in PostScript + PS_XONXOFFBUG -- PostScript version 23.0 Xon/Xoff bug workaround + PXLID -- TeX PXL file ID + RB_OPEN -- fopen() mode flags for binary read + SEGMEM -- segmented memory (Intel); bitmap is raster vector + STDRES -- standard resolution (200 dpi) + SUBPATH -- substitution font file path + TEXFONTS -- TeX font file path environment variable + TEXINPUTS -- TeX input file path environment variable + USEGLOBALMAG -- allow runtime global magnification scaling + VIRTUAL_FONTS -- implement virtual font caching + WB_OPEN -- fopen() mode flags for binary write + ZAPTHISOUT -- remove some obsolete code + +Alternate library routines for misfeature workarounds (these have the +same names as standard library routines, but upper-cased): + EXIT + FOPEN + FSEEK + FTELL + GETENV + MALLOC(n) + READ + REWIND(fp) + UNGETC + +C Implementations: + ATT -- AT&T Unix (System III, V) + BSD41 -- Berkeley 4.1BSD + BSD42 -- Berkeley 4.2BSD + HPUX -- HP 9000 series Unix (System V based) + IBM_PC_LATTICE -- IBM PC Lattice C compiler + IBM_PC_MICROSOFT-- IBM PC Microsoft Version 3.x or later C compiler + IBM_PC_WIZARD -- IBM PC Wizard C compiler + KCC_20 -- SRI's KCC Compiler on TOPS-20 + PCC_20 -- Portable C Compiler on TOPS-20 + +Operating systems: + OS_ATARI -- Atari 520ST+ TOS (similar to MS DOS) + OS_PCDOS -- IBM (and clones) PC DOS and MS DOS + OS_IBMOS2 -- IBM (and clones) IBM OS/2 and MS OS/2 + OS_TOPS20 -- DEC-20 TOPS-20 + OS_UNIX -- Unix (almost any variant) + OS_VAXVMS -- VAX VMS + +Device names (defined in each DVIxxx.C file): + APPLEIMAGEWRITER -- Apple ImageWriter printer + BBNBITGRAPH -- BBN BitGraph terminal + CANON_A2 -- Canon LBP-8 A2 laser printer + DECLA75 -- DEC LA75 printer + DECLN03PLUS -- DEC LN03-PLUS laser printer + EPSON -- Epson 9-pin family dot-matrix printer + GOLDENDAWNGL100 -- Golden Dawn GL100 laser printer + HPJETPLUS -- Hewlett-Packard Laser Jet Plus (downloaded fonts) + HPLASERJET -- Hewlett-Packard Laser Jet (bitmap display) + IMPRESS -- imPRESS (IMAGEN laser printer) + MPISPRINTER -- MPI Sprinter printer + OKIDATA2410 -- OKIData 2410 printer + POSTSCRIPT -- Adobe PostScript (Apple LaserWriter laser printer) + PRINTRONIX -- Printronix (DEC LXY-11, C-Itoh) printer + TOSHIBAP1351 -- Toshiba P-1351 dot matrix printer + +***********************************************************************/ + +/********************************************************************** +Define all symbols for devices, operating systems, and implementations +to be explicitly 0, unless it is expected that they might be set at +compile time. +***********************************************************************/ + +#define ALLOW_INTERRUPT 0 +#define ANSI_PROTOTYPES 0 + +#ifndef ANSI_LIBRARY /* may be specified at compile time */ +#define ANSI_LIBRARY 0 +#endif + +#if ANSI_LIBRARY +#undef ANSI_PROTOTYPES +#define ANSI_PROTOTYPES 1 /* If library conforms, declarations do too */ +#endif + +#define ARITHRSHIFT 1 /* most C compilers use arithmetic right shift */ +#define DISKFULL(fp) (ferror(fp) && (errno == ENOSPC)) +#define DVIEXT ".dvi" +#define DVIPREFIX "dvi-" +#define EXIT exit +#define FASTZERO 0 + +/* The following definitions work for at least PCC-20, BSD 4.2 and 4.3, +and HPUX; VAX VMS has an extra level of indirection. Check the +definition of fileno(fp) in stdio.h; on PCC-20, it is + #define fileno(p) ((p)->_file) +*/ +#define FILE_CNT(fp) (fp)->_cnt +#define FILE_BASE(fp) (fp)->_base +#define FILE_PTR(fp) (fp)->_ptr + +/* #define FONTLIST 0 -- can be set at compile time */ +/* #define FONTPATH 0 -- can be set at compile time */ + +#define FOPEN fopen +#define FSEEK fseek +#define FTELL ftell +#define GETENV getenv +#define HIRES 0 +#define MALLOC(n) malloc(n) +#define MAXDRIFT 2 /* we insist that + abs|(hh-pixel_round(h))<=MAXDRIFT| */ + +/* MAXOPEN should be 6 less than the system limit on open files, +allowing for files open on stdin, stdout, stderr, .dvi, .dvi-log, +.dvi-xxx, plus MAXOPEN font files. It may be additionally limited by +the amount of memory available for buffers (e.g. IBM PC). */ +#define MAXOPEN 14 + +/* #define PS_MAXWIDTH 72 -- can be set at compile time */ + +/* #define PS_SHORTLINES 0 -- can be set at compile time */ + +#define PS_XONXOFFBUG 0 +#define PXLID 0 +#define RB_OPEN "r" + +/* For virtual font caching to succeed, read() must return the requested +number of bytes, and preferably do this with one system call and no +double buffering. */ + +#define READ read + +/* In many implementations, rewind(fp) is defined as equivalent to +fseek(fp,0L,0). In some, however (e.g. PCC-20, and probably others +based on PCC), it additionally discards input buffer contents, which may +cause unnecessary I/O, and in the case of virtual font caching, clears +the cache. Defining it in terms of fseek() should be okay, but the +implementation of fseek() should be checked. */ + +#define REWIND(fp) FSEEK(fp,0L,0) + +#define SEGMEM 0 /* may be reset by dvixxx for big bitmaps */ +#define STDRES 0 + +/* #define SUBPATH 0 -- can be set at compile time */ + +#define SUBEXT ".sub" +#define SUBNAME "texfonts" + +/* #define TEXFONTS 0 -- can be set at compile time */ +/* #define TEXINPUTS 0 -- can be set at compile time */ + +#define UNGETC ungetc +#define USEGLOBALMAG 0 +#define WB_OPEN "w" +#define ZAPTHISOUT 0 + + +/**********************************************************************/ +/* Clear all implementation/operating-system flags--reset later */ + +#define ATT 0 /* define zero or one of these */ +#define BSD41 0 +#define BSD42 0 +#define HPUX 0 +#define IBM_PC_LATTICE 0 +#define IBM_PC_MICROSOFT 0 +#define IBM_PC_WIZARD 0 +#define KCC_20 0 +#define PCC_20 0 + +#define OS_ATARI 0 /* define one of these */ +#define OS_IBMOS2 0 +#define OS_PCDOS 0 +#define OS_TOPS20 0 +#define OS_UNIX 0 +#define OS_VAXVMS 0 + +#define APPLEIMAGEWRITER 0 /* one will be defined by DVIxxx */ +#define BBNBITGRAPH 0 +#define CANON_A2 0 +#define DECLA75 0 +#define DECLN03PLUS 0 +#define EPSON 0 +#define GOLDENDAWNGL100 0 +#define HPJETPLUS 0 +#define HPLASERJET 0 +#define IMPRESS 0 +#define MPISPRINTER 0 +#define OKIDATA2410 0 +#define POSTSCRIPT 0 +#define PRINTRONIX 0 +#define TOSHIBAP1351 0 +#define VIRTUAL_FONTS 0 + + +/*********************************************************************** +Define operating system and implementation here. Since these have all +been explicitly set to 0 above, we issue #undef's to avoid compiler +macro redefinition warning messages. +***********************************************************************/ + +/*==================== +#undef PCC_20 +#undef OS_TOPS20 +#define PCC_20 1 +#define OS_TOPS20 1 +====================*/ + +/*==================== +#undef KCC_20 +#undef OS_TOPS20 +#define KCC_20 1 +#define OS_TOPS20 1 +====================*/ + +/*==================== +#undef OS_ATARI +#define OS_ATARI 1 +====================*/ + +/*==================== +#undef IBM_PC_LATTICE +#undef OS_PCDOS +#define IBM_PC_LATTICE 1 +#define OS_PCDOS 1 +====================*/ + +/*==================== +#undef IBM_PC_MICROSOFT +#undef OS_PCDOS +#define IBM_PC_MICROSOFT 1 +#define OS_PCDOS 1 +====================*/ + +#undef IBM_PC_MICROSOFT +#undef OS_IBMOS2 +#define IBM_PC_MICROSOFT 1 +#define OS_IBMOS2 1 + +/*==================== +#undef IBM_PC_WIZARD +#undef OS_PCDOS +#define IBM_PC_WIZARD 1 +#define OS_PCDOS 1 +====================*/ + +/*==================== +#undef OS_VAXVMS +#define OS_VAXVMS 1 +====================*/ + +#if (OS_ATARI | OS_PCDOS | OS_IBMOS2 | OS_TOPS20 | OS_UNIX | OS_VAXVMS) +#else +#undef OS_UNIX +#define OS_UNIX 1 /* provide default operating system */ +#endif + + +/**********************************************************************/ + +#if OS_ATARI + +#undef BSD42 +#define BSD42 1 + +#undef DISKFULL +#define DISKFULL(fp) ferror(fp) + +#define DVIHELP "type e:\\tex\\dvi.hlp" + +#ifdef FONTLIST /* can be set at compile time */ +#else +#define FONTLIST "PK-GF-PXL" /* preferred search order */ +#endif /* FONTLIST */ + +#ifdef FONTPATH /* can be set at compile time */ +#else +#define FONTPATH "e:\\tex\\fonts\\" +#endif + +#define HOST_WORD_SIZE 32 /* must be 32 or larger -- used in */ + /* signex to pack 8-bit bytes back */ + /* into integer values, and in dispchar */ + /* and fillrect for managing character */ + /* raster storage. */ +#define MAXFNAME 64 /* longest host complete filename */ + +#ifndef PS_MAXWIDTH +#define PS_MAXWIDTH 72 +#endif + +#ifndef PS_SHORTLINES +#define PS_SHORTLINES 1 +#endif + +#ifdef SUBPATH /* can be set at compile time */ +#else +#define SUBPATH "e:\\tex\\inputs\\" +#endif + +#ifdef TEXINPUTS /* can be set at compile time */ +#else +#define TEXINPUTS "TEXINPUTS" +#endif + +#define TEXFONTS "TEXFONTS" + +#endif /* OS_ATARI */ + + +/**********************************************************************/ + +#if (OS_PCDOS | OS_IBMOS2) + +#if IBM_PC_MICROSOFT +#undef ANSI_PROTOTYPES +#define ANSI_PROTOTYPES 1 + +/* +Argument type checking in MSC Version 4.0 is selected by LINT_ARGS. +MSC Version 5.0 has it selected by default. For Version 5.0, +ANSI_LIBRARY should be defined at compile time so as to get +ANSI-conformant library function declarations. +Treating float as double eliminates lots of data conversion warnings with +both Versions 4.0 and 5.0. +*/ +#define float double +#define LINT_ARGS 1 + +#undef MALLOC +#define MALLOC(n) calloc(n,1) +#endif /* IBM_PC_MICROSOFT */ + +#define DVIHELP "type d:\\tex\\dvi.hlp" + +#undef DVIPREFIX +#define DVIPREFIX "" + +#ifdef FONTLIST /* can be set at compile time */ +#else +#define FONTLIST "PK-GF-PXL" /* preferred search order */ +#endif /* FONTLIST */ + +#ifdef FONTPATH /* can be set at compile time */ +#else +#define FONTPATH "d:\\tex\\fonts\\" +#endif /* FONTPATH */ + +#define HOST_WORD_SIZE 32 /* must be 32 or larger -- used in */ + /* signex to pack 8-bit bytes back */ + /* into integer values, and in dispchar */ + /* and fillrect for managing character */ + /* raster storage. */ +#define MAXFNAME 64 /* longest host complete filename */ + +#undef MAXOPEN +#define MAXOPEN 5 /* limit on number of open font files */ + +#ifndef PS_MAXWIDTH +#define PS_MAXWIDTH 72 +#endif + +#ifndef PS_SHORTLINES +#define PS_SHORTLINES 1 +#endif + +#undef RB_OPEN +#define RB_OPEN "rb" + +#ifdef SUBPATH /* can be set at compile time */ +#else +#define SUBPATH "d:\\tex\\inputs\\" +#endif + +#if TEXINPUTS /* can be set at compile time */ +#else +#define TEXINPUTS "TEXINPUTS" +#endif + +#define TEXFONTS "TEXFONTS" + +#if IBM_PC_MICROSOFT +#undef VIRTUAL_FONTS +#define VIRTUAL_FONTS 1 +#endif + +#undef WB_OPEN +#define WB_OPEN "wb" + +#endif /* OS_PCDOS | OS_IBMOS2*/ + + +/***********************************************************************/ +#if OS_TOPS20 + +/************************************************************************ +** +** Adapted for the DEC-20 TOPS-20 operating system with Jay Lepreau's +** PCC-20 by Nelson H.F. Beebe, College of Science Computer, +** University of Utah, Salt Lake City, UT 84112, Tel: (801) 581-5254. +** +** The PCC_20 switch is used to get around variations on the DEC-20. +** The major one is that text files have 7-bit bytes, while the .DVI +** file and the font files have 8-bit bytes. For the latter, we use a +** routine f20open which provides the necessary interface for opening +** with a ddifferent byte size. PCC-20 follows many other C compilers +** in that only the first 8 characters of identifiers are looked at, so +** massive substitutions were necessary in the file commands.h to +** shorten the long names there. +** +** The PCC_20 switch is also used to get variant font directory names +** and to select TOPS-20 jsys code. TOPS-20 is a wonderous operating +** system with capabilities far beyond most of its contemporaries. +** Like Topsy, it just grew, and consequently, its many capabilities +** are not well integrated. The terminal control jsys'es (MTOPR, +** RFMOD, SFMOD, STPAR, RFCOC, SFCOC and TLINK) are particularly poorly +** done -- RFMOD returns the JFN mode word, particular bits of which +** must be set by SFMOD, STPAR, and TLINK. Why could there not be a +** "return the terminal state" and "restore the terminal state" +** jsys'es? Some of this may in fact be already integrated into the +** PCC-20 C run-time library, but since it is totally undocumented (an +** all-too common problem with C), it is essentially unusable in that +** form. +** +** The OS_TOPS20 switch is used in one place to get ioctl.h included at +** the right point, and in several places to get error messages output +** with Tops-20 conventions in column 1: query (?) causes batch job +** abort, percent (%) flags a warning. +** +***********************************************************************/ + +#if KCC_20 +/* KCC wants all #if symbols defined before use. */ +#ifndef FONTLIST +#define FONTLIST "PK-GF-PXL" +#endif + +#ifndef FONTPATH +#define FONTPATH "TEXFONTS:" +#endif + +#ifndef SUBPATH +#define SUBPATH "TEXINPUTS:" +#endif + +#ifndef TEXFONTS +#define TEXFONTS "TEXFONTS:" +#endif + +#ifndef TEXINPUTS +#define TEXINPUTS "TEXINPUTS:" +#endif + +#undef VIRTUAL_FONTS +#define VIRTUAL_FONTS 0 /* cannot support this yet */ + +#endif + +#if KCC_20 +#include <jsys.h> +/* KCC-20 and PCC-20 have similar enough JSYS interfaces that we just +define values for KCC-20 using PCC-20 names. */ +#define JSchfdb CHFDB +#define JSmtopr MTOPR +#define JSrfcoc RFCOC +#define JSrfmod RFMOD +#define JSsfcoc SFCOC +#define JSsfmod SFMOD +#define JSsti STI +#define JSstpar STPAR +#define JStlink TLINK +#define Getmask(name) ( 1?name ) +#define Getshift(name) ( 0?name ) +#define Absmask(name) ( (1?name) << (0?name) ) /* maybe use this one */ +#define Value(name) ( (1?name) << (0?name) ) /* maybe use this one */ +#define makefield(name, value) ( ((value) & Getmask(name)) << Getshift(name) ) +#define getfield(var, name) ( (var) >> Getshift(name) & Getmask(name) ) +#define setfield(var, name, value) ( (var) = ((var) & ~Absmask(name)) |\ + makefield(name, value) ) +#endif + +#if PCC_20 +#undef ARITHRSHIFT +#define ARITHRSHIFT 0 /* PCC-20 uses logical right shift */ +#undef DISKFULL +#define DISKFULL(fp) ferror(fp) /* PCC-20 does not always set errno */ +#endif + +#define DVIHELP "help dvi\nor\ntype hlp:dvi.hlp\nor\nxinfo local clsc dvi" + +#if PCC_20 +#undef FASTZERO +#define FASTZERO 1 /* for fast assembly language memory zeroing */ +#endif + +#ifdef FONTLIST /* can be set at compile time */ +#else +#define FONTLIST "PK-GF-PXL" /* preferred search order */ +#endif /* FONTLIST */ + +#ifdef FONTPATH /* can be set at compile time */ +#else +#define FONTPATH "/texfonts/" +#endif + +#undef FOPEN +#define FOPEN f20open /* private version for 8-bit binary */ + +#define HOST_WORD_SIZE 36 + +#undef MAXFNAME +#define MAXFNAME 256 /* longest host complete filename */ + +#ifdef KCC_20 +#undef MAXOPEN +#define MAXOPEN 26 +#endif + +#ifdef PCC_20 +#undef MAXOPEN +#define MAXOPEN 14 +#endif + +#ifndef PS_MAXWIDTH +#define PS_MAXWIDTH 72 +#endif + +#ifndef PS_SHORTLINES +#define PS_SHORTLINES 1 +#endif + +#undef RB_OPEN +#define RB_OPEN "rb" + +#ifdef PCC_20 +#undef READ +#define READ _read /* fast version with one system call */ +#endif + /* and single buffering */ +#ifdef SUBPATH +#else +#define SUBPATH "/texinputs/" +#endif + +#ifdef TEXFONTS /* can be set at compile time */ +#else +#define TEXFONTS "TEXFONTS" +#endif + +#ifdef TEXINPUTS /* can be set at compile time */ +#else +#define TEXINPUTS "TEXINPUTS" +#endif + +#if PCC_20 +#undef VIRTUAL_FONTS +#define VIRTUAL_FONTS 1 +#endif + +#undef WB_OPEN +#define WB_OPEN "wb" + +/**********************************************************************/ +/* The following definitions (down to the endif) are taken from */ +/* monsym.h. It is too big for CPP to handle, so this kludge is */ +/* necessary until CPP's tables can be enlarged. */ + +/* selected fields for CHFDB% */ +#define CF_nud 01:35-0 /* no update directory */ +#define CF_dsp 0777:35-17 /* fdb displacement */ +#define CF_jfn 0777777:35-35 /* jfn */ + +#define FBbyv 011 /* retention+bytesize+mode,,# of pages*/ +#define FB_ret 077:35-5 /* retention count */ + + +/* tty mode definitions */ + +#define MOrlw 030 /* read width */ +#define MOslw 031 /* set width */ +#define MOrll 032 /* read length */ +#define MOsll 033 /* set length */ + +#define MOsnt 034 /* set tty non-terminal status */ +#define MOsmn 01 /* no system messages(i.e. suppress) */ +#define MOsmy 00 /* yes system messages(default) */ +#define MOrnt 035 /* read tty non-terminal status */ + +/* fields of jfn mode word */ + +#define TT_osp 01:35-0 /* output suppress */ +#define TT_mff 01:35-1 /* mechanical formfeed present */ +#define TT_tab 01:35-2 /* mechanical tab present */ +#define TT_lca 01:35-3 /* lower case capabilities present */ +#define TT_len 0177:35-10 /* page length */ +#define TT_wid 0177:35-17 /* page width */ +#define TT_wak 017:35-23 /* wakeup field */ +#define TT_wk0 01:35-18 /* wakeup class 0 (unused) */ +#define TT_ign 01:35-19 /* ignore tt_wak on sfmod */ +#define TT_wkf 01:35-20 /* wakeup on formating control chars */ +#define TT_wkn 01:35-21 /* wakeup on non-formatting controls */ +#define TT_wkp 01:35-22 /* wakeup on punctuation */ +#define TT_wka 01:35-23 /* wakeup on alphanumerics */ +#define TT_eco 01:35-24 /* echos on */ +#define TT_ecm 01:35-25 /* echo mode */ +#define TT_alk 01:35-26 /* allow links */ +#define TT_aad 01:35-27 /* allow advice (not implemented) */ +#define TT_dam 03:35-29 /* data mode */ +#define TTbin 00 /* binary */ +#define TTasc 01 /* ascii */ +#define TTato 02 /* ascii and translate output only */ +#define TTate 03 /* ascii and translate echos only */ +#define TT_uoc 01:35-30 /* upper case output control */ +#define TT_lic 01:35-31 /* lower case input control */ +#define TT_dum 03:35-33 /* duplex mode */ +#define TTfdx 00 /* full duplex */ +#define TT0dx 01 /* not used, reserved */ +#define TThdx 02 /* half duplex (character) */ +#define TTldx 03 /* line half duplex */ +#define TT_pgm 01:35-34 /* page mode */ +#define TT_car 01:35-35 /* carrier state */ + +/* tlink */ + +#define TL_cro 01:35-0 /* clear remote to object link */ +#define TL_cor 01:35-1 /* clear object to remote link */ +#define TL_eor 01:35-2 /* establist object to remote link */ +#define TL_ero 01:35-3 /* establish remote to object link */ +#define TL_sab 01:35-4 /* set accept bit for object */ +#define TL_abs 01:35-5 /* accept bit state */ +#define TL_sta 01:35-6 /* set or clear advice */ +#define TL_aad 01:35-7 /* accept advice */ +#define TL_obj 0777777:35-35 /* object designator */ + +#endif /* OS_TOPS20 */ + +/**********************************************************************/ + +#if OS_UNIX + +#undef BSD42 +#define BSD42 1 /* want DVISPOOL code in dviterm.h */ + +#define DVIHELP "man dvi\nor\napropos dvi" + +#ifdef FONTLIST /* can be set at compile time */ +#else +#define FONTLIST "PK-GF-PXL" /* preferred search order */ +#endif /* FONTLIST */ + +#ifdef FONTPATH /* can be set at compile time */ +#else +#define FONTPATH "/usr/lib/tex/fonts/" +#endif + +#undef MAXOPEN + +#if HPUX +#define MAXFNAME 1024 /* longest host complete filename */ +#define MAXOPEN 50 +#else /* NOT HPUX */ +#define MAXFNAME 256 /* longest host complete filename */ +#define MAXOPEN 14 +#endif /* HPUX */ + +#ifndef PS_MAXWIDTH +#define PS_MAXWIDTH 72 +#endif + +#ifndef PS_SHORTLINES +#define PS_SHORTLINES 1 /* some Unix utilities fail with long lines */ +#endif + +#ifdef SUBPATH /* can be set at compile time */ +#else +#define SUBPATH "/usr/lib/tex/macros/" +#endif + +#if TEXINPUTS /* can be set at compile time */ +#else +#define TEXINPUTS "TEXINPUTS" +#endif + +#if TEXFONTS /* can be set at compile time */ +#else +#define TEXFONTS "TEXFONTS" +#endif + +#define HOST_WORD_SIZE 32 /* must be 32 or larger -- used in */ + /* signex to pack 8-bit bytes back */ + /* into integer values, and in dispchar */ + /* and fillrect for managing character */ + /* raster storage. */ +#endif /* OS_UNIX */ + + +/**********************************************************************/ + +#if OS_VAXVMS + +/*********************************************************************** +** Several standard Unix library functions do not work properly with VMS +** C, or are not implemented: +** +** exit() -- wrong conventions for return code +** fseek() -- fails on record-oriented files +** ftell() -- fails on record-oriented files +** getchar() -- waits for <CR> to be typed +** getenv() -- colon- and case-sensitive +** getlogin() -- not implemented +** qsort() -- not implemented +** tell() -- not implemented +** ungetc() -- fails for any character with high-order bit set +** unlink() -- not implemented (equivalent available) +** +** The file VAXVMS.C contains workarounds; it must be compiled +** separately and loaded with each of the DVI drivers. +***********************************************************************/ + +#include <jpidef.h> /* need for getjpi() in openfont() */ + +#define DVIHELP "help dvi\nor\ntype tex_inputs:dvi.hlp" +#define EXIT vms_exit + +#define FILE_CNT(fp) (*fp)->_cnt +#define FILE_BASE(fp) (*fp)->_base +#define FILE_PTR(fp) (*fp)->_ptr + +#ifndef FONTLIST /* can be set at compile time */ +#define FONTLIST "PK-GF-PXL" /* preferred search order */ +#endif /* FONTLIST */ + +#ifndef FONTPATH /* can be set at compile time */ +#define FONTPATH "TEX_FONTS:" /* Kellerman & Smith VMS TeX */ +#endif /* FONTPATH */ + +#define FSEEK vms_fseek +#define FTELL vms_ftell +#define GETENV vms_getenv +#define HOST_WORD_SIZE 32 /* must be 32 or larger -- used in */ + /* signex to pack 8-bit bytes back */ + /* into integer values, and in dispchar */ + /* and fillrect for managing character */ + /* raster storage. */ + +#define MAXFNAME 256 /* longest host complete filename */ + +#undef MAXOPEN +#define MAXOPEN 14 + +#undef RB_OPEN +#define RB_OPEN "rb" + +#ifndef PS_MAXWIDTH +#define PS_MAXWIDTH 72 +#endif + +#ifndef PS_SHORTLINES +#define PS_SHORTLINES 1 /* VMS has trouble with long lines */ +#endif + +#define READ vms_read /* ordinary read() returns only one disk */ + /* at each call */ + +#ifndef SUBPATH /* can be set at compile time */ +#define SUBPATH "TEX_INPUTS:" /* Kellerman & Smith VMS TeX */ +#endif + +#ifndef TEXINPUTS /* can be set at compile time */ +#define TEXINPUTS "TEX_INPUTS:" +#endif + +#ifndef TEXFONTS /* can be set at compile time */ +#define TEXFONTS "TEX_FONTS:" +#endif + +#define UNGETC vms_ungetc + +/* VIRTUAL_FONTS cannot be implemented yet. The code works, but the +calls to FSEEK() (vms_seek) result in _filbuf() being called to refill +the buffer, obviating the pre-buffering. Additional code in case 0 of +vms_seek() can probably be developed to avoid this, but I have run out +of time for now. */ + +#undef WB_OPEN +#define WB_OPEN "wb" + +#endif /* OS_VAXVMS */ + +/**********************************************************************/ + diff --git a/systems/os2/dviware/hp-deskjet/texhelp.ovl b/systems/os2/dviware/hp-deskjet/texhelp.ovl Binary files differnew file mode 100644 index 0000000000..0e4d3a4eb3 --- /dev/null +++ b/systems/os2/dviware/hp-deskjet/texhelp.ovl diff --git a/systems/os2/e4t b/systems/os2/e4t new file mode 120000 index 0000000000..989ecd18c7 --- /dev/null +++ b/systems/os2/e4t @@ -0,0 +1 @@ +../msdos/e4t
\ No newline at end of file diff --git a/systems/os2/emtex b/systems/os2/emtex new file mode 120000 index 0000000000..cae996b453 --- /dev/null +++ b/systems/os2/emtex @@ -0,0 +1 @@ +../msdos/emtex
\ No newline at end of file diff --git a/systems/os2/emtex-contrib/texit/texit.cmd b/systems/os2/emtex-contrib/texit/texit.cmd new file mode 100644 index 0000000000..0de3e9786e --- /dev/null +++ b/systems/os2/emtex-contrib/texit/texit.cmd @@ -0,0 +1,149 @@ +/* +OS/2 script doing a kind of 'make' on a TeX file. First the TeX +source if TeXed until the .aux-file stays constant. Then, if +the -p option is provided, the postscript file is generated. +No action is taken, when the file to create is more recent than +the corresponding source from which it is to create. +NOTE: The argument must be given without extension! + +Syntax: texit [-p] <Texfilename-without-extension> + +The -p option tells texit, that the resulting DVI file should be +processed by dvips afterwards. + +First get out the basename of the file and the path where it is located +*/ + +call RxFuncAdd 'SysFileDelete', 'RexxUtil', 'SysFileDelete' +call RxFuncAdd 'SysFileTree', 'RexxUtil', 'SysFileTree' +TMP='c:\tmp' +postscript=0 +current_dir=directory() +parse arg arguments +parse var arguments options rest +if options='-p' then +do + postscript=1 + parse var arguments options arguments +end + +do while \ (arguments='') + parse var arguments filename1 arguments + filename=stream(filename1'.TeX','c','query exists') + if (filename='') then + filename=stream(filename1,'c','query exists') + if \ (filename='') then + do + bn=left(filespec("name",filename),length(filespec("name",filename))-4) + path=filespec("drive",filename)filespec("path",filename) + path=left(path,length(path)-1) + call directory path + end + else + bn='qwoeiruz' /* avoid the file being found */ + /* Check, if TeXing is necessary. */ + if exists(bn'.TeX') then + do + if exists(bn'.dvi') & get_date(bn'.dvi')>get_date(bn'.TeX') then + say 'texit: TeX started despite DVI file newer than TeX file...' + + do until \ index_changed + index_changed=0 + if exists(bn'.idx') then + 'copy 'bn'.idx 'TMP' >nul' + do until \ diff(bn'.aux', TMP'\'bn'.aux') + /* First copy .aux and .idx file to allow finding differences later on */ + if exists(bn'.aux') then + 'copy 'bn'.aux 'TMP'\'bn'.aux >nul' + 'call gblatex 'bn'.TeX' + end + + /* Now clean up the copied .aux-file */ + if exists(TMP'\'bn'.aux') then + call SysFileDelete TMP'\'bn'.aux' + + /* At this point in each case a preliminary stable dvi-file has been + built. Now look, if an index file (bn.idx) has been generated. + The condition for checking, if the .idx-file has been generated + is its date. If it's more recent than the bn.TeX file, then it is + considered generated. */ + + if diff(bn'.idx', TMP'\'bn'.idx') | (exists(bn'.idx') & \ exists(bn'.ind')) then + do + /* If the .idx-files differ, make the .ind-file using makeindex and + rerun latex in order to insert this new index into the .dvi-file + */ + index_changed = 1 + 'makeindx 'bn + end + end /* of do until \ indexchanged */ + + /* Clean up the copied .idx-file */ + if exists(TMP'\'bn'.idx') then + call SysFileDelete TMP'\'bn'.idx' + + /* Now look at postscript option: */ + if postscript then + 'call dvips 'bn + end /* if .TeX-File exists */ + else + say 'texit: TeX-File not found!' +end +call directory current_dir +exit + +/* *********************************************************************** */ +diff: procedure; +/* *********************************************************************** */ + parse arg f1, f2 + /* If the names are equal, or both files do not exists, + then the files are identical. They are considered different, if only + one of the files does not exist. */ + if f1=f2 then + return 0 + else if exists(f1) & \ exists(f2) then + return 1 + else if exists(f2) & \ exists(f1) then + return 1 + else if \ exists(f1) & \ exists(f2) then + return 0 + else if \ (stream(f1,'c','query size')=stream(f2,'c','query size')) then + return 1 + else + do + linein(f1,,0) + linein(f2,,0) + do while lines(f1) & lines(f2) + l1=linein(f1) + l2=linein(f2) + if \ (l1=l2) then + do + call stream f1, 'c', 'close' + call stream f2, 'c', 'close' + return 1 + end + end + call stream f1, 'c', 'close' + call stream f2, 'c', 'close' + return 0 + end + +/* *********************************************************************** */ +exists: procedure; +/* *********************************************************************** */ + parse arg filename + st=stream(filename,'c','query exists') + if st='' then + return 0 + else + return 1 + +/* *********************************************************************** */ +get_date: procedure; +/* *********************************************************************** */ + /* Returns the date of the file passed as argument in the format + YY/MM/DD/HH/MM */ + parse arg filename + call SysFileTree filename, ft, tf + file_date=left(ft.1,14) + return file_date diff --git a/systems/os2/emtex-contrib/texit/texit.txt b/systems/os2/emtex-contrib/texit/texit.txt new file mode 100644 index 0000000000..3b46341185 --- /dev/null +++ b/systems/os2/emtex-contrib/texit/texit.txt @@ -0,0 +1,22 @@ +texit.cmd is a REXX script, that does a dependence check similar to make, but +for TeX files. It allows generating the postscript file by an option '-p'. The +calling syntax is: + + texit [-p] <TeX-filename> + +where <TeX-filename> may contain backlashes, since texit does a cd into the +directory, where the TeX-file resides. This makes texit well-suited for use +with the WPS drag&drop facility. The <TeX-filename> may be provided with +or without extension. + +If the TeX-file causes an index-file to be created, makeindex will be called in +order to create the .ind-file. TeX will be run as long as the .dvi-file or any +file contributing to the .dvi-file changes. After that, if specified, dvips +will be called to generate the postscript output. + +The TeX executable has to be reachable as 'gblatex', makeindex has to be +callable via 'makeindx', and dvips must, how else could it be, named 'dvips'. + +Send comments and feedback to auhl@fzi.de. Enjoy, + +Axel. diff --git a/systems/os2/epmtex/epmtx31a.readme b/systems/os2/epmtex/epmtx31a.readme new file mode 100644 index 0000000000..fa91470693 --- /dev/null +++ b/systems/os2/epmtex/epmtx31a.readme @@ -0,0 +1,7 @@ + + *PATCH UPDATE* EPMTeX Standard Version 3.1a and EPMTeX Pro Version 3.1a + - November 1995 - This is an update for the EPMTeX v3.1 package to correct + two minor defects in the original release. + upload: Frank_Busse@AC3.Maus.De, Jan 22, 1996 + origin: IBM BBS Ehningen (Germany) +49-7034-63250 + diff --git a/systems/os2/epmtex/readme b/systems/os2/epmtex/readme new file mode 100644 index 0000000000..44529b06f4 --- /dev/null +++ b/systems/os2/epmtex/readme @@ -0,0 +1,210 @@ + TeX Macro Enhancements for EPM 5.51a and EPM 6 + + EPMTeX Standard Version 3.1 + and + EPMTeX Pro Version 3.1 + + Installation/Upgrade Notes + + Jon Hacker + Rodney Korte + + September 1995 + + +License Agreement: +~~~~~~~~~~~~~~~~~ +You agree to abide by the license agreement contained in the on-line help +of epmtex.exe if you choose to install or use the EPMTeX macro package. + + +CONTENTS +~~~~~~~~ + Section 1: What is EPMTeX and this new EPMTeX Pro? + (a brief synopsis of what it can do) + + Section 2: Easy installation of EPMTeX 3.1 (standard version) + (how to get going as fast and easily as possible) + + Appendix A: Removing a previous version of EPMTeX + (how to remove an old version before upgrading) + + Appendix B: Compiling in the EPMTeX Macros. + (an alternative more complicated way to install) + + Appendix C: Disclaimer + (Hey, you get what you pay for!) + + +####################################################################### + +Section 1: What is EPMTeX, and this new EPMTeX Pro? +~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +EPMTeX is a sophisticated *free* macro package that integrates the TeX +typesetting system with the IBM enhanced editor EPM for OS/2. The +EPMTeX macro suite adds a TeX pull down menu to the EPM menu bar, and +includes a PM style notebook program for configuration of the package. + +Menu items in the TeX pull down menu allow the user to TeX (with any +format, e.g. LaTeX), jump to errors in the TeX source, preview +(portrait and landscape), and print (portrait and landscape) the TeX +file currently active in EPM. Custom 'user' modes may also be defined +for special needs unique to the user. + +Due to popular demand, the standard edition of EPMTeX now comes +precompiled. The version of EPM shipped with OS/2 is all that is +required to run EPMTeX. It is no longer necessary to obtain the EPM +macro compiler from IBM to add the core EPMTeX features. Consequently, +installation is now greatly simplified. + +EPMTeX Pro... what is this? + +EPMTeX was substantially rewritten to allow it to be distributed +precompiled. In the process, some existing features were removed due to +limitations in what can be done with a precompiled EPM macro. Users of +earlier versions of EPMTeX may not wish to give up these features, +particularly if they are comfortable compiling macros for EPM. For this +reason, a Pro version of the macro package is also provided. The Pro +version does *not* come precompiled and is not recommended for novice +users. Its installation is complicated, requires the complete EPM macro +compiler from IBM, and does not offer much more than the standard +version anyway. It is provided solely as a comfort to our longtime +EPMTeX users. + +The Pro version offers the following (minor) extra things over the +standard version: + + - The format and orientation can be chosen from either the settings + notebook (as per the standard version) or from the EPM TeX menu. + - The EPM TeX menu items get enabled/disabled (greyed out) as + appropriate. For example, if the dvi file does not exist, the + preview and print functions will be greyed out in the menu. + - Access to the macro source code should you wish to dabble in + a little customization of the package. + +If you wish to use EPMTeX Pro, unzip the file TeXpro.zip included with +EPMTeX 3.1 and follow the installation instructions contained in the +file readme.pro. + +We recommend most users stick with the simpler precompiled EPMTeX +Standard version, as it is much easier to install. + + +####################################################################### + +Section 2: Easy Installation Procedure (Standard version) +~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + (see also the on-line help in epmtex.exe) + +NOTE: Users of older versions of EPMTeX will first have to + expunge the old EPMTeX files before installing the new + version. Refer to Appendix A for further instructions. + +a) Unzip the EPMTeX files into a convenient directory. + +b) Copy tex.ex and profile.erx to a directory that + is specified in either EPMPATH or PATH so that EPM can + find them. Most *.EX files are in the \OS2\APPS directory. + +NOTE: For people using EPM version 6, you need to unzip the tex.ex + file from v60x.zip to replace the tex.ex that is the + default (v5.51a). + +c) Copy bpmcc.dll to any directory in your LIBPATH. Copy + epmtex.exe and epmtex.hlp anywhere to your liking, it doesn't + matter where, but keep them together. + +d) Run epmtex.exe and fill in the notebook to describe your local TeX + environment. Refer to the on-line help for further information. + +e) Now you are ready to use the EPMTeX. There are a couple of + ways to tell EPM to load the tex.ex file (see also Appendix B). + The simplest is to use the REXX profile file 'profile.erx' + supplied with EPMTeX. EPM will automatically 'run' this file + when it starts, creating a way to customize EPM without recompiling + the epm macro files. + + Start EPM. If the TeX menu is not visible, then you need + to enable the REXX profile support. Type ctrl -i to open the EPM + command window. Type the command 'profile on' (no quotes). Then + select the 'Save Options' command in the pull-down EPM menu. + +NOTE: For people using EPM version 6, enable REXX profile support by + opening the EPM settings notebook and check the 'REXX profile' + option on the Misc page. + +f) Exit EPM and restart. The TeX menu should be visible now. Load a + TeX file and test it out! + + +####################################################################### + +APPENDIX A: Removing a previous EPMTeX Version + +To install over a previous version of EPMTeX you will need to first +purge the old EPMTeX files from your system. + +a) Remove the old EPMTeX version from your epm files: + + 1) Delete the EPMTeX part of Mymnuini.e + 2) Delete the EPMTeX part of Mykeyset.e (if any) + 3) Delete the EPMTeX part of Mykeys.e (if any) + 4) Delete the EPMTeX part of Mystuff.e (if any) + 5) Delete the EPMTeX constants from Mycnf.e (This is optional + but the constants are no longer used) + 6) delete the old tex.ex (if any) + +b) Recompile (version 6 users can skip the extra.e recompile) + etpm epm + etpm extra + +c) Now you should have a plain version of EPM, like + it was before you installed EPMTeX. Try running EPM + and make sure the TeX menu is gone. + + +####################################################################### + +APPENDIX B: Compiling in the EPMTeX Macros. + + Another way to link in the tex.ex file is to edit your mystuff.e file. + This is more work because it requires recompiling your EPM macros. In + fact, if you're going to go to this much bother, you might as well + just install the full blown EPMTeX Pro version. But for those people + who want to do it anyway, add the following lines to mystuff.e + + definit + 'linkverify tex' + + Now recompile (version 6 users can skip the extra.e recompile) + + etpm epm + etpm extra + + This will cause tex.ex to be linked in automatically whenever + you start EPM. You can delete the EPMTeX portion of your profile.erx + file if you use this method since it is no longer needed. + + +####################################################################### + +APPENDIX C: Disclaimer: + ~~~~~~~~~~ + +We are by no means experts on programming the EPM enhanced editor. While these +TeX enhancements have been fairly thoroughly tested, there could easily be +oversights on our parts that result in problems for some configurations of EPM. +If you think you have found a genuine bug, or would like to make suggestions, +contributions, or enhancements to this code please drop one of us a note. +Since we have released this code without charge, we cannot offer a warranty +or customer support. Everything you need to get going should be available +in the EPMTeX package and the IBM supplied EPM documentation. + +9/95 +Jon Hacker +INTERNET: hacker@patagonia.bellcore.com + +Rodney Korte +Penn State, State College, PA +INTERNET: korte@sabine.psu.edu + diff --git a/systems/os2/epmtfe/NEWS b/systems/os2/epmtfe/NEWS new file mode 100644 index 0000000000..a80a793bd5 --- /dev/null +++ b/systems/os2/epmtfe/NEWS @@ -0,0 +1,433 @@ +EPM TeX Front End: Changes, new features and bug fixes +======================================================== + + + +Version 5.4 (Special thanks to Andreas Schnellbacher!) +------------------------------------------------------ + +All particular features of the former "professional" +version, including the live menu, are now made available +also with the precompiled (linkable) version. + +The `classic' flavor of the TFE (the one for use with emTeX) +is no longer shipped as a precompiled module, It can +however, still be compiled from the sources. + +Browsing through error messages in the source code is now +possible also after TeXing of a marked region. + +Small improvements to the configuration menu and menu texts. + +Both the source code and the ready-made module will be +compatible with NEPMD 1.01 or better. (Still undocumented) + +The interface to the experimental auto-indentation and +reflowing package has been removed from the source code; +I doubt that anyone has ever used it in practice, and it was +never fully working. + +The source file MYMNUINI.ADD is no longer needed; if you +have installed the sources of the TFE, delete its contents +from MYMNUNI.E (or delete the latter file completely, if it +is nothing but a copy of MYMNUINI.ADD). + + + +Version 4.2 +----------- +By default, .dtx and .ins are recognized as TeX document +files, in addition to .tex; .cls is recognized as macro +file, in addition to .sty. + +Particular changes to the "classical" version: + + Additional menu item for ps2pdf + + The toolbar is no longer provided. An existing toolbar + can still be used, but it will be lacking the ps2pdf + action. + + Bug fix: The default actions for PDF and PS preview are + properly intialized now. + + Decent error message (pop-up window), when dvips is + requested while no dvips program is specified. + +Particular changes to the version for VTeX: + + Default VTeX options are appropriate for latest VTeX/2. + + Documentation substantially improved and corrected. + + + +Version 4.0 +----------- +Everything, except for the user-defined menu items, can be +configured interactively now; this holds both for the +"classical" and for the "VTeX" version of the TeX Front End. + +The format can be specified in teTeX-like syntax, i.e., by a +pseudo comment like %&latex in the first line. The old +texit-style syntax (% Format: latex) is still valid, too. + +External commands are passed the fully qualified filename +now, in order to avoid potential problems. + +Thorough "clean up" of menus, window titles and error messages. + +Default path for gsview updated with respect to GSView 4.x. + +The following changes affect only the TeX Front End for +VTeX: + + Default VTeX options: + With PS mode, the default BoundingBox is set to A4; + with PDF mode, CFF font embedding is enabled. + + New menu item to build file name cache; the item is + enabled only if a cache is actually used. + + Changed VTeX invocation so that the window will stay open + after the VTeX run, if there was any error. This requires + VTeX 7.45e or later and appropriate setting of + "retcodes=0,0,1,1" in vtex.ini; otherwise any warning will + cause the window to stay open. + + Improved parsing of the log file, making use of VTeX"s + particular error messages, which indicate the file name, + too. + +The following changes affect only the "classical" +TeX Front End: + + Format names are immediately used as command names, with + the exception of "plain", which is always translated to + "tex". + + The menu item "TeX/PS" is disabled, if the dvips program + is unknown. With the previous version, this situation + would result in a strange error message from the command + shell. + + + +Version 3.0 +----------- +The "quick keys" F9..F12 are permanently enabled now. +The "auxiliary" file types need no longer be specified. +The default VTeX options were changed wrt/ VTeX/2 v7.00. +With the Pro version, the menu is always active. + +The German versions of the texfe module were compiled with +the EPM bracket matching facility mapped to Ctrl-a, because +the default key combo Ctrl-[ is useless with a German +keyboard. + +Improved documentation. + +Internal code cleanup. + + + +Version 2.6 +----------- +There is a special version of the TeX Front End for VTeX now. + +The distribution has been rearranged. + +The settings dialogs have been added a button to restore +the default settings. + + + +Version 2.5a +------------ +Fixed tfconfig.cmd (new version is 2.9c): The previous +version would cause unexpected and faulty behaviour of the +TeX Front End, when the configuration file contained TAB +characters. + + + +Version 2.5 +----------- +Bug fix: The toolbar used to display a wrong icon for the +second user-definable command; this has been corrected. + +Bug fix: A folder which has been opened from the TeX menu +can be closed properly via the window list now. + +Bug fix: TeXing a document in the root directory of a drive +should no longer fail. + +New feature: Additional Menu and toolbar items for starting +a pdf previewing program (Ghostscript or Acrobat). + +New feature: "Locate Next Error" will now understand the +log files from VTeX/2, too. + +Menu shortcut for dvips changed to "v". + + + +Version 2.4 (as of 1999/03/29 or later) +----------- +New sample configuration files profile.smp and MYCNF.SMP; +they select automatic conversion from Unix to DOS-style line +endings, so that one cannot unwantedly produce mixed-style +files any longer. This does not affect the TeX FrontEnd +modules, so the version number is unchanged. + + + +Version 2.4 +----------- +When a path was given for the master file, it was not always +evaluated properly; this has (hopefully ;-) been fixed. +(Thanks to Wonkoo Kim for detecting this bug!) + +The hot keys and the syntax assist facility would fail +sometimes, especially when a filename was passed to the EPM +on the command line or via "drag and drop". This should +have been fixed now. (Thanks to Frank Schmittroth for +pointing me to this problem!) + +TeXing a marked region now works with standard (CUA) marking +mode, too, as opposed to "advanced" marking mode only. + +Enhanced syntax assist: Expand \[ and \( + +Menu shortcut and "quick key" for dvips. + +The menu item PRINT is suppressed, if there is no command +defined for it. + +Running TeX and dvips in sequence does no longer require a +separate shell script (tfetexps.cmd). + +The dvips program may now be a .cmd file, too. + +Dvips options are now passed before the name of the dvi +file; the name of the dvi file is passed to dvips _without_ +the extension ".dvi". + +When running dvips, the OS/2 window will stay open in case +there occurs an error in dvips, so that the error message +can be read. + +The texfe version without menu is no longer distributed in +binary (.ex) format; it can, however, still be compiled from +the source code. Please, contact the author if you need +this badly, but cannot compile it yourself! + +The toolbar will show the original GSView icon now. + +---> See the file SOURCE\compile.txt for additional features +which are not provided with the pre-compiled modules. + + + +Version 2.3 +----------- +(not released) + + + +Version 2.2 +----------- +Improved syntax assist: +- Arguments of environments may appear on the same line. +- Arbitrary long environment names are recognized. +- Reasonable handling of the "verbatim" and "macrocode" + environments. + +Documentation bugs fixed. + +Optimized code for processing the EPMTeX accelerator keys; +approx. 1kB smaller than the previous version. + +Improved EPM configuration (source) file MYCNF.SMP, +including a bug fix for the "Tags" facility. + +LaTeX indentation is now enabled in the source code by +default. + + + +Version 2.1 +----------- +Files with identical names, i.e., differing with respect to +the path only, are now handled properly. + +The precompiled modules come with LaTeX auto-indentation +enabled now. + +Fixed menu item "Menu always on". (Affects Pro version +only.) + + + +Version 2.0 +----------- +The TeX menu is now provided with the module, too. Use of +the toolbar is optional. Also a toolbar-only version (i.e. +without a menu) is available. + +The default TeX format can be changed via the settings menu. + +New syntax expansion: \fo -> \footnote{} + +Fixed syntax expansion: \end{...} will be indented by the +same amount as the corresponding \begin{...}. + +A sinple auto-indent facility for LaTeX environments, +similar to EPM syntax assist for C or Java, is provided. +(Source code only, not part of the precompiled modules!) + +The source code provides a "hook" for the inclusion of +Juan J.G. Ripoll"s LaTeX auto-indentation and reflowing +package. See the file SOURCE\compile.txt. + +"Menu always on" is enabled/disabled via the menu only. + +A customized <enter> key will be honored upon compilation. + +>> Many thanks to Wonkoo Kim for his help and his ideas! << + + + +Version 1.1, bug fix #1 +----------------------- + +Fixed the menu item "Master file support". (Applies to the +"Pro" version only.) + +tfconfig v2.9: The previous version would not always find +the EPM.INI file. Null bytes are no longer written to the +standard output. + + + +Version 1.1 +----------- +A German version is now available beside the international +(english) one. + +Partial TeXing is no longer restricted to the LaTeX format. + +The actions "Log" and "Error" now refer to the log file of +the most recent TeX run. + +New icon TEXFE.ICO. The previous one was corrupt and should +not be used any more! + +The location of a TeX error in the source code is marked by +a colored circle. + +Pressing "Log" while the log file is already being edited +will now reset the error browsing facility to the first +error message in the log file. + +The master file is loaded for TeXing only, not for the other +actions. + +The EPM changes the current directory only if this is +required to execute a command, not each time a new file gets +displayed. + +Changes to the syntax expansion facility: Added \ref{} and +\label{}, removed \hspace{} and \vspace{}. + +Fixed a bug which prevented the "description" environment +from getting expanded. + +Fixed a bug which, in certain cases, made the actions +"Shell" and "Folder" start up in the wrong directory, when +multiple EPM windows had been opened. + +The TeX command connected with a certain format can be a +.exe file, too. + +.dtx and .fdd files are never highlighted. + +Each occurrence of %**N or %**F in the external commands +(not only the first one) is replaced with the file name. + +Added "Cancel" buttons to various dialog windows. + +Added sample REXX profile "profile.smp" + +New, smaller, toolbar. Toolbars from v0.96 or 1.0 can still +be used. Names of the toolbar bitmap files changed. + + + +Version 1.0 +----------- +A marked region of a file can be TeXed. + +"View Log File" loads the file read-only and shows the +position of the last error which has been located before. + +The name of the dvips program can now be specified in +tfe.cfg. The default is "dvips", as before. + +Fixed TeX/PS action to accept file types other than .TEX, +too. + +Fixed auto save facility (could not save included files +which had no extension). + +Fixed the last remaining bugs which had caused the "find +next error" facility to crash with certain TeX error +messages in the log file. + +New icon for the configuration menu. + +The debug level is no longer memorized in the INI file. +Each EPM session will start with TeX_debuglevel = 0 . + + + +Version 0.96 +------------ +Fixed a bug in the TFCONFIG program: The USERn commands +would not start, if a blank character was given between the +equals sign and the file type in tfe.cfg. + +The editor commands have been replaced with a +"Configuration" menu, suggested and written by Wonkoo Kim. + +Added "quick keys" for main actions. + +TeX errors which do not refer to a line number, e.g. +"Runaway argument", will no longer cause the "Error" +facility to run into an endless loop. + +Syntax assist: Completion of environments and keywords is +always enabled with TeX documents and style files. + +Syntax assist: +Added \fr -> \frac{}{}, removed \it -> \item. + +Syntax assist: All "accelerator keys" from EPMTeX are now +available. + +The configuration program TFCONFIG.CMD does no longer +overwrite the settings entered interactively. As a +consequence, however, settings are _not_ deleted +automatically when missing from tfe.cfg. Instead, they must +be deleted explicitly by specifying an empty value. + + + +Version 0.92 +------------ +See the source file texfe.e for a summary of all changes +with respect to EPMTeX 3.1a. + + +-- finis + diff --git a/systems/os2/epmtfe/README.epmtfe b/systems/os2/epmtfe/README.epmtfe new file mode 100644 index 0000000000..9034c5e698 --- /dev/null +++ b/systems/os2/epmtfe/README.epmtfe @@ -0,0 +1,41 @@ +============================================================ + The EPM TeX Front End version 5.4 2004-07-25 +============================================================ + Walter Schmidt + <epmtfe (at) gmx.net> + + +The EPM TeX Front End is an additional module for the OS/2 +`Enhanced Editor' (EPM). It turns the EPM into an +integrated TeX environment, providing (La)TeXing, +previewing, executing BibTeX, makeindex etc. from the EPM +menu. + +The TeX Front End is primarily intended for use with the TeX +system VTeX/2 <http://www.micropress-inc.com/os2>. +A version, that works also with traditional TeX systems such +as emTeX, can be compiled from the E language sources. + +Remarkable features are: + +* (La)TeX errors are highlighted in the document source +* optional TeXing of a marked region of a file +* support for multi-file documents +* optional LaTeX syntax assist +* Postscript support (dvips conversion on-the-fly) +* maintenance of the path cache (file name database) for + VTeX +* user-definable menu items +* OS/2 shell and WPS interface +* stable, reliable, and esay to use +* available with either English or German user interface + +Download the archive file tfe.zip and the documentation file +tfe.pdf; then follow the instructions in the documentation +file. + +The E language sources of the TeX Front End are available +from the archive file source.zip. + + +== finis diff --git a/systems/os2/epmtfe/epmtfe.license b/systems/os2/epmtfe/epmtfe.license new file mode 100644 index 0000000000..71d8d4e88a --- /dev/null +++ b/systems/os2/epmtfe/epmtfe.license @@ -0,0 +1,88 @@ + License Agreement for + EPM TeX Front End + + +IF YOU DOWNLOAD OR USE THE EPM TEX FRONT END (PROGRAM) YOU +AGREE TO THESE TERMS: + +I grant you a license to use the Program, only in the +country where you acquired it. The Program is copyrighted +and licensed (not sold). I do not transfer title to the +Program to you. You obtain no rights other than those +granted you under this license. + +Under this license, you may: + + 1. use the Program on one or more machines at a time; + + 2. make copies of the Program for use or backup purposes + within your Enterprise; + + 3. make copies of the original files and distribute them, + provided that you distribute ALL files of the Program, as + listed in the file manifest.txt, including this license. + The other party agrees to these terms by its first use of + the Program. + + 4. modify the source code provided that you change the + name of the package source code files and give credit + where credit is due. + +You must reproduce the copyright notice and any other legend +of ownership on each copy or partial copy of the Program. + +You may NOT sublicense, rent, lease, or assign the Program. + +Under no circumstances am I liable for any of the following: + + 1. third-party claims against you for losses or damages; + + 2. loss of, or damage to, your records or data; or + + 3. economic consequential damages (including lost profits + or savings) or incidental damages, even if I am informed + of their possibility. + +Some jurisdictions do not allow these limitations or +exclusions, so they may not apply to you. + +I do not warrant uninterrupted or error free operation of +the Program. I have no obligation to provide service, +defect correction, or any maintenance for the Program. I +have no obligation to supply any Program updates or +enhancements to you even if such are or later become +available. + +THERE ARE NO WARRANTIES, EXPRESS OR IMPLIED, INCLUDING THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +PARTICULAR PURPOSE. + +Some jurisdictions do not allow the exclusion of implied +warranties, so the above exclusion may not apply to you. + +You may terminate this license at any time. I may terminate +this license if you fail to comply with any of its terms. +In either event, you must destroy all your copies of the +Program. + +You are responsible for the payment of any taxes resulting +from this license. + +You may not sell, transfer, assign, or subcontract any of +your rights or obligations under this license. Any attempt +to do so is void. + +Neither of us may bring a legal action more than two years +after the cause of action arose. + +This license is governed by the laws of the country in which +you acquired the Program. + + + January 2003 + + Walter Schmidt + Nuernberger Strasse 76 + 91052 Erlangen + Germany + diff --git a/systems/os2/epmtfe/manifest.txt b/systems/os2/epmtfe/manifest.txt new file mode 100644 index 0000000000..41a58e8301 --- /dev/null +++ b/systems/os2/epmtfe/manifest.txt @@ -0,0 +1,12 @@ +These are the files of the EPM TeX Front End distribution: + +NEWS +README.epmtfe +epmtfe.license +manifest.txt +readme.pdf +source.zip +tfe.zip + +-- finis + diff --git a/systems/os2/epmtfe/tfe.pdf b/systems/os2/epmtfe/tfe.pdf Binary files differnew file mode 100644 index 0000000000..94cf66e727 --- /dev/null +++ b/systems/os2/epmtfe/tfe.pdf diff --git a/systems/os2/ftetx/README b/systems/os2/ftetx/README new file mode 120000 index 0000000000..bf07a27adc --- /dev/null +++ b/systems/os2/ftetx/README @@ -0,0 +1 @@ +file_id.diz
\ No newline at end of file diff --git a/systems/os2/ftetx/file_id.diz b/systems/os2/ftetx/file_id.diz new file mode 100644 index 0000000000..883b3b37b5 --- /dev/null +++ b/systems/os2/ftetx/file_id.diz @@ -0,0 +1,19 @@ +TeX-addons for the fte text editor. +----------------------------------- +version 0.04 +(c) 1997, Oliver John von Zydowitz + +o Replacement of the original syntax + highlighter for TeX-mode +o TeX-Macro/Template Menu +o Launching TeX programs from fte + (TeX, dvi-drivers, ghostscript...) +o Calling LaTeX help files +o split documents support + +Operating systems: + OS/2, DOS. Linux (see docs). + Windows not supported (but see docs). + +Requires: +fte 0.46beta3 or later (see docs). diff --git a/systems/os2/os2tex/os2tex.eng b/systems/os2/os2tex/os2tex.eng new file mode 100644 index 0000000000..9135440d98 --- /dev/null +++ b/systems/os2/os2tex/os2tex.eng @@ -0,0 +1,146 @@ +*********************************************************************
+* OS2TeX December 1998 *
+*********************************************************************
+
+
+Content:
+
+About OS2TeX
+What are the features of OS2TeX?
+Installation requirements
+How to install OS2TeX?
+The first step after installing OS2TeX
+Important information for English speaking users
+How to register?
+
+
+
+ABOUT OS2TeX
+
+OS2TeX is a distribution of Donald E. Knuth's typesetting system TeX
+for the IBM operating system OS/2 Warp.
+
+---------------------------------------------------------------------
+
+WHAT ARE THE FEATURES OF OS2TeX?
+
+- An installation program installs and configures the whole system
+
+- User interface (shell) is supporting every step to create and work
+ on TeX documents
+
+- Automatic creation of the needed fonts for every output device
+ controlled by an OS/2 printer driver.
+
+- OS2TeX is based on the client-server architecture. Caused by this
+ the consistency of the fonts is guaranteed, even if several DVI
+ drivers are active at the same time.
+
+- Tool for the driver independent integration of graphics into TeX
+ documents by the transformation of graphics to fonts. The graphics
+ can be scaled to several resolutions. Therefore it is possible to
+ print documents with graphcis on printers with different
+ resolutions, e.g. 300 dpi and 360 dpi.
+
+- OS2TeX is built up multi-threaded, including modern techniques of
+ process synchronisation, therefore serveral steps can be done at
+ the same time.
+
+---------------------------------------------------------------------
+
+INSTALLATION REQUIREMENTS
+
+- OS/2 Warp V3, OS/2 Warp V4 fixpack 1 and higher.
+
+- HPFS filesystem.
+
+- 30 MB of free disk space.
+
+---------------------------------------------------------------------
+
+HOW TO INSTALL OS2TeX?
+
+
+1. Unzip file os2tex.zip:
+
+ unzip os2tex.zip
+
+ You'll get 8 files:
+
+ os2tex.ger
+ os2tex.eng
+ disk1.zip
+ disk2.zip
+ disk3.zip
+ disk4.zip
+ disk5.zip
+ disk6.zip
+
+2.1. Create a temporary directorie on hard disk:
+
+ md temp
+
+2.2 Change into that directory:
+
+ cd temp
+
+2.3 Unzip disk1.zip through disk4.zip:
+
+ unzip -o disk1.zip
+ unzip -o disk2.zip
+ unzip -o disk3.zip
+ unzip -o disk4.zip
+ unzip -o disk5.zip
+ unzip -o disk6.zip
+
+2.4 Start the installation program and follow the instructions:
+
+ install.exe
+
+---------------------------------------------------------------------
+
+THE FIRST STEP AFTER INSTALLING OS2TEX
+
+As mentioned above, OS2TeX is based on the client-server
+architecture. A DVI previewer will try to establish a connection
+to a font server for retrieving fonts that are part of your TeX
+document. Therefore it is necessary to start the font server
+before starting any DVI viewer. This is done through an icon
+"metafont server", you will find within the OS/2-TeX folder.
+
+If you forget to start the metafont server, any requests on fonts
+will fail!
+
+---------------------------------------------------------------------
+
+IMPORTANT INFORMATION FOR ENGLISH SPEAKING USERS
+
+The English translation is not quite complete. All menus and dialogs
+are written in English, but not the help files. A version including
+all help files written in English is planned in 1998.
+
+---------------------------------------------------------------------
+
+HOW TO REGISTER?
+
+If you'd like to register OS2TeX or to provide feedback, make feature
+requests or to report a bug, please contact the author:
+
+Jrgen Kleinb”hl
+Heinrich-Heine-Str. 18
+64560 Riedstadt
+Germany
+
+e-mail: kleinboe@hrzpub.tu-darmstadt.de
+
+WEB: http://www.tu-darmstadt.de/~kleinboe/os2tex.html
+
+Fax: +49(0)6158-975253
+
+OS2TeX is shareware and costs 70 DEM per copy. Updates will be free
+of charge (subject for alterations). For holding these conditions, as
+much as possible users should register OS2TeX!
+
+---------------------------------------------------------------------
+
+
\ No newline at end of file diff --git a/systems/os2/os2tex/os2tex.ger b/systems/os2/os2tex/os2tex.ger new file mode 100644 index 0000000000..bb68cb8d22 --- /dev/null +++ b/systems/os2/os2tex/os2tex.ger @@ -0,0 +1,167 @@ +*********************************************************************
+* OS2TeX Dezember 1998 *
+*********************************************************************
+
+
+Inhalt:
+
+Was ist OS2TeX?
+Was sind die Merkmale von OS2TeX?
+Voraussetzungen fuer die Installation
+Wie wird OS2TeX installiert?
+Was tun, wenn die Installation fehlschlaegt?
+Der erste Schritt mit OS2TeX
+Wie kann man sich registrieren lassen?
+
+
+
+Was ist OS2TeX?
+
+OS2TeX ist eine Distribution des Textsatzsystems TeX fuer das IBM-
+Betriebssystem OS/2 Warp.
+
+---------------------------------------------------------------------
+
+Was sind die Merkmale von OS2TeX?
+
+- Automatische Installation und Konfiguration.
+
+- Einfache integrierte Entwicklungsumgebung mit Editor, DVI-
+ Previewer und Compiler-Aufruf.
+
+- Externer DVI-Previewer mit voller Unterstuetzung des OS/2
+ Presentations Managers, auch beim Drucken.
+
+- Drucken auf jedem beliebigen Ausgabegeraet, fuer das ein OS/2
+ Druckertreiber existiert.
+
+- Automatische Berechnung der Zeichensaetze bei Bedarf durch
+ Metafont.
+
+- Zentrale Verwaltung der Zeichensaetze mithilfe eines Zeichen-
+ satz-Servers auf Basis der Client-Server Architektur.
+
+ ø Da alle DVI-Clienten mit demselben Server kommunizieren, kommt
+ es zu keinen Inkonsistenzen in der Zeichensatzverwaltung, wenn
+ mehrer DVI-Treiber denselben Zeichensatz anfordern.
+
+ ø Optimierte Speicherauslastung durch Shared-Memory-Konzept.
+ Jeder Zeichensatz wird nur genau einmal geladen, auch dann, wenn
+ ihn mehrere DVI-Treiber gleichzeitig benutzten.
+
+ ø Durch die Client-Server-Architektur kann OS2TeX prinzipiell
+ mit Netzwerkfaehigkeiten nachgeruestet werden.
+
+- Vereinfachte Integration von Bildern und Grafiken nach der
+ Methode der Transformation in TeX-Zeichensaetze. Uebersicht ueber
+ die bereits bearbeiteten Grafiken mithilfe eines Dia-Leucht-
+ tisches.
+
+- PM-Programm Formatdatei-Werkzeug zur einfachen Erstellung von
+ ein- und zweisprachigen LaTeX2e-Formatdateien.
+
+- OS2TeX ist vollstaendig multi-threaded ausgelegt.
+
+---------------------------------------------------------------------
+
+Voraussetzungen fuer die Installation:
+
+- OS/2 Warp V3, OS/2 Warp V4 mit Fixpack 1 oder h”her
+
+- HPFS-Dateisystem.
+
+- 30 MB freier Speicher auf der Festplatte.
+
+- Grafikkarte mit Aufloesung 800 x 600 Punkte oder h”her
+
+---------------------------------------------------------------------
+
+Wie wird OS2TeX installiert?
+
+
+1. Auspacken der Datei os2tex.zip:
+
+ unzip os2tex.zip
+
+ Es werden 8 Dateien erzeugt:
+
+ os2tex.ger
+ os2tex.eng
+ disk1.zip
+ disk2.zip
+ disk3.zip
+ disk4.zip
+ disk5.zip
+ disk6.zip
+
+2.1 Erzeugen eines temporaeren Verzeichnisses auf der Festplatte:
+
+ md temp
+
+2.2 In das Verzeichnis wechseln:
+
+ cd temp
+
+2.3 Die 6 Disketten entpacken:
+
+ unzip -o disk1.zip
+ unzip -o disk2.zip
+ unzip -o disk3.zip
+ unzip -o disk4.zip
+ unzip -o disk5.zip
+ unzip -o disk6.zip
+
+2.4 Das Installationsprogramm starten:
+
+ install.exe
+
+---------------------------------------------------------------------
+
+Was tun, wenn die Installation fehlschlaegt?
+
+Das Installationsprogramm protokolliert jeden Installationsschritt
+in der Datei install.log. Diese Datei befindet sich im Verzeichnis
+texmf\os2tex\install. Tritt bei der Installation ein Fehler auf,
+so kann diese Protokolldatei zwecks Fehleranalyse an den Programm-
+Auto eingeschickt werden.
+
+---------------------------------------------------------------------
+
+Der erste Schritt mit OS2TeX
+
+Das Installationsprogramm erzeugt auf der WPS eine Ordner-Struktur,
+ueber die alle ausfhrbaren Programme und die Dokumentationen
+bequem erreichbar sind.
+
+Nach dem Hochfahren des Betriebssystems muá vor der ersten TeX-
+Arbeitssitzung der Schriftarten-Server gestartet werden, damit
+die Dvi-Previewer Zugriff auf die Zeichens„tze erhalten. Fr den
+Schriftarten-Server gibt es ein Programm-Icon, welches sich im
+OS/2-TeX-Order auf der WPS befindet. Doppelklickt man auf dieses
+Symbol wird der Metafont-Server in einem OS/2-Fenster gestartet.
+
+---------------------------------------------------------------------
+
+Wie kann man sich registrieren lassen?
+
+Anwender, die sich registrieren lassen moechten, koennen mit dem
+Programm-Autor in Kontakt treten:
+
+Juergen Kleinboehl
+Heinrich-Heine-Str. 18
+64560 Riedstadt
+Germany
+
+e-mail: kleinboe@hrzpub.tu-darmstadt.de
+
+WEB: http://www.tu-darmstadt.de/~kleinboe/os2tex.html
+
+Fax: +049(0)6158-975253
+
+OS2TeX ist Shareware, die Registriergebuehr betraegt 70 DM.
+Ein Versand der 6 Disketten ist nicht mehr m”glich.
+Alle Updates sind kostenlos.
+
+---------------------------------------------------------------------
+
+
\ No newline at end of file diff --git a/systems/os2/pmcstex/README b/systems/os2/pmcstex/README new file mode 100644 index 0000000000..efa8c53343 --- /dev/null +++ b/systems/os2/pmcstex/README @@ -0,0 +1,29 @@ +This is pmCSTeX for EPM, version 16. 4. 2000 (April 16, 2000) + +pmCSTeX is a macro package for the OS/2 editor EPM (Enhanced Programmers +Editor, version 6.03b or higher). + +It installs the CSTeX menu, hotkeys and optionally a toolbar into EPM, which +access comfortably many useful actions for {em}(La)TeXing from within the EPM: + -- (La)TeXing the document, LaTeXing a paragraph, + -- locate next error, + -- previewing (dviPM version, full-screen, and printer previewing), + -- printing (several printers configurable or print to a file), + -- producing PostScript output (dvips-ing, GhostView or psview preview), + -- access to other TeX tools like BibTeX, MakeIndex, vlnka, cstocs, + -- all of the above is applied to the currently edited file or its Master; + the Master, TeX format, dvips options etc. is easily configured on the + first line of the Master file, + -- new editor actions added (the list of the LaTeX/AMS-math environments + and fonts; a keyboard of the names of Greek letters, generalized + version of the "Include file under cursor" (Alt-1) action, easy + manipulation with dictionary of several languages, syntax highlighting, + TeX-friendly paragraph reformatting, filter for backing up edited files + before save, + -- hypertext help for the LaTeX2e commands, + -- and much more. + +pmCSTeX for EPM tries to implement the best features of these packages: +CSTeX MNU for DOS, TeXshell, EPMTeX, pmgraf, emacs. + +Homepage: http://www.sci.muni.cz/~mikulik/os2/pmCSTeX.html diff --git a/systems/os2/texed/ReadMe.txt b/systems/os2/texed/ReadMe.txt new file mode 100644 index 0000000000..3915c39d21 --- /dev/null +++ b/systems/os2/texed/ReadMe.txt @@ -0,0 +1,138 @@ + + + + + FSS - TeX Editor V1.3 + (8/96) + + + +FSS-TeXEdit provide an easy interface for LaTeX2e, dvips, Ghostscript +and ispell. Most actions can be done like in common writing programmes +but you will have all features of LaTeX2e. + +Read this overview, try TeXEdit and you will not live without it any more. + +TeXEdit was written and developed in german. After some people asked me +for an english version I have started a first translation. It took more +time as I thought, but now I have a first result. Of course you will find +some errors (particularly in the INF file) but feel free to send me a bug +report. I try to complete the help file soon. + +I am sure that it takes some time to finish the INF file, but I want to +place TeXEdit at your disposal now. +-------------------------------------------------------------------------- + +Some features: + + - 32bit multi-threaded design which is able to handle long file names. + + - Easiest way to build TeX source files with + 'pull-down' and 'click-up' menus, or with drag and drop. + + - Address data base included. + + - Shortcuts for macros + + - Text modules + + - The way of formating is the same as in common programmes: Select text + and choose the formating command (bold, center, rotate etc.). + + - The menu bar provides access to more than 150 LaTeX-commands. + + - Input of (mathematic or special) characters with preview. + + - Supports dvips and LaTeX2e. + + - One shell as console for all programmes + + - Templates + + - Quick access window with all captions, which is able to move the text to + the selected caption. + + - Comfortable editing of several files + + - ReXX interface + + - Automatic insertion of EPS, PCX and HPGL files by drag and drop. + + - Drag and drop + - for import commands (EPS, PCX, HPGL, TeX) + - for deleting the window + - for (formated) printing + + - Help for LaTeX commands (F1) and access to all with emTeX distributed + INF files. + + - Support of extern speller. + + - Preload option for a quick startup. +-------------------------------------------------------------------------- +Systemrequirements: + + - OS/2 2.1 or higher + + - 1,8 MB disk space + + - VGA minimum + 800x600 recommended + + - 12 MB RAM recommended + (for simultaneous use of TeXEdit, Previewer and TeX) + + - Installed emTeX distribution + + - dvips, Ghostscript and hp2xx recommended + +-------------------------------------------------------------------------- + +Installation: + + The installation procedure is described in TeXEdit.INF. + + +-------------------------------------------------------------------------- + +Deinstallation: + + - Therefor you've to call DEINST.CMD. It will delete all entries + made by TeXEdit from the OS2.INI file, but it will not delete + any files. + +-------------------------------------------------------------------------- + +Misc: + + FSS-TeXEdit is shareware. You may use this programme (which provides + nearly all features of the registered version) for a testing period. + If you find FSS-TeXEdit useful, please register. After adding your + registration code to TexEdit the following features will be available: + + - The status bar can be closed + + - The macro interface will be available. You can write your own + macros and you've access to some useful macros provided with + TeXEdit + + - You're allowed to open as many files as you want at one time. + + - The data base will save more than 5 addresses. + + - The text module option will be available. + + - The 'printing with options' will work + + - The 'next error' Button will work + + + The registration of TeXEdit will cost $50. It is a life time + registration. You don't have to pay for any newer version. + + + Frank Stippich + Jakob-Bernhard Strasse 9 + 69151 Neckargemuend (Germany) + Tel. 049+ 62 23 87 96 + E-Mail: 106154.1231@compuserve.com diff --git a/systems/os2/texit/texit046.txt b/systems/os2/texit/texit046.txt new file mode 100644 index 0000000000..4c56f08b08 --- /dev/null +++ b/systems/os2/texit/texit046.txt @@ -0,0 +1,10 @@ +desc:
+
+TeXIT 0.46, is a Worksshell for emTeX
+or other OS/2 TeX-packages.
+
+Only for OS/2 Warp.
+
+author: Michael Schank
+email: schank@nuertingen.netsurf.de
+dest: somewhere in /warp/utils
diff --git a/systems/os2/texshell b/systems/os2/texshell new file mode 120000 index 0000000000..bc246efbb1 --- /dev/null +++ b/systems/os2/texshell @@ -0,0 +1 @@ +../msdos/texshell
\ No newline at end of file diff --git a/systems/os2/web2c-6.1/copying b/systems/os2/web2c-6.1/copying new file mode 100644 index 0000000000..a43ea2126f --- /dev/null +++ b/systems/os2/web2c-6.1/copying @@ -0,0 +1,339 @@ + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 675 Mass Ave, Cambridge, MA 02139, USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + Appendix: How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + <one line to give the program's name and a brief idea of what it does.> + Copyright (C) 19yy <name of author> + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) 19yy name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + <signature of Ty Coon>, 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. diff --git a/systems/os2/web2c-6.1/copying.lib b/systems/os2/web2c-6.1/copying.lib new file mode 100644 index 0000000000..eb685a5ec9 --- /dev/null +++ b/systems/os2/web2c-6.1/copying.lib @@ -0,0 +1,481 @@ + GNU LIBRARY GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1991 Free Software Foundation, Inc. + 675 Mass Ave, Cambridge, MA 02139, USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the library GPL. It is + numbered 2 because it goes with version 2 of the ordinary GPL.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Library General Public License, applies to some +specially designated Free Software Foundation software, and to any +other libraries whose authors decide to use it. You can use it for +your libraries, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if +you distribute copies of the library, or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link a program with the library, you must provide +complete object files to the recipients so that they can relink them +with the library, after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + Our method of protecting your rights has two steps: (1) copyright +the library, and (2) offer you this license which gives you legal +permission to copy, distribute and/or modify the library. + + Also, for each distributor's protection, we want to make certain +that everyone understands that there is no warranty for this free +library. If the library is modified by someone else and passed on, we +want its recipients to know that what they have is not the original +version, so that any problems introduced by others will not reflect on +the original authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that companies distributing free +software will individually obtain patent licenses, thus in effect +transforming the program into proprietary software. To prevent this, +we have made it clear that any patent must be licensed for everyone's +free use or not licensed at all. + + Most GNU software, including some libraries, is covered by the ordinary +GNU General Public License, which was designed for utility programs. This +license, the GNU Library General Public License, applies to certain +designated libraries. This license is quite different from the ordinary +one; be sure to read it in full, and don't assume that anything in it is +the same as in the ordinary license. + + The reason we have a separate public license for some libraries is that +they blur the distinction we usually make between modifying or adding to a +program and simply using it. Linking a program with a library, without +changing the library, is in some sense simply using the library, and is +analogous to running a utility program or application program. However, in +a textual and legal sense, the linked executable is a combined work, a +derivative of the original library, and the ordinary General Public License +treats it as such. + + Because of this blurred distinction, using the ordinary General +Public License for libraries did not effectively promote software +sharing, because most developers did not use the libraries. We +concluded that weaker conditions might promote sharing better. + + However, unrestricted linking of non-free programs would deprive the +users of those programs of all benefit from the free status of the +libraries themselves. This Library General Public License is intended to +permit developers of non-free programs to use free libraries, while +preserving your freedom as a user of such programs to change the free +libraries that are incorporated in them. (We have not seen how to achieve +this as regards changes in header files, but we have achieved it as regards +changes in the actual functions of the Library.) The hope is that this +will lead to faster development of free libraries. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, while the latter only +works together with the library. + + Note that it is possible for a library to be covered by the ordinary +General Public License rather than by this special one. + + GNU LIBRARY GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library which +contains a notice placed by the copyright holder or other authorized +party saying it may be distributed under the terms of this Library +General Public License (also called "this License"). Each licensee is +addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also compile or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + c) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + d) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the source code distributed need not include anything that is normally +distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Library General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + Appendix: How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. + + <one line to give the library's name and a brief idea of what it does.> + Copyright (C) <year> <name of author> + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with this library; if not, write to the Free + Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random Hacker. + + <signature of Ty Coon>, 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! diff --git a/systems/os2/web2c-6.1/ctan b/systems/os2/web2c-6.1/ctan new file mode 100644 index 0000000000..ba61df8c38 --- /dev/null +++ b/systems/os2/web2c-6.1/ctan @@ -0,0 +1 @@ +The directory prefix for WEB2C/2 should be `systems/os2/web2c-6.1'. diff --git a/systems/os2/web2c-6.1/files b/systems/os2/web2c-6.1/files new file mode 100644 index 0000000000..8e5e0fe48c --- /dev/null +++ b/systems/os2/web2c-6.1/files @@ -0,0 +1,18 @@ +COPYING GNU General Public Licence +COPYING.LIB GNU Library General Public Licence +CTAN informations for CTAN administrators +README useful informations about WEB2C/2 +binary/ binary release of WEB2C/2 +binary/emxrt.zip emx 0.9a runtime environment +binary/kpathsea.zip Kpathsea 1.8 libraries and include files +binary/symlink.zip SYMLINK 1.1 libraries and include files +binary/web2c.zip WEB2C/2 6.1 executables, pool files and manual pages +source/ source code of WEB2C/2 +source/bases.zip files for building METAFONT bases +source/formats.zip files for building TeX formats +source/kpathsea.pl `kpathsearch' for Perl (matches Kpathsea 1.6) +source/kpathsea.zip source code of Kpathsea 1.8 (OS/2 and Linux DLL) +source/makefonts.zip source code of MakeFonts (no longer supported) +source/symlink.zip source code of the SYMLINK Library +source/web.zip WEB 6.1 sources (you can also use `web-6.1.tar.gz') +source/web2c.zip source code of WEB2C/2 with patches applied diff --git a/systems/os2/web2c-6.1/readme b/systems/os2/web2c-6.1/readme new file mode 100644 index 0000000000..6c4989d7c0 --- /dev/null +++ b/systems/os2/web2c-6.1/readme @@ -0,0 +1,204 @@ + ,,,
+ (o o)
+---------------------------oOO-(_)-OOo---------------------------
+This directory contains WEB2C/2, a port of WEB2C to IBM OS/2.
+
+
+Table of contents
+=================
+
+1 Copying conditions
+2 System requirements
+3 User requirements
+4 Additional features
+5 Installation
+6 First tests
+7 Performance improvements
+8 The author
+
+
+1 Copying conditions
+=====================
+
+WEB2C/2 is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 2 of the License, or (at your option)
+any later version.
+
+WEB2C/2 is distributed in the hope that it will be useful, but WITHOUT
+ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
+
+You should have received a copy of the GNU General Public License along
+with this program; if not, write to the Free Software Foundation, Inc.,
+675 Mass Ave, Cambridge, MA 02139, USA.
+
+
+2 System requirements
+======================
+
+The binary release of WEB2C/2 (see the `binary' subdirectory) requires
+OS/2 2.0 or any later version. The release was compiled with emx 0.9a
+under OS/2 2.1 with optimization enabled for an i486 CPU. Thus, you
+have to install the emx runtime environment if you don't have it
+already.
+
+WEB2C/2 contains only the programs for TeX, METAFONT and friends. There
+are no fonts, TeX macros or pre-compiled format and base files. WEB2C/2
+is intended as a drop-in replacement for your current binaries.
+
+Have a look at `tex-archive/systems/web2c/lib-<version>.tar.gz' on CTAN
+if you have no TeX infrastructure on your disk.
+
+
+3 User requirements
+====================
+
+WEB2C/2 is no ready-to-run distribution for the reasons pointed out in
+the previous section. I think that this is the right way. The only
+non-portable files of a TeX system are the executables, the pool, format
+and base files. WEB2C/2 offers you pre-compiled executables, pool files
+and `Makefile' files for building formats and bases. Thus, you have all
+you need for making TeX work.
+
+So, get the packages *you* want to use, read the documentation coming
+along with them, configure and install them, learn for what all these
+files are good for and keep your system up-to-date yourself. Don't wait
+for someone else doing it for you.
+
+You should also read the manual pages before you ask `how'. That's why
+they were written. There is the German phrase `Lesen bildet' which
+means `reading trains' in English -- 'nough said.
+
+
+4 Additional features
+======================
+
+WEB2C/2 is as close to the original as possible (including support for
+symbolic links -- you read right) but there are some enhancements due to
+the differences between UN*X and OS/2:
+
+* Backslashes as well as normal slashes may be used as directory
+ separators in environment variables.
+
+* Environment variables may be referenced as `%FOO%' beside the two
+ UN*X styles `$FOO' and `${FOO}'.
+
+* TeX and BibTeX can load a character translation table at runtime.
+ See `$TEXMFROOT/keymaps/README' for details.
+
+
+5 Installation
+===============
+
+Installing WEB2C/2 on a HPFS-drive is recommended.
+
+Choose a directory prefix and change to that directory. The binary
+release was compiled with `/usr/local' but `/usr' and `/opt' are also
+common choices. All archives unpack their contents relative to the
+current working directory. First, unpack the whole stuff:
+
+ $ mkdir /usr/local
+ $ cd /usr/local
+ $ unzip /foo/binary/web2c.zip
+ $ unzip /foo/binary/kpathsea.zip
+ $ unzip /foo/binary/symlink.zip
+
+Fire up your editor if it is not already running and visit `config.sys'.
+Include the file `/usr/local/lib/TeX+MF/etc/setenv.cmd' and change the
+environment variables matching your setup. Setting `TEXMFROOT' to, for
+example `d:/usr/local/lib/TeX+MF' may do it on some systems. The syntax
+and the meaning of the variables are explained in the documentation for
+the Kpathsearch Library (see the file `.../info/kpathsea.info').
+
+Make sure that `/usr/local/bin' and `/usr/local/dll' are in your `PATH'
+respectively `LIBPATH' -- `/usr/local/lib' should be in your `DPATH'.
+
+Reboot your machine.
+
+Don't forget to rebuild all your format and base files. Note: sharable
+format and base files load slower on little endian machines (especially
+under OS/2, not noticeable under Linux) -- I have disabled it.
+
+
+6 First tests
+==============
+
+If your old binaries are still in your `PATH', ensure that the new ones
+in `/usr/local/bin' will be found first!
+
+Try to build a format file now. Say, e.g.,
+
+ $ texmf formats
+ $ initex "plain \dump"
+
+If that works, try
+
+ $ mv plain.fmt tex.fmt
+ $ ln -s tex.fmt plain.fmt
+ $ cd /usr/local/bin
+ $ ln -t exec virtex.exe tex.exe
+
+Do you know what you have just done? `tex.exe' is a link to `virtex.exe'
+causing `virtex.exe' to pre-load the file `tex.fmt' instead of the default
+`plain.fmt'. The file `plain.fmt' is a link to `tex.fmt' so that you can
+still say `tex "&plain" foo' or `virtex foo'. See the manual page of TeX
+for more details.
+
+Try these commands next:
+
+ $ cd /tmp
+ $ tex null
+ This is TeX, Version 3.1415 (C version 6.1)
+ (d:/usr/local/lib/TeX+MF/tex/plain/null.tex)
+ *\end
+ No pages of output.
+ Transcript written on null.log.
+
+Do you have the same output? Congratulations, TeX is up and running! Now
+do something similar with METAFONT:
+
+ $ texmf bases
+ $ inimf "plain; input modes; dump"
+ $ mv plain.base mf.base
+ $ ln -s mf.base plain.base
+ $ cd /usr/local/bin
+ $ ln -t exec virmf.exe mf.exe
+ $ cd /tmp
+ $ mf smiley
+ This is METAFONT, Version 2.71 (C version 6.1)
+ (d:/usr/local/lib/TeX+MF/mf/local/smiley.mf [0])
+ *end.
+ Output written on smiley.2602gf (1 character, 248 bytes).
+ Transcript written on smiley.log.
+
+Do you see what?
+
+
+7 Performance improvements
+===========================
+
+The programs itself are fast but you can slow down everything if you
+miss-configure the environment variables for Kpathsea. OS/2's file
+systems are slow compared with those of most UN*X Systems. So, avoid
+heavy usage of `//' sequences in the middle of a path specification.
+You should also maintain a `ls-R' database if you have lots of
+subdirectories below `TEXMFROOT'.
+
+
+8 The author
+=============
+
+WEB2C/2 was ported by Ralph Schleicher <rs@purple.in-ulm.de>.
+
+ Voice: +49-7352-51322 (calling time doesn't matter)
+ Data: +49-7352-7425, V32bis, V42bis, FAX
+ UUCP: login `Unknown', send e-mail address as password,
+ request `~/WEB2C' for news about WEB2C/2
+
+I don't use OS/2 any more. I switched entirely to Linux in April 1994
+but I am willing to maintain WEB2C/2 as long as future releases of OS/2
+are compatible with my current installation.
+---------------------------oOo-----oOo---------------------------
+
diff --git a/systems/os2/web2c-6.1/source/kpathsea.pl b/systems/os2/web2c-6.1/source/kpathsea.pl new file mode 100644 index 0000000000..dd5f570911 --- /dev/null +++ b/systems/os2/web2c-6.1/source/kpathsea.pl @@ -0,0 +1,124 @@ +# kpathsea.pl -- search a file as Karl Berry likes to do it. +# +# Copyright (C) 1994 Ralph Schleicher (rs@purple.in-ulm.de) +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Library General Public +# License as published by the Free Software Foundation; either +# version 2 of the License, or (at your option) any later version. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Library General Public License for more details. +# +# You should have received a copy of the GNU Library General Public +# License along with this library; if not, write to the Free +# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +# +# The comments are borrowed from `kpathsea.info'. ;-) + + +package KPathSearch; + +# Is `require' local to a package? I don't know. +# +if (! $find_included) +{ + do 'find.pl' || die "$0:find.pl: $!\n"; + + $find_included = 1; +} + +sub main'kpathsearch +{ + local ($var, $def, $file) = @_; + + local (@path) = split (':', $ENV{$var} || $def, -1); + local (@def) = split (':', $def, -1); + local (@dir) = (); + + local ($[) = 0; + + while (@path) + { + $_ = shift @path; + + # Extra colons expand to the compilation default. + # + unshift (@path, @def), next if $_ eq ''; + + # `~' and `~user' expand to home directories. + # + if (/^~/) + { + local ($slash, $name, $n, $p, $u, $g, $q, $c, $o, $home, $s); + + $slash = index ($_, '/'); + $slash = length if $slash < 0; + + $name = substr ($_, 1, $slash - 1); + if ($name ne '') + { ($n, $p, $u, $g, $q, $c, $o, $home, $s) = getpwnam ($name); } + else + { ($n, $p, $u, $g, $q, $c, $o, $home, $s) = getpwuid ($<); } + + $home = '.' if $home eq ''; + + $_ =~ s/^~$name/$home/; + } + + # `$foo' and `${foo}' expand to environment values. + # + while (/\$(\w*|\{.*\})/) + { + $_ = join ('', $`, $ENV{$1} || '.', $'); + } + + # `a//' and `a//b' recursively expand to sub-directories. + # + if (/\/\//) + { + local ($base, @sub) = split ('//', $_, -1); + local ($term) = pop (@sub); + + undef @directories; + &find ($base); + + foreach $sub (@sub) + { + @directories = grep (m|^$base/(.*/)?$sub|, @directories); + } + @directories = grep (m|$term$|, @directories) if $term ne ''; + + push (@dir, @directories); + } + else + { + push (@dir, $_); + } + } + + # See what we have to return. + # + return @dir if $file eq ''; + + if (wantarray) + { + return grep (-e ($_ = "$_/$file"), @dir); + } + + foreach (@dir) + { + return $_ if -f ($_ = "$_/$file"); + } + + return undef; +} + +sub wanted +{ + push (@directories, $name) if (lstat ($_)) && -d _; +} + +1; diff --git a/systems/os2/wetex/00readme.txt b/systems/os2/wetex/00readme.txt new file mode 100644 index 0000000000..590684599d --- /dev/null +++ b/systems/os2/wetex/00readme.txt @@ -0,0 +1,7 @@ +This package contains files which support running emTeX from the
+Enhanced Editor 6.03 and from Workplace Shell.
+
+Author: Zdenek Wagner
+e-mail: wagner@icpf.cas.cz
+
+See install.txt for more information.
diff --git a/systems/os2/wetex/install.txt b/systems/os2/wetex/install.txt new file mode 100644 index 0000000000..413df21bba --- /dev/null +++ b/systems/os2/wetex/install.txt @@ -0,0 +1,10 @@ +This package contains files which support running emTeX from the
+Enhanced Editor 6.03 and from Workplace Shell. The distribution is in
+`wetex10a.zip' compressed with Info-zip. Use unzip.exe (from
+Info-zip) or pkunzip.exe with `-d' option for unpacking.
+
+Start the installation by unzipping the distribution into the root of
+your emTeX installation. The directory `emtex\book\english' will
+contain the file `zwtexsup.inf'. Double-click to its icon to view the
+complete online documentation and follow the installation steps
+described there.
|