Re: [PATCH] kbuild: support byacc as alternative YACC to bison

From: Masahiro Yamada
Date: Mon Oct 28 2019 - 21:57:01 EST


Hi Ethan,

On Tue, Oct 29, 2019 at 10:41 AM Ethan Sommer <e5ten.arch@xxxxxxxxx> wrote:
>
> > I applied this patch, and tried the latest byacc,
> > but I still cannot build kconfig probably because
> > %destructor is not supported.
> > byacc does not seem to work anyway.
>
> Hi Masahiro, because I hadn't built it in a while I completely forgot
> that to support %destructor byacc needs to be built with
> --enable-btyacc, should I update the commit message to include that
> detail?

OK, I was able to build kconfig with --enable-btyacc.

byacc still cannot build scripts/dtc/dtc-parser.y
Thought?

dtc is not compiled for x86.
Please try ARCH=arm.


masahiro@pug:~/ref/linux$ make ARCH=arm
CROSS_COMPILE=arm-linux-gnueabihf- YACC=/home/masahiro/bin/yacc
scripts/kconfig/conf --syncconfig Kconfig
SYSHDR arch/arm/include/generated/uapi/asm/unistd-common.h
SYSHDR arch/arm/include/generated/uapi/asm/unistd-oabi.h
SYSHDR arch/arm/include/generated/uapi/asm/unistd-eabi.h
HOSTCC scripts/dtc/dtc.o
HOSTCC scripts/dtc/flattree.o
HOSTCC scripts/dtc/fstree.o
HOSTCC scripts/dtc/data.o
HOSTCC scripts/dtc/livetree.o
HOSTCC scripts/dtc/treesource.o
HOSTCC scripts/dtc/srcpos.o
HOSTCC scripts/dtc/checks.o
HOSTCC scripts/dtc/util.o
LEX scripts/dtc/dtc-lexer.lex.c
YACC scripts/dtc/dtc-parser.tab.[ch]
/home/masahiro/bin/yacc: e - line 120 of "scripts/dtc/dtc-parser.y",
syntax error
ERROR(&@2, "Header flags don't match earlier ones");
^
make[1]: *** [scripts/Makefile.host;17: scripts/dtc/dtc-parser.tab.h] Error 1
make[1]: *** Deleting file 'scripts/dtc/dtc-parser.tab.h'
make[1]: *** [scripts/dtc/dtc-parser.tab.h] Deleting file
'scripts/dtc/dtc-parser.tab.c'
make: *** [Makefile;1260: scripts_dtc] Error 2




--
Best Regards
Masahiro Yamada