Compiling Log
This document assumes that you have successfully compiled
the Psys libraries. This
document also assumes that you have uncompressed and untarred the
Log file, and installed it in the chipmunk
directory.
Step 1: Initialization
Begin by descending to the log/src directory.
At this point OS/2 users only should execute the following
commands.
cp Makefile.os2 Makefile
cp ana/Makefile.os2 ana/Makefile
Step 2: Makefile Editing
All users should now edit the files Makefile
and ana/Makefile, and make any necessary changes. Comments
in the Makefile will guide you through these changes; the changes are
labeled with the markers (1), (2), (3), etc.
Step 3: Munch replacement
Once Makefile edits are made, check to see if your platform
is listed below. If it is, execute the command under the platform
name in the log/src directory.
- Apple Mac AU/X (NOT Mac OS X, which needs no changes)
- cp munch.coff munch
- HP Series 700, HPUX
- cp munch.hp800 munch
- IBM RS/6000
- cp munch.rs6000 munch
- Sun SPARC, Solaris 2.X (SunOS 5.X)
- cp munch.solaris2 munch
Step 4: Compilation
Once these changes are made, execute the command
make install
If things are working correctly, a long series of
compilations, linkings, and file movements should occur without error.
This will create the programs chipmunk/bin/diglog,
chipmunk/bin/analog, and chipmunk/bin/loged. To
check basic functionality, try to run these three programs. For
each program, two windows should appear on program launch, one called
newcrt and one called mylib. Type :exit in
the newcrt window to leave analog and
diglog. Type exit in the newcrt to leave
loged. See the user
documentation for information on using these tools.
Problems and Solutions
Its quite possible that compilation did not proceed smoothly, or
that execution problems happen while using the tool. Here are some
possible ways that things could have went wrong, along with
suggestions.
- The Log windows appear, and then the program exits.
- This symptom usually means that you moved the log source code
directory after compling the program. To solve this problem, set the
LOGLIB environment variable to the absolute location of this directory.
For example, on my system, using the tcsh shell, I solve the problem using:
setenv LOGLIB /Users/lazzaro/work/legacy/chipmunk/log/lib
- Log comes up in monochrome -- too few colors available
- This symptom could indicate several conditions. If you display
hardware has less that 4 bits per pixel, Log can't use the small
number of colors available effectively, and reverts to monochrome
display. If your display has greater than 4 bits per pixel, perhaps
a color-hungry program (like Netscape) is monopolizing the colormap.
To test this hypothesis, exit Netscape then restart Log. See the
Netscape FAQs for information on improving the color-allocation
manners of the program.
- Log comes up in monochrome -- too many colors available
- Log now has code to handle displays with 16 bits per pixel and 24
bits per pixel. However, this code hasn't been extensively tested on
many X servers, and may be buggy. See this document for information
on working around these bugs. Alternatively, try switching your
display driver to "8 bits per pixel" mode.
- File system problems
- The symptom is that Log runs fine for a few days (weeks, months),
but one day it stops working. Another symptom is that Log runs on the
machine it was compiled on, but not on other machines in a NFS
cluster. The cause of these problems often traces to Log noting where
its absolute location is during compile time, using pwd
commands in its Makefiles. If your disk is reorganized, Log will be
confused, and recompilation (Psys and Log) will be necessary. Also, if
your system uses the NFS automounter, the results of the pwd
command may not be correct for every machine on your cluster, or may
change with time. In this case, replacing the pwd commands in
the log Makefiles with hard-coded paths, or with the environment
variable PWD, is a good idea.
- log.c won't compile
- This file breaks many compilers because of its length, in many
different ways. Possible solutions include compiling with or without
optimization on, and directing the compiler to place temporary files
in a disk partition with more free space.
- Print spooling is broken
- Pressing File in the Log preview screens should send a
Postscript file to a local printer, by writing a file to
/tmp, and printing the file using lpr. This may be
incorrect for your system. If so, change line 2868 (Unix) or 2865
(OS/2) of the file log/src/lplot.c to conform to your
environment.
- Problems finding libraries or include files
- Some OS installations don't have X11 or other needed libraries
in the include path and/or the linking path. Look in the Makefile for
tips on solving this problem, at the definitions of LIBX11 and
XINCLUDEDIR.
If these suggestions don't help you compile Log, I'd be happy to
offer suggestions; press here for more
information about asking for help.
- Email
- john [dot] lazzaro [at] gmail [dot] com