Print this page
10804 Enable unused warnings outside of uts
Reviewed by: Andy Stormont <astormont@racktopsystems.com>
Reviewed by: Toomas Soome <tsoome@me.com>


 439 #
 440 XFFLAG=                 -xF=%all
 441 XESS=                   -xs
 442 XSTRCONST=              -xstrconst
 443 
 444 #
 445 # turn warnings into errors (C)
 446 CERRWARN = -errtags=yes -errwarn=%all
 447 CERRWARN += -erroff=E_EMPTY_TRANSLATION_UNIT
 448 CERRWARN += -erroff=E_STATEMENT_NOT_REACHED
 449 
 450 CERRWARN += -_gcc=-Wno-missing-braces
 451 CERRWARN += -_gcc=-Wno-sign-compare
 452 CERRWARN += -_gcc=-Wno-unknown-pragmas
 453 CERRWARN += -_gcc=-Wno-unused-parameter
 454 CERRWARN += -_gcc=-Wno-missing-field-initializers
 455 
 456 # Unfortunately, this option can misfire very easily and unfixably.
 457 CERRWARN +=     -_gcc=-Wno-array-bounds
 458 
 459 # DEBUG v. -nd make for frequent unused variables, empty conditions, etc. in
 460 # -nd builds
 461 $(RELEASE_BUILD)CERRWARN += -_gcc=-Wno-unused
 462 $(RELEASE_BUILD)CERRWARN += -_gcc=-Wno-empty-body
 463 
 464 CERRWARN += -_smatch=-p=illumos_user
 465 include $(SRC)/Makefile.smatch
 466 
 467 #
 468 # turn warnings into errors (C++)
 469 CCERRWARN=              -xwe
 470 
 471 # C standard.  Keep Studio flags until we get rid of lint.
 472 CSTD_GNU89=     -xc99=%none
 473 CSTD_GNU99=     -xc99=%all
 474 CSTD=           $(CSTD_GNU89)
 475 C99LMODE=       $(CSTD:-xc99%=-Xc99%)
 476 
 477 # In most places, assignments to these macros should be appended with +=
 478 # (CPPFLAGS.first allows values to be prepended to CPPFLAGS).
 479 sparc_CFLAGS=   $(sparc_XARCH) $(CCSTATICSYM)
 480 sparcv9_CFLAGS= $(sparcv9_XARCH) -dalign $(CCVERBOSE) $(V9ABIWARN) $(CCREGSYM) \
 481                 $(CCSTATICSYM)
 482 i386_CFLAGS=    $(i386_XARCH)




 439 #
 440 XFFLAG=                 -xF=%all
 441 XESS=                   -xs
 442 XSTRCONST=              -xstrconst
 443 
 444 #
 445 # turn warnings into errors (C)
 446 CERRWARN = -errtags=yes -errwarn=%all
 447 CERRWARN += -erroff=E_EMPTY_TRANSLATION_UNIT
 448 CERRWARN += -erroff=E_STATEMENT_NOT_REACHED
 449 
 450 CERRWARN += -_gcc=-Wno-missing-braces
 451 CERRWARN += -_gcc=-Wno-sign-compare
 452 CERRWARN += -_gcc=-Wno-unknown-pragmas
 453 CERRWARN += -_gcc=-Wno-unused-parameter
 454 CERRWARN += -_gcc=-Wno-missing-field-initializers
 455 
 456 # Unfortunately, this option can misfire very easily and unfixably.
 457 CERRWARN +=     -_gcc=-Wno-array-bounds
 458 




 459 
 460 CERRWARN += -_smatch=-p=illumos_user
 461 include $(SRC)/Makefile.smatch
 462 
 463 #
 464 # turn warnings into errors (C++)
 465 CCERRWARN=              -xwe
 466 
 467 # C standard.  Keep Studio flags until we get rid of lint.
 468 CSTD_GNU89=     -xc99=%none
 469 CSTD_GNU99=     -xc99=%all
 470 CSTD=           $(CSTD_GNU89)
 471 C99LMODE=       $(CSTD:-xc99%=-Xc99%)
 472 
 473 # In most places, assignments to these macros should be appended with +=
 474 # (CPPFLAGS.first allows values to be prepended to CPPFLAGS).
 475 sparc_CFLAGS=   $(sparc_XARCH) $(CCSTATICSYM)
 476 sparcv9_CFLAGS= $(sparcv9_XARCH) -dalign $(CCVERBOSE) $(V9ABIWARN) $(CCREGSYM) \
 477                 $(CCSTATICSYM)
 478 i386_CFLAGS=    $(i386_XARCH)