2.6.18-rc1 build error (YACC): followup
Quoted 6 lines · I wrote:
$YACC now seems to be undefined when I do a "make bzImage" and the build process gets to
drivers/scsi/aic7xxx/aicasm(with the aic7xxx driver configured as a built-in). As a workaround, it's possible to "cd" into the indicated directory and run "make" directly. Once the default build completes, restarting "make bzImage" from the kernel source root continues as expected.
Found it. The main "Makefile" has "MAKEFLAGS += -rR" uncommented as of 2.6.18-rc1. The deleted comment about "possibly random breakage" that used to be just above that line pretty much says it all :-).
Signature · 4 lines
----------------------------------------------------------------------- Bob Tracy WTO + WIPO = DMCA? http://www.anti-dmca.org [email protected] -----------------------------------------------------------------------
Quoted 11 lines · Bob Tracy
Quoted 6 lines · I wrote:
$YACC now seems to be undefined when I do a "make bzImage" and the build process gets to
drivers/scsi/aic7xxx/aicasm(with the aic7xxx driver configured as a built-in). As a workaround, it's possible to "cd" into the indicated directory and run "make" directly. Once the default build completes, restarting "make bzImage" from the kernel source root continues as expected.Found it. The main "
Makefile" has "MAKEFLAGS += -rR" uncommented as of 2.6.18-rc1. The deleted comment about "possibly random breakage" that used to be just above that line pretty much says it all :-).
Translated: aic7xxx must supply its own definition of YACC or we should put it in the top-level Makefile.
kbuild no longer rely on the predefined variables in make.
Sam
Quoted 11 lines · Bob Tracy
Quoted 6 lines · I wrote:
$YACC now seems to be undefined when I do a "make bzImage" and the build process gets to
drivers/scsi/aic7xxx/aicasm(with the aic7xxx driver configured as a built-in). As a workaround, it's possible to "cd" into the indicated directory and run "make" directly. Once the default build completes, restarting "make bzImage" from the kernel source root continues as expected.Found it. The main "
Makefile" has "MAKEFLAGS += -rR" uncommented as of 2.6.18-rc1. The deleted comment about "possibly random breakage" that used to be just above that line pretty much says it all :-).
I have now applied a patch where YACC= bison is dined in aicasm/Makefile.
There are no other $(YACC) users in the kernel - the others specify bison direct.
Sam
Quoted 8 lines · Sam Ravnborg
Quoted 7 lines · Bob Tracy
Quoted 6 lines · I wrote:
$YACC now seems to be undefined when I do a "make bzImage" and the build process gets to
drivers/scsi/aic7xxx/aicasm(with the aic7xxx driver configured as a built-in). As a workaround, it's possible to "cd" into the indicated directory and run "make" directly. Once the default build completes, restarting "make bzImage" from the kernel source root continues as expected.
Quoted 8 lines
Quoted 3 lines
Found it. The main "
Makefile" has "MAKEFLAGS += -rR" uncommented as of 2.6.18-rc1. The deleted comment about "possibly random breakage" that used to be just above that line pretty much says it all :-).I have now applied a patch where YACC= bison is dined in aicasm/Makefile.
There are no other $(YACC) users in the kernel - the others specify bison direct.
I propose the following as a global yacc rule; already used in usr/dash in the klibc tree, and which seems to work for both bison and BSD yacc:
quiet_cmd_yacc = YACC $@
cmd_yacc = $(YACC) -d -o $@ $<
$(obj)/%.c %(obj)/%.h: $(src)/%.y
$(call cmd,yacc)
Note that bison seems to make smaller code than yacc, so I definiteily think we should default to bison over yacc.
-hpa
Quoted 8 lines · H. Peter Anvin
I propose the following as a global yacc rule; already used in usr/dash in the klibc tree, and which seems to work for both bison and BSD yacc:
quiet_cmd_yacc= YACC $@cmd_yacc = $(YACC) -d -o $@ $<$(obj)/%.c %(obj)/%.h: $(src)/%.y
$(call cmd,yacc)
klibc and the kernel does not share any rules today.
And yacc is so special that it's not worth it only for yacc to start doing this.
In todays kernel build yacc is never used. For the few cases were output of yacc is needed the kernel include _shipped files. For dash we should maybe consider the same?
Sam
Quoted 8 lines · Sam Ravnborg
Quoted 7 lines · H. Peter Anvin
I propose the following as a global yacc rule; already used in usr/dash in the klibc tree, and which seems to work for both bison and BSD yacc:
quiet_cmd_yacc= YACC $@cmd_yacc = $(YACC) -d -o $@ $<$(obj)/%.c %(obj)/%.h: $(src)/%.y
$(call cmd,yacc)
Quoted 8 lines
klibc and the kernel does not share any rules today.
And yacc is so special that it's not worth it only for yacc to start doing this.In todays kernel build yacc is never used. For the few cases were output of yacc is needed the kernel include
_shippedfiles. For dash we should maybe consider the same?
Personally I consider that pretty silly. yacc/bison is a standard, portable utility, and it isn't even architecture-dependent so there is no porting effort.
-hpa
Quoted 14 lines · H. Peter Anvin
Quoted 13 lines · Sam Ravnborg
Quoted 8 lines · H. Peter Anvin
I propose the following as a global yacc rule; already used in usr/dash in the klibc tree, and which seems to work for both bison and BSD yacc:
quiet_cmd_yacc= YACC $@cmd_yacc = $(YACC) -d -o $@ $<$(obj)/%.c %(obj)/%.h: $(src)/%.y
$(call cmd,yacc)klibc and the kernel does not share any rules today.
And yacc is so special that it's not worth it only for yacc to start doing this.
Quoted 8 lines
Quoted 4 lines
In todays kernel build yacc is never used. For the few cases were output of yacc is needed the kernel include
_shippedfiles. For dash we should maybe consider the same?Personally I consider that pretty silly. yacc/bison is a standard, portable utility, and it isn't even architecture-dependent so there is no porting effort.
While the correct fix is being contemplated, LEX also needs defining in the same aic7xxx/aicasm Makefile context.
Signature · 4 lines
----------------------------------------------------------------------- Bob Tracy WTO + WIPO = DMCA? http://www.anti-dmca.org [email protected] -----------------------------------------------------------------------