2012/7/31 Moore, Robert robert.moore@intel.com:
We are using gcc 4.6.3 here.
Can you send me the error output from the use of -Wredundant-decls?
Thanks, Bob
$ make clean ; make V=1 rm -f iasl iasl.exe aslcompilerlex.o aslcompilerparse.o dtparserlex.o dtparserparse.o prparserlex.o prparserparse.o adfile.o adisasm.o adwalk.o ahpredef.o aslanalyze.o aslbtypes.o aslcodegen.o aslcompile.o aslerror.o aslfiles.o aslfold.o asllength.o asllisting.o aslload.o asllookup.o aslmain.o aslmap.o aslopcodes.o asloperands.o aslopt.o aslpredef.o aslresource.o aslrestype1.o aslrestype1i.o aslrestype2.o aslrestype2d.o aslrestype2e.o aslrestype2s.o aslrestype2q.o aslrestype2w.o aslstartup.o aslstubs.o asltransform.o asltree.o aslutils.o asluuid.o aslwalks.o dtcompile.o dtexpress.o dtfield.o dtio.o dtsubtable.o dttable.o dttemplate.o dtutils.o dbfileio.o dmbuffer.o dmextern.o dmnames.o dmobject.o dmopcode.o dmresrc.o dmresrcl.o dmresrcl2.o dmresrcs.o dmrestag.o dmtable.o dmtbdump.o dmtbinfo.o dmutils.o dmwalk.o dsargs.o dscontrol.o dsfield.o dsobject.o dsopcode.o dsutils.o dswexec.o dswload.o dswload2.o dswscope.o dswstate.o exconvrt.o excreate.o exdump.o exmisc.o exmutex.o exnames.o exoparg1.o exoparg2.o exoparg3.o exoparg6.o exprep.o exregion.o exresnte.o exresolv.o exresop.o exstore.o exstoren.o exstorob.o exsystem.o exutils.o getopt.o nsaccess.o nsalloc.o nsdump.o nsnames.o nsobject.o nsparse.o nssearch.o nsutils.o nswalk.o nsxfobj.o osunixxf.o prexpress.o prmacros.o prscan.o prutils.o psargs.o psloop.o psopcode.o psparse.o psscope.o pstree.o psutils.o pswalk.o tbfadt.o tbinstal.o tbutils.o tbxface.o utaddress.o utalloc.o utcache.o utcopy.o utdebug.o utdecode.o utdelete.o utexcep.o utglobal.o utinit.o utlock.o utmath.o utmisc.o utmutex.o utobject.o utresrc.o utstate.o utxferror.o utxface.o aslcompilerlex.c aslcompilerparse.c dtparserlex.c dtparserparse.c prparserlex.c prparserparse.c aslcompilerparse.h aslcompiler.y.h aslcompilerparse.output dtparserparse.h dtparser.y.h dtparserparse.output prparserparse.h prparser.y.h prparserparse.output flex -i -s -PAslCompiler -oaslcompilerlex.c ../../source/compiler/aslcompiler.l bison -v -d -y -pAslCompiler -oaslcompilerparse.c ../../source/compiler/aslcompiler.y flex -i -s -PDtParser -odtparserlex.c ../../source/compiler/dtparser.l bison -v -d -y -pDtParser -odtparserparse.c ../../source/compiler/dtparser.y flex -i -s -PPrParser -oprparserlex.c ../../source/compiler/prparser.l bison -v -d -y -pPrParser -oprparserparse.c ../../source/compiler/prparser.y Copy intermediate file: 'aslcompilerparse.h' -> 'aslcompiler.y.h' Copy intermediate file: 'dtparserparse.h' -> 'dtparser.y.h' Copy intermediate file: 'prparserparse.h' -> 'prparser.y.h' cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -Wall -Werror -Wstrict-aliasing=0 -oaslcompilerlex.o aslcompilerlex.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -Wall -Werror -Wstrict-aliasing=0 -oaslcompilerparse.o aslcompilerparse.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -Wall -Werror -Wstrict-aliasing=0 -odtparserlex.o dtparserlex.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -Wall -Werror -Wstrict-aliasing=0 -odtparserparse.o dtparserparse.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -Wall -Werror -Wstrict-aliasing=0 -oprparserlex.o prparserlex.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -Wall -Werror -Wstrict-aliasing=0 -oprparserparse.o prparserparse.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -ansi -Wall -Wbad-function-cast -Wdeclaration-after-statement -Werror -Wformat=2 -Wmissing-declarations -Wmissing-prototypes -Wstrict-aliasing=0 -Wstrict-prototypes -Wswitch-default -Wpointer-arith -Wundef -Waddress -Waggregate-return -Wchar-subscripts -Wempty-body -Wlogical-op -Wmissing-declarations -Wmissing-field-initializers -Wmissing-parameter-type -Wnested-externs -Wold-style-declaration -Wold-style-definition -Wredundant-decls -Wtype-limits -oadfile.o ../../source/common/adfile.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -ansi -Wall -Wbad-function-cast -Wdeclaration-after-statement -Werror -Wformat=2 -Wmissing-declarations -Wmissing-prototypes -Wstrict-aliasing=0 -Wstrict-prototypes -Wswitch-default -Wpointer-arith -Wundef -Waddress -Waggregate-return -Wchar-subscripts -Wempty-body -Wlogical-op -Wmissing-declarations -Wmissing-field-initializers -Wmissing-parameter-type -Wnested-externs -Wold-style-declaration -Wold-style-definition -Wredundant-decls -Wtype-limits -oadisasm.o ../../source/common/adisasm.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -ansi -Wall -Wbad-function-cast -Wdeclaration-after-statement -Werror -Wformat=2 -Wmissing-declarations -Wmissing-prototypes -Wstrict-aliasing=0 -Wstrict-prototypes -Wswitch-default -Wpointer-arith -Wundef -Waddress -Waggregate-return -Wchar-subscripts -Wempty-body -Wlogical-op -Wmissing-declarations -Wmissing-field-initializers -Wmissing-parameter-type -Wnested-externs -Wold-style-declaration -Wold-style-definition -Wredundant-decls -Wtype-limits -oadwalk.o ../../source/common/adwalk.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -ansi -Wall -Wbad-function-cast -Wdeclaration-after-statement -Werror -Wformat=2 -Wmissing-declarations -Wmissing-prototypes -Wstrict-aliasing=0 -Wstrict-prototypes -Wswitch-default -Wpointer-arith -Wundef -Waddress -Waggregate-return -Wchar-subscripts -Wempty-body -Wlogical-op -Wmissing-declarations -Wmissing-field-initializers -Wmissing-parameter-type -Wnested-externs -Wold-style-declaration -Wold-style-definition -Wredundant-decls -Wtype-limits -oahpredef.o ../../source/common/ahpredef.c cc -c -D_LINUX -D_GNU_SOURCE -DACPI_ASL_COMPILER -I../../source/include -I../../source/compiler -ansi -Wall -Wbad-function-cast -Wdeclaration-after-statement -Werror -Wformat=2 -Wmissing-declarations -Wmissing-prototypes -Wstrict-aliasing=0 -Wstrict-prototypes -Wswitch-default -Wpointer-arith -Wundef -Waddress -Waggregate-return -Wchar-subscripts -Wempty-body -Wlogical-op -Wmissing-declarations -Wmissing-field-initializers -Wmissing-parameter-type -Wnested-externs -Wold-style-declaration -Wold-style-definition -Wredundant-decls -Wtype-limits -oaslanalyze.o aslanalyze.c In file included from aslanalyze.c:118:0: aslcompilerparse.h:738:5: error: redundant redeclaration of 'AslCompilerparse' [-Werror=redundant-decls] In file included from aslanalyze.c:117:0: aslcompiler.h:163:1: note: previous declaration of 'AslCompilerparse' was here cc1: all warnings being treated as errors make: *** [aslanalyze.o] Error 1