home *** CD-ROM | disk | FTP | other *** search
/ rtsi.com / 2014.01.www.rtsi.com.tar / www.rtsi.com / OS9 / OSK / NETWORK / netpbm_src.lzh / NETPBM / AMIGA / README.DICE < prev    next >
Text File  |  1996-11-18  |  4KB  |  99 lines

  1. This file describes how to compile NETPBM with DICE (registered version).
  2. You need a real "make" program (the "dmake" supplied with DICE won't work for
  3. this), and "patch".  The "make" program should ignore a WARN return code.
  4. Compilation requires about 4MB RAM and 6MB of HD space, and takes about
  5. 45 minutes on a 25MHz 68030.
  6.  
  7. Compilation of the TIFF library is not covered in this file. A compiled
  8. TIFF lib is available in the dicelibs archive (see "NETPBM.INTRO" for
  9. FTP addresses).  Copy this library to the netpbm/libtiff directory.
  10.  
  11.  
  12. (1) CD into netpbm/amiga and compile dice_stack.c with
  13.         dcc -c dice_stack.c
  14.  
  15. (2) Set the environment variable "USER" to your name, like this:
  16.         setenv USER "Al Bundy"
  17.     CD into the toplevel netpbm directory and execute the shell-script
  18.     "stamp-date.amiga".  This will create the file "compile.h".
  19.  
  20. (3) Apply the patch:
  21.         patch -l < amiga/DICE.PATCH
  22.     This installs a workaround for a DICE bug in two source files.  If you
  23.     are using a DICE version newer than 2.07.56R, this bug might already be
  24.     fixed.  To test this, compile this program:
  25.         main() { double d = 0.5; int i = 2; i *= d; printf("%d\n", i); }
  26.     If the result is "0", the bug still exists.
  27.  
  28. (4) Edit pbmplus.h.  The following symbols should be set:
  29.         A_SMALLSTACK (obsolete, no longer used)
  30.         A_FRAGARRAY
  31.         A_RGBENV     (optional, but recommended)
  32.         A_STRERROR
  33.  
  34. (5) There is no toplevel Makefile. CD into netpbm/pbm and type
  35.         make -f Makefile.dice all     for separate binaries
  36.     or  make -f Makefile.dice merge   for a merged binary (see "NETPBM.INTRO")
  37.     Repeat this in the directories netpbm/pgm, netpbm/ppm and netpbm/pnm,
  38.     in this order.  If you are changing the compiler options, make sure to
  39.     change them in all four makefiles.
  40.  
  41. (6) The binaries are now in netpbm/p?m/bin, just move them to a directory in
  42.     your search path.  See the file "NETPBM.INTRO" for more installation info.
  43.     Note that binaries created by you will not use the PBMMEM environment
  44.     variable.
  45.  
  46.  
  47. Here is a short explanations of compiler options used in the DICE Makefiles:
  48.     -E xxx      write error messages into file xxx
  49.     -ms         place strings constants in read-only code hunk
  50.     -mu         unix-compat, if there are two definitions for the
  51.                 same variable (at the same scope), merge them into one
  52.     -gs         generate stack-checking code (see dice_stack.c: whenever
  53.                 available stack falls below _stack_fudge, allocate a new stack
  54.                 of size _stack_chunk)
  55.     -proto      strict prototype checking
  56.     -mRR        functions take their args in registers (requires full prototyping)
  57.     -mD         large data model (absolute addressing instead of A4-rel)
  58.     -mC         large code model (absolute addressing instead of PC-rel)
  59.     -r          generate "pure" executable (no -mD and -mC allowed)
  60.     -S          alternate library section naming (used for link libs only)
  61.     -s          DEBUG: don't strip symbol information from executable
  62.     -d1         DEBUG: include LINE information in executable (for Enforcer's FindHit)
  63.  
  64. Naming conventions in the Makefiles:
  65.     RLIBP?M     small data library, args in registers
  66.     RLLIBP?M    large data library, args in registers
  67.     SLIBP?M     small data library, args on stack
  68.     SLLIB?M     large data library, args on stack
  69.  
  70.     RALLCFLAGS  options to compile register-args executables
  71.     SALLCFLAGS  options to compile stack-args executables
  72.     MALLCFLAGS  options to compile merged executable
  73.  
  74.     BINS        small data executables, register-args
  75.     LBINS       large data executables, register-args
  76.     SBINS       small data executables, stack-args
  77.     SLBINS      large data executables, stack-args
  78.  
  79.     MATHBINS    \
  80.     LMATHBINS    \  same as above, but need floating-point
  81.     SMATHBINS    /  version of printf/scanf (link with math-lib)
  82.     SLMATHBINS  /
  83.  
  84.     *.or        library object file (small data, reg-args)
  85.     *.os        library object file (small data, stack args)
  86.     *.olr       library object file (large data, reg-args)
  87.     *.ols       library object file (large data, stack args)
  88.     *.om        object file for merged binary (large data, stack args)
  89.  
  90. I tried to use small data/reg-args whenever possible.  Some programs
  91. had to be compiled with large data, and some with stack-args or the
  92. compiler would complain.
  93.  
  94.  
  95.  
  96. -Ingo
  97. email: Ingo.Wilken@informatik.uni-oldenburg.de
  98.  
  99.