home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 6 / FreshFish_September1994.bin / bbs / gnu / gcc-2.6.0-diffs.lha / GNU / src / diffs / gcc-2.6.0.diffs
Encoding:
Text File  |  1994-09-07  |  105.4 KB  |  3,240 lines

  1. diff -rc --new-file gcc-2.6.0/ChangeLog /gnu/src/amiga/gcc-2.6.0/ChangeLog
  2. *** gcc-2.6.0/ChangeLog    Thu Jul 14 13:43:11 1994
  3. --- /gnu/src/amiga/gcc-2.6.0/ChangeLog    Mon Aug 29 16:42:19 1994
  4. ***************
  5. *** 1,3 ****
  6. --- 1,10 ----
  7. + Fri Aug 26 12:24:14 1994  Brendan Kehoe  (brendan@lisa.cygnus.com)
  8. +     * call.c (build_method_call) [PCC_STATIC_STRUCT_RETURN]: Also
  9. +     accept an RTL_EXPR in what we're about to use for the instance,
  10. +     since anything which would end up with pcc_struct_return set
  11. +     inside cplus_expand_expr.
  12.   Thu Jul 14 09:42:23 1994  Richard Kenner  (kenner@vlsi1.ultra.nyu.edu)
  13.   
  14.       * Version 2.6.0 released.
  15. diff -rc --new-file gcc-2.6.0/Makefile.in /gnu/src/amiga/gcc-2.6.0/Makefile.in
  16. *** gcc-2.6.0/Makefile.in    Wed Jul 13 22:47:13 1994
  17. --- /gnu/src/amiga/gcc-2.6.0/Makefile.in    Fri Jul 29 20:11:03 1994
  18. ***************
  19. *** 65,75 ****
  20.   AR_FLAGS = rc
  21.   SHELL = /bin/sh
  22.   # on sysV, define this as cp.
  23. ! INSTALL = install -c
  24.   # These permit overriding just for certain files.
  25.   INSTALL_PROGRAM = $(INSTALL)
  26.   INSTALL_DATA = $(INSTALL)
  27. ! SYMLINK = ln -s
  28.   MAKEINFO = makeinfo
  29.   TEXI2DVI = texi2dvi
  30.   # For GNUmake: let us decide what gets passed to recursive makes.
  31. --- 65,78 ----
  32.   AR_FLAGS = rc
  33.   SHELL = /bin/sh
  34.   # on sysV, define this as cp.
  35. ! INSTALL = cp
  36.   # These permit overriding just for certain files.
  37.   INSTALL_PROGRAM = $(INSTALL)
  38.   INSTALL_DATA = $(INSTALL)
  39. ! SYMLINK = cp
  40. ! # Some systems don't support hardlinks.  For this case, a simple copy
  41. ! # will achieve the same results for our purposes.
  42. ! HARDLINK = cp
  43.   MAKEINFO = makeinfo
  44.   TEXI2DVI = texi2dvi
  45.   # For GNUmake: let us decide what gets passed to recursive makes.
  46. ***************
  47. *** 99,111 ****
  48.   OLDAR = ar
  49.   
  50.   # Target to use when installing include directory.  Either
  51. ! # install-headers-tar or install-headers-cpio.
  52.   INSTALL_HEADERS_DIR = install-headers-tar
  53.   
  54.   # The GCC to use for compiling libgcc2.a, enquire, and cross-test.
  55.   # Usually the one we just built.
  56.   # Don't use this as a dependency--use $(GCC_PASSES) or $(GCC_PARTS).
  57. ! GCC_FOR_TARGET = ./xgcc -B./
  58.   
  59.   # This is used instead of ALL_CFLAGS when compiling with GCC_FOR_TARGET.
  60.   # It omits XCFLAGS, and specifies -B./.
  61. --- 102,115 ----
  62.   OLDAR = ar
  63.   
  64.   # Target to use when installing include directory.  Either
  65. ! # install-headers-tar install-headers-cpio, or install-headers-cp.
  66.   INSTALL_HEADERS_DIR = install-headers-tar
  67.   
  68.   # The GCC to use for compiling libgcc2.a, enquire, and cross-test.
  69.   # Usually the one we just built.
  70.   # Don't use this as a dependency--use $(GCC_PASSES) or $(GCC_PARTS).
  71. ! XGCC = xgcc
  72. ! GCC_FOR_TARGET = ./$(XGCC) -B./
  73.   
  74.   # This is used instead of ALL_CFLAGS when compiling with GCC_FOR_TARGET.
  75.   # It omits XCFLAGS, and specifies -B./.
  76. ***************
  77. *** 150,161 ****
  78.   srcdir = .
  79.   # Common prefix for installation directories.
  80.   # NOTE: This directory must exist when you start installation.
  81. ! prefix = /usr/local
  82.   # Directory in which to put localized header files. On the systems with
  83.   # gcc as the native cc, `local_prefix' may not be `prefix' which is
  84.   # `/usr'.
  85.   # NOTE: local_prefix *should not* default from prefix.
  86. ! local_prefix = /usr/local
  87.   # Directory in which to put host dependent programs and libraries
  88.   exec_prefix = $(prefix)
  89.   # Directory in which to put the executable for the command `gcc'
  90. --- 154,168 ----
  91.   srcdir = .
  92.   # Common prefix for installation directories.
  93.   # NOTE: This directory must exist when you start installation.
  94. ! prefix = /gnu
  95.   # Directory in which to put localized header files. On the systems with
  96.   # gcc as the native cc, `local_prefix' may not be `prefix' which is
  97.   # `/usr'.
  98. + # Similar considerations apply for toolkits located on non-writable storage,
  99. + # such as CD-ROM, where we need a completely separate place to put local
  100. + # include files.
  101.   # NOTE: local_prefix *should not* default from prefix.
  102. ! local_prefix = /gnu
  103.   # Directory in which to put host dependent programs and libraries
  104.   exec_prefix = $(prefix)
  105.   # Directory in which to put the executable for the command `gcc'
  106. ***************
  107. *** 620,626 ****
  108.       $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o xgcc gcc.o version.o $(LIBS)
  109.   
  110.   # Dump a specs file to make -B./ read these specs over installed ones.
  111. ! specs: xgcc
  112.       $(GCC_FOR_TARGET) -dumpspecs > specs
  113.   
  114.   # We do want to create an executable named `xgcc', so we can use it to
  115. --- 627,633 ----
  116.       $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o xgcc gcc.o version.o $(LIBS)
  117.   
  118.   # Dump a specs file to make -B./ read these specs over installed ones.
  119. ! specs: xgcc xgccv
  120.       $(GCC_FOR_TARGET) -dumpspecs > specs
  121.   
  122.   # We do want to create an executable named `xgcc', so we can use it to
  123. ***************
  124. *** 837,844 ****
  125.   # the second ar command tries to overwrite this file.  To avoid the error
  126.   # message from ar, we make sure all files are writable.
  127.       -(cd tmpcopy; chmod +w * > /dev/null 2>&1)
  128. !     (cd tmpcopy; $(AR) x ../$(LIBGCC2))
  129. !     (cd tmpcopy; $(AR) $(AR_FLAGS) ../tmplibgcc.a *.o)
  130.       rm -rf tmpcopy
  131.       -if $(RANLIB_TEST) ; then $(RANLIB) tmplibgcc.a; else true; fi
  132.   # Actually build it in tmplibgcc.a, then rename at end,
  133. --- 844,852 ----
  134.   # the second ar command tries to overwrite this file.  To avoid the error
  135.   # message from ar, we make sure all files are writable.
  136.       -(cd tmpcopy; chmod +w * > /dev/null 2>&1)
  137. ! # The "cd..; wait" makes sure that the lock on tmpcopy has time to disappear.
  138. !     (cd tmpcopy; $(AR) x ../$(LIBGCC2); cd ..; /c/wait 2)
  139. !     (cd tmpcopy; $(AR) $(AR_FLAGS) ../tmplibgcc.a *.o; cd ..; /c/wait 2)
  140.       rm -rf tmpcopy
  141.       -if $(RANLIB_TEST) ; then $(RANLIB) tmplibgcc.a; else true; fi
  142.   # Actually build it in tmplibgcc.a, then rename at end,
  143. ***************
  144. *** 899,908 ****
  145.       cd objc; \
  146.       $(MAKE) -f $${srcdir1}/objc/Makefile libobjc.a \
  147.         srcdir=$${srcdir1} tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
  148. !       GCC_FOR_TARGET="$${thisdir1}/xgcc -B$${thisdir1}/" \
  149.         GCC_CFLAGS="$(GCC_CFLAGS)"
  150.       -rm -f libobjc.a
  151. !     ln objc/libobjc.a . >/dev/null 2>&1 || cp objc/libobjc.a .
  152.       -if $(RANLIB_TEST) ; then $(RANLIB) libobjc.a; else true; fi
  153.   
  154.   # This is used by objc/Makefile if the user runs that directly.
  155. --- 907,916 ----
  156.       cd objc; \
  157.       $(MAKE) -f $${srcdir1}/objc/Makefile libobjc.a \
  158.         srcdir=$${srcdir1} tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
  159. !       GCC_FOR_TARGET="$${thisdir1}/$(XGCC) -B$${thisdir1}/" \
  160.         GCC_CFLAGS="$(GCC_CFLAGS)"
  161.       -rm -f libobjc.a
  162. !     cp objc/libobjc.a . >/dev/null 2>&1 || cp objc/libobjc.a .
  163.       -if $(RANLIB_TEST) ; then $(RANLIB) libobjc.a; else true; fi
  164.   
  165.   # This is used by objc/Makefile if the user runs that directly.
  166. ***************
  167. *** 912,918 ****
  168.       cd objc; \
  169.       $(MAKE) -f $$srcdir1/objc/Makefile libobjc.a \
  170.         srcdir=$$srcdir1 tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
  171. !       GCC_FOR_TARGET="$$thisdir1/xgcc -B$$thisdir1/" \
  172.         GCC_CFLAGS="$(GCC_CFLAGS)"
  173.   
  174.   # Compile two additional files that are linked with every program
  175. --- 920,926 ----
  176.       cd objc; \
  177.       $(MAKE) -f $$srcdir1/objc/Makefile libobjc.a \
  178.         srcdir=$$srcdir1 tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
  179. !       GCC_FOR_TARGET="$$thisdir1/$(XGCC) -B$$thisdir1/" \
  180.         GCC_CFLAGS="$(GCC_CFLAGS)"
  181.   
  182.   # Compile two additional files that are linked with every program
  183. ***************
  184. *** 963,969 ****
  185.   # To make a configuration always use collect2, set USE_COLLECT2 to ld.
  186.   ld: collect2
  187.       rm -f ld
  188. !     ln collect2 ld
  189.   
  190.   collect2 : collect2.o version.o $(LIBDEPS)
  191.   # Don't try modifying collect2 (aka ld) in place--it might be linking this.
  192. --- 971,977 ----
  193.   # To make a configuration always use collect2, set USE_COLLECT2 to ld.
  194.   ld: collect2
  195.       rm -f ld
  196. !     $(HARDLINK) collect2 ld
  197.   
  198.   collect2 : collect2.o version.o $(LIBDEPS)
  199.   # Don't try modifying collect2 (aka ld) in place--it might be linking this.
  200. ***************
  201. *** 1476,1482 ****
  202.   # Making the preprocessor
  203.   cpp: cccp
  204.       -rm -f cpp
  205. !     ln cccp cpp
  206.   cccp: cccp.o cexp.o version.o $(LIBDEPS)
  207.       $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o cccp cccp.o cexp.o version.o $(LIBS)
  208.   cexp.o: $(srcdir)/cexp.c $(CONFIG_H)
  209. --- 1484,1490 ----
  210.   # Making the preprocessor
  211.   cpp: cccp
  212.       -rm -f cpp
  213. !     $(HARDLINK) cccp cpp
  214.   cccp: cccp.o cexp.o version.o $(LIBDEPS)
  215.       $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o cccp cccp.o cexp.o version.o $(LIBS)
  216.   cexp.o: $(srcdir)/cexp.c $(CONFIG_H)
  217. ***************
  218. *** 1636,1642 ****
  219.       cd objc; \
  220.       $(MAKE) -f $${srcdir1}/objc/Makefile copy-headers \
  221.       srcdir=$${srcdir1} tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
  222. !     GCC_FOR_TARGET="$${thisdir1}/xgcc -B$${thisdir1}/" \
  223.       GCC_CFLAGS="$(GCC_CFLAGS)" incinstalldir=$${thisdir1}/include
  224.       touch objc-headers
  225.   
  226. --- 1644,1650 ----
  227.       cd objc; \
  228.       $(MAKE) -f $${srcdir1}/objc/Makefile copy-headers \
  229.       srcdir=$${srcdir1} tooldir=$(tooldir) AR="$(AR)" AR_FLAGS="$(AR_FLAGS)" \
  230. !     GCC_FOR_TARGET="$${thisdir1}/$(XGCC) -B$${thisdir1}/" \
  231.       GCC_CFLAGS="$(GCC_CFLAGS)" incinstalldir=$${thisdir1}/include
  232.       touch objc-headers
  233.   
  234. ***************
  235. *** 1811,1816 ****
  236. --- 1819,1825 ----
  237.       -rm -f Makefile *.oaux
  238.       -rm -fr stage1 stage2 stage3 stage4
  239.       -rm -f */stage1 */stage2 */stage3 */stage4
  240. +     -rm -f cp-parse.output
  241.       -rm -f objc-parse.output
  242.       -rm -f c-parse.output
  243.   
  244. ***************
  245. *** 1934,1940 ****
  246.         rm -f $(bindir)/gcc; \
  247.         $(INSTALL_PROGRAM) xgcc $(bindir)/gcc; \
  248.         rm -f $(bindir)/$(target)-gcc-1; \
  249. !       ln $(bindir)/gcc $(bindir)/$(target)-gcc-1; \
  250.         mv $(bindir)/$(target)-gcc-1 $(bindir)/$(target)-gcc; \
  251.       fi
  252.   # Install protoize if it was compiled.
  253. --- 1943,1949 ----
  254.         rm -f $(bindir)/gcc; \
  255.         $(INSTALL_PROGRAM) xgcc $(bindir)/gcc; \
  256.         rm -f $(bindir)/$(target)-gcc-1; \
  257. !       $(HARDLINK) $(bindir)/gcc $(bindir)/$(target)-gcc-1; \
  258.         mv $(bindir)/$(target)-gcc-1 $(bindir)/$(target)-gcc; \
  259.       fi
  260.   # Install protoize if it was compiled.
  261. ***************
  262. *** 2010,2016 ****
  263.           dest=`ls -ld $(libsubdir)/include/$$i | sed -n 's/.*-> //p'`; \
  264.           if expr "$$dest" : "$$dir.*" > /dev/null; then \
  265.             rm -f $(libsubdir)/include/$$i; \
  266. !           ln -s `echo $$i | sed "s|/[^/]*|/..|g" | sed 's|/..$$||'``echo "$$dest" | sed "s|$$dir||"` $(libsubdir)/include/$$i; \
  267.           fi; \
  268.         done; \
  269.       fi
  270. --- 2019,2025 ----
  271.           dest=`ls -ld $(libsubdir)/include/$$i | sed -n 's/.*-> //p'`; \
  272.           if expr "$$dest" : "$$dir.*" > /dev/null; then \
  273.             rm -f $(libsubdir)/include/$$i; \
  274. !           $(HARDLINK) -s `echo $$i | sed "s|/[^/]*|/..|g" | sed 's|/..$$||'``echo "$$dest" | sed "s|$$dir||"` $(libsubdir)/include/$$i; \
  275.           fi; \
  276.         done; \
  277.       fi
  278. ***************
  279. *** 2033,2038 ****
  280. --- 2042,2051 ----
  281.   install-headers-cpio: stmp-headers $(STMP_FIXPROTO) install-include-dir
  282.       (cd include; find . -print) | (cd include; cpio -pdum $(libsubdir)/include)
  283.   
  284. + # Install the include directory using simple recursive copy.
  285. + install-headers-cp: stmp-headers install-include-dir
  286. +     cd include; cp -r . $(libsubdir)/include
  287.   # Put assert.h where it won't override GNU libc's assert.h.
  288.   # It goes in a dir that is searched after GNU libc's headers;
  289.   # thus, the following conditionals are no longer needed.
  290. ***************
  291. *** 2122,2128 ****
  292.       mkdir tmp/ginclude
  293.       mkdir tmp/objc
  294.       for file in *[0-9a-zA-Z+]; do \
  295. !       ln $$file tmp > /dev/null 2>&1 || cp $$file tmp; \
  296.       done
  297.       cd config; \
  298.       for file in *[0-9a-zA-Z+]; do \
  299. --- 2135,2141 ----
  300.       mkdir tmp/ginclude
  301.       mkdir tmp/objc
  302.       for file in *[0-9a-zA-Z+]; do \
  303. !       $(HARDLINK) $$file tmp > /dev/null 2>&1 || cp $$file tmp; \
  304.       done
  305.       cd config; \
  306.       for file in *[0-9a-zA-Z+]; do \
  307. ***************
  308. *** 2130,2141 ****
  309.           mkdir ../tmp/config/$$file; \
  310.           cd $$file; \
  311.           for subfile in *[0-9a-zA-Z+]; do \
  312. !           ln $$subfile ../../tmp/config/$$file >/dev/null 2>&1 \
  313.             || cp $$subfile ../../tmp/config/$$file; \
  314.           done; \
  315.           cd ..; \
  316.         else \
  317. !         ln $$file ../tmp/config >/dev/null 2>&1 \
  318.           || cp $$file ../tmp/config; \
  319.         fi; \
  320.       done
  321. --- 2143,2154 ----
  322.           mkdir ../tmp/config/$$file; \
  323.           cd $$file; \
  324.           for subfile in *[0-9a-zA-Z+]; do \
  325. !           $(HARDLINK) $$subfile ../../tmp/config/$$file >/dev/null 2>&1 \
  326.             || cp $$subfile ../../tmp/config/$$file; \
  327.           done; \
  328.           cd ..; \
  329.         else \
  330. !         $(HARDLINK) $$file ../tmp/config >/dev/null 2>&1 \
  331.           || cp $$file ../tmp/config; \
  332.         fi; \
  333.       done
  334. ***************
  335. *** 2145,2153 ****
  336.       done
  337.       cd objc; \
  338.       for file in *[0-9a-zA-Z+]; do \
  339. !       ln $$file ../tmp/objc >/dev/null 2>&1 || cp $$file ../tmp/objc; \
  340.       done
  341. !     ln .gdbinit tmp
  342.   
  343.   # Finish making `distdir', after the languages have done their thing.
  344.   distdir-finish:
  345. --- 2158,2166 ----
  346.       done
  347.       cd objc; \
  348.       for file in *[0-9a-zA-Z+]; do \
  349. !       $(HARDLINK) $$file ../tmp/objc >/dev/null 2>&1 || cp $$file ../tmp/objc; \
  350.       done
  351. !     $(HARDLINK) .gdbinit tmp
  352.   
  353.   # Finish making `distdir', after the languages have done their thing.
  354.   distdir-finish:
  355. ***************
  356. *** 2175,2191 ****
  357.   # in the intended test directory to make it a suitable test directory.
  358.   # THIS IS OBSOLETE; use the -srcdir operand in configure instead. 
  359.   maketest:
  360. !     ln -s $(DIR)/*.[chy] .
  361. !     ln -s $(DIR)/configure .
  362. !     ln -s $(DIR)/*.def .
  363.       -rm -f =*
  364. !     ln -s $(DIR)/.gdbinit .
  365. !     ln -s $(DIR)/$(FIXINCLUDES) .
  366. !     -ln -s $(DIR)/bison.simple .
  367. !     ln -s $(DIR)/config .
  368. !     ln -s $(DIR)/move-if-change .
  369.   # The then and else were swapped to avoid a problem on Ultrix.
  370. !     if [ ! -f Makefile ] ; then ln -s $(DIR)/Makefile .; else false; fi
  371.       -rm tm.h aux-output.c config.h md
  372.       make clean
  373.   # You must then run config to set up for compilation.
  374. --- 2188,2204 ----
  375.   # in the intended test directory to make it a suitable test directory.
  376.   # THIS IS OBSOLETE; use the -srcdir operand in configure instead. 
  377.   maketest:
  378. !     $(SYMLINK) $(DIR)/*.[chy] .
  379. !     $(SYMLINK) $(DIR)/configure .
  380. !     $(SYMLINK) $(DIR)/*.def .
  381.       -rm -f =*
  382. !     $(SYMLINK) $(DIR)/.gdbinit .
  383. !     $(SYMLINK) $(DIR)/$(FIXINCLUDES) .
  384. !     -$(SYMLINK) $(DIR)/bison.simple .
  385. !     $(SYMLINK) $(DIR)/config .
  386. !     $(SYMLINK) $(DIR)/move-if-change .
  387.   # The then and else were swapped to avoid a problem on Ultrix.
  388. !     if [ ! -f Makefile ] ; then $(SYMLINK) $(DIR)/Makefile .; else false; fi
  389.       -rm tm.h aux-output.c config.h md
  390.       make clean
  391.   # You must then run config to set up for compilation.
  392. ***************
  393. *** 2201,2217 ****
  394.   # To prevent `make install' from compiling alloca.o and then relinking cc1
  395.   # because alloca.o is newer, we permit these recursive makes to compile
  396.   # alloca.o.  Then cc1 is newer, so it won't have to be relinked.
  397. !     $(MAKE) CC="stage1/xgcc -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  398.       $(MAKE) stage2
  399. !     $(MAKE) CC="stage2/xgcc -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  400.   
  401.   bootstrap2: force
  402. !     $(MAKE) CC="stage1/xgcc -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  403.       $(MAKE) stage2
  404. !     $(MAKE) CC="stage2/xgcc -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  405.   
  406.   bootstrap3: force
  407. !     $(MAKE) CC="stage2/xgcc -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  408.   
  409.   # Compare the object files in the current directory with those in the
  410.   # stage2 directory.
  411. --- 2214,2230 ----
  412.   # To prevent `make install' from compiling alloca.o and then relinking cc1
  413.   # because alloca.o is newer, we permit these recursive makes to compile
  414.   # alloca.o.  Then cc1 is newer, so it won't have to be relinked.
  415. !     $(MAKE) CC="stage1/$(XGCC) -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  416.       $(MAKE) stage2
  417. !     $(MAKE) CC="stage2/$(XGCC) -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  418.   
  419.   bootstrap2: force
  420. !     $(MAKE) CC="stage1/$(XGCC) -Bstage1/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  421.       $(MAKE) stage2
  422. !     $(MAKE) CC="stage2/$(XGCC) -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  423.   
  424.   bootstrap3: force
  425. !     $(MAKE) CC="stage2/$(XGCC) -Bstage2/" CFLAGS="$(BOOT_CFLAGS)" LDFLAGS="$(BOOT_LDFLAGS)" libdir=$(libdir) LANGUAGES="$(LANGUAGES)"
  426.   
  427.   # Compare the object files in the current directory with those in the
  428.   # stage2 directory.
  429. ***************
  430. *** 2286,2292 ****
  431.       -if [ -d stage1 ] ; then true ; else mkdir stage1 ; fi
  432.       -for dir in . $(SUBDIRS) ; \
  433.        do \
  434. !        if [ -d stage1/$$dir ] ; then true ; else mkdir stage1/$$dir ; fi \
  435.        done
  436.       -mv $(STAGESTUFF) stage1
  437.       -rm -f stage1/libgcc.a
  438. --- 2299,2305 ----
  439.       -if [ -d stage1 ] ; then true ; else mkdir stage1 ; fi
  440.       -for dir in . $(SUBDIRS) ; \
  441.        do \
  442. !        if [ -d stage1/$$dir ] ; then true ; else mkdir stage1/$$dir ; fi; \
  443.        done
  444.       -mv $(STAGESTUFF) stage1
  445.       -rm -f stage1/libgcc.a
  446. ***************
  447. *** 2298,2304 ****
  448.       -if [ -d stage2 ] ; then true ; else mkdir stage2 ; fi
  449.       -for dir in . $(SUBDIRS) ; \
  450.        do \
  451. !        if [ -d stage2/$$dir ] ; then true ; else mkdir stage2/$$dir ; fi \
  452.        done
  453.       -mv $(STAGESTUFF) stage2
  454.       -rm -f stage2/libgcc.a
  455. --- 2311,2317 ----
  456.       -if [ -d stage2 ] ; then true ; else mkdir stage2 ; fi
  457.       -for dir in . $(SUBDIRS) ; \
  458.        do \
  459. !        if [ -d stage2/$$dir ] ; then true ; else mkdir stage2/$$dir ; fi; \
  460.        done
  461.       -mv $(STAGESTUFF) stage2
  462.       -rm -f stage2/libgcc.a
  463. ***************
  464. *** 2310,2316 ****
  465.       -if [ -d stage3 ] ; then true ; else mkdir stage3 ; fi
  466.       -for dir in . $(SUBDIRS) ; \
  467.        do \
  468. !        if [ -d stage3/$$dir ] ; then true ; else mkdir stage3/$$dir ; fi \
  469.        done
  470.       -mv $(STAGESTUFF) stage3
  471.       -rm -f stage3/libgcc.a
  472. --- 2323,2329 ----
  473.       -if [ -d stage3 ] ; then true ; else mkdir stage3 ; fi
  474.       -for dir in . $(SUBDIRS) ; \
  475.        do \
  476. !        if [ -d stage3/$$dir ] ; then true ; else mkdir stage3/$$dir ; fi; \
  477.        done
  478.       -mv $(STAGESTUFF) stage3
  479.       -rm -f stage3/libgcc.a
  480. ***************
  481. *** 2322,2328 ****
  482.       -if [ -d stage4 ] ; then true ; else mkdir stage4 ; fi
  483.       -for dir in . $(SUBDIRS) ; \
  484.        do \
  485. !        if [ -d stage4/$$dir ] ; then true ; else mkdir stage4/$$dir ; fi \
  486.        done
  487.       -mv $(STAGESTUFF) stage4
  488.       -rm -f stage4/libgcc.a
  489. --- 2335,2341 ----
  490.       -if [ -d stage4 ] ; then true ; else mkdir stage4 ; fi
  491.       -for dir in . $(SUBDIRS) ; \
  492.        do \
  493. !        if [ -d stage4/$$dir ] ; then true ; else mkdir stage4/$$dir ; fi; \
  494.        done
  495.       -mv $(STAGESTUFF) stage4
  496.       -rm -f stage4/libgcc.a
  497. diff -rc --new-file gcc-2.6.0/Product-Info /gnu/src/amiga/gcc-2.6.0/Product-Info
  498. *** gcc-2.6.0/Product-Info    Thu Jan  1 00:00:00 1970
  499. --- /gnu/src/amiga/gcc-2.6.0/Product-Info    Sat Sep  3 12:47:57 1994
  500. ***************
  501. *** 0 ****
  502. --- 1,22 ----
  503. + .name
  504. + gcc
  505. + .fullname
  506. + GNU C/C++/Objective-C compiler
  507. + .type
  508. + Compiler
  509. + .short
  510. + GNU C/C++/Obj-C compilers.
  511. + .description
  512. + The GNU C, C++, and Objective C compilers.  Includes all support for
  513. + compiling C, C++ and Objective C, including a run-time library for
  514. + Objective C.
  515. + .version
  516. + 2.6.0
  517. + .author
  518. + Free Software Foundation
  519. + .requirements
  520. + Amiga binaries require ixemul.library.
  521. + .distribution
  522. + GNU Public License
  523. + .described-by
  524. + Fred Fish (fnf@amigalib.com)
  525. diff -rc --new-file gcc-2.6.0/calls.c /gnu/src/amiga/gcc-2.6.0/calls.c
  526. *** gcc-2.6.0/calls.c    Wed Jul 13 11:03:16 1994
  527. --- /gnu/src/amiga/gcc-2.6.0/calls.c    Fri Jul 29 09:39:08 1994
  528. ***************
  529. *** 2153,2158 ****
  530. --- 2153,2166 ----
  531.   
  532.     argvec = (struct arg *) alloca (nargs * sizeof (struct arg));
  533.   
  534. + #if defined (__amigados__)
  535. + /* how would you do this RIGHT ?? fake a DECL node? dunno... */
  536. + #ifdef ENCODE_SECTION_INFO
  537. +   /* mark it as a function (to be in the text section that is) */
  538. +   SYMBOL_REF_FLAG (fun) = 1;
  539. + #endif
  540. + #endif
  541.     INIT_CUMULATIVE_ARGS (args_so_far, NULL_TREE, fun);
  542.   
  543.     args_size.constant = 0;
  544. diff -rc --new-file gcc-2.6.0/cccp.c /gnu/src/amiga/gcc-2.6.0/cccp.c
  545. *** gcc-2.6.0/cccp.c    Mon Jul 11 19:07:09 1994
  546. --- /gnu/src/amiga/gcc-2.6.0/cccp.c    Fri Jul 29 09:39:15 1994
  547. ***************
  548. *** 39,44 ****
  549. --- 39,60 ----
  550.   #include "config.h"
  551.   #endif /* not EMACS */
  552.   
  553. + #ifdef amigados
  554. + /* Since cpp uses alloca to store all its read files, this is quite deadly
  555. +    on a system with non-automatic stackgrowth like amigados, so we better
  556. +    turn it off now.  Normally alloca is #defined to __builtin_alloca, so
  557. +    undefining it causes an external alloca to be used.
  558. +    Note that it's not wise to generally inhibit __builtin_alloca, since
  559. +    using the generic emulator entitels a serious (!) speed penalty, and
  560. +    it's bad enough that we have to live with it in cccp, don't make cc1
  561. +    unbearably slow as well... */
  562. + #undef alloca
  563. + static int amigados_abs_filename ();
  564. + #endif
  565.   #ifndef STANDARD_INCLUDE_DIR
  566.   #define STANDARD_INCLUDE_DIR "/usr/include"
  567.   #endif
  568. ***************
  569. *** 1958,1968 ****
  570.         int len;
  571.   
  572.         /* Discard all directory prefixes from filename.  */
  573.         if ((q = rindex (in_fname, '/')) != NULL)
  574.       ++q;
  575.         else
  576.       q = in_fname;
  577.         /* Copy remainder to mungable area.  */
  578.         p = (char *) alloca (strlen(q) + 8);
  579.         strcpy (p, q);
  580. --- 1974,1987 ----
  581.         int len;
  582.   
  583.         /* Discard all directory prefixes from filename.  */
  584. + #ifdef FILE_NAME_NONDIRECTORY
  585. +       q = FILE_NAME_NONDIRECTORY (in_fname);
  586. + #else
  587.         if ((q = rindex (in_fname, '/')) != NULL)
  588.       ++q;
  589.         else
  590.       q = in_fname;
  591. ! #endif
  592.         /* Copy remainder to mungable area.  */
  593.         p = (char *) alloca (strlen(q) + 8);
  594.         strcpy (p, q);
  595. ***************
  596. *** 3730,3736 ****
  597. --- 3749,3760 ----
  598.   
  599.         if (!no_output && already_output == 0
  600.         && (kt->pass_thru
  601. + /* Phil.B 27-Mar-93 not quiet sure to keep this old fix */      
  602. + #ifdef maybe_amigados
  603. +           || ((kt->type == T_DEFINE || kt->type == T_UNDEF)
  604. + #else
  605.             || (kt->type == T_DEFINE
  606. + #endif /* amigados */
  607.             && (dump_macros == dump_names
  608.                 || dump_macros == dump_definitions)))) {
  609.           int len;
  610. ***************
  611. *** 4071,4076 ****
  612. --- 4095,4112 ----
  613.           search_start = dsp;
  614.   #ifndef VMS
  615.           ep = rindex (nam, '/');
  616. + #ifdef amigados
  617. +         /* amigados uses unix-style directory-filename separation, but
  618. +            has VMS-style logicals as well */
  619. +         if (ep == NULL) 
  620. +           {
  621. +         ep = rindex (nam, ':');
  622. +         /* a ':' is part of the directory name, a '/' isn't ! */
  623. +             if (ep != NULL) ep++;
  624. +           }
  625. + #endif /* amigados */
  626.   #else                /* VMS */
  627.           ep = rindex (nam, ']');
  628.           if (ep == NULL) ep = rindex (nam, '>');
  629. ***************
  630. *** 4172,4178 ****
  631. --- 4208,4218 ----
  632.   
  633.     /* If specified file name is absolute, just open it.  */
  634.   
  635. + #ifndef amigados
  636.     if (*fbeg == '/') {
  637. + #else
  638. +   if (amigados_abs_filename (fbeg, flen)) {
  639. + #endif
  640.       strncpy (fname, fbeg, flen);
  641.       fname[flen] = 0;
  642.       if (redundant_include_p (fname))
  643. ***************
  644. *** 4195,4200 ****
  645. --- 4235,4244 ----
  646.       if (searchptr->fname[0] == 0)
  647.         continue;
  648.       strcpy (fname, searchptr->fname);
  649. + #ifdef amigados
  650. +     if (fname[strlen (fname) - 1] != ':')
  651. + #endif
  652.       strcat (fname, "/");
  653.       fname[strlen (fname) + flen] = 0;
  654.         } else {
  655. ***************
  656. *** 9391,9399 ****
  657.   perror_with_name (name)
  658.        char *name;
  659.   {
  660.     fprintf (stderr, "%s: ", progname);
  661. !   if (errno < sys_nerr)
  662. !     fprintf (stderr, "%s: %s\n", name, sys_errlist[errno]);
  663.     else
  664.       fprintf (stderr, "%s: undocumented I/O error\n", name);
  665.     errors++;
  666. --- 9435,9445 ----
  667.   perror_with_name (name)
  668.        char *name;
  669.   {
  670. +   int error = errno;
  671.     fprintf (stderr, "%s: ", progname);
  672. !   if (error < sys_nerr)
  673. !     fprintf (stderr, "%s: %s\n", name, sys_errlist[error]);
  674.     else
  675.       fprintf (stderr, "%s: undocumented I/O error\n", name);
  676.     errors++;
  677. ***************
  678. *** 9802,9804 ****
  679. --- 9848,9874 ----
  680.     return dst;
  681.   }
  682.   #endif /* VMS */
  683. + #ifdef amigados
  684. + /* This function returns whether the LEN characters long filename FNAME 
  685. +    is an absolute path specification. */
  686. + static int
  687. + amigados_abs_filename (fname, len)
  688. +      char *fname;
  689. +      int len;
  690. + {
  691. +   /* we're using ixemul.library, which treats `/foo' as `foo:', so 
  692. +      fname[0] is to be considered absolute as well */
  693. +   if (fname[0] == '/')
  694. +     return 1;
  695. +   /* else do an index() on fname, but one which is limited to len characters */
  696. +   while (*fname && *fname != ':' && len) 
  697. +     fname++, len--;
  698. +   return *fname == ':';
  699. + }
  700. + #endif /* amigados */
  701. diff -rc --new-file gcc-2.6.0/config/m68k/amigados.c /gnu/src/amiga/gcc-2.6.0/config/m68k/amigados.c
  702. *** gcc-2.6.0/config/m68k/amigados.c    Thu Jan  1 00:00:00 1970
  703. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/amigados.c    Fri Jul 29 09:39:16 1994
  704. ***************
  705. *** 0 ****
  706. --- 1,158 ----
  707. + /* Definitions of target machine for GNU compiler.  amiga 68000/68020 version.
  708. +    Copyright (C) 1992 Free Software Foundation, Inc.
  709. +    Contributed by Markus M. Wild (wild@amiga.physik.unizh.ch).
  710. + This file is part of GNU CC.
  711. + GNU CC is free software; you can redistribute it and/or modify
  712. + it under the terms of the GNU General Public License as published by
  713. + the Free Software Foundation; either version 2, or (at your option)
  714. + any later version.
  715. + GNU CC is distributed in the hope that it will be useful,
  716. + but WITHOUT ANY WARRANTY; without even the implied warranty of
  717. + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  718. + GNU General Public License for more details.
  719. + You should have received a copy of the GNU General Public License
  720. + along with GNU CC; see the file COPYING.  If not, write to
  721. + the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */
  722. + #include "m68k/m68k.c"
  723. + /* Does operand (which is a symbolic_operand) live in text space? If
  724. +    so SYMBOL_REF_FLAG, which is set by ENCODE_SECTION_INFO, will be true.
  725. +    This function is used in base relative code generation. */
  726. + int
  727. + read_only_operand (operand)
  728. +      rtx operand;
  729. + {
  730. +   if (GET_CODE (operand) == CONST)
  731. +     operand = XEXP (XEXP (operand, 0), 0);
  732. +   if (GET_CODE (operand) == SYMBOL_REF)
  733. +     return SYMBOL_REF_FLAG (operand) || CONSTANT_POOL_ADDRESS_P (operand);
  734. +   return 1;
  735. + }
  736. + /* the rest of the file is to implement AmigaDOS specific keywords some day.
  737. +    The approach used so far used __attribute__ for this, but this required
  738. +    changes to c-parse.y as well as if we'd use the common keywords used
  739. +    on commercial AmigaDOS C-compilers as well. So in the future I'll probably
  740. +    switch to __saveds and __interrupt keywords as well.
  741. +    The rest of this file is currently ignored, because it's no longer
  742. +    working with the current gcc version. */
  743. + #if not_yet_working
  744. + #include "tree.h"
  745. + struct attribute {
  746. +   tree ident;
  747. +   int  saveds : 1,
  748. +        interrupt : 1;
  749. + };
  750. + static struct attribute *a_tab = 0;
  751. + static int a_index, a_size;
  752. + void
  753. + add_attr_entry (attr)
  754. +     struct attribute *attr;
  755. + {
  756. +   if (! a_tab)
  757. +     {
  758. +       a_size = 10;
  759. +       a_index = 0;
  760. +       a_tab  = (struct attribute *) xmalloc (a_size * sizeof (struct attribute));
  761. +     }
  762. +   if (a_index == a_size)
  763. +     {
  764. +       a_size <<= 1;
  765. +       a_tab = (struct attribute *) xrealloc (a_tab, a_size * sizeof (struct attribute));
  766. +     }
  767. +   a_tab[a_index++] = *attr;
  768. + }
  769. + void
  770. + attr_do_saveds (function_ident)
  771. +       tree function_ident;
  772. + {
  773. +   struct attribute attr, *a;
  774. +   int i;
  775. +   for (i = 0, a = a_tab; i < a_index; i++, a++)
  776. +     if (a->ident == function_ident)
  777. +       {
  778. +     a->saveds = 1;
  779. +     return;
  780. +       }
  781. +   /* create a new entry for this function */
  782. +   attr.ident     = function_ident;
  783. +   attr.saveds    = 1;
  784. +   attr.interrupt = 0;
  785. +   add_attr_entry (&attr);
  786. + }
  787. + void
  788. + attr_do_interrupt (function_ident)
  789. +     tree function_ident;
  790. + {
  791. +   struct attribute attr, *a;
  792. +   int i;
  793. +   for (i = 0, a = a_tab; i < a_index; i++, a++)
  794. +     if (a->ident == function_ident)
  795. +       {
  796. +     /* __interrupt implies __saveds */
  797. +     a->saveds    = 1;
  798. +     a->interrupt = 1;
  799. +     return;
  800. +       }
  801. +   /* create a new entry for this function */
  802. +   attr.ident     = function_ident;
  803. +   attr.saveds     = 1;
  804. +   attr.interrupt = 1;
  805. +   add_attr_entry (&attr);
  806. + }
  807. + int
  808. + attr_does_saveds (function_name)
  809. +     char *function_name;
  810. + {
  811. +   tree ident = get_identifier (function_name);
  812. +   struct attribute *attr;
  813. +   int i;
  814. +   
  815. +   for (i = 0, attr = a_tab; i < a_index; i++, attr++)
  816. +     if (attr->ident == ident)
  817. +       return attr->saveds;
  818. +   return 0;
  819. + }
  820. + int
  821. + attr_does_interrupt (function_name)
  822. +     char *function_name;
  823. + {
  824. +   tree ident = get_identifier (function_name);
  825. +   struct attribute *attr;
  826. +   int i;
  827. +   
  828. +   for (i = 0, attr = a_tab; i < a_index; i++, attr++)
  829. +     if (attr->ident == ident)
  830. +       return attr->interrupt;
  831. +   return 0;
  832. + }
  833. + #endif
  834. diff -rc --new-file gcc-2.6.0/config/m68k/amigados.h /gnu/src/amiga/gcc-2.6.0/config/m68k/amigados.h
  835. *** gcc-2.6.0/config/m68k/amigados.h    Thu Jan  1 00:00:00 1970
  836. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/amigados.h    Sun Sep  4 09:01:57 1994
  837. ***************
  838. *** 0 ****
  839. --- 1,418 ----
  840. + /* Definitions of target machine for GNU compiler.  amiga 68000/68020 version.
  841. +    Copyright (C) 1992 Free Software Foundation, Inc.
  842. +    Contributed by Markus M. Wild (wild@amiga.physik.unizh.ch).
  843. + This file is part of GNU CC.
  844. + GNU CC is free software; you can redistribute it and/or modify
  845. + it under the terms of the GNU General Public License as published by
  846. + the Free Software Foundation; either version 2, or (at your option)
  847. + any later version.
  848. + GNU CC is distributed in the hope that it will be useful,
  849. + but WITHOUT ANY WARRANTY; without even the implied warranty of
  850. + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  851. + GNU General Public License for more details.
  852. + You should have received a copy of the GNU General Public License
  853. + along with GNU CC; see the file COPYING.  If not, write to
  854. + the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */
  855. + #include "m68k/m68k.h"
  856. + /* See m68k.h for bits in TARGET_DEFAULT.
  857. +    0 means 68000, no hardware fpu (68881/68882/68040).
  858. +    7 means 68020 (or higher) with hardware fpu.  */
  859. + #ifndef TARGET_DEFAULT
  860. + #define TARGET_DEFAULT 0
  861. + #endif
  862. + /* Define __HAVE_68881__ in preprocessor according to the -m flags.
  863. +    This will control the use of inline 68881 insns in certain macros.
  864. +    Also inform the program which CPU this is for.  */
  865. + #if TARGET_DEFAULT & 02
  866. + /* -m68881 is the default */
  867. + #define CPP_SPEC \
  868. + "%{!msoft-float:-D__HAVE_68881__ }\
  869. + %{!ansi:%{m68000:-Dmc68010}%{mc68000:-Dmc68010}%{m68030:-Dmc68030}%{mc68030:-Dmc68030}%{m68040:-Dmc68040}\
  870. + %{mc68040:-Dmc68040}%{!mc68000:%{!m68000:-Dmc68020}}}"
  871. + #else
  872. + /* -msoft-float is the default, assume -mc68000 as well */
  873. + #define CPP_SPEC \
  874. + "%{m68881:-D__HAVE_68881__ }\
  875. + %{!ansi:%{m68020:-Dmc68020}%{mc68020:-Dmc68020}%{m68030:-Dmc68030}%{mc68030:-Dmc68030}%{m68040:-Dmc68040}\
  876. + %{mc68040:-Dmc68040}%{!mc68020:%{!m68020:%{!mc68030:%{!m68030:%{!mc68040:%{!m68040:-Dmc68010}}}}}}}"
  877. + /* Don't try using XFmode since we don't have appropriate runtime software
  878. +    support.  */
  879. + #undef LONG_DOUBLE_TYPE_SIZE
  880. + #define LONG_DOUBLE_TYPE_SIZE 64
  881. + #endif
  882. + /* -m68000 requires special flags to the assembler.  */
  883. + #if TARGET_DEFAULT & 01
  884. + #define ASM_SPEC \
  885. +  "%{m68000:-mc68010}%{mc68000:-mc68010}%{mc68030:-mc68030}%{m68030:-mc68030}%{mc68040:-mc68040}%{m68040:-mc68040}\
  886. + %{!mc68000:%{!m68000:%{!mc68030:%{!m68030:%{!mc68040:%{!m68040:-mc68020}}}}}} %{msmall-code:-l} "
  887. + #else
  888. + #define ASM_SPEC \
  889. +  "%{m68020:-mc68020}%{mc68020:-mc68020}%{mc68030:-mc68030}%{m68030:-mc68030}%{mc68040:-mc68040}\
  890. + %{m68040:-mc68040}%{!mc68020:%{!m68020:%{!mc68030:%{!m68030:%{!mc68040:%{!m68040:-mc68010}}}}}} %{msmall-code:-l} "
  891. + #endif
  892. + /* amiga/amigados are the new "standard" defines for the Amiga, MCH_AMIGA
  893. +  * was used before and is included for compatibility reasons */
  894. + #define CPP_PREDEFINES "-Dmc68000 -Damiga -Damigados -DMCH_AMIGA -DAMIGA"
  895. + /* Choose the right startup file, depending on whether we use base relative
  896. +    code, base relative code with automatic relocation (-resident), or plain
  897. +    crt0.o. 
  898. +   
  899. +    Profiling is currently only available for plain startup.
  900. +    mcrt0.o does not (yet) exist. */
  901. + #define STARTFILE_SPEC \
  902. +   "%{!noixemul:%{resident:rcrt0.o%s}%{!resident:%{!fbaserel:%{pg:gcrt0.o%s}%{!pg:%{p:mcrt0.o%s}%{!p:crt0.o%s}}}\
  903. + %{fbaserel:%{pg:bgcrt0.o%s}%{!pg:%{p:bmcrt0.o%s}%{!p:bcrt0.o%s}}}}}\
  904. + %{noixemul:%{resident:/gnu/lib/libnix/nrcrt0.o%s}%{!resident:%{fbaserel:/gnu/lib/libnix/nbcrt0.o%s}\
  905. + %{!fbaserel:/gnu/lib/libnix/ncrt0.o%s}}}"
  906. + #define ENDFILE_SPEC "%{noixemul:-lstubs}"
  907. + /* Automatically search libamiga.a for AmigaDOS specific functions.  Note
  908. +    that we first search the standard C library to resolve as much as
  909. +    possible from there, since it has names that are duplicated in libamiga.a
  910. +    which we *don't* want from there.  Then search the standard C library
  911. +    again to resolve any references that libamiga.a might have generated.
  912. +    This may only be a temporary solution since it might be better to simply
  913. +    remove the things from libamiga.a that should be pulled in from libc.a
  914. +    instead, which would eliminate the first reference to libc.a. */
  915. + #define LIB_SPEC "%{!noixemul:%{!p:%{!pg:-lc -lamiga -lc}}%{p:-lc_p -lamiga -lc_p}%{pg:-lc_p -lamiga -lc_p}}%{noixemul:-lnixmain -lnix -lamiga}"
  916. + /* if debugging, tell the linker to output amiga-hunk symbols *and* a BSD
  917. +    compatible debug hunk (which will probably change in the future, it's not
  918. +    tremendously useful in its current state). */
  919. + #define LINK_SPEC "%{!noixemul:%{g:-amiga-debug-hunk} %{fbaserel:-databss-together}\
  920. + %{resident:-databss-together -datadata-reloc -fl libb} %{m68020:-fl lib020} %{m68030:-fl lib020} %{m68040:-fl 68020}}\
  921. + %{noixemul:%{g:-amiga-debug-hunk} %{resident:-databss-together -datadata-reloc -fl libnix/libb }\
  922. + %{!resident:%{fbaserel:-databss-together -fl libnix/libb }%{!fbaserel:-fl libnix}}}"
  923. + #define CC1_SPEC "%{m68040:-mbitfield}%{mc68040:-mbitfield}%{resident:-fbaserel} "
  924. + #define CC1PLUS_SPEC "%{m68040:-mbitfield}%{mc68040:-mbitfield}%{resident:-fbaserel} "
  925. + /* Omit frame pointer at high optimization levels. (This doesn't hurt, since
  926. +    GDB doesn't work under AmigaDOS at the moment anyway..) */
  927. +   
  928. + #define OPTIMIZATION_OPTIONS(OPTIMIZE) \
  929. + {                                  \
  930. +   if (OPTIMIZE >= 2)                         \
  931. +     flag_omit_frame_pointer = 1;                \
  932. + }
  933. + /* provide a dummy entry for the small-code switch. This is currently only
  934. +    needed by the assembler (explanations: m68k.h), but will be used by cc1
  935. +    to output 16bit pc-relative code later. */
  936. + #undef TARGET_SWITCHES
  937. + #define TARGET_SWITCHES  \
  938. +   { { "68020", 5},                \
  939. +     { "c68020", 5},                \
  940. +     { "68881", 2},                \
  941. +     { "bitfield", 4},                \
  942. +     { "68000", -5},                \
  943. +     { "c68000", -5},                \
  944. +     { "soft-float", -0102},            \
  945. +     { "nobitfield", -4},            \
  946. +     { "rtd", 8},                \
  947. +     { "nortd", -8},                \
  948. +     { "short", 040},                \
  949. +     { "noshort", -040},                \
  950. +     { "fpa", 0100},                \
  951. +     { "nofpa", -0100},                \
  952. +     { "sky", 0200},                \
  953. +     { "nosky", -0200},                \
  954. +     { "68040", 0407},                \
  955. +     { "68030", -01400},                \
  956. +     { "68030", 7},                \
  957. +     { "68040-only", 01000},            \
  958. +     { "small-code", 0 },            \
  959. +     { "", TARGET_DEFAULT}}
  960. + /* Every structure or union's size must be a multiple of 2 bytes.  */
  961. + #define STRUCTURE_SIZE_BOUNDARY 16
  962. + /* This is (almost;-)) BSD, so it wants DBX format.  */
  963. + #define DBX_DEBUGGING_INFO
  964. + /* Allow folding division by zero.  */
  965. + #define REAL_INFINITY
  966. + #if 0    /* This apparently is no longer necessary? */
  967. + /* This is how to output an assembler line defining a `double' constant.  */
  968. + #undef ASM_OUTPUT_DOUBLE
  969. + #define ASM_OUTPUT_DOUBLE(FILE,VALUE)                    \
  970. +   {                                    \
  971. +     if (REAL_VALUE_ISINF (VALUE))                    \
  972. +       fprintf (FILE, "\t.double 0r%s99e999\n", (VALUE) > 0 ? "" : "-");    \
  973. +     else if (isnan (VALUE))                        \
  974. +       {                                    \
  975. +     union { double d; long l[2];} t;                \
  976. +     t.d = (VALUE);                            \
  977. +     fprintf (FILE, "\t.long 0x%lx\n\t.long 0x%lx\n", t.l[0], t.l[1]); \
  978. +       }                                    \
  979. +     else                                \
  980. +       fprintf (FILE, "\t.double 0r%.17g\n", VALUE);            \
  981. +   }
  982. + /* This is how to output an assembler line defining a `float' constant.  */
  983. + #undef ASM_OUTPUT_FLOAT
  984. + #define ASM_OUTPUT_FLOAT(FILE,VALUE)                    \
  985. +   {                                    \
  986. +     if (REAL_VALUE_ISINF (VALUE))                    \
  987. +       fprintf (FILE, "\t.single 0r%s99e999\n", (VALUE) > 0 ? "" : "-");    \
  988. +     else if (isnan (VALUE))                        \
  989. +       {                                    \
  990. +     union { float f; long l;} t;                    \
  991. +     t.f = (VALUE);                            \
  992. +     fprintf (FILE, "\t.long 0x%lx\n", t.l);                \
  993. +       }                                    \
  994. +     else                                \
  995. +       fprintf (FILE, "\t.single 0r%.9g\n", VALUE);            \
  996. +   }
  997. + /* This is how to output an assembler lines defining floating operands.
  998. +    There's no way to output a NaN's fraction, so we lose it.  */
  999. +   
  1000. + #undef ASM_OUTPUT_FLOAT_OPERAND
  1001. + #define ASM_OUTPUT_FLOAT_OPERAND(CODE,FILE,VALUE)                \
  1002. +  do {                                \
  1003. +       if (CODE == 'f')                        \
  1004. +         {                            \
  1005. +           (REAL_VALUE_ISINF ((VALUE))                        \
  1006. +            ? asm_fprintf (FILE, "%I0r%s99e999", ((VALUE) > 0 ? "" : "-")) \
  1007. +            : (VALUE) == -0.0                            \
  1008. +            ? asm_fprintf (FILE, "%I0r-0.0")                    \
  1009. +            : asm_fprintf (FILE, "%I0r%.9g", (VALUE))) \
  1010. +         } else {                                        \
  1011. +           long l;                        \
  1012. +           REAL_VALUE_TO_TARGET_SINGLE (VALUE, l);        \
  1013. +           if (sizeof (int) == sizeof (long))            \
  1014. +             asm_fprintf ((FILE), "%I0x%x", l);            \
  1015. +           else                            \
  1016. +             asm_fprintf ((FILE), "%I0x%lx", l);            \
  1017. +         }                            \
  1018. +      } while (0)
  1019. + #undef ASM_OUTPUT_DOUBLE_OPERAND
  1020. + #define ASM_OUTPUT_DOUBLE_OPERAND(FILE,VALUE)                \
  1021. +   (REAL_VALUE_ISINF ((VALUE))                        \
  1022. +    ? asm_fprintf (FILE, "%I0r%s99e999", ((VALUE) > 0 ? "" : "-")) \
  1023. +    : (VALUE) == -0.0                            \
  1024. +    ? asm_fprintf (FILE, "%I0r-0.0")                    \
  1025. +    : asm_fprintf (FILE, "%I0r%.17g", (VALUE)))
  1026. + #endif    /* 0 */
  1027. + /* use A5 as framepointer instead of A6, this makes A6 available as a
  1028. +    general purpose register, and can thus be used without problems in
  1029. +    direct library calls. */
  1030. + #undef FRAME_POINTER_REGNUM
  1031. + #define FRAME_POINTER_REGNUM 13
  1032. + #undef ARG_POINTER_REGNUM
  1033. + #define ARG_POINTER_REGNUM 13
  1034. + /* we use A4 for this, not A5, which is the framepointer */
  1035. + #undef PIC_OFFSET_TABLE_REGNUM
  1036. + #define PIC_OFFSET_TABLE_REGNUM 12
  1037. + /* setup a default shell return value for those (gazillion..) programs that
  1038. +    (inspite of ANSI-C) declare main() to be void (or even VOID...) and thus
  1039. +    cause the shell to randomly caugh upon executing such programs (contrary
  1040. +    to Unix, AmigaDOS scripts are terminated with an error if a program returns
  1041. +    with an error code above the `error' or even `failure' level
  1042. +    (which is configurable with the FAILAT command) */
  1043. + #define DEFAULT_MAIN_RETURN c_expand_return (integer_zero_node)
  1044. + /* we do have an ansi-compliant c-library ;-) */
  1045. + #define HAVE_VPRINTF
  1046. + #define HAVE_VFPRINTF
  1047. + #define HAVE_PUTENV
  1048. + #define HAVE_STRERROR
  1049. + #define HAVE_ATEXIT
  1050. + /* given that symbolic_operand(X), return TRUE if no special
  1051. +    base relative relocation is necessary */
  1052. + #define LEGITIMATE_BASEREL_OPERAND_P(X) \
  1053. +   (flag_pic >= 3 && read_only_operand (X))
  1054. + #undef LEGITIMATE_PIC_OPERAND_P
  1055. + #define LEGITIMATE_PIC_OPERAND_P(X) \
  1056. +   (! symbolic_operand (X, VOIDmode) || LEGITIMATE_BASEREL_OPERAND_P (X))
  1057. + /* Define this macro if references to a symbol must be treated
  1058. +    differently depending on something about the variable or
  1059. +    function named by the symbol (such as what section it is in).
  1060. +    The macro definition, if any, is executed immediately after the
  1061. +    rtl for DECL or other node is created.
  1062. +    The value of the rtl will be a `mem' whose address is a
  1063. +    `symbol_ref'.
  1064. +    The usual thing for this macro to do is to a flag in the
  1065. +    `symbol_ref' (such as `SYMBOL_REF_FLAG') or to store a modified
  1066. +    name string in the `symbol_ref' (if one bit is not enough
  1067. +    information).
  1068. +    On the Amiga we use this to indicate if a symbol is in text or
  1069. +    data space.  */
  1070. + #define ENCODE_SECTION_INFO(DECL)\
  1071. + do                                    \
  1072. +   {                                    \
  1073. +     if (TREE_CODE (DECL) == FUNCTION_DECL)                \
  1074. +       SYMBOL_REF_FLAG (XEXP (DECL_RTL (DECL), 0)) = 1;            \
  1075. +     else                                \
  1076. +       {                                    \
  1077. +     rtx rtl = (TREE_CODE_CLASS (TREE_CODE (DECL)) != 'd'        \
  1078. +            ? TREE_CST_RTL (DECL) : DECL_RTL (DECL));        \
  1079. +     if (RTX_UNCHANGING_P (rtl) && !MEM_VOLATILE_P (rtl))        \
  1080. +       SYMBOL_REF_FLAG (XEXP (rtl, 0)) = 1;                \
  1081. +       }                                    \
  1082. +   }                                    \
  1083. + while (0)
  1084. + #undef SELECT_RTX_SECTION
  1085. + #define SELECT_RTX_SECTION(MODE, X) readonly_data_section ();
  1086. + /* according to varasm.c, RELOC referrs *only* to whether constants (!)
  1087. +    are addressed by address. This doesn't matter in baserelative code,
  1088. +    so we allow (inspite of flag_pic) readonly_data_section() in that
  1089. +    case */
  1090. + #undef SELECT_SECTION
  1091. + #define SELECT_SECTION(DECL, RELOC)                    \
  1092. + {                                    \
  1093. +   if (TREE_CODE (DECL) == STRING_CST)                    \
  1094. +     {                                    \
  1095. +       if (! flag_writable_strings)                    \
  1096. +     readonly_data_section ();                    \
  1097. +       else                                \
  1098. +     data_section ();                        \
  1099. +     }                                    \
  1100. +   else if (TREE_CODE (DECL) == VAR_DECL)                \
  1101. +     {                                    \
  1102. +       if ((flag_pic && flag_pic < 3 && RELOC)                \
  1103. +       || !TREE_READONLY (DECL) || TREE_SIDE_EFFECTS (DECL))        \
  1104. +     data_section ();                        \
  1105. +       else                                \
  1106. +     readonly_data_section ();                    \
  1107. +     }                                    \
  1108. +   else                                    \
  1109. +     readonly_data_section ();                        \
  1110. + }
  1111. + #if not_yet_working
  1112. + /* starting support for amiga specific keywords
  1113. +  * --------------------------------------------
  1114. +  */
  1115. + /* validate attributes that don't take a parameter. Currently we support
  1116. +  * __attribute__ (saveds) and __attribute__ (interrupt)
  1117. +  */
  1118. + #define HANDLE_ATTRIBUTE0(attr) \
  1119. +   (strcmp(attr, "saveds") != 0 && strcmp(attr, "interrupt") != 0)
  1120. + /* (c-common.c)
  1121. +  * install additional attributes
  1122. +  */
  1123. + #define HANDLE_EXTRA_ATTRIBUTES(a)                         \
  1124. +   if (TREE_VALUE (a) != 0                            \
  1125. +       && TREE_CODE (TREE_VALUE (a)) == IDENTIFIER_NODE                \
  1126. +       && TREE_VALUE (a) == get_identifier ("saveds"))                \
  1127. +     {                                        \
  1128. +       if (TREE_CODE (decl) != FUNCTION_DECL)                    \
  1129. +         {                                    \
  1130. +           warning_with_decl (decl,                        \
  1131. +               "saveds attribute specified for non-function `%s'");        \
  1132. +       return;                                \
  1133. +         }                                    \
  1134. +                                               \
  1135. +       attr_do_saveds (DECL_NAME (decl));                    \
  1136. +     }                                        \
  1137. +   else if (TREE_VALUE (a) != 0                            \
  1138. +       && TREE_CODE (TREE_VALUE (a)) == IDENTIFIER_NODE                \
  1139. +       && TREE_VALUE (a) == get_identifier ("interrupt"))            \
  1140. +     {                                        \
  1141. +       if (TREE_CODE (decl) != FUNCTION_DECL)                    \
  1142. +         {                                    \
  1143. +           warning_with_decl (decl,                        \
  1144. +               "saveds attribute specified for non-function `%s'");        \
  1145. +       return;                                \
  1146. +         }                                    \
  1147. +                                               \
  1148. +       attr_do_interrupt (DECL_NAME (decl));                    \
  1149. +     }                                        \
  1150. + #define PROLOGUE_EXTRA_SAVE(mask)                        \
  1151. +   { extern char *current_function_name;                        \
  1152. +     /* saveds makes the function preserve d1/a0/a1 as well */            \
  1153. +     if (attr_does_saveds (current_function_name))                \
  1154. +       mask |= 0x40c0; }                                \
  1155. + #define EPILOGUE_EXTRA_RESTORE(mask, nregs)                    \
  1156. +   { extern char *current_function_name;                        \
  1157. +     /* restore those extra registers */                        \
  1158. +     if (attr_does_saveds (current_function_name))                \
  1159. +       {                                        \
  1160. +     mask |= 0x0302;                                \
  1161. +     nregs += 3;                                \
  1162. +       } }                                    \
  1163. + #define EPILOGUE_EXTRA_BARRIER_KLUDGE(stream)                    \
  1164. +   { extern char *current_function_name;                        \
  1165. +     /* PLEASE Help! how is this done cleaner?? */                \
  1166. +     if (attr_does_saveds (current_function_name))                \
  1167. +       {                                        \
  1168. +     fprintf (stderr,                             \
  1169. +          "warning: couldn't cleanup `saveds'-stack in `%s'.\n");    \
  1170. +     fprintf (stderr,                            \
  1171. +          "         this is only ok, if the function never returns!\n");    \
  1172. +       }    }                                    \
  1173. +         
  1174. + #define EPILOGUE_EXTRA_TEST(stream)                        \
  1175. +   { extern char *current_function_name;                        \
  1176. +     /* with the interrupt-attribute, we have to set the cc before rts */    \
  1177. +     if (attr_does_interrupt (current_function_name))                \
  1178. +       asm_fprintf (stream, "\ttstl %s\n", reg_names[0]); }            \
  1179. + #endif
  1180. diff -rc --new-file gcc-2.6.0/config/m68k/m68k.c /gnu/src/amiga/gcc-2.6.0/config/m68k/m68k.c
  1181. *** gcc-2.6.0/config/m68k/m68k.c    Sat Apr 16 23:16:27 1994
  1182. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/m68k.c    Fri Jul 29 09:39:20 1994
  1183. ***************
  1184. *** 61,67 ****
  1185.   void
  1186.   finalize_pic ()
  1187.   {
  1188. !   if (flag_pic && current_function_uses_pic_offset_table)
  1189.       emit_insn (gen_rtx (USE, VOIDmode, pic_offset_table_rtx));
  1190.   }
  1191.   
  1192. --- 61,67 ----
  1193.   void
  1194.   finalize_pic ()
  1195.   {
  1196. !   if (flag_pic && (flag_pic < 3) && current_function_uses_pic_offset_table)
  1197.       emit_insn (gen_rtx (USE, VOIDmode, pic_offset_table_rtx));
  1198.   }
  1199.   
  1200. ***************
  1201. *** 141,147 ****
  1202.     else if (fsize)
  1203.       {
  1204.         /* Adding negative number is faster on the 68040.  */
  1205. !       if (fsize + 4 < 0x8000)
  1206.       {
  1207.       /* asm_fprintf() cannot handle %. */
  1208.   #ifdef MOTOROLA
  1209. --- 141,148 ----
  1210.     else if (fsize)
  1211.       {
  1212.         /* Adding negative number is faster on the 68040.  */
  1213. !         if (fsize + 4 < 0x8000)
  1214.       {
  1215.       /* asm_fprintf() cannot handle %. */
  1216.   #ifdef MOTOROLA
  1217. ***************
  1218. *** 196,201 ****
  1219. --- 197,205 ----
  1220.         mask &= ~ (1 << (15 - FRAME_POINTER_REGNUM));
  1221.         num_saved_regs--;
  1222.       }
  1223. + #ifdef PROLOGUE_EXTRA_SAVE
  1224. +   PROLOGUE_EXTRA_SAVE (mask);
  1225. + #endif
  1226.   
  1227.   #if NEED_PROBE
  1228.     fprintf (stream, "\ttstl sp@(%d)\n", NEED_PROBE - num_saved_regs * 4);
  1229. ***************
  1230. *** 229,235 ****
  1231.         asm_fprintf (stream, "\tmoveml %0I0x%x,%Rsp@-\n", mask);
  1232.   #endif
  1233.       }
  1234. !   if (flag_pic && current_function_uses_pic_offset_table)
  1235.       {
  1236.   #ifdef MOTOROLA
  1237.         asm_fprintf (stream, "\t%Olea (%Rpc, %U_GLOBAL_OFFSET_TABLE_@GOTPC), %s\n",
  1238. --- 233,239 ----
  1239.         asm_fprintf (stream, "\tmoveml %0I0x%x,%Rsp@-\n", mask);
  1240.   #endif
  1241.       }
  1242. !   if (flag_pic && (flag_pic < 3) && current_function_uses_pic_offset_table)
  1243.       {
  1244.   #ifdef MOTOROLA
  1245.         asm_fprintf (stream, "\t%Olea (%Rpc, %U_GLOBAL_OFFSET_TABLE_@GOTPC), %s\n",
  1246. ***************
  1247. *** 294,299 ****
  1248. --- 298,306 ----
  1249.         /* Output just a no-op so that debuggers don't get confused
  1250.        about which function the pc is in at this address.  */
  1251.         asm_fprintf (stream, "\tnop\n");
  1252. + #ifdef EPILOGUE_EXTRA_BARRIER_KLUDGE
  1253. +       EPILOGUE_EXTRA_BARRIER_KLUDGE(stream);
  1254. + #endif
  1255.         return;
  1256.       }
  1257.   
  1258. ***************
  1259. *** 324,329 ****
  1260. --- 331,339 ----
  1261.           nregs++;
  1262.       mask |= 1 << regno;
  1263.         }
  1264. + #ifdef EPILOGUE_EXTRA_RESTORE
  1265. +   EPILOGUE_EXTRA_RESTORE(mask, nregs);
  1266. + #endif
  1267.     offset = foffset + nregs * 4;
  1268.     if (offset + fsize >= 0x8000
  1269.         && frame_pointer_needed
  1270. ***************
  1271. *** 528,533 ****
  1272. --- 538,546 ----
  1273.   #endif
  1274.       }
  1275.       }
  1276. + #ifdef EPILOGUE_EXTRA_TEST
  1277. +   EPILOGUE_EXTRA_TEST(stream);
  1278. + #endif
  1279.     if (current_function_pops_args)
  1280.       asm_fprintf (stream, "\trtd %0I%d\n", current_function_pops_args);
  1281.     else
  1282. ***************
  1283. *** 818,832 ****
  1284.     /* First handle a simple SYMBOL_REF or LABEL_REF */
  1285.     if (GET_CODE (orig) == SYMBOL_REF || GET_CODE (orig) == LABEL_REF)
  1286.       {
  1287.         if (reg == 0)
  1288.       abort ();
  1289.   
  1290. !       pic_ref = gen_rtx (MEM, Pmode,
  1291. !              gen_rtx (PLUS, Pmode,
  1292. !                   pic_offset_table_rtx, orig));
  1293.         current_function_uses_pic_offset_table = 1;
  1294.         RTX_UNCHANGING_P (pic_ref) = 1;
  1295.         emit_move_insn (reg, pic_ref);
  1296.         return reg;
  1297.       }
  1298.     else if (GET_CODE (orig) == CONST)
  1299. --- 831,855 ----
  1300.     /* First handle a simple SYMBOL_REF or LABEL_REF */
  1301.     if (GET_CODE (orig) == SYMBOL_REF || GET_CODE (orig) == LABEL_REF)
  1302.       {
  1303. + #ifdef LEGITIMATE_BASEREL_OPERAND_P
  1304. +   if (LEGITIMATE_BASEREL_OPERAND_P (orig))
  1305. +     return orig;
  1306. + #endif
  1307.         if (reg == 0)
  1308.       abort ();
  1309.   
  1310. !       if (flag_pic >= 3)
  1311. !     pic_ref = gen_rtx (PLUS, Pmode, pic_offset_table_rtx, orig);
  1312. !       else
  1313. !         pic_ref = gen_rtx (MEM, Pmode,
  1314. !                gen_rtx (PLUS, Pmode,
  1315. !                     pic_offset_table_rtx, orig));
  1316.         current_function_uses_pic_offset_table = 1;
  1317.         RTX_UNCHANGING_P (pic_ref) = 1;
  1318.         emit_move_insn (reg, pic_ref);
  1319.         return reg;
  1320.       }
  1321.     else if (GET_CODE (orig) == CONST)
  1322. ***************
  1323. *** 855,860 ****
  1324. --- 878,884 ----
  1325.         pic_ref = gen_rtx (PLUS, Pmode, base, orig);
  1326.         /* Likewise, should we set special REG_NOTEs here?  */
  1327.       }
  1328.     return pic_ref;
  1329.   }
  1330.   
  1331. ***************
  1332. *** 2167,2172 ****
  1333. --- 2191,2200 ----
  1334.                 fprintf (file, ":w");
  1335.               if ((flag_pic == 2) && (breg == pic_offset_table_rtx))
  1336.                 fprintf (file, ":l");
  1337. +             if ((flag_pic == 3) && (breg == pic_offset_table_rtx))
  1338. +               fprintf (file, ":W");
  1339. +             if ((flag_pic == 4) && (breg == pic_offset_table_rtx))
  1340. +               fprintf (file, ":L");
  1341.             }
  1342.           if (addr != 0 && ireg != 0)
  1343.             {
  1344. diff -rc --new-file gcc-2.6.0/config/m68k/m68k.h /gnu/src/amiga/gcc-2.6.0/config/m68k/m68k.h
  1345. *** gcc-2.6.0/config/m68k/m68k.h    Sun Apr 10 11:10:37 1994
  1346. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/m68k.h    Fri Jul 29 09:39:22 1994
  1347. ***************
  1348. *** 353,361 ****
  1349.   #ifndef SUPPORT_SUN_FPA
  1350.   
  1351.   #define CONDITIONAL_REGISTER_USAGE \
  1352. ! {                                               \
  1353. !   if (flag_pic)                                 \
  1354. !     fixed_regs[PIC_OFFSET_TABLE_REGNUM] = 1;    \
  1355.   }
  1356.   
  1357.   #else /* defined SUPPORT_SUN_FPA */
  1358. --- 353,364 ----
  1359.   #ifndef SUPPORT_SUN_FPA
  1360.   
  1361.   #define CONDITIONAL_REGISTER_USAGE \
  1362. ! {                                                \
  1363. !   if (flag_pic)                                  \
  1364. !     fixed_regs[PIC_OFFSET_TABLE_REGNUM] = 1;     \
  1365. !   /* prevent saving/restoring of the base reg */ \
  1366. !   if (flag_pic == 3)                 \
  1367. !     call_used_regs[PIC_OFFSET_TABLE_REGNUM] = 1; \
  1368.   }
  1369.   
  1370.   #else /* defined SUPPORT_SUN_FPA */
  1371. diff -rc --new-file gcc-2.6.0/config/m68k/m68k.md /gnu/src/amiga/gcc-2.6.0/config/m68k/m68k.md
  1372. *** gcc-2.6.0/config/m68k/m68k.md    Thu Jun 30 22:14:18 1994
  1373. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/m68k.md    Fri Aug 19 17:21:07 1994
  1374. ***************
  1375. *** 712,724 ****
  1376.   {
  1377.     if (flag_pic && symbolic_operand (operands[1], SImode)) 
  1378.       {
  1379. !       /* The source is an address which requires PIC relocation.  
  1380. !          Call legitimize_pic_address with the source, mode, and a relocation
  1381. !          register (a new pseudo, or the final destination if reload_in_progress
  1382. !          is set).   Then fall through normally */
  1383. !       extern rtx legitimize_pic_address();
  1384. !       rtx temp = reload_in_progress ? operands[0] : gen_reg_rtx (Pmode);
  1385. !       operands[1] = legitimize_pic_address (operands[1], SImode, temp);
  1386.       }
  1387.   }")
  1388.   
  1389. --- 712,729 ----
  1390.   {
  1391.     if (flag_pic && symbolic_operand (operands[1], SImode)) 
  1392.       {
  1393. ! #ifdef LEGITIMATE_BASEREL_OPERAND_P
  1394. !       if (flag_pic < 3 || !LEGITIMATE_BASEREL_OPERAND_P (operands[1]))
  1395. ! #endif
  1396. !       {
  1397. !         /* The source is an address which requires PIC relocation.  
  1398. !            Call legitimize_pic_address with the source, mode, and a relocation
  1399. !            register (a new pseudo, or the final destination if reload_in_progress
  1400. !            is set).   Then fall through normally */
  1401. !         extern rtx legitimize_pic_address();
  1402. !         rtx temp = reload_in_progress ? operands[0] : gen_reg_rtx (Pmode);
  1403. !         operands[1] = legitimize_pic_address (operands[1], SImode, temp);
  1404. !       }
  1405.       }
  1406.   }")
  1407.   
  1408. ***************
  1409. *** 1856,1863 ****
  1410.   
  1411.         /* These insns can result from reloads to access
  1412.        stack slots over 64k from the frame pointer.  */
  1413. !       if (GET_CODE (operands[2]) == CONST_INT
  1414. !       && INTVAL (operands[2]) + 0x8000 >= (unsigned) 0x10000)
  1415.           return \"move%.l %2,%0\;add%.l %1,%0\";
  1416.   #ifdef SGS
  1417.         if (GET_CODE (operands[2]) == REG)
  1418. --- 1861,1869 ----
  1419.   
  1420.         /* These insns can result from reloads to access
  1421.        stack slots over 64k from the frame pointer.  */
  1422. !       if (((GET_CODE (operands[2]) == CONST_INT
  1423. !        && INTVAL (operands[2]) + 0x8000 >= (unsigned) 0x10000))
  1424. !       || (flag_pic == 4 && operands[1] == pic_offset_table_rtx))
  1425.           return \"move%.l %2,%0\;add%.l %1,%0\";
  1426.   #ifdef SGS
  1427.         if (GET_CODE (operands[2]) == REG)
  1428. ***************
  1429. *** 4765,4771 ****
  1430.     ""
  1431.     "
  1432.   {
  1433. !   if (flag_pic && GET_CODE (XEXP (operands[0], 0)) == SYMBOL_REF)
  1434.   #ifdef MOTOROLA
  1435.       SYMBOL_REF_FLAG (XEXP (operands[0], 0)) = 1;
  1436.   #else
  1437. --- 4771,4777 ----
  1438.     ""
  1439.     "
  1440.   {
  1441. !   if (flag_pic && flag_pic < 3 && GET_CODE (XEXP (operands[0], 0)) == SYMBOL_REF)
  1442.   #ifdef MOTOROLA
  1443.       SYMBOL_REF_FLAG (XEXP (operands[0], 0)) = 1;
  1444.   #else
  1445. ***************
  1446. *** 4780,4786 ****
  1447.        (match_operand:SI 1 "general_operand" "g"))]
  1448.     ;; Operand 1 not really used on the m68000.
  1449.   
  1450. !   "! flag_pic"
  1451.     "*
  1452.   #ifdef MOTOROLA
  1453.   #ifdef MOTOROLA_BSR
  1454. --- 4786,4792 ----
  1455.        (match_operand:SI 1 "general_operand" "g"))]
  1456.     ;; Operand 1 not really used on the m68000.
  1457.   
  1458. !   "(! flag_pic || flag_pic >= 3)"
  1459.     "*
  1460.   #ifdef MOTOROLA
  1461.   #ifdef MOTOROLA_BSR
  1462. ***************
  1463. *** 4800,4806 ****
  1464.        (match_operand:SI 1 "general_operand" "g"))]
  1465.     ;; Operand 1 not really used on the m68000.
  1466.   
  1467. !   "flag_pic"
  1468.     "*
  1469.   #ifdef MOTOROLA
  1470.     if (GET_CODE (operands[0]) == MEM 
  1471. --- 4806,4812 ----
  1472.        (match_operand:SI 1 "general_operand" "g"))]
  1473.     ;; Operand 1 not really used on the m68000.
  1474.   
  1475. !   "(flag_pic && flag_pic < 3)"
  1476.     "*
  1477.   #ifdef MOTOROLA
  1478.     if (GET_CODE (operands[0]) == MEM 
  1479. ***************
  1480. *** 4825,4831 ****
  1481.     ""
  1482.     "
  1483.   {
  1484. !   if (flag_pic && GET_CODE (XEXP (operands[1], 0)) == SYMBOL_REF)
  1485.   #ifdef MOTOROLA
  1486.       SYMBOL_REF_FLAG (XEXP (operands[1], 0)) = 1;
  1487.   #else
  1488. --- 4831,4837 ----
  1489.     ""
  1490.     "
  1491.   {
  1492. !   if (flag_pic && flag_pic < 3 && GET_CODE (XEXP (operands[1], 0)) == SYMBOL_REF)
  1493.   #ifdef MOTOROLA
  1494.       SYMBOL_REF_FLAG (XEXP (operands[1], 0)) = 1;
  1495.   #else
  1496. ***************
  1497. *** 4840,4846 ****
  1498.       (call (match_operand:QI 1 "memory_operand" "o")
  1499.             (match_operand:SI 2 "general_operand" "g")))]
  1500.     ;; Operand 2 not really used on the m68000.
  1501. !   "! flag_pic"
  1502.     "*
  1503.   #ifdef MOTOROLA
  1504.   #ifdef MOTOROLA_BSR
  1505. --- 4846,4852 ----
  1506.       (call (match_operand:QI 1 "memory_operand" "o")
  1507.             (match_operand:SI 2 "general_operand" "g")))]
  1508.     ;; Operand 2 not really used on the m68000.
  1509. !   "(! flag_pic || flag_pic >= 3)"
  1510.     "*
  1511.   #ifdef MOTOROLA
  1512.   #ifdef MOTOROLA_BSR
  1513. ***************
  1514. *** 4860,4866 ****
  1515.       (call (match_operand:QI 1 "memory_operand" "o")
  1516.             (match_operand:SI 2 "general_operand" "g")))]
  1517.     ;; Operand 2 not really used on the m68000.
  1518. !   "flag_pic"
  1519.     "*
  1520.   #ifdef MOTOROLA
  1521.     if (GET_CODE (operands[1]) == MEM 
  1522. --- 4866,4872 ----
  1523.       (call (match_operand:QI 1 "memory_operand" "o")
  1524.             (match_operand:SI 2 "general_operand" "g")))]
  1525.     ;; Operand 2 not really used on the m68000.
  1526. !   "(flag_pic && flag_pic < 3)"
  1527.     "*
  1528.   #ifdef MOTOROLA
  1529.     if (GET_CODE (operands[1]) == MEM 
  1530. diff -rc --new-file gcc-2.6.0/config/m68k/t-amigados /gnu/src/amiga/gcc-2.6.0/config/m68k/t-amigados
  1531. *** gcc-2.6.0/config/m68k/t-amigados    Thu Jan  1 00:00:00 1970
  1532. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/t-amigados    Fri Jul 29 09:39:27 1994
  1533. ***************
  1534. *** 0 ****
  1535. --- 1,187 ----
  1536. + # Makefile fragment for amigados target.
  1537. + # We generate two additional things:
  1538. + #
  1539. + # libb/libgcc.a
  1540. + #    A base relative version of libgcc.a which is used when compiling and
  1541. + #    linking with the '-resident' option.
  1542. + #
  1543. + # xgccv
  1544. + #    A forking gcc instead of one calling ssytem(). This makes it less
  1545. + #    system conformant (can't ^C it when started from make), while providing
  1546. + #    increased functionality (-pipe option).
  1547. + # Use the vfork'ing version of gcc by default, so that the -pipe option can
  1548. + # get tested.  To use the regular version just do "make XGCC=gcc".  Note that
  1549. + # PIPE is defined in x-amigados, so if we are doing a native build, it will
  1550. + # be defined.  It can be overridden with "make PIPE=".
  1551. + XGCC = xgccv $(PIPE)
  1552. + GCC_FOR_TARGET = ./$(XGCC) -B./
  1553. + # Build residentable versions of the gcc executables by default.  Use
  1554. + # "make RESIDENT=" to build non-residentable versions.
  1555. + # Note:  This failed during bootstrapping of 2.5.5.
  1556. + #RESIDENT = -resident
  1557. + # The standard additional target flags for the compiler.
  1558. + T_CFLAGS = $(RESIDENT)
  1559. + # Allow the user to override the default target optimizations with gcc, or if
  1560. + # the target compiler is not gcc and doesn't understand -O<N>.
  1561. + T_OPTIMISE = -O2
  1562. + # Each compilation environment (Manx, Dice, GCC, SAS/C, etc) provides its
  1563. + # own equivalent of the UNIX /usr/include tree.  For gcc, the standard headers
  1564. + # are in /gnu/include and system specific headers are in /gnu/os-include.
  1565. + # Use these paths for fixincludes.
  1566. + SYSTEM_HEADER_DIR = /gnu/include
  1567. + OTHER_FIXINCLUDES_DIRS = /gnu/os-include
  1568. + # We don't need a libgcc1, it's all in ixemul.library
  1569. + LIBGCC1 = libgcc1.null
  1570. + # Flags to use when compiling the normal version of libgcc.a.
  1571. + # Don't compile with debugging, as long as there is no debugger.
  1572. + # Explicitly leave out the -resident compilation flag and don't use T_CFLAGS.
  1573. + LIBGCC2_CFLAGS = $(T_OPTIMIZE) $(INTERNAL_CFLAGS) $(X_CFLAGS) $(CFLAGS) \
  1574. +           $(CROSS_GCC_CFLAGS)
  1575. + # Flags to use when compiling the base relative version of libgcc.a.
  1576. + # Don't compile with debugging, as long as there is no debugger.
  1577. + # Explicitly force -resident in the compilation flags and don't use T_CFLAGS.
  1578. + LIBBGCC2_CFLAGS = $(T_OPTIMIZE) $(INTERNAL_CFLAGS) $(X_CFLAGS) $(CFLAGS) \
  1579. +           $(CROSS_GCC_CFLAGS) -resident
  1580. + # Build the base relative library.
  1581. + # It is later copied into /gnu/lib/gcc-lib/amigados/<version>/libb/libgcc.a, whereas
  1582. + # libgcc.a is copied into /gnu/lib/gcc-lib/amigados/<version>/libgcc.a.
  1583. + # It doesn't work very well to define one of the EXTRA_* macros to contain
  1584. + # libb/libgcc.a, particularly for doing "make stageN" or "make install".
  1585. + GCC_PARTS=$(GCC_PASSES) libgcc.a libb/libgcc.a $(EXTRA_PROGRAMS) $(USE_COLLECT2) $(EXTRA_PARTS)
  1586. + # Add install_libbgcc to normal define of INSTALL_LIBGCC.  Let install-gccv
  1587. + # hitch a ride on here as well.
  1588. + INSTALL_LIBGCC = install-libgcc install-libbgcc install-gccv
  1589. + # This includes the knowledge that target amigados doesn't need libgcc1.a
  1590. + libb/libgcc.a: libgcc1.null libgcc2.c libgcc2.ready $(CONFIG_H) \
  1591. +    $(LIB2FUNCS_EXTRA) machmode.h longlong.h gbl-ctors.h config.status
  1592. + # Actually build it in tmplibbgcc.a, then rename at end,
  1593. + # so that libb/libgcc.a itself remains nonexistent if compilation is aborted.
  1594. +     -rm -f tmplibbgcc.a
  1595. + # -e causes any failing command to make this rule fail.
  1596. + # -e doesn't work in certain shells, so we test $$? as well.
  1597. +     set -e; \
  1598. +     for name in $(LIB2FUNCS); \
  1599. +     do \
  1600. +       echo $${name}; \
  1601. +       $(GCC_FOR_TARGET) $(LIBBGCC2_CFLAGS) $(INCLUDES) -c -DL$${name} \
  1602. +           $(srcdir)/libgcc2.c -o $${name}.o; \
  1603. +       if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
  1604. +       $(AR) $(AR_FLAGS) tmplibbgcc.a $${name}.o; \
  1605. +       rm -f $${name}.o; \
  1606. +     done
  1607. + # Some shells crash when a loop has no items.
  1608. + # So make sure there is always at least one--`..'.
  1609. + # Then ignore it.
  1610. + # We don't use -e here because there are if statements
  1611. + # that should not make the command give up when the if condition is false.
  1612. + # Instead, we test for failure after each command where it matters.
  1613. +     -for file in .. $(LIB2FUNCS_EXTRA); \
  1614. +     do \
  1615. +       if [ x$${file} != x.. ]; then \
  1616. +         name=`echo $${file} | sed -e 's/[.]c$$//' -e 's/[.]asm$$//'`; \
  1617. +         echo $${name}; \
  1618. +         if [ $${name}.asm = $${file} ]; then \
  1619. +           cp $${file} $${name}.s || exit 1; file=$${name}.s; \
  1620. +         else true; fi; \
  1621. +         $(GCC_FOR_TARGET) $(LIBBGCC2_CFLAGS) $(INCLUDES) -c $${file}; \
  1622. +         if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
  1623. +         $(AR) $(AR_FLAGS) tmplibbgcc.a $${name}.o; \
  1624. +         rm -f $${name}.[so]; \
  1625. +       else true; \
  1626. +       fi; \
  1627. +     done
  1628. +     -if $(RANLIB_TEST) ; then $(RANLIB) tmplibbgcc.a; else true; fi
  1629. +     -if [ -d libb ] ; then true ; else mkdir libb ; fi
  1630. +     mv tmplibbgcc.a libb/libgcc.a
  1631. + install-libbgcc: libb/libgcc.a install-dir
  1632. +     -if [ -d $(libsubdir)/libb ] ; then true ; else mkdir $(libsubdir)/libb ; fi
  1633. +     -if [ -f libb/libgcc.a ] ; then \
  1634. +       rm -f $(libsubdir)/libb/libgcc.a; \
  1635. +       $(INSTALL_DATA) libb/libgcc.a $(libsubdir)/libb/libgcc.a; \
  1636. +       if $(RANLIB_TEST) ; then \
  1637. +         (cd $(libsubdir)/libb; $(RANLIB) libgcc.a); else true; fi; \
  1638. +       chmod a-x $(libsubdir)/libb/libgcc.a; \
  1639. +     else true; fi
  1640. +     
  1641. + # The default gcc (xgcc) is built without -DAMIGADOS_FORK_GCC. This gcc (xgccv)
  1642. + # is built with AMIGADOS_FORK_GCC defined, so that it can use '-pipe'.  We
  1643. + # don't want to define EXTRA_PASSES to xgccv because that will cause xgccv
  1644. + # to be installed in $(libsubdir), so instead we use the default GCC_PASSES
  1645. + # and add xgccv to it.
  1646. + GCC_PASSES = xgcc xgccv cc1 cpp $(EXTRA_PASSES)
  1647. + xgccv: xgccv.o version.o $(LIBDEPS)
  1648. +     $(CC) $(ALL_CFLAGS) $(LDFLAGS) -o xgccv xgccv.o version.o $(LIBS)
  1649. + xgccv.o: gcc.c $(CONFIG_H) config.status
  1650. +     $(CC) $(ALL_CFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
  1651. +   -DSTANDARD_STARTFILE_PREFIX=\"$(libdir)/\" \
  1652. +   -DSTANDARD_EXEC_PREFIX=\"$(libdir)/gcc-lib/\" \
  1653. +   -DDEFAULT_TARGET_VERSION=\"$(version)\" \
  1654. +   -DDEFAULT_TARGET_MACHINE=\"$(target)\" \
  1655. +   -DTOOLDIR_BASE_PREFIX=\"$(exec_prefix)/\" \
  1656. +   -DAMIGADOS_FORK_GCC \
  1657. +   -c `echo $(srcdir)/gcc.c | sed 's,^\./,,'` -o xgccv.o
  1658. + install-gccv: xgccv
  1659. +     rm -f $(bindir)/gccv
  1660. +     $(INSTALL_PROGRAM) xgccv $(bindir)/gccv
  1661. + # When making one of the stage<N> dirs, we need to make a libb subdir for
  1662. + # it, and copy libbgcc.a there as libgcc.a.
  1663. + EXTRA_STAGE1_TARGETS = stage1-libb
  1664. + EXTRA_STAGE2_TARGETS = stage2-libb
  1665. + EXTRA_STAGE3_TARGETS = stage3-libb
  1666. + EXTRA_STAGE4_TARGETS = stage4-libb
  1667. + stage1-libb:
  1668. +     -if [ -d stage1 ] ; then true ; else mkdir stage1 ; fi
  1669. +     -if [ -d stage1/libb ] ; then true ; else mkdir stage1/libb ; fi
  1670. +     -cp libb/libgcc.a stage1/libb/libgcc.a
  1671. +     -if $(RANLIB_TEST) ; then $(RANLIB) stage1/libb/libgcc.a; else true; fi
  1672. + stage2-libb:
  1673. +     -if [ -d stage2 ] ; then true ; else mkdir stage2 ; fi
  1674. +     -if [ -d stage2/libb ] ; then true ; else mkdir stage2/libb ; fi
  1675. +     -cp libb/libgcc.a stage2/libb/libgcc.a
  1676. +     -if $(RANLIB_TEST) ; then $(RANLIB) stage2/libb/libgcc.a; else true; fi
  1677. + stage3-libb:
  1678. +     -if [ -d stage3 ] ; then true ; else mkdir stage3 ; fi
  1679. +     -if [ -d stage3/libb ] ; then true ; else mkdir stage3/libb ; fi
  1680. +     -cp libb/libgcc.a stage3/libb/libgcc.a
  1681. +     -if $(RANLIB_TEST) ; then $(RANLIB) stage3/libb/libgcc.a; else true; fi
  1682. + stage4-libb:
  1683. +     -if [ -d stage4 ] ; then true ; else mkdir stage4 ; fi
  1684. +     -if [ -d stage4/libb ] ; then true ; else mkdir stage4/libb ; fi
  1685. +     -cp libb/libgcc.a stage4/libb/libgcc.a
  1686. +     -if $(RANLIB_TEST) ; then $(RANLIB) stage4/libb/libgcc.a; else true; fi
  1687. diff -rc --new-file gcc-2.6.0/config/m68k/x-amigados /gnu/src/amiga/gcc-2.6.0/config/m68k/x-amigados
  1688. *** gcc-2.6.0/config/m68k/x-amigados    Thu Jan  1 00:00:00 1970
  1689. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/x-amigados    Fri Jul 29 09:39:29 1994
  1690. ***************
  1691. *** 0 ****
  1692. --- 1,44 ----
  1693. + # Note: It doesn't do any good to try to define prefix or local_prefix
  1694. + # in the host overrides because configure will just change them back.
  1695. + # You either have to give an appropriate option to configure or live with
  1696. + # an Amiga specific patch to configure.  See the note in configure.  -fnf
  1697. + # Building under amigados almost certainly requires an already working gcc.
  1698. + # Use gccv, which is a gcc compiled with AMIGADOS_FORK_GCC so "-pipe" will
  1699. + # work and get exercised.  To bootstrap with the regular gcc just do
  1700. + # "make CC=gcc".  To bootstrap without "-pipe" do "make PIPE=".
  1701. + CC = gccv $(PIPE)
  1702. + # Disable -pipe for now since I had problems bootstrapping gcc 2.5.5 with
  1703. + # it. (fnf)
  1704. + #PIPE = -pipe
  1705. + # Allow the user to override the default host optimization with gcc, or if the
  1706. + # host compiler is not gcc and doesn't understand -O<N>.
  1707. + X_OPTIMIZE = -O2
  1708. + # The standard additional host flags for the compiler.
  1709. + X_CFLAGS = $(X_OPTIMIZE)
  1710. + # Man pages get a wierd suffix...
  1711. + manext = .0
  1712. + # We really shouldn't specify CFLAGS from here, but there's no other way
  1713. + # to get rid of the `-g' indoctrinated by Makefile.in.  Note this becomes
  1714. + # part of both the host compilation CFLAGS and the target compilation
  1715. + # CFLAGS.
  1716. + CFLAGS =
  1717. + # Ranlib does exist, but may not be in a path where the default RANLIB_TEST
  1718. + # expects it, so just force it to true.
  1719. + RANLIB_TEST = true
  1720. + # My current version of ln doesn't work, so use cp instead.  -fnf
  1721. + HARDLINK = cp
  1722. diff -rc --new-file gcc-2.6.0/config/m68k/xm-amigados.h /gnu/src/amiga/gcc-2.6.0/config/m68k/xm-amigados.h
  1723. *** gcc-2.6.0/config/m68k/xm-amigados.h    Thu Jan  1 00:00:00 1970
  1724. --- /gnu/src/amiga/gcc-2.6.0/config/m68k/xm-amigados.h    Fri Jul 29 09:39:30 1994
  1725. ***************
  1726. *** 0 ****
  1727. --- 1,218 ----
  1728. + /* Configuration for GNU C-compiler for Commodore Amiga, running AmigaDOS.
  1729. +    Copyright (C) 1992 Free Software Foundation, Inc.
  1730. +    Contributed by Markus M. Wild (wild@amiga.physik.unizh.ch).
  1731. + This file is part of GNU CC.
  1732. + GNU CC is free software; you can redistribute it and/or modify
  1733. + it under the terms of the GNU General Public License as published by
  1734. + the Free Software Foundation; either version 2, or (at your option)
  1735. + any later version.
  1736. + GNU CC is distributed in the hope that it will be useful,
  1737. + but WITHOUT ANY WARRANTY; without even the implied warranty of
  1738. + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1739. + GNU General Public License for more details.
  1740. + You should have received a copy of the GNU General Public License
  1741. + along with GNU CC; see the file COPYING.  If not, write to
  1742. + the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */
  1743. + /* first include the generic header, then modify some parts.. */
  1744. + #include "m68k/xm-m68k.h"
  1745. + /* Amiga specific headers, such as from the Native Developer Update kits,
  1746. +    go in SYSTEM_INCLUDE_DIR.  STANDARD_INCLUDE_DIR is the equivalent of
  1747. +    Unix "/usr/include".  All other include paths are set in Makefile. */
  1748. + #define SYSTEM_INCLUDE_DIR    "/gnu/os-include"
  1749. + #define STANDARD_INCLUDE_DIR    "/gnu/include"
  1750. + /* Fork one piped subcommand.  SEARCH_FLAG is the system call to use
  1751. +    (either execv or execvp).  ARGV is the arg vector to use.
  1752. +    NOT_LAST is nonzero if this is not the last subcommand
  1753. +    (i.e. its output should be piped to the next one.)  */
  1754. + #ifndef AMIGADOS_FORK_GCC
  1755. + /* This version uses a more or less amigados-conformant way of running a
  1756. +    program (in the context of the parent). If you want to use -pipe however,
  1757. +    you'll have to use the vfork() version afterwards.
  1758. +    Phil.B: 29-May-94 quick hack (number 20 added to length) because xgcc
  1759. +    doesn't work.
  1760. +  */
  1761. + #define PEXECUTE(SEARCH_FLAG,PROGRAM,ARGV,NOT_LAST) \
  1762. + ({char *_argline;                        \
  1763. +   int _arglinelength, _i;                    \
  1764. +                                 \
  1765. +   for (_i = 1, _arglinelength=0; ARGV[_i]; ++_i)        \
  1766. +     _arglinelength += strlen(ARGV[_i]) + 1;            \
  1767. +                                 \
  1768. +   _arglinelength += strlen(PROGRAM) + 20 + 1;            \
  1769. +                                 \
  1770. +   if (!(_argline = (char *)alloca(_arglinelength)))         \
  1771. +     pfatal_with_name ("alloca");                \
  1772. +                                 \
  1773. +   strcpy(_argline, PROGRAM);                    \
  1774. +   for (_i = 1; ARGV[_i]; ++_i)                     \
  1775. +     {                                \
  1776. +       strcat(_argline, " ");                    \
  1777. +       strcat(_argline, ARGV[_i]);                \
  1778. +     }                                \
  1779. +                                 \
  1780. +   ssystem(_argline); })                        \
  1781. + #define PEXECUTE_RESULT(STATUS, COMMAND) \
  1782. +   ({ STATUS = COMMAND.pid; })
  1783. + #else
  1784. + /* the vfork() version. This one has the drawback, that gcc is not 
  1785. +    interruptible when started from make, since ixemul.library doesn't yet
  1786. +    propagate ^C to subprocesses. */
  1787. + #define PEXECUTE(SEARCH_FLAG,PROGRAM,ARGV,NOT_LAST) \
  1788. + ({int (*_func)() = (SEARCH_FLAG ? execv : execvp);            \
  1789. +   int _pid;                                \
  1790. +   int _pdes[2];                                \
  1791. +   int _input_desc = last_pipe_input;                    \
  1792. +   int _output_desc = STDOUT_FILE_NO;                    \
  1793. +   int _retries, _sleep_interval, _result;                \
  1794. +                                     \
  1795. +   /* If this isn't the last process, make a pipe for its output,    \
  1796. +      and record it as waiting to be the input to the next process.  */    \
  1797. +                                     \
  1798. +   if (NOT_LAST)                                \
  1799. +     {                                    \
  1800. +       if (pipe (_pdes) < 0)                        \
  1801. +     pfatal_with_name ("pipe");                    \
  1802. +       _output_desc = _pdes[WRITE_PORT];                    \
  1803. +       last_pipe_input = _pdes[READ_PORT];                \
  1804. +     }                                    \
  1805. +   else                                    \
  1806. +     last_pipe_input = STDIN_FILE_NO;                    \
  1807. +                                     \
  1808. +   /* Fork a subprocess; wait and retry if it fails.  */            \
  1809. +   _sleep_interval = 1;                            \
  1810. +   for (_retries = 0; _retries < 4; _retries++)                \
  1811. +     {                                    \
  1812. +       _pid = vfork ();                            \
  1813. +       if (_pid >= 0)                            \
  1814. +     break;                                \
  1815. +       sleep (_sleep_interval);                        \
  1816. +       _sleep_interval *= 2;                        \
  1817. +     }                                    \
  1818. +                                     \
  1819. +   switch (_pid)                                \
  1820. +     {                                    \
  1821. +     case -1:                                \
  1822. +       pfatal_with_name ("vfork");                    \
  1823. +       /* NOTREACHED */                            \
  1824. +       _result = 0;                            \
  1825. +       break;                                \
  1826. +                                     \
  1827. +     case 0: /* child */                            \
  1828. +       /* Move the input and output pipes into place, if nec.  */    \
  1829. +       if (_input_desc != STDIN_FILE_NO)                    \
  1830. +     {                                \
  1831. +       close (STDIN_FILE_NO);                    \
  1832. +       dup (_input_desc);                        \
  1833. +       close (_input_desc);                        \
  1834. +     }                                \
  1835. +       if (_output_desc != STDOUT_FILE_NO)                \
  1836. +     {                                \
  1837. +       close (STDOUT_FILE_NO);                    \
  1838. +       dup (_output_desc);                        \
  1839. +       close (_output_desc);                        \
  1840. +     }                                \
  1841. +                                     \
  1842. +       /* Close the parent's descs that aren't wanted here.  */        \
  1843. +       if (last_pipe_input != STDIN_FILE_NO)                \
  1844. +     close (last_pipe_input);                    \
  1845. +                                     \
  1846. +       /* Exec the program.  */                        \
  1847. +       (*_func) (PROGRAM, ARGV);                        \
  1848. +       perror_exec (PROGRAM);                        \
  1849. +       exit (-1);                            \
  1850. +       /* NOTREACHED */                            \
  1851. +       _result = 0;                            \
  1852. +       break;                                \
  1853. +                                     \
  1854. +     default:                                \
  1855. +       /* In the parent, after forking.                    \
  1856. +      Close the descriptors that we made for this child.  */        \
  1857. +       if (_input_desc != STDIN_FILE_NO)                    \
  1858. +     close (_input_desc);                        \
  1859. +       if (_output_desc != STDOUT_FILE_NO)                \
  1860. +     close (_output_desc);                        \
  1861. +                                     \
  1862. +       /* Return child's process number.  */                \
  1863. +       _result = _pid;                            \
  1864. +       break;                                \
  1865. +     }                                     \
  1866. + _result; })                                \
  1867. + #define PEXECUTE_RESULT(STATUS, COMMAND) \
  1868. +   ({ wait (& STATUS); })
  1869. + #endif /* AMIGADOS_FORK_GCC */
  1870. + /* the following macros are stolen more or less from xm-vms.h ... */
  1871. + /* This macro is used to help compare filenames in cp-lex.c.
  1872. +    We also need to make sure that the names are all lower case, because
  1873. +    we must be able to compare filenames to determine if a file implements
  1874. +    a class.  */
  1875. + #define FILE_NAME_NONDIRECTORY(C)                \
  1876. + ({                                \
  1877. +    extern char *rindex();                    \
  1878. +    char * pnt_ = (C), * pnt1_;                    \
  1879. +    pnt1_ = pnt_ - 1;                        \
  1880. +    while (*++pnt1_)                        \
  1881. +      if ((*pnt1_ >= 'A' && *pnt1_ <= 'Z')) *pnt1_ |= 0x20;    \
  1882. +    pnt1_ = rindex (pnt_, '/');                     \
  1883. +    pnt1_ = (pnt1_ == 0 ? rindex (pnt_, ':') : pnt1_);        \
  1884. +    (pnt1_ == 0 ? pnt_ : pnt1_ + 1);                \
  1885. +  })
  1886. + /* Macro to generate the name of the cross reference file.  The standard
  1887. +    one does not work, since it was written assuming that the conventions
  1888. +    of a unix style filesystem will work on the host system.
  1889. +  
  1890. +    Contrary to VMS, I'm using the original unix filename, there's no reason
  1891. +    not to use this under AmigaDOS. */
  1892. + #define XREF_FILE_NAME(BUFF, NAME)    \
  1893. +   s = FILE_NAME_NONDIRECTORY (NAME);            \
  1894. +   if (s == NAME) sprintf(BUFF, ".%s.gxref", NAME);    \
  1895. +   else {                        \
  1896. +     unsigned char ch = *s; /* could be Latin1 char.. */    \
  1897. +     /* temporary: cut the filename from the directory */\
  1898. +     *s = 0;                        \
  1899. +     sprintf (BUFF, "%s.%c%s.gxref", NAME, ch, s+1);    \
  1900. +     /* and restore the filename */            \
  1901. +     *s = ch;                        \
  1902. +   }                            \
  1903. + /* Macro that is used in cp-xref.c to determine whether a file name is
  1904. +    absolute or not.
  1905. +    This checks for both, '/' as first character, since we're running under
  1906. +    ixemul.library which provides for this unix'ism, and for the usual 
  1907. +    logical-terminator, ':', somewhere in the filename. */
  1908. + #define FILE_NAME_ABSOLUTE_P(NAME) (NAME[0] == '/' || index(NAME, ':'))
  1909. + /* the colon conflicts with the name space of logicals */
  1910. + #define PATH_SEPARATOR ','
  1911. + /* AmigaDOS handles rename(2) *much* better than any link(2)/unlink(2)
  1912. +    hacks. It's actually the inverse case as on Unix. rename(2) was always
  1913. +    there, link(2) is new with OS 2.0 */
  1914. + #define HAVE_rename 1
  1915. diff -rc --new-file gcc-2.6.0/configure /gnu/src/amiga/gcc-2.6.0/configure
  1916. *** gcc-2.6.0/configure    Mon Jul 11 23:25:53 1994
  1917. --- /gnu/src/amiga/gcc-2.6.0/configure    Fri Jul 29 18:22:28 1994
  1918. ***************
  1919. *** 4,9 ****
  1920. --- 4,13 ----
  1921.   
  1922.   #This file is part of GNU CC.
  1923.   
  1924. + # AmigaDOS Notes:  Where "echo" can be invoked with a first arg that
  1925. + # starts with '-', run the external echo instead, since the pdksh builtin
  1926. + # version botches this case.
  1927.   #GNU CC is free software; you can redistribute it and/or modify
  1928.   #it under the terms of the GNU General Public License as published by
  1929.   #the Free Software Foundation; either version 2, or (at your option)
  1930. ***************
  1931. *** 46,53 ****
  1932.   
  1933.   # Default --srcdir to the directory where the script is found, 
  1934.   # if a directory was specified.
  1935. ! # The second sed call is to convert `.//configure' to `./configure'.
  1936. ! srcdir=`echo $0 | sed 's|//|/|' | sed 's|/[^/]*$||'`
  1937.   if [ x$srcdir = x$0 ]
  1938.   then
  1939.   srcdir=
  1940. --- 50,59 ----
  1941.   
  1942.   # Default --srcdir to the directory where the script is found, 
  1943.   # if a directory was specified.
  1944. ! # The first sed call works around a bug in the AmigaDOS port of sksh, where
  1945. ! # $0 has a trailing slash appended to it.  It is a NOP for other systems.
  1946. ! # The third sed call is to convert `.//configure' to `./configure'.
  1947. ! srcdir=`echo $0 | sed 's|/$||' | sed 's|//|/|' | sed 's|/[^/]*$||'`
  1948.   if [ x$srcdir = x$0 ]
  1949.   then
  1950.   srcdir=
  1951. ***************
  1952. *** 55,70 ****
  1953.   
  1954.   host=
  1955.   
  1956. ! # Default prefix to /usr/local.
  1957. ! prefix=/usr/local
  1958.   
  1959. ! # local_prefix specifies where to find the directory /usr/local/include
  1960.   # We don't use $(prefix) for this
  1961. ! # because we always want GCC to search /usr/local/include
  1962. ! # even if GCC is installed somewhere other than /usr/local.
  1963.   # Think THREE TIMES before specifying any other value for this!
  1964.   # DO NOT make this use $prefix!
  1965. ! local_prefix=/usr/local
  1966.   # Default is to let the Makefile set exec_prefix from $(prefix)
  1967.   exec_prefix='$(prefix)'
  1968.   #
  1969. --- 61,86 ----
  1970.   
  1971.   host=
  1972.   
  1973. ! # Note:  For AmigaDOS we want this to default to /gnu unless we specify
  1974. ! # otherwise to configure.  We also don't want to have to remember to always
  1975. ! # configure with "--prefix=/gnu".  Changing it in Makefile.in or in
  1976. ! # config/m68k/x-amigados is ineffective since configure will always change
  1977. ! # it back in the final generated Makefile, so we have to go to the root of
  1978. ! # the problem, which is here.  There should be a way to do this in the
  1979. ! # individual machine configuration files!  -fnf
  1980. ! # here.  -fnf
  1981. ! # Default prefix to "/gnu".
  1982. ! prefix=/gnu
  1983.   
  1984. ! # local_prefix specifies where to find the directory /gnu/local/include
  1985.   # We don't use $(prefix) for this
  1986. ! # because we always want GCC to search /gnu/local/include
  1987. ! # even if GCC is installed somewhere other than /gnu/local.
  1988.   # Think THREE TIMES before specifying any other value for this!
  1989.   # DO NOT make this use $prefix!
  1990. ! # Note:  See AmigaDOS note above for this AmigaDOS specific change.  -fnf
  1991. ! # NoteII:We don't want to have yet-another-assign so we use /gnu/local
  1992. ! local_prefix=/gnu/local
  1993.   # Default is to let the Makefile set exec_prefix from $(prefix)
  1994.   exec_prefix='$(prefix)'
  1995.   #
  1996. ***************
  1997. *** 72,79 ****
  1998.   gxx_include_dir='$(libdir)/g++-include'
  1999.   
  2000.   remove=rm
  2001. ! hard_link=ln
  2002. ! symbolic_link='ln -s'
  2003.   copy=cp
  2004.   
  2005.   # Record all the arguments, to write them in config.status.
  2006. --- 88,100 ----
  2007.   gxx_include_dir='$(libdir)/g++-include'
  2008.   
  2009.   remove=rm
  2010. ! # AmigaDOS specific change.  Although we support symbolic links using
  2011. ! # the GNU tools, they need to be made using the syntax "somewhere:foo/bar"
  2012. ! # and not "/somewhere/foo/bar", since they must be in standard AmigaDOS
  2013. ! # format.  This should probably be done by having GNU ln translate paths
  2014. ! # that start with '/' to canonical AmigaDOS device:name form.
  2015. ! hard_link=cp
  2016. ! symbolic_link=cp
  2017.   copy=cp
  2018.   
  2019.   # Record all the arguments, to write them in config.status.
  2020. ***************
  2021. *** 129,159 ****
  2022.       next_arg=--srcdir
  2023.       ;;
  2024.        -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=* | --s=*)
  2025. !     srcdir=`echo $arg | sed 's/-*s[a-z]*=//'`
  2026.       ;;
  2027.        -host | --host | --hos | --ho | --h)
  2028.       next_arg=--host
  2029.       ;;
  2030.        -host=* | --host=* | --hos=* | --ho=* | --h=*)
  2031. !     host=`echo $arg | sed 's/-*h[a-z]*=//'`
  2032.       ;; 
  2033.        -target | --target | --targe | --targ | --tar | --ta | --t)
  2034.       next_arg=--target
  2035.       ;;
  2036.        -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  2037. !     target=`echo $arg | sed 's/-*t[a-z]*=//'`
  2038.       ;; 
  2039.        -build | --build | --buil | --bui | --bu | --b)
  2040.       next_arg=--build
  2041.       ;;
  2042.        -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
  2043. !     build=`echo $arg | sed 's/-*b[a-z]*=//'`
  2044.       ;; 
  2045.        -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  2046.       next_arg=--prefix
  2047.       ;;
  2048.        -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  2049. !     prefix=`echo $arg | sed 's/-*p[a-z]*=//'`
  2050.       ;;
  2051.        -local-prefix | --local-prefix | --local-prefi | --local-pref | --local-pre \
  2052.       | --local-pr | --local-p | --local- | --local | --loc | --lo | --l)
  2053. --- 150,180 ----
  2054.       next_arg=--srcdir
  2055.       ;;
  2056.        -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=* | --s=*)
  2057. !     srcdir=`/bin/echo $arg | sed 's/-*s[a-z]*=//'`
  2058.       ;;
  2059.        -host | --host | --hos | --ho | --h)
  2060.       next_arg=--host
  2061.       ;;
  2062.        -host=* | --host=* | --hos=* | --ho=* | --h=*)
  2063. !     host=`/bin/echo $arg | sed 's/-*h[a-z]*=//'`
  2064.       ;; 
  2065.        -target | --target | --targe | --targ | --tar | --ta | --t)
  2066.       next_arg=--target
  2067.       ;;
  2068.        -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  2069. !     target=`/bin/echo $arg | sed 's/-*t[a-z]*=//'`
  2070.       ;; 
  2071.        -build | --build | --buil | --bui | --bu | --b)
  2072.       next_arg=--build
  2073.       ;;
  2074.        -build=* | --build=* | --buil=* | --bui=* | --bu=* | --b=*)
  2075. !     build=`/bin/echo $arg | sed 's/-*b[a-z]*=//'`
  2076.       ;; 
  2077.        -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  2078.       next_arg=--prefix
  2079.       ;;
  2080.        -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  2081. !     prefix=`/bin/echo $arg | sed 's/-*p[a-z]*=//'`
  2082.       ;;
  2083.        -local-prefix | --local-prefix | --local-prefi | --local-pref | --local-pre \
  2084.       | --local-pr | --local-p | --local- | --local | --loc | --lo | --l)
  2085. ***************
  2086. *** 162,168 ****
  2087.        -local-prefix=* | --local-prefix=* | --local-prefi=* | --local-pref=* \
  2088.       | --local-pre=* | --local-pr=* | --local-p=* | --local-=* | --local=* \
  2089.       | --loc=* | --lo=* | --l=*)
  2090. !     local_prefix=`echo $arg | sed 's/-*l[-a-z]*=//'`
  2091.       ;;
  2092.        -gxx-include-dir | --gxx-include-dir | --gxx-include \
  2093.       | --gxx-incl | --gxx-inc | --gxx-in | --gxx-i | --gxx- \
  2094. --- 183,189 ----
  2095.        -local-prefix=* | --local-prefix=* | --local-prefi=* | --local-pref=* \
  2096.       | --local-pre=* | --local-pr=* | --local-p=* | --local-=* | --local=* \
  2097.       | --loc=* | --lo=* | --l=*)
  2098. !     local_prefix=`/bin/echo $arg | sed 's/-*l[-a-z]*=//'`
  2099.       ;;
  2100.        -gxx-include-dir | --gxx-include-dir | --gxx-include \
  2101.       | --gxx-incl | --gxx-inc | --gxx-in | --gxx-i | --gxx- \
  2102. ***************
  2103. *** 172,178 ****
  2104.        -gxx-include-dir=* | --gxx-include-dir=* | --gxx-include=* \
  2105.       | --gxx-incl=* | --gxx-inc=* | --gxx-in=* | --gxx-i=* \
  2106.       | --gxx-=* | --gxx=* | --gxx=* | --gxx=* | --g=*)
  2107. !     gxx_include_dir=`echo $arg | sed 's/-*g[-a-z]*=//'`
  2108.       ;;
  2109.        -exec-prefix | --exec-prefix | --exec-prefi | --exec-pref | --exec-pre \
  2110.       | --exec-pr | --exec-p | --exec- | --exec | --exe | --ex | --e)
  2111. --- 193,199 ----
  2112.        -gxx-include-dir=* | --gxx-include-dir=* | --gxx-include=* \
  2113.       | --gxx-incl=* | --gxx-inc=* | --gxx-in=* | --gxx-i=* \
  2114.       | --gxx-=* | --gxx=* | --gxx=* | --gxx=* | --g=*)
  2115. !     gxx_include_dir=`/bin/echo $arg | sed 's/-*g[-a-z]*=//'`
  2116.       ;;
  2117.        -exec-prefix | --exec-prefix | --exec-prefi | --exec-pref | --exec-pre \
  2118.       | --exec-pr | --exec-p | --exec- | --exec | --exe | --ex | --e)
  2119. ***************
  2120. *** 181,187 ****
  2121.        -exec-prefix=* | --exec-prefix=* | --exec-prefi=* | --exec-pref=* \
  2122.       | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* | --exec=* \
  2123.       | --exe=* | --ex=* | --e=*)
  2124. !     exec_prefix=`echo $arg | sed 's/-*e[-a-z]*=//'`
  2125.       ;;
  2126.        -with-gnu-ld | --with-gnu-ld | --with-gnu-l)
  2127.       gnu_ld=yes
  2128. --- 202,208 ----
  2129.        -exec-prefix=* | --exec-prefix=* | --exec-prefi=* | --exec-pref=* \
  2130.       | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* | --exec=* \
  2131.       | --exe=* | --ex=* | --e=*)
  2132. !     exec_prefix=`/bin/echo $arg | sed 's/-*e[-a-z]*=//'`
  2133.       ;;
  2134.        -with-gnu-ld | --with-gnu-ld | --with-gnu-l)
  2135.       gnu_ld=yes
  2136. ***************
  2137. *** 318,324 ****
  2138.       use_collect2=
  2139.       # Set this to override the default target model.
  2140.       target_cpu_default=
  2141. !     # Set this to force use of install.sh.
  2142.       broken_install=
  2143.       # Set this to control which fixincludes program to use.
  2144.       fixincludes=fixincludes
  2145. --- 339,346 ----
  2146.       use_collect2=
  2147.       # Set this to override the default target model.
  2148.       target_cpu_default=
  2149. !     # Set this to force use of install.sh (if set to 'yes')
  2150. !     # Set to name of installer to use a custom installer.
  2151.       broken_install=
  2152.       # Set this to control which fixincludes program to use.
  2153.       fixincludes=fixincludes
  2154. ***************
  2155. *** 1054,1059 ****
  2156. --- 1076,1091 ----
  2157.           tmake_file=t-svr3
  2158.           header_files=math-68881.h
  2159.           ;;
  2160. +     m68k-*-amigados)
  2161. +         xm_file=m68k/xm-amigados.h
  2162. +         out_file=m68k/amigados.c
  2163. +         tm_file=m68k/amigados.h
  2164. +         tmake_file=m68k/t-amigados
  2165. +         xmake_file=m68k/x-amigados
  2166. +         fixincludes=Makefile.in # Headers are already fixed.
  2167. +         broken_install=cp
  2168. +         install_headers_dir=install-headers-cp
  2169. +         ;;
  2170.       m68k-cbm-sysv4*)        # Commodore variant of V.4.
  2171.           tm_file=m68k/amix.h
  2172.           xm_file=m68k/xm-amix.h
  2173. ***************
  2174. *** 1921,1927 ****
  2175.       # Make it set VPATH if necessary so that the sources are found.
  2176.       # Also change its value of srcdir.
  2177.       # Also create a .gdbinit file which runs the one in srcdir
  2178. !     # and tells GDB to look there for source files.
  2179.       case $srcdir in
  2180.       . | ./$subdir | .././$subdir)
  2181.           rm -f Makefile.tem
  2182. --- 1953,1959 ----
  2183.       # Make it set VPATH if necessary so that the sources are found.
  2184.       # Also change its value of srcdir.
  2185.       # Also create a .gdbinit file which runs the one in srcdir
  2186. !     # and tells GDB to     look there for source files.
  2187.       case $srcdir in
  2188.       . | ./$subdir | .././$subdir)
  2189.           rm -f Makefile.tem
  2190. ***************
  2191. *** 1968,1975 ****
  2192.       then true
  2193.       else
  2194.           rm -f Makefile.xx
  2195. !         abssrcdir=`cd ${srcdir}; pwd`
  2196. !         sed "s|^INSTALL = .*|INSTALL = ${abssrcdir}/install.sh -c|" Makefile.tem > Makefile.xx
  2197.           rm -f Makefile.tem
  2198.           mv Makefile.xx Makefile.tem
  2199.       fi
  2200. --- 2000,2013 ----
  2201.       then true
  2202.       else
  2203.           rm -f Makefile.xx
  2204. !          if [ x$host_broken_install = xyes ]
  2205. !          then
  2206. !              abssrcdir=`cd ${srcdir}; pwd`
  2207. !              installer=${abssrcdir}/install.sh -c
  2208. !          else
  2209. !              installer=$host_broken_install
  2210. !          fi
  2211. !          sed "s|^INSTALL = .*|INSTALL = ${installer}|" Makefile.tem > Makefile.xx
  2212.           rm -f Makefile.tem
  2213.           mv Makefile.xx Makefile.tem
  2214.       fi
  2215. ***************
  2216. *** 2177,2186 ****
  2217.           rm -f symtest.tem
  2218.           if $symbolic_link symtest1.tem symtest.tem 2>/dev/null
  2219.           then
  2220. !             sed -e 's,CC=set-by-configure,CC=$(CC),' \
  2221.                   Makefile.tem > Makefile.xx
  2222.           else
  2223. !             sed -e "s,CC=set-by-configure,CC=\`case '$(CC)' in stage*) echo '$(CC)' | sed -e 's|stage|../stage|g';; *) echo '$(CC)';; esac\`," \
  2224.                   Makefile.tem > Makefile.xx
  2225.           fi
  2226.           rm -f Makefile.tem
  2227. --- 2215,2224 ----
  2228.           rm -f symtest.tem
  2229.           if $symbolic_link symtest1.tem symtest.tem 2>/dev/null
  2230.           then
  2231. !             sed -e 's,CC=set-by-configure,CC=\$(CC),' \
  2232.                   Makefile.tem > Makefile.xx
  2233.           else
  2234. !             sed -e "s,CC=set-by-configure,CC=\`case '\$(CC)' in stage*) echo '\$(CC)' | sed -e 's|stage|../stage|g';; *) echo '\$(CC)';; esac\`," \
  2235.                   Makefile.tem > Makefile.xx
  2236.           fi
  2237.           rm -f Makefile.tem
  2238. ***************
  2239. *** 2256,2261 ****
  2240. --- 2294,2313 ----
  2241.           vintmsg=" (vint)"
  2242.       fi
  2243.       
  2244. +     # If a subdirectory has a configure script, run it.
  2245. +     if [ x$subdir != x. ]
  2246. +     then
  2247. +         if [ -f $srcdir/configure ]
  2248. +         then
  2249. +             ${CONFIG_SHELL-sh} $srcdir/configure $arguments --srcdir=$srcdir
  2250. +         fi
  2251. +     fi
  2252. +     if [ xx${vint} != xx ]
  2253. +     then
  2254. +         vintmsg=" (vint)"
  2255. +     fi
  2256.       # If a subdirectory has a configure script, run it.
  2257.       if [ x$subdir != x. ]
  2258.       then
  2259. diff -rc --new-file gcc-2.6.0/cp/call.c /gnu/src/amiga/gcc-2.6.0/cp/call.c
  2260. *** gcc-2.6.0/cp/call.c    Sat Jul  9 07:10:06 1994
  2261. --- /gnu/src/amiga/gcc-2.6.0/cp/call.c    Mon Aug 29 16:41:12 1994
  2262. ***************
  2263. *** 1806,1812 ****
  2264.           }
  2265.         else
  2266.           {
  2267. !           if (TREE_CODE (instance) != CALL_EXPR)
  2268.           my_friendly_abort (125);
  2269.             if (TYPE_NEEDS_CONSTRUCTING (basetype))
  2270.           instance = build_cplus_new (basetype, instance, 0);
  2271. --- 1806,1816 ----
  2272.           }
  2273.         else
  2274.           {
  2275. !           if (TREE_CODE (instance) != CALL_EXPR
  2276. ! #ifdef PCC_STATIC_STRUCT_RETURN
  2277. !           && TREE_CODE (instance) != RTL_EXPR
  2278. ! #endif
  2279. !           )
  2280.           my_friendly_abort (125);
  2281.             if (TYPE_NEEDS_CONSTRUCTING (basetype))
  2282.           instance = build_cplus_new (basetype, instance, 0);
  2283. diff -rc --new-file gcc-2.6.0/gcc.c /gnu/src/amiga/gcc-2.6.0/gcc.c
  2284. *** gcc-2.6.0/gcc.c    Mon Jul 11 19:08:58 1994
  2285. --- /gnu/src/amiga/gcc-2.6.0/gcc.c    Fri Jul 29 09:39:40 1994
  2286. ***************
  2287. *** 1270,1286 ****
  2288.   #endif
  2289.   
  2290.   #ifndef STANDARD_EXEC_PREFIX
  2291. ! #define STANDARD_EXEC_PREFIX "/usr/local/lib/gcc-lib/"
  2292.   #endif /* !defined STANDARD_EXEC_PREFIX */
  2293.   
  2294.   static char *standard_exec_prefix = STANDARD_EXEC_PREFIX;
  2295. ! static char *standard_exec_prefix_1 = "/usr/lib/gcc/";
  2296.   #ifdef MD_EXEC_PREFIX
  2297.   static char *md_exec_prefix = MD_EXEC_PREFIX;
  2298.   #endif
  2299.   
  2300.   #ifndef STANDARD_STARTFILE_PREFIX
  2301. ! #define STANDARD_STARTFILE_PREFIX "/usr/local/lib/"
  2302.   #endif /* !defined STANDARD_STARTFILE_PREFIX */
  2303.   
  2304.   #ifdef MD_STARTFILE_PREFIX
  2305. --- 1270,1286 ----
  2306.   #endif
  2307.   
  2308.   #ifndef STANDARD_EXEC_PREFIX
  2309. ! #define STANDARD_EXEC_PREFIX "/gnu/lib/gcc-lib/"
  2310.   #endif /* !defined STANDARD_EXEC_PREFIX */
  2311.   
  2312.   static char *standard_exec_prefix = STANDARD_EXEC_PREFIX;
  2313. ! static char *standard_exec_prefix_1 = "/local/lib/gcc-lib/";
  2314.   #ifdef MD_EXEC_PREFIX
  2315.   static char *md_exec_prefix = MD_EXEC_PREFIX;
  2316.   #endif
  2317.   
  2318.   #ifndef STANDARD_STARTFILE_PREFIX
  2319. ! #define STANDARD_STARTFILE_PREFIX "/gnu/lib/"
  2320.   #endif /* !defined STANDARD_STARTFILE_PREFIX */
  2321.   
  2322.   #ifdef MD_STARTFILE_PREFIX
  2323. ***************
  2324. *** 1290,1300 ****
  2325.   static char *md_startfile_prefix_1 = MD_STARTFILE_PREFIX_1;
  2326.   #endif
  2327.   static char *standard_startfile_prefix = STANDARD_STARTFILE_PREFIX;
  2328. ! static char *standard_startfile_prefix_1 = "/lib/";
  2329. ! static char *standard_startfile_prefix_2 = "/usr/lib/";
  2330.   
  2331.   #ifndef TOOLDIR_BASE_PREFIX
  2332. ! #define TOOLDIR_BASE_PREFIX "/usr/local/"
  2333.   #endif
  2334.   static char *tooldir_base_prefix = TOOLDIR_BASE_PREFIX;
  2335.   static char *tooldir_prefix;
  2336. --- 1290,1300 ----
  2337.   static char *md_startfile_prefix_1 = MD_STARTFILE_PREFIX_1;
  2338.   #endif
  2339.   static char *standard_startfile_prefix = STANDARD_STARTFILE_PREFIX;
  2340. ! static char *standard_startfile_prefix_1 = "/local/lib/";
  2341. ! static char *standard_startfile_prefix_2 = "/local/lib/";
  2342.   
  2343.   #ifndef TOOLDIR_BASE_PREFIX
  2344. ! #define TOOLDIR_BASE_PREFIX "/local/"
  2345.   #endif
  2346.   static char *tooldir_base_prefix = TOOLDIR_BASE_PREFIX;
  2347.   static char *tooldir_prefix;
  2348. ***************
  2349. *** 1495,1502 ****
  2350. --- 1495,1507 ----
  2351.     base = choose_temp_base_try (P_tmpdir, base);
  2352.   #endif
  2353.   
  2354. + #ifdef amigados
  2355. +   if (!base) /* No env var set */
  2356. +     base = "RAM:";
  2357. + #else
  2358.     base = choose_temp_base_try ("/usr/tmp", base);
  2359.     base = choose_temp_base_try ("/tmp", base);
  2360. + #endif
  2361.   
  2362.     /* If all else fails, use the current directory! */  
  2363.     if (base == (char *)0)
  2364. ***************
  2365. *** 1505,1511 ****
  2366.     len = strlen (base);
  2367.     temp_filename = xmalloc (len + sizeof("/ccXXXXXX") + 1);
  2368.     strcpy (temp_filename, base);
  2369. !   if (len > 0 && temp_filename[len-1] != '/')
  2370.       temp_filename[len++] = '/';
  2371.     strcpy (temp_filename + len, "ccXXXXXX");
  2372.   
  2373. --- 1510,1520 ----
  2374.     len = strlen (base);
  2375.     temp_filename = xmalloc (len + sizeof("/ccXXXXXX") + 1);
  2376.     strcpy (temp_filename, base);
  2377. !   if (len > 0 && temp_filename[len-1] != '/'
  2378. ! #ifdef amigados
  2379. !                         && temp_filename[len-1] != ':'
  2380. ! #endif
  2381. !                                     )
  2382.       temp_filename[len++] = '/';
  2383.     strcpy (temp_filename + len, "ccXXXXXX");
  2384.   
  2385. ***************
  2386. *** 1650,1656 ****
  2387.   
  2388.     /* Determine the filename to execute (special case for absolute paths).  */
  2389.   
  2390. !   if (*name == '/')
  2391.       {
  2392.         if (access (name, mode))
  2393.       {
  2394. --- 1659,1669 ----
  2395.   
  2396.     /* Determine the filename to execute (special case for absolute paths).  */
  2397.   
  2398. !   if (*name == '/'
  2399. ! #ifdef amigados
  2400. !           || index (name, ':')
  2401. ! #endif
  2402. !                     )
  2403.       {
  2404.         if (access (name, mode))
  2405.       {
  2406. ***************
  2407. *** 1870,1875 ****
  2408. --- 1883,1889 ----
  2409.      NOT_LAST is nonzero if this is not the last subcommand
  2410.      (i.e. its output should be piped to the next one.)  */
  2411.   
  2412. + #ifndef PEXECUTE
  2413.   #ifndef OS2
  2414.   #ifdef __MSDOS__
  2415.   
  2416. ***************
  2417. *** 2025,2030 ****
  2418. --- 2039,2045 ----
  2419.     return (search_flag ? spawnv : spawnvp) (1, program, argv);
  2420.   }
  2421.   #endif /* not OS2 */
  2422. + #endif /* !defined (PEXECUTE) */
  2423.   
  2424.   /* Execute the command specified by the arguments on the current line of spec.
  2425.      When using pipes, this includes several piped-together commands
  2426. ***************
  2427. *** 2119,2127 ****
  2428. --- 2134,2148 ----
  2429.       {
  2430.         char *string = commands[i].argv[0];
  2431.   
  2432. + #ifdef PEXECUTE
  2433. +       commands[i].pid = PEXECUTE (string != commands[i].prog,
  2434. +                   string, commands[i].argv,
  2435. +                   i + 1 < n_commands);
  2436. + #else
  2437.         commands[i].pid = pexecute (string != commands[i].prog,
  2438.                     string, commands[i].argv,
  2439.                     i + 1 < n_commands);
  2440. + #endif
  2441.   
  2442.         if (string != commands[i].prog)
  2443.       free (string);
  2444. ***************
  2445. *** 2142,2152 ****
  2446. --- 2163,2177 ----
  2447.       int pid;
  2448.       char *prog = "unknown";
  2449.   
  2450. + #ifdef PEXECUTE_RESULT
  2451. +     pid = PEXECUTE_RESULT (status, commands[i]);
  2452. + #else /* PEXECUTE_RESULT */
  2453.   #ifdef __MSDOS__
  2454.           status = pid = commands[i].pid;
  2455.   #else
  2456.       pid = wait (&status);
  2457.   #endif
  2458. + #endif /* PEXECUTE_RESULT */
  2459.       if (pid < 0)
  2460.         abort ();
  2461.   
  2462. ***************
  2463. *** 2263,2268 ****
  2464. --- 2288,2294 ----
  2465.         if (*endp == PATH_SEPARATOR || *endp == 0)
  2466.           {
  2467.             strncpy (nstore, startp, endp-startp);
  2468. + #ifndef amigados
  2469.             if (endp == startp)
  2470.           {
  2471.             strcpy (nstore, "./");
  2472. ***************
  2473. *** 2274,2279 ****
  2474. --- 2300,2314 ----
  2475.           }
  2476.             else
  2477.           nstore[endp-startp] = 0;
  2478. + #else
  2479. +           if (endp[-1] != '/' && endp[-1] != ':')
  2480. +         {
  2481. +           nstore[endp-startp] = '/';
  2482. +           nstore[endp-startp+1] = 0;
  2483. +         }
  2484. +           else
  2485. +         nstore[endp-startp] = 0;
  2486. + #endif
  2487.             add_prefix (&exec_prefix, nstore, 0, 0, NULL_PTR);
  2488.             if (*endp == 0)
  2489.           break;
  2490. ***************
  2491. *** 2296,2301 ****
  2492. --- 2331,2337 ----
  2493.         if (*endp == PATH_SEPARATOR || *endp == 0)
  2494.           {
  2495.             strncpy (nstore, startp, endp-startp);
  2496. + #ifndef amigados
  2497.             if (endp == startp)
  2498.           {
  2499.             strcpy (nstore, "./");
  2500. ***************
  2501. *** 2307,2312 ****
  2502. --- 2343,2357 ----
  2503.           }
  2504.             else
  2505.           nstore[endp-startp] = 0;
  2506. + #else
  2507. +           if (endp[-1] != '/' && endp[-1] != ':')
  2508. +         {
  2509. +           nstore[endp-startp] = '/';
  2510. +           nstore[endp-startp+1] = 0;
  2511. +         }
  2512. +           else
  2513. +         nstore[endp-startp] = 0;
  2514. + #endif
  2515.             add_prefix (&startfile_prefix, nstore, 0, 0, NULL_PTR);
  2516.             if (*endp == 0)
  2517.           break;
  2518. ***************
  2519. *** 2330,2335 ****
  2520. --- 2375,2381 ----
  2521.         if (*endp == PATH_SEPARATOR || *endp == 0)
  2522.           {
  2523.             strncpy (nstore, startp, endp-startp);
  2524. + #ifndef amigados
  2525.             if (endp == startp)
  2526.           {
  2527.             strcpy (nstore, "./");
  2528. ***************
  2529. *** 2341,2346 ****
  2530. --- 2387,2401 ----
  2531.           }
  2532.             else
  2533.           nstore[endp-startp] = 0;
  2534. + #else
  2535. +           if (endp[-1] != '/' && endp[-1] != ':')
  2536. +         {
  2537. +           nstore[endp-startp] = '/';
  2538. +           nstore[endp-startp+1] = 0;
  2539. +         }
  2540. +           else
  2541. +         nstore[endp-startp] = 0;
  2542. + #endif
  2543.             add_prefix (&startfile_prefix, nstore, 0, 0, NULL_PTR);
  2544.             if (*endp == 0)
  2545.           break;
  2546. ***************
  2547. *** 4213,4222 ****
  2548. --- 4268,4281 ----
  2549.         register char *p;
  2550.         int len;
  2551.   
  2552. + #ifdef FILE_NAME_NONDIRECTORY
  2553. +       input_basename = FILE_NAME_NONDIRECTORY (input_filename);
  2554. + #else
  2555.         input_basename = input_filename;
  2556.         for (p = input_filename; *p; p++)
  2557.           if (*p == '/')
  2558.             input_basename = p + 1;
  2559. + #endif
  2560.   
  2561.         /* Find a suffix starting with the last period,
  2562.            and set basename_length to exclude that suffix.  */
  2563. diff -rc --new-file gcc-2.6.0/genconfig.c /gnu/src/amiga/gcc-2.6.0/genconfig.c
  2564. *** gcc-2.6.0/genconfig.c    Wed Jun 15 07:37:01 1994
  2565. --- /gnu/src/amiga/gcc-2.6.0/genconfig.c    Fri Jul 29 09:39:43 1994
  2566. ***************
  2567. *** 303,310 ****
  2568. --- 303,318 ----
  2569.     printf ("/* Generated automatically by the program `genconfig'\n\
  2570.   from the machine description file `md'.  */\n\n");
  2571.   
  2572. + #ifdef amigados
  2573. +   /* this constant probably better be 14 in general, or a cross compiling
  2574. +      host might choke on some amigados header files... */
  2575. +   /* Allow at least 14 operands for the sake of asm constructs.  */
  2576. +   max_recog_operands = 14;
  2577. + #else
  2578.     /* Allow at least 10 operands for the sake of asm constructs.  */
  2579.     max_recog_operands = 9;  /* We will add 1 later.  */
  2580. + #endif
  2581.     max_dup_operands = 1;
  2582.   
  2583.     /* Read the machine description.  */
  2584. diff -rc --new-file gcc-2.6.0/ginclude/stdarg.h /gnu/src/amiga/gcc-2.6.0/ginclude/stdarg.h
  2585. *** gcc-2.6.0/ginclude/stdarg.h    Sat Jul  9 02:04:27 1994
  2586. --- /gnu/src/amiga/gcc-2.6.0/ginclude/stdarg.h    Fri Jul 29 09:39:44 1994
  2587. ***************
  2588. *** 156,159 ****
  2589. --- 156,167 ----
  2590.   #endif /* _STDARG_H */
  2591.   
  2592.   #endif /* not _ANSI_STDARG_H_ */
  2593. + #ifdef amigados
  2594. + # ifndef _VA_LIST
  2595. + #  define _VA_LIST
  2596. +    typedef __gnuc_va_list va_list;
  2597. + # endif
  2598. + #endif /* amigados */
  2599.   #endif /* not _STDARG_H */
  2600. diff -rc --new-file gcc-2.6.0/ginclude/stddef.h /gnu/src/amiga/gcc-2.6.0/ginclude/stddef.h
  2601. *** gcc-2.6.0/ginclude/stddef.h    Mon Apr 25 18:13:23 1994
  2602. --- /gnu/src/amiga/gcc-2.6.0/ginclude/stddef.h    Fri Jul 29 09:39:45 1994
  2603. ***************
  2604. *** 3,8 ****
  2605. --- 3,48 ----
  2606.   #ifndef _ANSI_STDDEF_H
  2607.   #ifndef __STDDEF_H__
  2608.   
  2609. + #ifdef amigados
  2610. + /* GNU libc has special support in this file, 4.3bsd-net2 libc deserves that
  2611. +    just as well. The system headers are ANSI compliant, the used compiler IS
  2612. +    gcc, so it's really ok to use the system header, no reason to hassle
  2613. +    with a jungle of ifdefs. Besides, amigados is only defined if compiling
  2614. +    with host=amigados, it doesn't apply if compiling with target=amigados
  2615. +    on a different host with possibly different system headers. Same thing
  2616. +    would apply to gstdarg.h and gvarargs.h, but those headers are more
  2617. +    easily fixable than this one and I'm sick of writing the same comment
  2618. +    there as well. MW
  2619. +    Include the contents of <stddef.h> inline rather than with a #include,
  2620. +    to avoid infinite include recursion when this file is installed in
  2621. +    gcc's include directory as stddef.h.  (fnf)  */
  2622. + #define _STDDEF_H_
  2623. + #include <machine/ansi.h>
  2624. + typedef    _PTRDIFF_T_    ptrdiff_t;
  2625. + #ifdef    _SIZE_T_
  2626. + typedef    _SIZE_T_    size_t;
  2627. + #undef    _SIZE_T_
  2628. + #endif
  2629. + #ifdef    _WCHAR_T_
  2630. + typedef    _WCHAR_T_    wchar_t;
  2631. + #undef    _WCHAR_T_
  2632. + #endif
  2633. + #ifndef    NULL
  2634. + #define    NULL    0
  2635. + #endif
  2636. + #define    offsetof(type, member)    ((size_t)(&((type *)0)->member))
  2637. + #else /* not amigados */
  2638.   /* Any one of these symbols __need_* means that GNU libc
  2639.      wants us just to define one data type.  So don't define
  2640.      the symbols that indicate this file's entire job has been done.  */
  2641. ***************
  2642. *** 172,177 ****
  2643. --- 212,219 ----
  2644.   #ifndef __WCHAR_TYPE__
  2645.   #define __WCHAR_TYPE__ int
  2646.   #endif
  2647. + #endif /* not  amigados */
  2648.   typedef __WCHAR_TYPE__ wchar_t;
  2649.   #endif
  2650.   #endif
  2651. diff -rc --new-file gcc-2.6.0/ginclude/varargs.h /gnu/src/amiga/gcc-2.6.0/ginclude/varargs.h
  2652. *** gcc-2.6.0/ginclude/varargs.h    Sat Jul  9 02:04:32 1994
  2653. --- /gnu/src/amiga/gcc-2.6.0/ginclude/varargs.h    Fri Jul 29 09:39:45 1994
  2654. ***************
  2655. *** 173,175 ****
  2656. --- 173,182 ----
  2657.   #ifdef _BSD_VA_LIST
  2658.   #undef _BSD_VA_LIST
  2659.   #endif
  2660. + #ifdef amigados
  2661. + # ifndef _VA_LIST
  2662. + #  define _VA_LIST
  2663. +    typedef __gnuc_va_list va_list;
  2664. + # endif
  2665. + #endif /* amigados */
  2666. diff -rc --new-file gcc-2.6.0/loop.c /gnu/src/amiga/gcc-2.6.0/loop.c
  2667. *** gcc-2.6.0/loop.c    Wed Jun 29 23:20:54 1994
  2668. --- /gnu/src/amiga/gcc-2.6.0/loop.c    Fri Jul 29 09:40:10 1994
  2669. ***************
  2670. *** 1791,1798 ****
  2671.                     /* Because the USAGE information potentially
  2672.                        contains objects other than hard registers
  2673.                        we need to copy it.  */
  2674. !                   CALL_INSN_FUNCTION_USAGE (i1) =
  2675. !                     copy_rtx (CALL_INSN_FUNCTION_USAGE (temp));
  2676.                   }
  2677.                     else
  2678.                   i1 = emit_insn_before (body, loop_start);
  2679. --- 1791,1799 ----
  2680.                     /* Because the USAGE information potentially
  2681.                        contains objects other than hard registers
  2682.                        we need to copy it.  */
  2683. !                   if (CALL_INSN_FUNCTION_USAGE (temp))
  2684. !                     CALL_INSN_FUNCTION_USAGE (i1) =
  2685. !                       copy_rtx (CALL_INSN_FUNCTION_USAGE (temp));
  2686.                   }
  2687.                     else
  2688.                   i1 = emit_insn_before (body, loop_start);
  2689. diff -rc --new-file gcc-2.6.0/protoize.c /gnu/src/amiga/gcc-2.6.0/protoize.c
  2690. *** gcc-2.6.0/protoize.c    Mon Jul 11 19:10:20 1994
  2691. --- /gnu/src/amiga/gcc-2.6.0/protoize.c    Fri Jul 29 09:39:51 1994
  2692. ***************
  2693. *** 828,835 ****
  2694. --- 828,840 ----
  2695.   {
  2696.     struct default_include *p;
  2697.   
  2698. + #ifdef FILE_NAME_ABSOLUTE_P
  2699. +   if (! FILE_NAME_ABSOLUTE_P (path))
  2700. +     abort ();
  2701. + #else
  2702.     if (path[0] != '/')
  2703.       abort ();        /* Must be an absolutized filename.  */
  2704. + #endif
  2705.   
  2706.     for (p = include_defaults; p->fname; p++)
  2707.       if (!strncmp (path, p->fname, strlen (p->fname))
  2708. ***************
  2709. *** 1256,1262 ****
  2710. --- 1261,1271 ----
  2711.     {
  2712.       const char *src_p;
  2713.   
  2714. + #ifdef FILE_NAME_ABSOLUTE_P
  2715. +     if (! FILE_NAME_ABSOLUTE_P (rel_filename))
  2716. + #else
  2717.       if (rel_filename[0] != '/')
  2718. + #endif
  2719.         {
  2720.           src_p = cwd2;
  2721.           while (*endp++ = *src_p++)
  2722. ***************
  2723. *** 1519,1524 ****
  2724. --- 1528,1552 ----
  2725.     return ++q;
  2726.   }
  2727.   
  2728. + /* Use this macro to advance a char * over the filename part in a line
  2729. +    read from an aux-info file. */
  2730. + #ifndef amigados
  2731. + /* Version for file systems where the colon has no special meaning */
  2732. + #define ADVANCE_PAST_FILENAME(CP) \
  2733. +   while (* (CP) != ':') (CP)++
  2734. + #else
  2735. + /* Have to heuristically decide whether the colon is part of the filename
  2736. +    or whether it serves to delimit the filename from the line number. If
  2737. +    it's the latter case, then the character following the colon *must*
  2738. +    be a digit. Note that this heuristic fails if the filename starts
  2739. +    with a digit. */
  2740. + #define ADVANCE_PAST_FILENAME(CP) \
  2741. +     while ((CP)[0] != ':' || !isdigit ((CP)[1])) \
  2742. +       (CP)++;
  2743. + #endif
  2744.   /* Given a line from  an aux info file, and a time at which the aux info
  2745.      file it came from was created, check to see if the item described in
  2746.      the line comes from a file which has been modified since the aux info
  2747. ***************
  2748. *** 1540,1547 ****
  2749.     {
  2750.       const char *filename_start = p = l + 3;
  2751.   
  2752. !     while (*p != ':')
  2753. !       p++;
  2754.       filename = (char *) alloca ((size_t) (p - filename_start) + 1);
  2755.       strncpy (filename, filename_start, (size_t) (p - filename_start));
  2756.       filename[p-filename_start] = '\0';
  2757. --- 1568,1574 ----
  2758.     {
  2759.       const char *filename_start = p = l + 3;
  2760.   
  2761. !     ADVANCE_PAST_FILENAME (p);
  2762.       filename = (char *) alloca ((size_t) (p - filename_start) + 1);
  2763.       strncpy (filename, filename_start, (size_t) (p - filename_start));
  2764.       filename[p-filename_start] = '\0';
  2765. ***************
  2766. *** 1598,1605 ****
  2767.       const char *filename_start = p = l + 3;
  2768.       char *filename;
  2769.   
  2770. !     while (*p != ':')
  2771. !       p++;
  2772.       filename = (char *) alloca ((size_t) (p - filename_start) + 1);
  2773.       strncpy (filename, filename_start, (size_t) (p - filename_start));
  2774.       filename[p-filename_start] = '\0';
  2775. --- 1625,1631 ----
  2776.       const char *filename_start = p = l + 3;
  2777.       char *filename;
  2778.   
  2779. !     ADVANCE_PAST_FILENAME (p);
  2780.       filename = (char *) alloca ((size_t) (p - filename_start) + 1);
  2781.       strncpy (filename, filename_start, (size_t) (p - filename_start));
  2782.       filename[p-filename_start] = '\0';
  2783. ***************
  2784. *** 2319,2325 ****
  2785.     {
  2786.       char *p = aux_info_base;
  2787.   
  2788. !     while (*p != ':')
  2789.         p++;
  2790.       p++;
  2791.       while (*p == ' ')
  2792. --- 2345,2353 ----
  2793.     {
  2794.       char *p = aux_info_base;
  2795.   
  2796. !     /* have to make sure at least one space is following the colon to make
  2797. !        sure the colon is not part of the filename */
  2798. !     while (*p != ':' && p[1] != ' ')
  2799.         p++;
  2800.       p++;
  2801.       while (*p == ' ')
  2802. ***************
  2803. *** 2333,2339 ****
  2804.         continue;
  2805.       aux_info_second_line = p;
  2806.       aux_info_relocated_name = 0;
  2807. !     if (invocation_filename[0] != '/')
  2808.         {
  2809.       /* INVOCATION_FILENAME is relative;
  2810.          append it to BASE_SOURCE_FILENAME's dir.  */
  2811. --- 2361,2371 ----
  2812.         continue;
  2813.       aux_info_second_line = p;
  2814.       aux_info_relocated_name = 0;
  2815. ! #ifdef FILE_NAME_ABSOLUTE_P
  2816. !     if (! FILE_NAME_ABSOLUTE_P (invocation_filename))
  2817. ! #else
  2818. !       if (invocation_filename[0] != '/')
  2819. ! #endif
  2820.         {
  2821.       /* INVOCATION_FILENAME is relative;
  2822.          append it to BASE_SOURCE_FILENAME's dir.  */
  2823. ***************
  2824. *** 2422,2428 ****
  2825.   #ifndef UNPROTOIZE
  2826.   
  2827.   /* Check an individual filename for a .c suffix.  If the filename has this
  2828. !    suffix, rename the file such that its suffix is changed to .C.  This
  2829.      function implements the -C option.  */
  2830.   
  2831.   static void
  2832. --- 2454,2460 ----
  2833.   #ifndef UNPROTOIZE
  2834.   
  2835.   /* Check an individual filename for a .c suffix.  If the filename has this
  2836. !    suffix, rename the file such that its suffix is changed to .cc.  This
  2837.      function implements the -C option.  */
  2838.   
  2839.   static void
  2840. ***************
  2841. *** 2431,2437 ****
  2842.   {
  2843.     const char *filename = hp->symbol;
  2844.     int last_char_index = strlen (filename) - 1;
  2845. !   char *const new_filename = (char *) alloca (strlen (filename) + 1);
  2846.   
  2847.     /* Note that we don't care here if the given file was converted or not.  It
  2848.        is possible that the given file was *not* converted, simply because there
  2849. --- 2463,2469 ----
  2850.   {
  2851.     const char *filename = hp->symbol;
  2852.     int last_char_index = strlen (filename) - 1;
  2853. !   char *const new_filename = (char *) alloca (strlen (filename) + 2);
  2854.   
  2855.     /* Note that we don't care here if the given file was converted or not.  It
  2856.        is possible that the given file was *not* converted, simply because there
  2857. ***************
  2858. *** 2443,2450 ****
  2859.       return;
  2860.   
  2861.     strcpy (new_filename, filename);
  2862. !   new_filename[last_char_index] = 'C';
  2863.   
  2864.     if (my_link (filename, new_filename) == -1)
  2865.       {
  2866.         fprintf (stderr, "%s: warning: can't link file `%s' to `%s': %s\n",
  2867. --- 2475,2499 ----
  2868.       return;
  2869.   
  2870.     strcpy (new_filename, filename);
  2871. !   strcat (new_filename + last_char_index, "cc");
  2872. !   
  2873. !   /* use rename(2) if available !! Update config files to include HAVE_rename
  2874. !      if the used OS provides it. Advantages are: it's atomic, it's one
  2875. !      system call compared to two. */
  2876. ! #ifdef HAVE_rename
  2877. !   /* if the mentioned systems (POSIX 1003.1-1988) have rename(2), this has
  2878. !      to be changed to `my_rename' as well. */
  2879.   
  2880. +   if (rename (filename, new_filename) == -1)
  2881. +     {
  2882. +       fprintf (stderr, "%s: warning: can't rename file `%s' to `%s': %s\n",
  2883. +            pname, shortpath (NULL, filename),
  2884. +            shortpath (NULL, new_filename), sys_errlist[errno]);
  2885. +       errors++;
  2886. +       return;
  2887. +     }
  2888. + #else
  2889.     if (my_link (filename, new_filename) == -1)
  2890.       {
  2891.         fprintf (stderr, "%s: warning: can't link file `%s' to `%s': %s\n",
  2892. ***************
  2893. *** 2461,2466 ****
  2894. --- 2510,2516 ----
  2895.         errors++;
  2896.         return;
  2897.       }
  2898. + #endif
  2899.   }
  2900.   
  2901.   #endif /* !defined (UNPROTOIZE) */
  2902. diff -rc --new-file gcc-2.6.0/real.c /gnu/src/amiga/gcc-2.6.0/real.c
  2903. *** gcc-2.6.0/real.c    Tue Jun 28 09:13:52 1994
  2904. --- /gnu/src/amiga/gcc-2.6.0/real.c    Fri Jul 29 09:39:56 1994
  2905. ***************
  2906. *** 4279,4287 ****
  2907. --- 4279,4293 ----
  2908.     if (y[NE - 1] == 0x7fff)
  2909.       {
  2910.         if (sign)
  2911. + #ifdef amigados
  2912.       sprintf (wstring, " -Infinity ");
  2913.         else
  2914.       sprintf (wstring, " Infinity ");
  2915. + #else
  2916. +     sprintf (wstring, " -NaN ");
  2917. +       else
  2918. +     sprintf (wstring, " NaN ");
  2919. + #endif
  2920.         goto bxit;
  2921.       }
  2922.   
  2923. diff -rc --new-file gcc-2.6.0/scan-types.sh /gnu/src/amiga/gcc-2.6.0/scan-types.sh
  2924. *** gcc-2.6.0/scan-types.sh    Mon Apr 18 07:07:12 1994
  2925. --- /gnu/src/amiga/gcc-2.6.0/scan-types.sh    Fri Jul 29 09:39:59 1994
  2926. ***************
  2927. *** 1,4 ****
  2928. ! #! /bin/sh
  2929.   # Deduce values of standard ANSI and POSIX types (e.g. size_t, pid_t).
  2930.   # Emits macros definitions for these, and some other types.
  2931.   # Intended to be used to massage the sys-protos.h file.
  2932. --- 1,4 ----
  2933. ! #!/bin/sh
  2934.   # Deduce values of standard ANSI and POSIX types (e.g. size_t, pid_t).
  2935.   # Emits macros definitions for these, and some other types.
  2936.   # Intended to be used to massage the sys-protos.h file.
  2937. diff -rc --new-file gcc-2.6.0/toplev.c /gnu/src/amiga/gcc-2.6.0/toplev.c
  2938. *** gcc-2.6.0/toplev.c    Thu Jul  7 02:58:55 1994
  2939. --- /gnu/src/amiga/gcc-2.6.0/toplev.c    Fri Jul 29 09:40:04 1994
  2940. ***************
  2941. *** 532,537 ****
  2942. --- 532,538 ----
  2943.     {"unroll-all-loops", &flag_unroll_all_loops, 1},
  2944.     {"writable-strings", &flag_writable_strings, 1},
  2945.     {"peephole", &flag_no_peephole, 0},
  2946. +   {"large-baserel", &flag_pic, 4},
  2947.     {"force-mem", &flag_force_mem, 1},
  2948.     {"force-addr", &flag_force_addr, 1},
  2949.     {"function-cse", &flag_no_function_cse, 0},
  2950. ***************
  2951. *** 550,555 ****
  2952. --- 551,557 ----
  2953.     {"schedule-insns2", &flag_schedule_insns_after_reload, 1},
  2954.     {"pic", &flag_pic, 1},
  2955.     {"PIC", &flag_pic, 2},
  2956. +   {"baserel", &flag_pic, 3},
  2957.     {"fast-math", &flag_fast_math, 1},
  2958.     {"common", &flag_no_common, 0},
  2959.     {"inhibit-size-directive", &flag_inhibit_size_directive, 1},
  2960. ***************
  2961. *** 1947,1952 ****
  2962. --- 1949,1957 ----
  2963.        FILE *asm_file;
  2964.        char *input_name;
  2965.   {
  2966. + #ifdef FILE_NAME_NONDIRECTORY
  2967. +   char *na = FILE_NAME_NONDIRECTORY (input_name);
  2968. + #else
  2969.     int len = strlen (input_name);
  2970.     char *na = input_name + len;
  2971.   
  2972. ***************
  2973. *** 1957,1962 ****
  2974. --- 1962,1968 ----
  2975.       break;
  2976.         na--;
  2977.       }
  2978. + #endif
  2979.   
  2980.   #ifdef ASM_OUTPUT_MAIN_SOURCE_FILENAME
  2981.     ASM_OUTPUT_MAIN_SOURCE_FILENAME (asm_file, na);
  2982. ***************
  2983. *** 3929,3934 ****
  2984. --- 3935,3941 ----
  2985.   
  2986.   #ifndef OS2
  2987.   #ifndef VMS
  2988. + #ifndef amigados
  2989.     if (flag_print_mem)
  2990.       {
  2991.   #ifdef __alpha
  2992. ***************
  2993. *** 3946,3951 ****
  2994. --- 3953,3959 ----
  2995.         system ("ps v");
  2996.   #endif /* not USG */
  2997.       }
  2998. + #endif /* not amigados */
  2999.   #endif /* not VMS */
  3000.   #endif /* not OS2 */
  3001.   
  3002.