"SfR Fresh" - the SfR Freeware/Shareware Archive 
Member "Lynx/lynx_doc/INSTALLATION" of archive lynx.zip:
As a special service "SfR Fresh" has tried to format the requested source page into HTML format using source code syntax highlighting with prefixed line numbers.
Alternatively you can here view or download the uninterpreted source code file.
That can be also achieved for any archive member file by clicking within an archive contents listing on the first character of the file(path) respectively on the according byte size field.
1
2 Lynx Installation Guide
3
4 This file describes how to compile and install Lynx. A description of Lynx
5 can be found in the README file. Lynx has been ported to UN*X, VMS, Win32
6 and 386DOS. The procedures for compiling these ports are quite divergent
7 and are detailed respectively in Sections II, III, IV and V. General
8 installation, problem solving and environment variables are covered in
9 Sections VI and VII. There is also a PROBLEMS file in the same directory
10 as INSTALLATION which contains advice for special problems people have
11 encountered, especially for particular machines and operating systems.
12
13 If you still have difficulties, send an e-mail message to the Lynx-Dev mailing
14 list (see the README file). Try to include information about your system,
15 the name and version of your compiler, which curses library you are using
16 and the compile-time errors. Be sure to say what version and image-number
17 of Lynx you are trying to build (alternately the top date of the CHANGES file).
18
19 If you don't understand what one of the defines means, try the README.defines
20 and *.announce files in the docs subdirectory. The docs/CHANGES* files record
21 the entire development history of Lynx and are an invaluable resource for
22 understanding how Lynx should perform.
23
24 First, you must configure Lynx for your system regardless of the port you use.
25 Follow the instructions given immediately below to configure for your system,
26 and then go to the respective section concerning the port you wish to compile.
27
28 I. General configuration instructions (all ports).
29
30 Step 1. Compile-time Variables.
31
32 There are a few variables that MUST be defined if Lynx is to build
33 and there are others you may want to change.
34
35 Lynx MUST be able to find lynx.cfg at start-up: using configure
36 (e.g. with UNIX or Cygwin), its location is best set with --sysconfdir ;
37 you can check in lynx_cfg.h after configure has run, if you wish.
38 otherwise, you can use LYNX_CFG_FILE in userdefs.h ,
39 environment variable LYNX_CFG or the -cfg command-line option.
40
41 If you are using configure, you need not make any changes in userdefs.h .
42 There are a few variables you can't define with configure --options
43 but can define in userdefs.h , e.g. numbering fields as well as links.
44 Many variables which can be defined with configure or userdefs.h
45 can also be defined in lynx.cfg or via the Options Menu.
46
47 Lynx implements Native Language Support. Read "ABOUT-NLS", if you want
48 to build an international version of Lynx or tailor status-line prompts,
49 messages and warnings to the requirements of your site.
50
51 Step 2. Run-time Variables.
52
53 Read lynx.cfg thoroughly, as many Lynx features and how to use them
54 are explained there, in some cases ONLY there. Set up local printers,
55 downloaders, assumed character set, key mapping and colors in lynx.cfg .
56 Also see the sample mime.types, mailcap and jumps files
57 in the samples subdirectory.
58
59 Step 3. Alternative Character Sets.
60
61 You may skip this, if you are not interested in special characters
62 and all local files or WWW pages you will view will use the ISO-8859-1
63 "ISO Latin 1" Western European character set.
64
65 If you will be running Lynx in an environment with different incompatible
66 character sets, configure CHARACTER_SET (the Display character set)
67 and ASSUME_LOCAL_CHARSET to work correctly before creating bookmark files
68 and other such items: read lynx.cfg for detailed instructions.
69 Additional character sets and their properties may be defined with tables
70 in the src/chrtrans directory: see the README.* files therein.
71
72 Step 4. News.
73
74 Set NNTPSERVER in lynx.cfg to your site's NNTP server
75 or set the environment variable externally. For posting to be enabled,
76 NEWS_POSTING must be TRUE in userdefs.h or lynx.cfg.
77 Also define LYNX_SIG_FILE in userdefs.h or lynx.cfg ,
78 so that it points to users' signature files for appending to messages.
79
80 Step 5. Anonymous Accounts *** VERY IMPORTANT!!!!! ***
81
82 If you are building Lynx for personal use only, you can skip this.
83
84 If you are setting up anonymous accounts to use Lynx captively,
85 i.e. making Web access publicly available to users who should not
86 be allowed any other type of access to your system,
87 you are STRONGLY advised to use the -anonymous command-line option:
88 if you do not use this option, users may be able to gain access
89 to all readable files on your machine!
90
91 Many implementations of telnetd allow passing of environment variables,
92 which might be used to modify the environment in anonymous accounts,
93 allowing mischief or damage by malicious users, so make sure the wrapper
94 uses the -cfg and -homepage switches to specify lynx.cfg and start-file,
95 rather than relying on variables LYNX_CFG, LYNX_CFG_FILE and WWW_HOME.
96
97 II. Compile instructions -- UNIX
98
99 1a. Auto-configure. The auto-configure script uses autoconf2.13 to generate a
100 Bourne shell script, configure, which creates "makefile" and "lynx_cfg.h".
101
102 If you are on a UNIX platform, the easiest way to build Lynx is to type:
103
104 ./configure
105 and
106 make
107
108 NOTE: Configure has a number of useful options. Please see below.
109
110 NOTE: The 'configure' script generates auxiliary files "config.status"
111 "config.cache" and "config.log". Normally you will not notice these;
112 they are created automatically and removed by a "make distclean".
113
114 + If you wish to rebuild Lynx with a new host, or change ANY of the
115 parameters which are stored in config.cache, you MUST first remove
116 the config.cache file before running configure; its options do NOT
117 override the settings in that file.
118
119 + The config.status file is a script which creates (or regenerates)
120 the files created by the configure script.
121
122 Please report problems in the configure/make process by including a copy
123 of config.status, config.cache and config.log, as well as the pertinent
124 compiler diagnostics.
125
126 See the note in aclocal.m4 for special instructions if you must modify the
127 configure script.
128
129 NOTE: Lynx is a curses-based application, so you must have a curses
130 library available to link to. Native curses (on the system when it was
131 installed) are often broken, so you may get superior performance if you
132 have either "ncurses" ("ftp://invisible-island.net/ncurses") or "slang"
133 ("ftp://space.mit.edu/pub/davis/slang"). If you install these libraries
134 in your home directory or a non-default location, you may need to set the
135 CPPFLAGS (full path to include files) and LIBS (full path to library files)
136 environment variables BEFORE running configure. See "1d. Environment".
137 Use the "--with-screen=ncurses" or "--with-screen=slang" option.
138
139 Note that while lynx will build with a variety of versions of curses and
140 ncurses, some will be less satisfactory. Versions of ncurses before 1.9.9g
141 will not render color properly. Some other versions of curses do not
142 display color at all. Likewise, lynx may not build with old versions of
143 slang, e.g., before 0.99-38, because slang's interfaces change periodically.
144
145 Note compiler/system specific problems below. See also:
146 http://invisible-island.net/ncurses/ncurses.faq.html
147
148 1b. Platforms. Configure should work properly on any Unix-style system.
149 It has been tested on the following platforms.
150
151 AIX 3.2.5 (cc w/ curses) BeOS 4.5 (gcc w/ ncurses)
152 CLIX (cc w/ curses & ncurses) DGUX
153 Digital Unix 3.2C and 4.0 (gcc & cc w/ curses, ncurses & slang)
154 FreeBSD 2.1.5, 3.1 (gcc 2.6.3 w/ curses & ncurses)
155 HP-UX (K&R and ANSI cc, gcc w/ curses, ncurses & slang)
156 IRIX 5.2 and 6.2 (cc & gcc w/ curses, ncurses & slang)
157 Linux 2.0.0 (gcc 2.7.2 w/ curses, ncurses & slang)
158 MkLinux 2.1.5 (gcc 2.7.2.1) NetBSD
159 NEXTSTEP 3.3 (gcc 2.7.2.3 w/ curses)
160 OS/2 EMX 0.9c (ncurses) SCO OpenServer (cc w/ curses)
161 Solaris 2.5, 2.6 & 2.7 (cc & gcc w/ curses, ncurses & slang)
162 SunOS 4.1 (cc w/ curses, gcc w/ ncurses & slang)
163 OS390 and BS2000.
164
165 NOTE: SunOS and HP-UX come with a bundled K&R compiler, which is only
166 useful for compiling with the bundled curses. Both ncurses and slang
167 require a compiler that recognizes prototypes.
168
169 1c. Options
170 To get a list of the configure script's options, type "./configure --help".
171 Below is an alphabetical listing of the Lynx-specific options. The actual
172 order shown by the -help option is different. See "docs/README.defines"
173 for information on defines for which there are no option switches.
174
175 --datadir
176 Defines the location where you want the documentation files installed.
177 The configure script constructs makefile actions to install lynx.cfg
178 modified to reflect this in the HELPFILE setting. (For platforms which
179 do not support a configure script, such as MS-DOS, Win32 and VMS, you
180 must edit lynx.cfg).
181
182 --disable-alt-bindings (prevent defining EXP_ALT_BINDINGS)
183 Compiles-in an alternative set of line-edit bindings, in addition
184 to the default bindings.
185
186 --disable-bibp-urls (define DISABLE_BIBP)
187 Disable (do not compile code) support for bibp: URLs.
188
189 --disable-color-style (define USE_COLOR_STYLE)
190 Use this option to disable optional color style. This is implemented
191 for modern curses implementations, e.g., those that support color.
192
193 Before lynx 2.8.6dev.18, this option was disabled by default.
194 You can achieve a similar color effect to match the non-color-style
195 (but still allowing users to use color-style) by using the
196 --without-lss-file option.
197
198 --disable-config-info (define NO_CONFIG_INFO)
199 Use this option to disable extended browsable configuration information
200 (a screen that shows the result of the configuration script, as well
201 as extended lynx.cfg viewing with a pointer to the lynx.cfg file and
202 additional functionality).
203
204 --disable-dired (prevent defining DIRED_SUPPORT)
205 Use this option to disable the optional directory-editor.
206
207 Lynx supports directory editing (DirEd) for local directories.
208 This allows users to do things like view, copy and remove files
209 using a tabular display of the directory and single-keystroke
210 commands instead of using the command line. From inside Lynx, the
211 keystroke sequence "g.<enter>" switches Lynx to DirEd mode on the
212 current directory. If you're building a Lynx that is to be used as
213 a kind of restricted shell for users who do not have access to the
214 command line and should not have access to equivalent capabilities,
215 you probably want to disable DirEd with this option. You can also
216 disable some DirEd functions while allowing others. If you have
217 disabled DirEd completely, you can ignore all the more specific
218 DirEd options.
219
220 All DirEd menu functions that were enabled on compilation can be
221 disabled or modified at run time via DIRED_MENU symbols in lynx.cfg.
222
223 --disable-dired-dearchive (define ARCHIVE_ONLY)
224 Use this option to prevent DirEd from extracting files from an
225 archive file.
226
227 --disable-dired-gzip (prevent defining OK_GZIP)
228 Use this option to prevent DirEd from using gzip and gunzip.
229
230 --disable-dired-override (prevent defining OK_OVERRIDE)
231 Normally, in DirEd directory viewing mode some key mappings are
232 overridden. Use this option to disable DirEd keymap overriding.
233
234 --disable-dired-permit (prevent defining OK_PERMIT)
235 Use this option to prevent DirEd from changing the permissions
236 on directories or files (i.e., from doing what the Unix chmod
237 command or the DOS attrib command does).
238
239 --disable-dired-tar (prevent defining OK_TAR)
240 Use this option to prevent DirEd from using the tar program.
241
242 --disable-dired-uudecode (prevent defining OK_UUDECODE)
243 Use this option to prevent DirEd from using uudecode.
244
245 --disable-dired-xpermit (define NO_CHANGE_EXECUTE_PERMS)
246 Use this option if you do not disable out the dired-permit
247 option, but want to restrict changes of the eXecute permission
248 to directories (i.e., not allow it to be changed for files). If
249 you don't do this, you can still block changes of the eXecute
250 permission for files but not directories via the
251 "change_exec_perms" command line restriction.
252
253 --disable-dired-zip (prevent defining OK_ZIP)
254 Use this option to prevent DirEd from using zip and unzip.
255
256 --disable-echo
257 Use this option to suppress the "compiling" commands during a build.
258 Doing this makes it easier to find and read warning messages.
259
260 --disable-extended-dtd (define NO_EXTENDED_HTMLDTD)
261 disable extended HTML DTD logic. This should revert to old-style
262 (2.7.1/2.7.2) behavior, but is not well-tested.
263
264 --disable-file-upload (define USE_FILE_UPLOAD)
265 Compile-in support for form-based file-upload.
266
267 --disable-finger (define DISABLE_FINGER)
268 Do not compile-in code used to connect to "finger" URLs.
269
270 --disable-forms-options (define NO_OPTION_FORMS)
271 Disable the Form-based Options Menu (see --disable-menu-options).
272 The default is to compile key-based & form-based Options Menu code,
273 allowing users the final choice via FORMS_OPTIONS in lynx.cfg
274 or the -forms_options command-line switch.
275
276 --disable-ftp (define DISABLE_FTP)
277 Do not compile-in code used to connect to FTP servers.
278
279 --disable-full-paths
280 Use this option to control whether full pathnames are compiled in for
281 various utilities invoked by lynx as external commands. By default,
282 full pathnames are compiled in for the the locations where configure
283 finds these commands at configure time. Affected commands are chmod,
284 compress, cp, gzip, install, mkdir, mv, rm, tar, touch, gunzip, unzip,
285 bzip2, uudecode, zcat, zip, telnet, tn3270, rlogin. (Not all of them
286 are used on all systems or in all configurations.)
287
288 This option makes Lynx simpler to install, but potentially less secure,
289 since the commands are then set in the user's $PATH. All of these
290 commands may also be overridden individually by setting environment
291 variables before configuring. For example, you can disable the telnet
292 command by doing this:
293
294 setenv TELNET /bin/false
295
296 --disable-gopher (define DISABLE_GOPHER)
297 Do not compile-in code used to connect to GOPHER servers.
298
299 --disable-included-msgs
300 Do not use included messages, for i18n support. If NLS support is
301 requested, the configure script will otherwise use the messages in the
302 ./po subdirectory.
303
304 --disable-justify-elts (define EXP_JUSTIFY_ELTS)
305 Do not use element-justification logic.
306
307 --disable-largefiles (prevent defining LONG_LIST)
308
309 Use this option to disable the compiler and linker options that
310 provide largefile interfaces.
311
312 --disable-long-list (prevent defining LONG_LIST)
313 Use this option to disable long "ls -l" directory listings (when
314 enabled, the actual directory style is configurable from lynx.cfg).
315
316 --disable-menu-options (define NO_OPTION_MENU)
317 Disable the Key-based Options Menu.
318 See --disable-forms-options (above) for further details.
319
320 --disable-news (define DISABLE_NEWS)
321 Do not compile-in code used to connect to NNTP (netnews) servers.
322
323 --disable-parent-dir-refs (define NO_PARENT_DIR_REFERENCE)
324 Use this option to disable "Up-to" parent-links in directory listings.
325
326 --disable-partial (prevent defining DISP_PARTIAL)
327 Turn off code that lets Lynx display parts of a long page while loading
328 it.
329
330 --disable-persistent-cookies (prevent defining USE_PERSISTENT_COOKIES)
331 Use this option to tell configure whether to compile-in support for
332 saving cookies to a file, for subsequent reuse. Persistent cookie
333 support will use (or create) the file specified by the 'COOKIE_FILE'
334 option, or default to ".lynx_cookies" in the home directory.
335 (Currently there is no protection against conflict if several lynx
336 sessions are active from the same account).
337
338 --disable-prettysrc (define USE_PRETTYSRC)
339 Use this option to compile-in support for colorizing the source view of
340 HTML pages. If compiled-in, new source view mode is available with
341 -prettysrc command line option.
342
343 --disable-read-eta (define USE_READPROGRESS)
344 Enhance the read-progress message to show ETA (estimated time to
345 completion), as well as the amount of time stalled without any data
346 transferred.
347
348 --disable-source-cache (define USE_SOURCE_CACHE)
349 Use this option to compile-in support for caching HTML pages locally,
350 in files or in memory. Configurable from lynx.cfg
351
352 --disable-trace (define NO_LYNX_TRACE)
353 Turn off code that lets you trace internal details of Lynx's operation.
354 We recommend that you leave this enabled, since we need this
355 information to diagnose problems with either Lynx or the sites to which
356 you connect.
357
358 --enable-addrlist-page (define EXP_ADDRLIST_PAGE)
359 Compiles-in an alternative list-page, bound to 'A' rather than 'l',
360 which always lists URLs rather than titles.
361
362 --enable-cgi-links (define LYNXCGI_LINKS)
363 Allows lynx to access a cgi script directly without the need for
364 a http daemon.
365
366 --enable-change-exec (define ENABLE_OPTS_CHANGE_EXEC)
367 Allow users to change the execution status within the options screen.
368 See EXEC_LINKS and EXEC_SCRIPTS.
369
370 --enable-charset-choice (define EXP_CHARSET_CHOICE)
371 Add logic for ASSUMED_DOC_CHARSET_CHOICE and DISPLAY_CHARSET_CHOICE in
372 lynx.cfg, allowing user to configure a subset of the compiled-in
373 charsets for normal use.
374
375 --enable-cjk (define CJK_EX)
376 Add experimental logic for supporting CJK documents. (This is not
377 necessary for CJK support and may go away in a future release.)
378
379 --enable-debug (The symbol DEBUG is always defined.)
380 Use this option to compile-in support for debugging.
381 Note that this flag is ignored if the CFLAGS environment
382 variable is set, in that case "-g" (or whatever) has to
383 be included in the CFLAGS value to get debugging.
384 Autoconf normally adds -g and -O options to CFLAGS if CFLAGS
385 was not set, and if the compiler supports those options.
386
387 --enable-default-colors (define USE_DEFAULT_COLORS)
388 Enable use of default-color background (ncurses/slang). Either
389 configuration supports the use of 'default' for colors even without
390 this option. That is, 'default' is interpreted as white (foreground)
391 or black (background) according to the context. When the default
392 colors configuration is built, the actual values for foreground and
393 background colors are determined by the terminal.
394
395 --enable-exec-links (define EXEC_LINKS)
396 Allows lynx to execute programs by accessing a link.
397
398 --enable-exec-scripts (define EXEC_SCRIPTS)
399 Allows lynx to execute programs inferred from a link.
400
401 --enable-externs (define USE_EXTERNALS)
402 Use this option to enable external application support. (See lynx.cfg.)
403
404 --enable-find-leaks (define LY_FIND_LEAKS)
405 Use this option to compile-in logic for testing memory leaks.
406
407 --enable-font-switch (define EXP_CHARTRANS_AUTOSWITCH)
408 Allow Lynx to automatically change the Linux console state (switch
409 fonts) according to the current Display Character Set. (Linux console
410 only. *Use with discretion.* See docs/README.chartrans.)
411
412 --enable-gzip-help
413 Install the lynx help files in gzip'd format [*.gz] to save space.
414
415 --enable-htmlized-cfg
416 generate an HTMLized copy of lynx.cfg which will be installed with
417 the other help files.
418
419 --enable-internal-links (prevent defining DONT_TRACK_INTERNAL_LINKS)
420 With `internal links' (links within a document to a location within
421 the same document) enabled, Lynx will distinguish between, for example,
422 `<A HREF="foo#frag">' and `<A HREF="#frag">' within a document whose
423 URL is `foo'. It may handle such links differently, although practical
424 differences would appear only if the document containing them resulted
425 from a POST request or had a no-cache flag set. This feature attempts
426 to interpret URL-references as suggested by RFC 2396, and to prevent
427 mistaken resubmissions of form content with the POST method. An
428 alternate opinion asserts that the feature could actually result in
429 inappropriate resubmission of form content.
430
431 --enable-ipv6 (define ENABLE_IPV6)
432 use experimental IPV6 (with IPV4) logic.
433
434 --enable-japanese-utf8 (define EXP_JAPANESEUTF8_SUPPORT)
435 use experimental Japanese UTF-8 logic.
436
437 --enable-kbd-layout (define EXP_KEYBOARD_LAYOUT)
438 Disabled by default, this option allows you to use translation
439 tables on the input keystrokes. Current tables include
440 ROT13'd keyboard layout
441 JCUKEN Cyrillic, for AT 101-key kbd
442 YAWERTY Cyrillic, for DEC LK201 kbd
443
444 --enable-libjs (define EXP_LIBJS)
445 Disabled by default; used for ifdef'ing JavaScript interface.
446 Currently dummy: no JavaScript support implemented in Lynx yet.
447
448 --enable-locale-charset (define EXP_LOCALE_CHARSET)
449 Use nl_langinfo(CODESET) to determine initial value for display
450 charset, overrides character_set value in .lynxrc file.
451
452 --enable-nested-tables
453 Extends TRST to format nested tables, as well as be smarter about
454 <BR> and <P> tags in table cells.
455
456 --enable-nls (several definitions)
457 use Native Language Support (i.e., gettext).
458
459 --enable-nsl-fork (define NSL_FORK)
460 Disabled by default, this allows interruption of NSL requests,
461 so that `z' will stop the `look-up' phase of a connection.
462
463 --enable-scrollbar (define USE_SCROLLBAR)
464 Compile-in experimental support for scrollbar on the right-margin of
465 the screen. If you configure with ncurses, this works with the mouse
466 on xterm, etc.
467
468 --enable-syslog (define SYSLOG_REQUESTED_URLS)
469 Use this option to log NSL requests via syslog().
470
471 --enable-underlines (define UNDERLINE_LINKS)
472 Use this option to underline links rather than using boldface.
473
474 --enable-vertrace (define LY_TRACELINE)
475 Turn on code that prefixes trace output lines with source filename
476 and line number.
477
478 --enable-warnings
479 Use this option to turn on GCC compiler warnings.
480
481 --enable-widec
482 Use this option to allow the configure script to look for wide-curses
483 features. If you do not specify the option, the configure script
484 will look for these features if --with-screen=ncursesw is given.
485 For this release of Lynx, we recommend the ncursew library built from
486 ncurses 5.5.
487
488 --sysconfdir (affect LYNX_CFG_FILE)
489 Defines the location where you want the lynx.cfg file installed.
490 The configure script defines the symbol LYNX_CFG_FILE to correspond
491 with the $sysconfdir environment variable. (For platforms which do not
492 support a configure script, such as MS-DOS, Win32 and VMS, you must
493 edit userdefs.h if you wish to specify the location of lynx.cfg).
494
495 --with-Xaw3d
496 This option allows you to specify the X libraries used if you
497 are configuring lynx to use PDCurses on a Unix platform.
498
499 --with-XawPlus
500 This option allows you to specify the X libraries used if you
501 are configuring lynx to use PDCurses on a Unix platform.
502
503 --with-charsets=list (define ALL_CHARSETS)
504 Limit the number of charsets that are compiled-in to the specified
505 list of comma-separated MIME names.
506
507 --with-cfg-file (define LYNX_CFG_FILE)
508 Specify the default configuration file's name. Use --without-cfg-file
509 to force the user to specify the configuration file on the command
510 line.
511
512 --with-curses-dir
513 Specify directory under which curses/ncurses is installed. This
514 assumes a standard install, e.g., with an include and lib subdirectory.
515
516 --with-dbmalloc
517 use Conor Cahill's dbmalloc library
518
519 --with-dmalloc
520 use Gray Watson's dmalloc library
521
522 --with-gnutls[=XXX] (define USE_SSL)
523 Use this option to configure with the GNU TLS library.
524 See docs/README.ssl for additional information.
525
526 The optional value XXX specifies the directory in which the library
527 can be found, and may be either the path of the "lib" directory,
528 or one level above. In either case, the corresponding header files
529 are assumed to be in the parallel "include" directory. The default
530 is /usr/local/gnutls.
531
532 --with-included-gettext
533 not supported in this package. The configure script uses macros which
534 are bundled together with more useful features.
535
536 See the "--enable-nls" option.
537
538 --with-libiconv-prefix=DIR
539 search for libiconv in DIR/include and DIR/lib
540
541 --with-lss-file{=path} (define LYNX_LSS_FILE)
542 Specify the default style-sheet file's name. Use --without-lss-file
543 to make the default behavior match the non-color-style (if no --lss
544 option is given, and no COLOR_STYLE setting is in lynx.cfg).
545
546 --with-neXtaw
547 This option allows you to specify the X libraries used if you
548 are configuring lynx to use PDCurses on a Unix platform.
549
550 --with-nls-datadir=DIR
551 Use this option to override the configure script's NLS data directory,
552 under which the locale (i.e., language) files are installed. The
553 default value is derived at configure time, and depends on whether GNU
554 or native gettext is used.
555
556 --with-screen=XXX
557 Use this option to select the screen type. The option value, XXX
558 must be one of curses (the default), ncurses, ncursesw, pdcurses or
559 slang. Specifying a screen type causes the configure script to
560 look in standard locations for the associated header and library
561 files, unless you have preset the $CFLAGS and $LIBS variables.
562
563 --with-screen=ncursesw (define NCURSES, WIDEC_CURSES)
564 --with-screen=ncurses (define NCURSES)
565 --with-screen=pdcurses (define PDCURSES)
566 --with-screen=slang (define USE_SLANG)
567
568 Note that some systems may have a default curses library which
569 does not support color, while on others, ncurses is installed as
570 the curses library. The variant ncursesw is the wide-character
571 version of ncurses. See also the --enable-widec option.
572
573 The pdcurses selection supported by the configure script is a UNIX-only
574 library which uses X11. If you are configuring with DJGPP, the likely
575 choice is "curses", since that is how PDCurses is normally installed.
576
577 --with-socks[=XXX] (define SOCKS)
578 Use this option to configure with the socks library.
579
580 The optional value XXX specifies the directory in which the library
581 can be found, and may be either the path of the "lib" directory,
582 or one level above. In either case, the corresponding header files
583 are assumed to be in the parallel "include" directory.
584
585 --with-socks5[=XXX] (define USE_SOCKS5, SOCKS)
586 Use this option to configure with the socks5 library.
587
588 The optional value XXX specifies the directory in which the library
589 can be found, and may be either the path of the "lib" directory,
590 or one level above. In either case, the corresponding header files
591 are assumed to be in the parallel "include" directory.
592
593 If you make a SOCKSified lynx, you may have trouble accessing FTP
594 servers. Also, instead of SOCKSifying lynx for use behind a firewall,
595 you are better off if you make it normally, and set it up to use a
596 proxy server. You can SOCKSify the proxy server, and it will handle
597 all clients, not just Lynx. If your SOCKS server was compiled to use
598 the short version of Rbind, also include -DSHORTENED_RBIND in your
599 SITE_LYDEFS and SITE_DEFS. If you do SOCKSify lynx, you can turn off
600 SOCKS proxy usage via a -nosocks command line switch.
601
602 --with-ssl[=XXX] (define USE_SSL)
603 Use this option to configure with the OpenSSL library, or SSLeay.
604 See docs/README.ssl for additional information.
605
606 The optional value XXX specifies the directory in which the library
607 can be found, and may be either the path of the "lib" directory,
608 or one level above. In either case, the corresponding header files
609 are assumed to be in the parallel "include" directory.
610
611 --with-build-cc=XXX
612 If cross-compiling, specify a host C compiler, which is needed to
613 compile a utility which generates tables for lynx.
614 If you do not give this option, the configure script checks if the
615 $BUILD_CC variable is set, and otherwise defaults to gcc or cc.
616
617 --with-build-cpp=XXX
618 This is unused by lynx.
619
620 --with-build-cflags=XXX
621 If cross-compiling, specify the host C compiler-flags. You might need
622 to do this if the target compiler has unusual flags which confuse the
623 host compiler.
624
625 --with-build-cppflags=XXX
626 If cross-compiling, specify the host C preprocessor-flags. You might
627 need to do this if the target compiler has unusual flags which confuse
628 the host compiler.
629
630 --with-build-ldflags=XXX
631 If cross-compiling, specify the host linker-flags. You might need to
632 do this if the target linker has unusual flags which confuse the host
633 compiler.
634
635 --with-build-libs=XXX
636 If cross-compiling, the host libraries. You might need to do this if
637 the target environment requires unusual libraries.
638
639 --with-bzlib (define USE_BZLIB)
640 Use libbz2 for decompression of some bzip2 files.
641
642 --with-zlib (define USE_ZLIB)
643 Use zlib for decompression of some gzip files.
644
645 1d. Environment variables
646 The configure script looks for programs and libraries in known/standard
647 locations. You can override the behavior of the script by presetting
648 environment variables. If they are set, the script will try to use these
649 values rather than computing new ones. Useful variables include:
650
651 CC - the C compiler. If you do not override this, configure
652 will try to use gcc. For instance, setting CC=cc and
653 exporting this value will cause configure to use cc instead.
654
655 CFLAGS - the C compiler options. These also include C
656 preprocessor options (such as -I), since the $CFLAGS and
657 $CPPFLAGS variables are maintained separately.
658
659 CPPFLAGS - the C preprocessor options. For some configuration
660 tests, you may need to set both $CFLAGS and $CPPFLAGS if
661 you are compiling against header files in nonstandard
662 locations.
663
664 LDFLAGS - linker/loader options.
665
666 LIBS - the libraries to be linked, with -L and -l options. If
667 you are linking against libraries in nonstandard locations
668 unrelated to the install prefix (that you can specify in
669 the configure script) you may have to specify these via
670 the $LIBS variable.
671
672 Lynx has compiled-in the pathnames of various programs which it executes.
673 Normally the full pathnames are given, rather than the program name
674 alone. These may be preset in the environment by the capitalized version,
675 e.g., INSTALL for "install". The corresponding internal definitions
676 are suffixed "_PATH", e.g., "INSTALL_PATH".
677
678
679 -- 1997/7/27 - T. Dickey <dickey@clark.net>
680
681 1e. Examples
682 If you are compiling Lynx for your personal use and are restricted to your
683 home directory, a simple method for building would be to choose some
684 directory, say ".lynx", and then type:
685
686 ./configure --prefix=~/.lynx --exec-prefix=~/.lynx
687 and
688 make install
689
690 Now you only need to add "~/.lynx/bin" to your PATH and edit "~/.lynx/lib/
691 lynx.cfg" as described above.
692
693 I personally use the following csh shell script to set environment
694 variables and configure options rather than type them each time.
695 #!/bin/csh -f
696 setenv CPPFLAGS "-I$HOME/slang -I$HOME/.usr/include"
697 setenv LIBS "-L$HOME/.slang/lib -L$HOME/.usr/lib"
698 ./configure --exec-prefix=$HOME --bindir=$HOME/.lynx \
699 --mandir=$HOME/.usr/man --sysconfdir=$HOME/.usr/lib \
700 --with-screen=slang --with-zlib
701
702 CPPFLAGS in this example defines the full path to the slang and zlib header
703 files, which are not kept in standard directories. Likewise, LIBS defines
704 the nonstandard locations of libslang.a and libz.a. Setting the option
705 --bindir tells the configure script where I want to install the lynx
706 binary; setting --mandir tells it where to put the lynx.1 man page, and
707 setting --sysconfdir tells it (while at the same time defining LYNX_CFG_FILE)
708 where to put the configuration file "lynx.cfg", when I type "make install".
709 The --with-screen=slang and --with-zlib options are explained above.
710
711 2. Wais support (optional)
712 To add direct WAIS support, get the freeWAIS distribution from
713 "ftp://ftp.cnidr.org/pub/NIDR.tools/freewais", and compile it. The compile
714 process will create the libraries you will need, wais.a and client.a. Edit
715 the Makefile in the top level directory and add the library locations under
716 the DIRECT WAIS ACCESS heading. Edit the Makefile for the WWW Library in
717 "WWW/Library/Implementation/makefile" to point to the include
718 directory for the freewais distribution. Precompiled libraries are
719 available for many platforms if you don't wish to compile one yourself.
720
721
722 III. Compile instructions -- VMS
723
724 Step 1. Downloading binary files.
725 Lynx must handle all IO as streams, and on VMS, output files are always
726 created with Stream_LF format via the C RTL's fopen(). The file headers
727 indicate Implied Carriage Control, even when the transfer was in binary
728 mode, which can confuse downloading software and cause corruption of
729 the file contents. To deal with this, you should define the symbol
730 USE_FIXED_RECORDS as TRUE in userdefs.h and/or lynx.cfg. This will
731 instruct Lynx to correct the header information to indicate FIXED 512
732 records, with No Implied Carriage Control. If Lynx fails to do the
733 conversion (because the file wasn't mapped to a binary MIME type) you can
734 execute FIXED512.COM externally to correct the header information. The
735 command file uses Joe Meadow's FILE utility, or the SET FILE/ATTRIBUTES
736 command on current versions of VMS, to modify the headers. See the
737 comments in FIXED512.COM, userdefs.h and lynx.cfg for more information.
738
739 Step 2. Passive FTP
740 If your system requires the PASV FTP code instead of the standard PORT FTP
741 code (e.g., to deal with a firewall) then set the FTP_PASSIVE option in
742 lynx.cfg
743
744 Step 3a.
745 Lynx uses the VMS port of gzip for uncompressing streams which have
746 Content-Encoding headers indicated compression with gzip or the
747 Unix compress. If you do not have gzip installed on your system
748 you can get it from "ftp://ftp.wku.edu/" in the fileserv directory.
749 The command Lynx uses to uncompress on VMS is "gzip -d".
750
751 If you are using the SOCKETSHR library, read SOCKETSHR.announce and
752 make sure you have defined SOCKETSHR and SOCKETSHR_LIBRARY as explained
753 therein.
754
755 A "build.com" and "build-slang.com" script for building Lynx with curses
756 or slang is in the top level directory. All you have to do is type
757 "@build" or "@build-slang" and answer its prompt for your system's TCP-IP
758 software. Current choices are:
759 MULTINET (default)
760 UCX
761 WIN_TCP
762 CMU_TCP
763 SOCKETSHR_TCP
764 TCPWARE
765 It will autosense whether you have VAXC, DECC or GNUC on VAX or AXP and
766 build appropriately. If a WWWLib already exists for that TCP-IP software,
767 it will prompt you for whether you want to rebuild it. If you want to
768 build a WWWLib separately, you can type "@libmake.com" with your default
769 directory set to [.WWW.Library.vms] instead doing it via "build.com" in
770 the top directory. You may need to modify "build-slang.com", as described
771 in its header, so that it can find slang.olb on your system. If you have
772 both DECC and VAXC, it will use DECC to benefit from the newer and more
773 efficient memory management functions.
774
775 Step 3b. (optional compilation method)
776 If you have and want to use MMS, read the header of descrip.mms in the
777 top directory and be sure you include the appropriate macro definitions
778 when you invoke it:
779
780 $ MMS /Macro = (MULTINET=1) for VAXC - MultiNet
781 $ MMS /Macro = (WIN_TCP=1) for VAXC - Wollongong TCP/IP
782 $ MMS /Macro = (UCX=1) for VAXC - UCX
783 $ MMS /Macro = (CMU_TCP=1) for VAXC - OpenCMU TCP/IP
784 $ MMS /Macro = (SOCKETSHR_TCP=1) for VAXC - SOCKETSHR/NETLIB
785 $ MMS /Macro = (TCPWARE=1) for VAXC - TCPWare TCP/IP
786
787 $ MMS /Macro = (MULTINET=1, DEC_C=1) for DECC - MultiNet
788 $ MMS /Macro = (WIN_TCP=1, DEC_C=1) for DECC - Wollongong TCP/IP
789 $ MMS /Macro = (UCX=1, DEC_C=1) for DECC - UCX
790 $ MMS /Macro = (CMU_TCP=1, DEC_C=1) for DECC - OpenCMU TCP/IP
791 $ MMS /Macro = (SOCKETSHR_TCP=1,DEC_C=1) for DECC - SOCKETSHR/NETLIB
792 $ MMS /Macro = (TCPWARE=1, DEC_C=1) for DECC - TCPWare TCP/IP
793
794 $ MMS /Macro = (MULTINET=1, GNU_C=1) for GNUC - MultiNet
795 $ MMS /Macro = (WIN_TCP=1, GNU_C=1) for GNUC - Wollongong TCP/IP
796 $ MMS /Macro = (UCX=1, GNU_C=1) for GNUC - UCX
797 $ MMS /Macro = (CMU_TCP=1, GNU_C=1) for GNUC - OpenCMU TCP/IP
798 $ MMS /Macro = (SOCKETSHR_TCP=1,GNU_C=1) for GNUC - SOCKETSHR/NETLIB
799 $ MMS /Macro = (TCPWARE=1, GNU_C=1) for GNUC - TCPWare TCP/IP
800
801 If you just type "MMS" it will default to the MULTINET and VAXC
802 configuration. MMS will build the WWW library and Lynx sources, and
803 link the executable. However, not all of the header dependencies are
804 specified. If you are not a developer, and need a clean build, you
805 should use build.com instead of the MMS utility.
806
807 If you want SOCKS support on VMS, you must add SOCKS as a compilation
808 definition, and the SOCKS library to the link command. However, instead
809 of SOCKSifying Lynx for use behind a firewall, you are better off if you
810 build Lynx normally, and set up Lynx to use a proxy server (see below).
811 You instead can SOCKSify the proxy server, and it will handle all clients,
812 not just Lynx.
813
814
815 IV. Compile instructions -- Win32 (Windows95/98/NT)
816
817 Borland C:
818
819 The original Win32 port was built with Borland C++ 4.52, but later
820 versions reportedly can be used. Before compiling the Lynx sources, you
821 need a curses library, and it is recommended that you have the zlib
822 library. Get pdcurses2.3 from "http://www.lightlink.com/hessling/". I
823 have modified it so that mouse support is no longer broken for Lynx (see
824 "http://www.fdisk.com/doslynx/"). You will want to get zlib from
825 "http://www.gzip.org/zlib/ ". Compile these libraries, and
826 put them in a convenient place (pdcurses inside the Lynx directory).
827
828 Unpack the latest Lynx source distribution, and make an obj directory
829 under the source root to contain the compile output. Copy in your
830 IDE file. A sample IDE file and helper libraries are available at
831 "http://www.fdisk.com/doslynx/wlynx/source/".
832
833 First build the .h files in src\chrtrans using "makew32.bat". Double
834 check for new .tbl files; hand edit in any new ones, and then do "makew32".
835 Jump into Borland C++, load the project (IDE file) and compile Lynx.
836 Alternately, after compiling the chartrans tables, you can come back to
837 the top directory and compile manually, i.e., do "make -f makefile.bcb".
838
839 I also have a binary available at "http://www.fdisk.com/doslynx/". This
840 binary was compiled with pdcurses 2.3, hacked so win32 mouse support works,
841 and with zlib, so Lynx can do gzip routines internally. More hints and
842 information can be found in "http://www.fdisk.com/doslynx/lynxport.htm".
843
844 -- 1997/10/12 - W. Buttles <lynx-port@fdisk.com>
845
846 Cygwin:
847 It is possible to compile under the cygwin system, which will allow you to
848 use the configure script described above for Unix. Type, for example,
849 "./configure --with-screen=ncurses --with-libz" in a Dos window running the
850 cygwin bash$ shell. You also have the choice of using either pdcurses or
851 slang. You will need a launch program such as sh.exe to call helper
852 applications. Paths may need to be in cygwin style, rather than Windows
853 style (e.g., TMPDIR=/cygdrive/d/cygwin/tmp, rather than
854 TMPDIR=d:\cygwin\tmp).
855
856 Visual C++:
857 You must have compiled zlib and PDCurses with the -MT (threaded code)
858 option. This is not the default with zlib (see Makefile.msc).
859
860 Copy into lib the following
861 zconf.h
862 zlib.h
863 zlib.lib
864
865 from the zlib build-tree, and
866 curses.h
867 pdcurses.lib
868
869 from the PDCurses build-tree.
870
871 Then
872 make-msc
873
874 to build lynx.
875
876 V. Compile instructions -- 386 DOS
877
878 Compiling for DOS with DJGPP has traditionally been a multistep
879 procedure. Now, if you have a full installation of DJGPP you can
880 also install using the configure script, just as in the UNIX
881 section. This needs to be done under a BASH shell. Use a shell
882 script to run configure as in the example at the end of this
883 section. Otherwise you can follow the below instructions. The
884 multistep procedure for DOS may not be supported in the future
885 and use of the configure script is recommended. The information
886 about required libraries and unpacking applies to both methods of
887 compiling.
888
889 First install the C compiler and its libraries (see readme.1st from
890 DJGPP distribution).
891
892 Originally, lynx makefiles come with the initial -O2 optimization
893 level. If you experience compilation process too slow due to paging
894 to the disk (DPMI server provide virtual memory, when in lack of
895 RAM), you may change optimization to -O1 or turn the optimization
896 off entirely.
897
898 If using optimization level -O2 or -O3 with older versions of DJGPP
899 and GCC, you may need to "stubedit" your "cc1.exe" file to enlarge
900 compiler stack size. For instance, if using DJGPP 2.02 and GCC 2.8.1,
901 to compile with -O3 optimization, the stub needs to be edited to give
902 a larger stack. To do this go into djgpp\lib\gcc-lib\djgpp\2.81 and
903 either type the command:
904 "stubedit cc1.exe bufsize=63k minstack=2M",
905 or edit interactively with: "stubedit cc1.exe". Current versions of
906 DJGPP and GCC generally work with the standard stack.
907
908 Unpack the source code using a DOS program like UNZIP386. If you are
909 using PKUNZIP to unpack the .zip archive, you must use the -d command
910 line switch to restore the directory structure contained in the archive,
911 i.e., do "pkunzip -d lynx-cur.zip". No switch is required if you use
912 unzip386 or unzip. If you are trying to compile the 386DOS port under a
913 WinNT DOS shell, be sure to unpack the source with a DOS program so
914 that all directories will be adjusted to the DOS 8.3 file format necessary
915 for compiling with DJGPP. Do NOT use Winzip, because that will create
916 long filenames that will not be recognized by DJGPP tools.
917
918 If you wish to compile with "USE_ZLIB" (recommended), you must have the
919 zlib library. Get the source from
920 http://www.gzip.org/zlib/
921 and compile it. Put libz.a in the lib subdirectory of DJGPP, and put
922 zlib.h and zconf.h in the include subdirectory.
923
924 In addition to the files in the Lynx distribution, you will need a curses
925 package and a TCP package. You can use PDCurses (available at
926 "http://pdcurses.sourceforge.net/") and the DJGPP port of WATTCP. The
927 updated version of WATTCP is known as WATT-32, and is available at
928 "http://www.bgnett.no/~giva/". You can also use slang (available at
929 "http://www.s-lang.org/") as your screen library. You must
930 compile these before you go any further. If you wish to use PDCurses 2.6,
931 you need to first apply the following patch:
932
933 --- dos/gccdos.mak.ori 2002-01-11 20:11:18.000000000 -0800
934 +++ dos/gccdos.mak 2003-12-13 21:29:28.000000000 -0800
935 @@ -40,11 +40,11 @@
936 CFLAGS = -c -g -Wall -DPDCDEBUG
937 LDFLAGS = -g
938 else
939 - CFLAGS = -c -O -Wall
940 + CFLAGS = -c -O2 -Wall
941 LDFLAGS =
942 endif
943
944 -CPPFLAGS = -I$(PDCURSES_HOME) -I$(CCINCDIR) -D_NAIVE_DOS_REGS
945 +CPPFLAGS = -I$(PDCURSES_HOME) -I$(CCINCDIR) -D_NAIVE_DOS_REGS -DHAVE_STRING_H
946
947 CCFLAGS = $(CFLAGS) $(CPPFLAGS)
948
949 @@ -64,10 +64,10 @@
950 all: $(PDCLIBS) $(DEMOS)
951
952 clean:
953 -del *.o
954 - -del curses.lib
955 - -del panel.lib
956 + -del pdcurses.a
957 + -del panel.a
958
959 demos: $(DEMOS)
960
961 @@ -287,33 +287,27 @@
962 #------------------------------------------------------------------------
963
964 firework.exe: firework.o $(LIBCURSES)
965 - $(LINK) $(LDFLAGS) -o firework firework.o $(LIBCURSES)
966 - $(COFF2EXE) firework
967 + $(LINK) $(LDFLAGS) -o firework.exe firework.o $(LIBCURSES)
968 strip $@
969
970 newdemo.exe: newdemo.o $(LIBCURSES)
971 - $(LINK) $(LDFLAGS) -o newdemo newdemo.o $(LIBCURSES)
972 - $(COFF2EXE) newdemo
973 + $(LINK) $(LDFLAGS) -o newdemo.exe newdemo.o $(LIBCURSES)
974 strip $@
975
976 ptest.exe: ptest.o $(LIBCURSES) $(LIBPANEL)
977 - $(LINK) $(LDFLAGS) -o ptest ptest.o $(LIBCURSES) $(LIBPANEL)
978 - $(COFF2EXE) ptest
979 + $(LINK) $(LDFLAGS) -o ptest.exe ptest.o $(LIBCURSES) $(LIBPANEL)
980 strip $@
981
982 testcurs.exe: testcurs.o $(LIBCURSES)
983 - $(LINK) $(LDFLAGS) -o testcurs testcurs.o $(LIBCURSES)
984 - $(COFF2EXE) testcurs
985 + $(LINK) $(LDFLAGS) -o testcurs.exe testcurs.o $(LIBCURSES)
986 strip $@
987
988 tuidemo.exe: tuidemo.o tui.o $(LIBCURSES)
989 - $(LINK) $(LDFLAGS) -o tuidemo tuidemo.o tui.o $(LIBCURSES)
990 - $(COFF2EXE) tuidemo
991 + $(LINK) $(LDFLAGS) -o tuidemo.exe tuidemo.o tui.o $(LIBCURSES)
992 strip $@
993
994 xmas.exe: xmas.o $(LIBCURSES)
995 - $(LINK) $(LDFLAGS) -o xmas xmas.o $(LIBCURSES)
996 - $(COFF2EXE) xmas
997 + $(LINK) $(LDFLAGS) -o xmas.exe xmas.o $(LIBCURSES)
998 strip $@
999
1000
1001 --- dos/pdckbd.c.ori 2002-09-01 00:13:30.000000000 -0800
1002 +++ dos/pdckbd.c 2004-01-19 20:30:02.000000000 -0800
1003 @@ -362,7 +362,7 @@
1004 return ((int) (0xb8 << 8));
1005 if (ascii == 0xe0 && scan == 0x53 && pdc_key_modifiers & PDC_KEY_MODIFIER_SHIFT) /* Shift Del */
1006 return ((int) (0xb9 << 8));
1007 - if (ascii == 0x00 || ascii == 0xe0)
1008 + if (ascii == 0x00 || (ascii == 0xe0 && scan != 0x00))
1009 return ((int) (scan << 8));
1010 return ((int) (ascii));
1011 }
1012 @@ -522,7 +522,7 @@
1013 _watch_breaks();
1014 #else
1015 # ifdef GO32
1016 - (void*)signal(SIGINT,(setting ? SIG_DFL : SIG_IGN));
1017 +/* (void*)signal(SIGINT,(setting ? SIG_DFL : SIG_IGN)); */
1018 /* __djgpp_set_ctrl_c(setting);*/
1019 setcbrk(setting);
1020 # else
1021 --- pdcurses/kernel.c.ori 2002-11-27 03:24:32.000000000 -0800
1022 +++ pdcurses/kernel.c 2003-12-13 21:22:38.000000000 -0800
1023 @@ -27,6 +27,10 @@
1024 #include <memory.h>
1025 #endif
1026
1027 +#ifdef HAVE_STRING_H
1028 +#include <string.h>
1029 +#endif
1030 +
1031 #ifdef UNIX
1032 #include <defs.h>
1033 #include <term.h>
1034 --- pdcurses/pdcutil.c.ori 2001-01-10 00:27:22.000000000 -0800
1035 +++ pdcurses/pdcutil.c 2003-12-13 21:24:58.000000000 -0800
1036 @@ -49,7 +49,7 @@
1037 # include <limits.h>
1038 #endif
1039
1040 -#ifdef STDC_HEADERS
1041 +#if defined(STDC_HEADERS) || defined(HAVE_STRING_H)
1042 # include <string.h>
1043 #endif
1044
1045 --- pdcurses/pdcwin.c.ori 2002-05-25 17:13:32.000000000 -0800
1046 +++ pdcurses/pdcwin.c 2003-12-13 21:26:02.000000000 -0800
1047 @@ -27,6 +27,10 @@
1048 # include <memory.h>
1049 #endif
1050
1051 +#ifdef HAVE_STRING_H
1052 +#include <string.h>
1053 +#endif
1054 +
1055 #ifndef HAVE_MEMMOVE
1056 # define memmove PDC_memmove
1057 #endif
1058
1059 If you wish to compile with SSL enabled, you need to get and compile
1060 OpenSSL. The DJGPP port has been successfully compiled with the
1061 0.9.7 stable series of OpenSSL. DJGPP can compile OpenSSL from the
1062 standard source distribution (http://www.openssl.org/). See the file
1063 "INSTALL.DJGPP" in the OpenSSL distribution.
1064
1065
1066 If you have trouble applying the patches, try using the "patch" program,
1067 ("http://www.delorie.com/pub/djgpp/current/v2gnu/pat253b.zip").
1068 To read the Unix man style documentation, use, for example, "less"
1069 ("http://www.delorie.com/pub/djgpp/current/v2gnu/lss374b.zip").
1070 Compile or place your compiled PDCurses library in /djgpp/pdcur26, and
1071 compile or place your compiled WATT-32 library in /djgpp/watt32. If
1072 using the SLANG library, put libslang.a in your DJGPP/lib directory and put
1073 slang.h and slcurses.h in your DJGPP/include directory, or in the
1074 appropriate directories specified by LIBRARY_PATH and INCLUDE_PATH in your
1075 DJGPP.ENV file.
1076
1077 Move to the "lynx2-*/WWW/Library/djgpp" directory. If compiling with
1078 PDCurses, do "make". If using SLANG, do "make -f makefile.sla". This
1079 should compile libwww.a. Next move to the "lynx2-*/src/chrtrans" directory
1080 and do "make -f makefile.dos" to compile the character tables. Then move
1081 to the "lynx2-*/src" directory. There are three choices for compiling at
1082 this point. You can do "make -f makefile.dos" to compile with PDCurses,
1083 "make -f makefile.wsl" to compile with SLANG, or "make -f makefile.dsl" to
1084 compile with SLANG and the DJGPP keyhandler. At the time of this writing,
1085 it is not clear what the advantages and disadvantages of each version are.
1086 The PDCurses version has the most experience and allows remapping of ALT
1087 and Function keys. The SLANG version seems to have better screen handling.
1088 It allows mapping of function keys, but not ALT keys. The SLANG with DJGPP
1089 keyhandler allows mapping of ALT and Function keys, but has the risk of
1090 incompatibilities from mixing different programs.
1091
1092 If you wish to compile with support for internationalization of messages,
1093 you first need to install the DOS ports of the GNU gettext and libiconv
1094 packages, available from any DJGPP mirror site. Then uncomment the lines
1095 for INTLFLAGS in src/makefile.dsl and in WWW/Library/djgpp/makefile.sla,
1096 and remove the "#" from the LIBS line in src/makefile.dsl. Make similar
1097 changes if using one of the other DOS makefiles. See the gettext
1098 documentation for information on creating and using message files for
1099 different languages.
1100
1101 If all goes well, you will have a lynx.exe file. If you have trouble,
1102 check to be sure djgpp.env is the way it came in the original package.
1103
1104 To test Lynx_386 you must have a packet driver installed. The simplest
1105 method is to use a null packet driver that just allows Lynx to start up,
1106 but doesn't do anything else. One such executable driver has been posted,
1107 uuencoded, to the lynx-dev mailing list:
1108 "http://www.flora.org/lynx-dev/html/month011998/msg00057.html".
1109 Start the dummy packet driver with "nullpkt 0x60", and take it out of
1110 memory with "nullpkt -u". You can also use slip8250.com. See the CRYNWR
1111 package "ftp://ftp.simtel.net/pub/simtelnet/msdos/pktdrvr/pktd11.zip".
1112 Usage is "slip8250 0x60", but you may have to invoke it as, for example,
1113 "slip8250 0x60 6 3 0x2F8" so that it uses COM2 and IRQ 3, in order to
1114 avoid an IRQ conflict with a mouse or some other device. Another packet
1115 driver is slipper.exe, which is available from many sites, including
1116 "ftp://ftp.trumpet.com.au/slipper". To remove it from memory use
1117 termin.com (usage "termin 0x60"), available in the CRYNWR package. To
1118 connect over a dialup PPP connection you need dosppp or klos' pppshare.
1119 (Find at:
1120 "http://www.ibiblio.org/pub/micro/pc-stuff/freedos/files/net/dosppp/dosppp06.zip"
1121 "http://www.ncf.carleton.ca/ncf/pda/computer/dos/net/dosppp06.zip"
1122 "http://mvmpc200.ciw.uni-karlsruhe.de/~mvmpc9/user/TONI/dosppp/dosppp06.zip"
1123 "ftp://ftp.oldskool.org/pub/tvdog/internet/dosppp06.zip";
1124 "ftp://ftp.klos.com/pub/demo/pppshare.exe")
1125
1126 File access looks like this:
1127
1128 file:///c:/
1129 file:///c:/dos
1130 file:///c:/dos/command.com
1131 file://localhost/c:/
1132 file://localhost/c:/dos
1133 file://localhost/c:/dos/command.com
1134
1135 See "http://www.fdisk.com/doslynx/lynxport.htm" for more hints and
1136 some precompiled libraries. One problem you can encounter is editing
1137 userdefs.h and lynx.cfg, which have unix-style end of lines. You would
1138 be well advised to use an editor that can handle end of lines terminated
1139 with a single LF character. You can also unpack the source code using
1140 unzip386 or unzip with the -a or -aa switch to convert unix LF to dos CRLF.
1141 That will make texts more readable under DOS. If you compile lynx
1142 regularly, you may automate the procedure by creating a batch file such
1143 as the following.
1144
1145 cd djgpp\watt32\src
1146 configur djgpp
1147 make -f djgpp.mak
1148 cd ..\..\..\www\library\djgpp
1149 make
1150 cd ..\..\..\src\chrtrans
1151 make -f makefile.dos
1152 cd ..\..\src
1153 make -f makefile.dos
1154 strip lynx.exe
1155 cd ..
1156
1157 This batch file expects the DJGPP port of WATT-32 to be installed in the
1158 lynx2-* directory. Place a copy of this batch file, named "djgpp.bat",
1159 in the lynx2-* directory, move to that directory and type "djgpp". A more
1160 complete batch file with error checking and annotation can be found at:
1161 "http://www.flora.org/lynx-dev/html/month111997/msg00250.html".
1162
1163 If you use the configure method, remember that if you configure with
1164 the option "--enable-nls", you also need to set LIBS="-liconv". A
1165 sample shell script to run configure using PDCurses follows. If you
1166 compile to use SLANG, note that the DJGPP keyhandler will be used
1167 instead of the SLANG keyhandler unless you define "NO_DJ_KEYHANDLER".
1168
1169 #!/bin/sh
1170 CFLAGS="-O2 -I/djgpp/pdcur26 -I/djgpp/watt32/inc" \
1171 LIBS="-L/djgpp/pdcur26/lib -L/djgpp/watt32/lib -liconv" \
1172 ./configure --prefix=d:/djgpp/lynx-rel/lynx-cnf \
1173 --with-screen=curses \
1174 --disable-full-paths \
1175 --enable-addrlist-page \
1176 --enable-change-exec \
1177 --enable-cgi-links \
1178 --enable-charset-choice \
1179 --enable-color-style \
1180 --enable-exec-links \
1181 --enable-externs \
1182 --enable-file-upload \
1183 --enable-nested-tables \
1184 --enable-nls \
1185 --sysconfdir=d:/djgpp/lynx-rel/lynx-cnf \
1186 --with-bzlib \
1187 --with-zlib \
1188 --with-ssl
1189
1190 -- 1997/9/29 - D. Kaufman <dkaufman@rahul.net>
1191 -- 1997/10/3 - B. Schiavo <Wschiavo@concentric.net>
1192 -- Last update - 2004/01/19
1193
1194
1195 VI. General installation instructions
1196
1197 Once you have compiled Lynx, test it out first on a local file. Be sure
1198 Lynx can find lynx.cfg. A _sample_ test command line would be:
1199 'lynx -cfg=/usr/local/lib/lynx.cfg .'. Once you are satisfied that
1200 Lynx works, go ahead and install it. For Unix, type "make install".
1201
1202 For VMS, you need to have the executable in a public place, make it
1203 accessible, define it as a foreign command, and copy lynx.cfg to
1204 "Lynx_Dir". Look at lynx.com in the samples directory as a model for
1205 installing Lynx. To include lynx.hlp in the system HELP library, use
1206 the command: "$ library/replace sys$help:helplib.hlb lynx.hlp".
1207
1208 Local copies of the Lynx online help should be made accessible in response
1209 to the Lynx 'h'elp command by defining HELPFILE in userdefs.h and/or
1210 lynx.cfg to an appropriate file://localhost/path URL. On Unix, all you
1211 need to do is type "make install-help." If you are installing manually,
1212 copy the files "COPYHEADER" and "COPYING" into the lynx_help directory
1213 BEFORE moving the lynx_help tree to its final location. These files are
1214 referenced hypertextually from help documents.
1215
1216 If you have old, pre-existing bookmark files from earlier versions of
1217 Lynx, those files may have to be updated. Conversion may just consist
1218 of adding one META line near the top, or may require creating new book-
1219 mark files and editing in bookmarks from outdated files.
1220
1221 IMPORTANT! Be sure you have read the warnings about setting up an
1222 anonymous account with Lynx if you plan to give public access to Lynx.
1223
1224 After applying patches or editing files to correct for an unsuccessful
1225 build, be certain to do a "make clean" (or "make distclean" for those
1226 using auto-configure) before attempting to compile again.
1227
1228
1229 VII. Setting environment variables before running Lynx (optional)
1230
1231 1. All ports
1232
1233 The Lynx Users Guide describes all of the environment variables used by
1234 Lynx. This should be checked later along with reading lynx.cfg after you
1235 have installed Lynx.
1236
1237 2. Win32 (95/98/NT) and 386 DOS
1238
1239 These ports cannot start before setting certain environment variables.
1240 Here are some environment variables that should be set, usually in a
1241 batch file that runs the lynx executable. Make sure that you have enough
1242 room left in your environment. You may need to change your "SHELL="
1243 setting in config.sys. In addition, lynx looks for a "SHELL" environment
1244 variable when shelling to DOS. If you wish to preserve the environment
1245 space when shelling, put a line like this in your AUTOEXEC.BAT file also
1246 "SET SHELL=C:\COMMAND.COM /E:4096". It should match CONFIG.SYS.
1247
1248 HOME Where to keep the bookmark file and personal config files.
1249 TEMP or TMP Bookmarks are kept here with no HOME. Temp files here.
1250 USER Set to your login name (optional)
1251 LYNX_CFG Set to the full path and filename for lynx.cfg
1252 LYNX_LSS Set to the full path and filename for lynx.lss
1253 LYNX_SAVE_SPACE The (modifiable) location for downloaded file storage.
1254 SSL_CERT_FILE Set to the full path and filename for your file of trusted
1255 certificates
1256
1257 386 version only:
1258 WATTCP.CFG Set to the full path for the WATTCP.CFG directory
1259 RL_CLCOPY_CMD Command to copy a URL to a "clipboard" file
1260 RL_PASTE_CMD Command to go to a URL in your "clipboard" file
1261
1262 Define these in your batch file for running Lynx. For example, if your
1263 application line is "D:\win32\lynx.bat", lynx.bat for Win32 may look like:
1264 @ECHO OFF
1265 set home=d:\win32
1266 set temp=d:\tmp
1267 set lynx_cfg=d:\win32\lynx.cfg
1268 set lynx_save_space=d:\download
1269 d:\win32\lynx.exe %1 %2 %3 %4 %5
1270
1271 For lynx_386, a typical batch file might look like:
1272
1273 @echo off
1274 set HOME=f:/lynx2-8
1275 set USER=your_login_name
1276 set LYNX_CFG=%HOME%/lynx.cfg
1277 set WATTCP.CFG=%HOME%
1278 f:\lynx2-8\lynx %1 %2 %3 %4 %5 %6 %7 %8 %9
1279
1280 You need to make sure that the WATTCP.CFG file has the correct information
1281 for IP number, Gateway, Netmask, and Domain Name Server. This can also be
1282 automated in the batch file.
1283
1284 Adapted from "readme.txt" by Wayne Buttles and "readme.dos" by Doug Kaufman.
1285
1286 VIII. Acknowledgment
1287
1288 Thanks to the many volunteers who offered suggestions for making this
1289 installation manual as accurate and complete as possible.
1290
1291 -- 1999/04/24 - H. Nelson <lynx-admin@irm.nara.kindai.ac.jp>