home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 6 / FreshFish_September1994.bin / bbs / gnu / gnat-1.80-src.lha / GNU / src / amiga / gnat-1.80 / README-amiga < prev    next >
Encoding:
Text File  |  1994-07-07  |  4.2 KB  |  137 lines

  1. This is the GNU Ada compiler, GNAT.  The compiler is in a 'hacker  
  2. state', ie. it is complete and certainly not bug free.  But you it can
  3. compile itself, more than 110,000 lines of Ada, and many other 
  4. programs.
  5. I have compiled the entire thing, including the compilers, the library
  6. and the other utility program that came with it.  I have not test any
  7. of it extensively, except for compiling itself and a few old programs
  8. I had from school.
  9. The only mandatory files you need are gnat1 and gnatbind for the amiga
  10. and the source, if you want to compile it yourself.
  11.     those files are
  12.         gnat1-gnatbind.lha
  13.         and gnat-1.80-src.lha
  14.  
  15.                 and of course, the gcc-2.5.8 source
  16.  
  17. There is a third file, gnat-1.80-bin.lha, it contains everything
  18. needed to run compile ada programs, but not the source to recompile
  19. GNAT. 
  20.  
  21. In gnat-1.80-src.lha there is a directory called corrections, these
  22. are some thing that needed to be done to gnat to get it to compile,
  23. just *ruff* notes. ( don't trust the diffs , they be backward ).
  24. The problem I ran into were:
  25.     1. the compiler generates bad code for the parser (par.o)
  26.        the statement that it compiles wrong is something like
  27.         
  28.                   exit when SS_FLAG.uncd
  29.  
  30.        par.s.diff will show you where the problem is, and a
  31.            working alternative.
  32.  
  33.         2. The compiler craps out with an interanl error, on two
  34.            code statement in uintp.adb.
  35.        Unitp.adb.diff shows a workaround that seem to work.
  36.  
  37.         3. The compiler bombs on some code in atree.adb.
  38.                Atree.adb.changes shows how to change the code,
  39.                but it must be repeated a couple of time.
  40.  
  41.         4. There is also a problem with the 'md' file. A replacement
  42.            is in the correction directory along with the original.
  43.  
  44. I also had a few other problem compiling the sytem, most seem to be
  45. related to memory constraints. Plan on a lot of memory to recompile
  46. this thing, > 14meg. ( most of the files do not need that much memory
  47. but there are a couple that do, par-*.ad?. Also *lots* of disk space.
  48.  
  49. Another problem for amiga owners seems to be the stack.  I compiled
  50. one old program and ran it, it needed 470,000 stack to run. I have no
  51. idea how to work around this.
  52.  
  53. Happy ADAing.
  54.  
  55. Pass Travis
  56.  
  57. ptravis@rs6.tcs.tulane.edu
  58.  
  59. ======================================================================
  60. These notes added by Fred Fish.
  61.  
  62.     *    This file has been renamed README-amiga
  63.  
  64.     *    There is a new directory, "amiga", containing amiga specific
  65.     notes and such.
  66.  
  67.     *    The "corrections" directory refered to above has been moved
  68.     to amiga/corrections, and is not used.
  69.  
  70.  
  71. ===============
  72. REBUILDING GNAT
  73. ===============
  74.  
  75. (1)    Start with the baseline FSF gcc 2.5.8 archive gcc-2.5.8.tar.gz.
  76.     Ungzip it, and then untar it:
  77.  
  78.         gzip -d gcc-2.5.8.tar.gz
  79.         tar -xvf gcc-2.5.8.tar
  80.         rm gcc-2.5.8.tar
  81.  
  82.         Note: if you are starting with my CD distribution, you
  83.         can skip steps 1 and 2, and simply clone the gcc-2.5.8
  84.         tree under gnu:src/amiga to use as a starting point with
  85.         step 3.
  86.  
  87. (2)    Cd to the gcc root directory and apply the diffs that turn the
  88.     baseline FSF gcc into Amiga gcc:
  89.  
  90.         cd gcc-2.5.8
  91.         patch -p1 <gnu:src/amiga/gnat-1.80/amiga/gcc-2.5.8.diffs
  92.         delete #?.orig
  93.         delete config/m68k/#?.orig
  94.  
  95. (3)    Now apply the diffs that are needed to amiga gcc files for amiga
  96.     gnat.  These diffs don't add any files, just change the gcc ones:
  97.  
  98.         patch -p1 <gnu:src/amiga/gnat-1.80/amiga/gcc-gnat.diffs
  99.         delete #?.orig
  100.         delete #?/#?/#?.orig
  101.  
  102. (4)    Now copy the new ada specific source files from the gnat
  103.     distribution into the gcc source directory:
  104.  
  105.         copy gnu:src/amiga/gnat-1.80/src "" all clone
  106.  
  107. (5)    Delete the diff files provided with gnat, they are already taken
  108.     care of by the patches applied above.
  109.  
  110.         delete #?.diff
  111.  
  112. (6)    Configure gcc/gnat for amigados:
  113.  
  114.         sh configure amigados
  115.  
  116. (7)    Build just the ada portions:
  117.  
  118.         make LANGUAGES=ada
  119.  
  120. (8)    Build the ada runtime
  121.  
  122.         make tmp-adainclude
  123.  
  124. (9)    Install the ada binaries:
  125.  
  126.         copy gnat1 gnu:lib/gcc-lib/amigados/2.5.8/gnat1
  127.         copy gnatbind gnu:bin/gnatbind
  128.         copy gnatbl gnu:bin/gnatbl
  129.         copy gnatchop gnu:bin/gnatchop
  130.         copy gnatf gnu:bin/gnatf
  131.         copy gnatk8 gnu:bin/gnatk8
  132.         copy gnatsplit gnu:bin/gnatsplit
  133.  
  134. (10)    Install the ada runtime:
  135.  
  136.         make install-gnatlib
  137.