Am Thu, 1 Aug 2002 05:40:24 +0200 schrieb Sebastian Helms:
* Philipp Thomas schrieb am 01 Aug 2002:
gcc -DIN_GCC -g -DHAVE_CONFIG_H -I. -I../../gcc -I../../gcc/config -I../../gcc/../include -c ../../gcc/c-parse.c /usr/share/bison.simple:172: conflicting types for `yyparse' ../../gcc/tree.h:2083: previous declaration of `yyparse'
Hier hat der Compiler versucht, c-parse.c zu übersetzen, welches aus c-parse.y entsteht. Nicht Bison meldet den Fehler, sondern der Compiler, weil letzterer sich widersprechende Typen für yyparse vorfindet. Ich würde zur Sicherheit ein
find . -name \*.y |xargs touch
in das Specfile einbauen. Damit wäre sichergestellt, dass alle .y noch einmal mit demselben Bison verarbeitet werden.
Hm. In den .c-Dateien aus dem tarball steht bison 1.25, den hab ich auch auf dem Rechner. Sprich, die mit bison selber erzeugte .c-Datei ist identisch mit der mitgelieferten ...
Könnte es an der bison.simple liegen?
Ich schmeiß das jetzt einfach mal so ein, ohne den thread verfolgt zu haben oder eine Ahnung von compilern zu haben. ---schnipp---- Bison problem under Unix The bison.simple file on many releases will not compile with the options used by the PWLib getdate.y grammar. The options are required to make the date parser thread safe so it is necessary to edit the bison.simple file to fix the problem. The file is usually at /usr/lib/bison.simple but in the tradition of unix could actually be anywhere. We leave it up to you to find it. The code: /* Prevent warning if -Wstrict-prototypes. */ #ifdef __GNUC__ int yyparse (void); #endif should be changed to /* Prevent warning if -Wstrict-prototypes. */ #ifdef __GNUC__ #ifndef YYPARSE_PARAM int yyparse (void); #endif #endif To prevent the incorrect function prototype from being defined. The getdate.y should then produce a getdate.tab.c file that will actually compile. ---schnapp--- Maybe? -- Andreas Meyer http://home.wtal.de/MeineHomepage