lojban / jbofihe

Parser & analyser for Lojban
GNU General Public License v2.0
33 stars 2 forks source link

rpc2x_act.tab.h: No such file or directory #11

Closed mozai closed 3 years ago

mozai commented 3 years ago

The Makefile renames the output from bison, then gcc later stops because it's looking for the file by it's original name.

Steps to reproduce:

LC_ALL=C make all

Seen:

bison -v -d rpc2x_act.y  
rpc2x_act.y: warning: 1 nonterminal useless in grammar [-Wother]
rpc2x_act.y: warning: 59 rules useless in grammar [-Wother]
rpc2x_act.y:360.1-14: warning: nonterminal useless in grammar: text_no_text_1 [-Wother]
  360 | text_no_text_1 : NAI_seq CMENE_seq free_seq joik_opt_ke free_seq
      | ^~~~~~~~~~~~~~
rpc2x_act.y: warning: 6675 shift/reduce conflicts [-Wconflicts-sr]
rpc2x_act.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples
mv rpc2x_act.tab.h rpc_tab.h   ### Makefile line 67
gcc -O2  -DHAVE_MMAP=1 -DDEFAULT_DICTIONARY=\"/usr/lib/jbofihe/smujmaji.dat\" -c lex2.c
gcc -O2  -DHAVE_MMAP=1 -DDEFAULT_DICTIONARY=\"/usr/lib/jbofihe/smujmaji.dat\" -c cmavotab.c
perl add_trace_to_tabc.pl < rpc2x_act.tab.c > rpc_tab.c
gcc -O2  -DHAVE_MMAP=1 -DDEFAULT_DICTIONARY=\"/usr/lib/jbofihe/smujmaji.dat\" -c rpc_tab.c
rpc_tab.c:1:8: warning: type defaults to 'int' in declaration of 'elide_trace_reduce' [-Wimplicit-int]
    1 | extern elide_trace_reduce(int, int);
      |        ^~~~~~~~~~~~~~~~~~
rpc_tab.c:2:8: warning: type defaults to 'int' in declaration of 'elide_trace_shift' [-Wimplicit-int]
    2 | extern elide_trace_shift(int,int);
      |        ^~~~~~~~~~~~~~~~~
rpc_tab.c:3:8: warning: type defaults to 'int' in declaration of 'report_trace_shift' [-Wimplicit-int]
    3 | extern report_trace_shift(int);
      |        ^~~~~~~~~~~~~~~~~~
rpc_tab.c:4:8: warning: type defaults to 'int' in declaration of 'report_trace_reduce' [-Wimplicit-int]
    4 | extern report_trace_reduce(int, int);
      |        ^~~~~~~~~~~~~~~~~~~
rpc_tab.c:5:8: warning: type defaults to 'int' in declaration of 'report_trace_error' [-Wimplicit-int]
    5 | extern report_trace_error(short *yyss, short *yyssp);
      |        ^~~~~~~~~~~~~~~~~~
rpc2x_act.tab.c:113:10: fatal error: rpc2x_act.tab.h: No such file or directory
  113 | #include "rpc2x_act.tab.h"
      |          ^~~~~~~~~~~~~~~~~
compilation terminated.