README 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432
  1. Building and installing GNU Texinfo with DJGPP v2.x
  2. ===================================================
  3. This directory holds files required for building Texinfo with DJGPP
  4. tools for MS-DOS and MS-Windows. If you got this file with a binary
  5. distribution, look for the "Installation" section below.
  6. 1. Building Texinfo
  7. ----------------
  8. a. To compile Texinfo, you will need the following tools:
  9. - basic DJGPP development environment: GCC, Binutils and djdev;
  10. - a DJGPP port of GNU Make version 3.78 or later;
  11. - a DJGPP port of Bash 2.04 or later;
  12. - a port of GNU Sed 3.02 or later;
  13. - DJGPP ports of Fileutils, Textutils, Sh-utils, Diffutils,
  14. Gawk and Grep;
  15. - etags (from the Emacs distribution) and mkid (from ID-utils)
  16. if you need the TAGS and ID targets of the Makefile's.
  17. All of the above are available from the DJGPP ftp sites on
  18. SimTel.NET mirrors, in the v2gnu directory.
  19. b. From the root of your DJGPP installation, unzip the source package:
  20. - if you are unpacking the official GNU source distribution:
  21. tar -xvzf texinfo-X.YZ.tar.gz
  22. or
  23. djtar -x texinfo-X.YZ.tar.gz
  24. where X.YZ is the version number. (Users of MS-DOS and
  25. MS-Windows 3.X, which don't support long file names, will need
  26. to rename the archive to something like texi-XYZ.tgz.)
  27. - if you are unpacking a source distribution from a DJGPP ftp
  28. site:
  29. unzip txiXYZs
  30. or
  31. pkunzip -d txiXYZs
  32. If you build Texinfo on Windows 9X, Windows ME, Windows 2000 or
  33. Windows XP, you are advised to use a version of Unzip which
  34. supports long filenames, so that the original long filenames of
  35. the source files will be preserved. Otherwise, the build
  36. procedure will most probably fail.
  37. Do NOT use an unzip program which supports long file names on
  38. Windows NT 4, as DJGPP doesn't support long names there.
  39. The program unzip32.exe, available from the SimTel.NET site,
  40. will deal correctly with long file names on any platform, so it
  41. is the recommended way of unzipping txiXYZs.zip archives.
  42. c. If the source distribution comes with a ready Makefile (this is
  43. usually the case with archives downloaded from the DJGPP sites),
  44. and all you need is to build Texinfo, you may skip the configure
  45. step below and go directly to step e.
  46. d. To build the official GNU distribution, or to configure Texinfo
  47. for any environment but stock DJGPP v2.x, run djgpp\config.bat
  48. first, like this:
  49. SRCDIR\djgpp\config SRCDIR
  50. Here SRCDIR is the directory where you unpacked the sources. If
  51. you are configuring from the source directory itself, you may
  52. omit the argument to the config.bat file. If you do supply the
  53. argument, you MUST use forward slashes in it, or else the batch
  54. file might fail.
  55. config.bat sets some environment variables, then invokes the
  56. configure script. The script will run for a few minutes and
  57. create Makefile's in all the directories, and the config.h file.
  58. e. Run `Make'. This builds the programs and the Info files.
  59. 2. Installation
  60. ------------
  61. a. If you are installing the binary distribution, then go to your
  62. main DJGPP directory and unzip the files. For instance, if your
  63. DJGPP installation is rooted on C:\DJGPP, then type this (XYZ is
  64. the version number):
  65. cd c:\djgpp
  66. unzip txiXYZb
  67. or, if you prefer `pkunzip':
  68. pkunzip -d txiXYZb
  69. b. If you downloaded and built Texinfo from sources, install by
  70. invoking Make:
  71. make install
  72. This requires a port of Unix-like program `install.exe'. It is
  73. available from the DJGPP port of GNU Fileutils on SimTel.NET.
  74. c. Info needs a file named DIR with the top-level menu of all the
  75. Info files installed on your system. If you installed the DJGPP
  76. development environment (djdevNN.zip), then you already have
  77. this file in the info/ subdirectory of your DJGPP installation.
  78. Otherwise, you will need to create it. A minimal DIR file is
  79. available in this distribution under the name `dir-example',
  80. which you can use as a starting point. Copy it to the directory
  81. where you install the Info files from this distribution.
  82. Even if you already have a DIR file, you should review it to
  83. make sure it is consistent with the names of the Info file you
  84. are installing. Here's how your Texinfo-related entries in DIR
  85. should look like:
  86. * Info: (info).
  87. Documentation browsing system. This topic teaches you about
  88. how to use the online help information.
  89. * Info-Standalone: (info-stnd).
  90. This topic helps you use the standalone Info-Program (info.exe)
  91. * infokey: (info-stnd)Invoking infokey.
  92. Compile Info key customizations.
  93. * Makeinfo: (texinfo)Invoking makeinfo.
  94. Convert a .texinfo file (.txi) to an info file suitable for the
  95. info reader or Emacs, into plain ASCII, into HTML, into XML,
  96. or into DocBook.
  97. * Texinfo: (texinfo).
  98. With one source file, make either a printed manual (through TeX)
  99. or an on-line manual (through makeinfo). This topic includes
  100. a full description of the Texinfo language and related
  101. facilities, including Emacs commands to work with Texinfo files.
  102. * install-info: (texinfo)Invoking install-info.
  103. How to update info/dir entries when installing GNU packages.
  104. * texi2dvi: (texinfo)Format with texi2dvi.
  105. Printing Texinfo documentation with TeX.
  106. * texindex: (texinfo)Format with tex/texindex.
  107. Sorting Texinfo index files automatically.
  108. Note that the asterisk `*' should be flushed all the way to the
  109. left, it is indented here just to make reading more convenient.
  110. If your DIR file entries differ from these, I suggest to edit them
  111. so they are as shown above. Otherwise, Info might not be able to
  112. find some of the files. You HAVE been warned!
  113. d. Optionally, set up environment variables for Info. These are:
  114. * INFO_LINES -- screen size for Info.
  115. * INFO_COLORS -- screen colors for Info.
  116. (If you have DJGPP installed on your system, the file djgpp.env
  117. which comes with it already has entries for Info, see the [info]
  118. section there.)
  119. INFO_LINES can be one of 25 (the default), 28, 35, 40, 43, or 50
  120. (that's if you have a VGA; EGAs only support 25, 35 and 43 lines).
  121. I recommend 40 if your monitor is 17" or larger, and at least 28
  122. lines for smaller monitors (I work with 40 lines even on 14"
  123. monitors).
  124. INFO_COLORS should have the following syntax:
  125. set INFO_COLORS=XX.YY
  126. where XX is the text attribute for text displayed in the text
  127. windows and the echo area, and YY is the text attribute for the
  128. modeline (aka the status line). Each attribute is a numeric
  129. value of a byte which describes the desired combination of
  130. foreground and background colors. The individual bits in the
  131. attribute byte are defined as follows:
  132. bBBBFFFF
  133. where `b' is the blink bit, `BBB' are the 3 bits for background
  134. color and `FFFF' are the 4 bits for the foreground color. This is
  135. the usual PC text attribute byte structure, and is further explained
  136. in any standard reference on text-mode programming for the PC.
  137. My favorite setting for INFO_COLORS is `0x1e.0x31'. This makes
  138. Info use yellow foreground on blue background for the text and
  139. blue foreground on cyan background for the modelines.
  140. After you've played with these variables and have chosen the values
  141. you like, it's a good idea to put them on the DJGPP.ENV file, in the
  142. [info] section.
  143. e. Beginning with version 3.6, GNU Info can read Unix man pages. If
  144. you have a `man' clone on your system and would like to be able to
  145. read man pages with Info, read the chapter ``Reading Man Pages''
  146. below. One such clone is available as v2apps/manXYb.zip from
  147. the DJGPP sites (XY is the version number).
  148. f. This port supports compressed Info files, like what Info under Unix
  149. gives you. For this to work, you will need to install a DOS port of
  150. GNU `Gzip' package and to observe certain rules of file naming, so
  151. that Info will find the compressed files working around the DOS 8.3
  152. filename restriction. The chapter ``Compressed Info Files'' below
  153. explains the details of this.
  154. g. If you need to use the `print-node' command, read the chapter
  155. ``Printing Nodes'' below.
  156. h. That's it! You are now ready to use Info, Makeinfo, and Texindex.
  157. To learn about them, type `Info' and press [Enter]. You will be
  158. presented with the top-level menu of GNU/DJGPP hypertext
  159. documentation. If you are unfamiliar with Info, press `?' to see
  160. the available commands. Pressing `h' will cause Info to take you on
  161. a guided tour through its features (recommended for first-time
  162. users).
  163. i. If you are used to Info ports of versions before 3.6, you should
  164. know that the command bindings to PC-specific keys has changed: the
  165. numeric keypad keys invoke the same commands as their extended
  166. namesakes. That is, e.g., the key `PgUp' on the numeric keypad
  167. invokes the same command as the grey `PgUp' key on the extended
  168. keypad. This was done at DJ's request, because laptop machines
  169. don't have extended keys. Commands to move between nodes
  170. (previously bound to numeric keypad) are now bound to Ctrl-
  171. varieties of numeric keypad keys (e.g., `next-node' is on
  172. `Ctrl-PgDn', `prev-node' is on `Ctrl-PgUp', etc.). You can use
  173. the `Alt-x describe-key' command to see which command is invoked
  174. by a particular key.
  175. j. There are several MSDOS-specific changes in Texinfo, relative to
  176. previous Texinfo ports (for other changes, see the file NEWS):
  177. * Full support for both forward and backslashes in all file
  178. names. Previously, Info was sensitive to the style of
  179. slashes in directories mentioned in the INFOPATH environment
  180. variable.
  181. * The default operation of the `print-node' command has been
  182. changed so that it automatically prints to the local printer
  183. device connected to the PRN port. (If your printer is
  184. connected to another port, set the INFO_PRINT_COMMAND
  185. environment variable like this:
  186. set INFO_PRINT_COMMAND=>LPT2
  187. In other words, if the value of INFO_PRINT_COMMAND begins
  188. wih a `>' character, Info will write to the file or device
  189. whose name follows the `>' character. (Don't leave any
  190. blanks between `>' and the device name!).
  191. Note that some old versions of stock DOS shell won't let you
  192. use the `>' character in environment variables set from the
  193. DOS prompt or batch files, but you can set it in the [info]
  194. section of your DJGPP.ENV file.
  195. * The `set-screen-height' command now actually changes the
  196. screen dimensions from within Info if you specify one of the
  197. sizes supported by your video hardware.
  198. * If you don't have a `man' clone installed, and you invoke
  199. Info with a name of a document which Info cannot find, it
  200. will no longer wait for 15 seconds.
  201. * Several bugs in handling of man pages were corrected.
  202. * Info opens the dribble and input files in BINARY mode. This
  203. allows to record keystrokes and restore them in another Info
  204. session, thus using dribble files as a startup or init file
  205. which changes default behavior, binds keys, etc.
  206. * Info recognizes a new DOS-specific command-line option `-b'
  207. or `--speech-friendly'. This option causes Info to use DOS
  208. I/O functions (`printf', `puts', etc.) instead of direct
  209. screen writes, which is required to enable speech
  210. synthesizer software (used by visually-impaired people) to
  211. grab the output. When this option is given, the screen
  212. colors defined by the `INFO_COLORS' environment variable and
  213. the visible-bell feature will be disabled, because stdio
  214. functions don't support neither color text nor inverting
  215. screen colors. This improvement was suggested and
  216. originally implemented by Hans-Bernhard Broeker
  217. <Broeker@physik.rwth-aachen.de>.
  218. * Makeinfo now generates full .info-NN filenames when long
  219. filenames are supported (e.g. on Win9x) and short .iNN
  220. filenames otherwise. When the Texinfo source or the
  221. command-line parameter -o specify an output file with no
  222. extension (like `texinfo'), and long filenames aren't
  223. supported, Makeinfo will make sure the generated names will
  224. be unique (it will create e.g. `texinf-1', `texin-10' etc.).
  225. * The texi2dvi script is now fully compatible with
  226. MS-DOS/MS-Windows and with the DJGPP port of TeX.
  227. 3. Reading Man Pages
  228. -----------------
  229. Yes, Info can now read man pages! This port supports that feature,
  230. but for it to work, you will have to make sure your `man' clone is
  231. set up correctly:
  232. a. You should have an executable file named `man.exe', `man.com'
  233. etc. somewhere on your PATH.
  234. b. When invoked with redirected stdout, that executable should
  235. print the contents of the file it gets as its argument to stdout
  236. and exit. If your man command calls some pager, that pager
  237. should have this behavior (various ports of Unix command `more'
  238. and the DJGPP port of GNU Less behave that way).
  239. One `man' clone is available as v2apps/manNNb.zip from the DJGPP
  240. sites on SimTel.NET.
  241. 4. Compressed Info Files
  242. ---------------------
  243. Info allows you to hold your Info files in compressed form, to save
  244. disk space. When a file Info wants cannot be found, it will
  245. automatically try to find that file in compressed form. Info does
  246. this by trying to find the original file with specific extensions.
  247. Each extension tells Info which program should be called to
  248. decompress the file.
  249. This port supports compression by the GNU Gzip program. When Info
  250. cannot find a file `foo', it will first try to find `foo.z' or
  251. `foo.gz'. If this fails, and the file has an extension, the last
  252. one or two characters of the extension are replaced by `z' and `gz'
  253. respectively, and Info tries again. If it finds any of these, it
  254. will call the `GUnzip' program to decompress the file, catch its
  255. output and display it. (The original compressed file stays
  256. intact.)
  257. So, to use this feature, compress your files with Gzip and call the
  258. compressed files using the following as guidelines:
  259. foo --> foo.gz
  260. foo.inf --> foo.igz
  261. foo.i5 --> foo.i5z
  262. foo.25 --> foo.25z
  263. If you have a package whose Info docs are split into more than 9
  264. sub-files and you need to compress those files, you will have to
  265. rename the sub-files from `foo.iNN' to `foo.NN' so that there will
  266. be place for the trailing `z' in the compressed names. Don't
  267. forget to edit the indirect file table in the main Info file and
  268. change the sub-file filenames there too!
  269. An alternative for those packages which have more than 99 Info
  270. sub-files is to generate them from the Texinfo sources and force
  271. Makeinfo to produce files without the .iNN extensions, like this:
  272. makeinfo -o foo foo.txi
  273. This causes Makeinfo to generate file names like foo-1, foo-2,
  274. etc., which leave more place for the numeric index. If necessary,
  275. Makeinfo will automatically remove characters from the end of the
  276. argument to `-o'. For example, "-o texinfo" produces files
  277. texinf-1, ..., texin-10, ..., texi-100, etc. on platforms which
  278. only support 8+3 file names.
  279. Saying "@setfilename foo" near the beginning of the Texinfo source
  280. file is another way of forcing Makeinfo to produce files without
  281. the .iNN extensions.
  282. Using Makeinfo to produce files whose names are "compression-ready"
  283. is more convenient, since you don't need to edit the the indirect
  284. file table to reflect the changes in file names.
  285. On platforms which support long filenames, the usual Info behavior
  286. of appending `.gz' or `.Z' to the original filename also works;
  287. this is done *before* Info checks the above butchered names.
  288. Special considerations apply if you are installing Info on dual
  289. DOS/Windows 9X/ME/2K/XP system, where you'd like Info to work with
  290. the same files both in plain DOS and from the Windows DOS box. In
  291. this case, you should make sure your compressed Info files follow
  292. the 8+3 DOS naming conventions outlined above, even though Info
  293. supports long file names on Windows 9X. Also, you need to turn off
  294. the generation of numeric tails in short 8+3 aliases Windows
  295. creates for long names (if you don't know how, the DJGPP FAQ list
  296. explains it).
  297. Please note: for the automatic decompression to work, Info must be
  298. able to find the file it looks for with an extension which
  299. indicates that the file is compressed. Do NOT call the compressed
  300. files as the original uncompressed files were called, or Info
  301. won't be able to find them! File names like bison-1, gcc.i10 or
  302. make.info-3 have nothing in them to suggest that they are
  303. compressed, so don't expect Info to uncompress them.
  304. 5. Printing Nodes
  305. --------------
  306. Info has a `print-node' command. It works by piping the contents of
  307. the current node through a program which is named by the environment
  308. variable INFO_PRINT_COMMAND. That command should read its standard
  309. input and write it to your printer. Find any such program, put its
  310. name into the above environment variable, and you can print nodes from
  311. within Info.
  312. If the value of INFO_PRINT_COMMAND begins with a redirection
  313. character `>', Info will write the contents of the node to the file
  314. whose name follows the `>' character.
  315. If INFO_PRINT_COMMAND is not defined, the DJGPP port will use
  316. ">PRN" as the default, which causes it to print to the local printer
  317. device, PRN.
  318. 6. Bug Reports
  319. -----------
  320. If you see any bugs which seem specific to this DOS port, please tell
  321. me about them.
  322. Enjoy,
  323. Eli Zaretskii <eliz@is.elta.co.il>