Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!usc!ucsd!ucsdhub!hp-sdd!apollo!vasta From: vasta@apollo.HP.COM (John Vasta) Newsgroups: comp.sys.apollo Subject: Re: GCC 1.37 for the Apollo Message-ID: <48ebcf75.20b6d@apollo.HP.COM> Date: 28 Feb 90 22:16:00 GMT References: <48c776b3.20b6d@apollo.HP.COM> <1140@tuvie> Sender: root@apollo.HP.COM Reply-To: vasta@apollo.HP.COM (John Vasta) Followup-To: comp.sys.apollo Organization: Hewlett-Packard Company, Apollo Division; Chelmsford, MA Lines: 54 In article <1140@tuvie> inst182@tuvie.UUCP (Inst.f.Techn.Informatik) writes: >In article <48c776b3.20b6d@apollo.HP.COM> vasta@apollo.HP.COM (John Vasta) writes: >>The changes required to get the GNU C compiler running on >>Apollo 68K platforms are available via anonymous ftp from >>labrea.stanford.edu in the form of a compressed tar file >>named "/pub/gnu/apollo-gcc-1.37.tar.Z". > >I got the tar file from stanford and it compiled ok. Bootstrapping >however did not work: > >[michael:95] make >gcc -O -fstrength-reduce -I. -I. -I./config >-DSTANDARD_STARTFILE_PREFIX=\"/usr/local/lib/\" >-DSTANDARD_EXEC_PREFIX=\"/usr/local/lib/gcc-\" -c `echo ./gcc.c | sed >'s,^\./,,'` >In file included from gcc.c:131: >/usr/include/stdio.h:30: parse error before `#' >/usr/include/stdio.h:32: parse error before `#' >gcc.c: In function main: >gcc.c:1471: warning: argument passing between incompatible pointer types >gcc.c:1473: warning: argument passing between incompatible pointer types >gcc.c:1475: warning: argument passing between incompatible pointer types >*** Exit 1 > >Stop. > >and in /usr/include/stdio.h is: > >extern struct _iobuf { > unsigned char *_ptr #attribute[aligned(1)]; /* line 30 */ > short _cnt; > unsigned char *_base #attribute[aligned(1)]; > short _flag; > short _file; >} _iob[]; > >Is it save to just copy stdio.h to /usr/local/lib/gcc-include/stdio.h >and remove the offending `#attribute's??? For some reason the parser was not rebuilt. The tar file contains a new version of c-parse.y which should have replaced the old version. You need to have Bison built and installed. Make sure that you got the c-parse.y file from the tar file, then delete 'c-parse.tab.*' in the gcc directory and rebuild. Otherwise, you could produce versions of the header files with the syntax extensions removed since they are only ignored by the modified gcc parser anyway. But it would be easier to just rebuild the parser. John Vasta Hewlett-Packard Apollo Systems Division vasta@apollo.hp.com M.S. CHA-01-LT (508) 256-6600 x6362 300 Apollo Drive, Chelmsford, MA 01824 UUCP: {decwrl!decvax, mit-eddie, attunix}!apollo!vasta