VirtualBox

Changeset 13006 in vbox for trunk


Ignore:
Timestamp:
Oct 6, 2008 1:44:03 PM (16 years ago)
Author:
vboxsync
Message:

enable more warnings with gcc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Config.kmk

    r12943 r13006  
    10371037# Compiler optimization flags.
    10381038#
     1039VBOX_GCC_WARN ?= -Wall $(VBOX_GCC_Wextra) $(VBOX_GCC_Wno-missing-field-initializers) -Wno-unused -Wno-trigraphs
    10391040ifeq ($(KBUILD_TYPE),debug)
    10401041 VBOX_GCC_FP  ?= -fno-omit-frame-pointer
     
    10651066 VBOX_VCC_GC_OPT ?= -Ogitb2
    10661067 endif
     1068endif
     1069ifeq ($(KBUILD_TARGET_ARCH),x86)
     1070 VBOX_GCC_OPT <= -march=i586
    10671071endif
    10681072
     
    14411445        $(APPEND) '$@' 'VBOX_GCC_LIBGCC                ?= $(shell $(TOOL_$(VBOX_GCC_TOOL)_CC) -print-libgcc-file-name)'
    14421446        $(APPEND) '$@' 'VBOX_GCC_Wno-pointer-sign      ?= $(call VBOX_GCC_CHECK_CC,-Wno-pointer-sign,)'
     1447# -Wextra produces additional useful warnings but includes -Wno-missing-field-initializers (too noisy)
     1448        $(APPEND) '$@' 'VBOX_GCC_Wextra                ?= $(call VBOX_GCC_CHECK_CC,-Wextra,)'
     1449        $(APPEND) '$@' 'VBOX_GCC_Wno-missing-field-initializers ?= $(call VBOX_GCC_CHECK_CC,-Wno-missing-field-initializers,)'
    14431450        $(APPEND) '$@' 'VBOX_GCC_Wno-variadic-macros   ?= $(call VBOX_GCC_CHECK_CXX,-Wno-variadic-macros,)'
    14441451        $(APPEND) '$@' 'VBOX_GCC_Wno-invalid-offsetof  ?= $(call VBOX_GCC_CHECK_CXX,-Wno-invalid-offsetof,)'
    1445         $(APPEND) '$@' 'VBOX_GCC_Wno-extra             ?= $(call VBOX_GCC_CHECK_CXX,-Wno-extra)'
    14461452        $(APPEND) '$@' 'VBOX_GCC_fno-stack-protector   ?= $(call VBOX_GCC_CHECK_CC,-fno-stack-protector,)'
    14471453# Produce code optimized for the most common IA32/AMD64/EM64T processors. Introduced with gcc version 4.2.
     
    18621868ifeq ($(VBOX_LDR_FMT32),elf)
    18631869TEMPLATE_VBOXGC_TOOL                = $(VBOX_GCC32_TOOL)
    1864 TEMPLATE_VBOXGC_CXXFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-exceptions -fno-rtti $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_fvisibility-inlines-hidden)
    1865 TEMPLATE_VBOXGC_CFLAGS              = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC32_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden)
     1870TEMPLATE_VBOXGC_CXXFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-exceptions -fno-rtti $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_fvisibility-inlines-hidden)
     1871TEMPLATE_VBOXGC_CFLAGS              = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC32_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden)
    18661872ifeq ($(KBUILD_TARGET),solaris)
    18671873 TEMPLATE_VBOXGC_LDFLAGS            = -r
     
    18811887TEMPLATE_VBOXGC_TOOL                = GXX4MACHO
    18821888TEMPLATE_VBOXGC_DEFS               += $(VBOX_DARWIN_DEF_SDK_DEFS)
    1883 TEMPLATE_VBOXGC_CXXFLAGS            = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -fno-exceptions -fno-rtti $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
    1884 TEMPLATE_VBOXGC_CFLAGS              = $(VBOX_DARWIN_DEF_SDK_CFLAGS)   -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -Wno-trigraphs -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
     1889TEMPLATE_VBOXGC_CXXFLAGS            = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -fno-exceptions -fno-rtti $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
     1890TEMPLATE_VBOXGC_CFLAGS              = $(VBOX_DARWIN_DEF_SDK_CFLAGS)   -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
    18851891TEMPLATE_VBOXGC_LDFLAGS             = $(VBOX_DARWIN_DEF_SDK_LDFLAGS)  -nostdlib
    18861892#TEMPLATE_VBOXGC_LDFLAGS.release     = -Wl,-S ???
     
    18891895ifeq ($(VBOX_LDR_FMT32),lx)
    18901896TEMPLATE_VBOXGC_TOOL                = GXX3OMF
    1891 TEMPLATE_VBOXGC_CXXFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-exceptions -fno-rtti $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
    1892 TEMPLATE_VBOXGC_CFLAGS              = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC32_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
     1897TEMPLATE_VBOXGC_CXXFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC32_Wno-variadic-macros) -pipe -fno-exceptions -fno-rtti $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
     1898TEMPLATE_VBOXGC_CFLAGS              = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC32_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_GC_OPT) $(VBOX_GCC_GC_FP) -fno-strict-aliasing
    18931899TEMPLATE_VBOXGC_LDFLAGS             = -Zdll -nostdlib
    18941900TEMPLATE_VBOXGC_LIBS                = \
     
    19641970ifeq ($(VBOX_LDR_FMT),elf)
    19651971TEMPLATE_VBOXR0_TOOL                = $(VBOX_GCC_TOOL)
    1966 TEMPLATE_VBOXR0_CFLAGS              = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden)
    1967 TEMPLATE_VBOXR0_CXXFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-rtti -fno-exceptions $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden)
     1972TEMPLATE_VBOXR0_CFLAGS              = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-hidden)
     1973TEMPLATE_VBOXR0_CXXFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-rtti -fno-exceptions $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden)
    19681974TEMPLATE_VBOXR0_CFLAGS.amd64        = -m64 -mno-red-zone -mcmodel=kernel -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-asynchronous-unwind-tables -ffreestanding
    19691975TEMPLATE_VBOXR0_CXXFLAGS.amd64      = -m64 -mno-red-zone -mcmodel=kernel -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-asynchronous-unwind-tables
     
    19851991TEMPLATE_VBOXR0_TOOL                = GXX4MACHO
    19861992TEMPLATE_VBOXR0_DEFS               += $(VBOX_DARWIN_DEF_SDK_DEFS)
    1987 TEMPLATE_VBOXR0_CXXFLAGS            = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -fno-rtti -fno-exceptions $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
    1988 TEMPLATE_VBOXR0_CFLAGS              = $(VBOX_DARWIN_DEF_SDK_CFLAGS)   -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
     1993TEMPLATE_VBOXR0_CXXFLAGS            = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -fno-rtti -fno-exceptions $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
     1994TEMPLATE_VBOXR0_CFLAGS              = $(VBOX_DARWIN_DEF_SDK_CFLAGS)   -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-common -msoft-float -static -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
    19891995TEMPLATE_VBOXR0_LDFLAGS             = $(VBOX_DARWIN_DEF_SDK_LDFLAGS)  -nostdlib
    19901996#TEMPLATE_VBOXR0_LDFLAGS.release     = -Wl,-S ???
     
    19931999ifeq ($(VBOX_LDR_FMT),lx)
    19942000TEMPLATE_VBOXR0_TOOL                = GXX3OMF
    1995 TEMPLATE_VBOXR0_CFLAGS              = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
    1996 TEMPLATE_VBOXR0_CXXFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-rtti -fno-exceptions $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
     2001TEMPLATE_VBOXR0_CFLAGS              = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
     2002TEMPLATE_VBOXR0_CXXFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -fno-rtti -fno-exceptions $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
    19972003TEMPLATE_VBOXR0_LDFLAGS             = -Zdll -nostdlib
    19982004TEMPLATE_VBOXR0_LIBS                = \
     
    20392045TEMPLATE_VBOXR0DRV_INCS                = $(VBOX_LINUX_INCS)
    20402046TEMPLATE_VBOXR0DRV_CFLAGS              = -nostdinc -iwithprefix include \
    2041         -Wall -Wstrict-prototypes -Wno-trigraphs $(VBOX_GCC_Wno-pointer-sign) \
     2047        $(VBOX_GCC_WARN) -Wstrict-prototypes $(VBOX_GCC_Wno-pointer-sign) \
    20422048        $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing -fno-common
    20432049TEMPLATE_VBOXR0DRV_CFLAGS.x86          = -mpreferred-stack-boundary=2 -msoft-float
     
    20602066ifeq ($(KBUILD_TARGET),os2)
    20612067TEMPLATE_VBOXR0DRV_TOOL                = GXX3OMF
    2062 TEMPLATE_VBOXR0DRV_CXXFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing -fno-rtti -fno-exceptions
    2063 TEMPLATE_VBOXR0DRV_CFLAGS              = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
     2068TEMPLATE_VBOXR0DRV_CXXFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing -fno-rtti -fno-exceptions
     2069TEMPLATE_VBOXR0DRV_CFLAGS              = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing
    20642070TEMPLATE_VBOXR0DRV_LIBS                = $(VBOX_GCC_LIBGCC)
    20652071# wlink thinks physdevice doesn't need fixups and should have a stack - stupid!
     
    20752081TEMPLATE_VBOXR0DRV_INCS               += $(VBOX_PATH_MACOSX_SDK)/System/Library/Frameworks/Kernel.framework/Headers
    20762082TEMPLATE_VBOXR0DRV_CXXFLAGS            = $(VBOX_DARWIN_DEF_SDK_CXXFLAGS) \
    2077         -g -Wall -Wno-long-long -Wno-trigraphs -pipe -fno-common -nostdinc -fno-builtin -finline \
     2083        -g $(VBOX_GCC_WARN) -Wno-long-long -pipe -fno-common -nostdinc -fno-builtin -finline \
    20782084        -fno-keep-inline-functions -force_cpusubtype_ALL -fno-exceptions -msoft-float -static \
    20792085        -fapple-kext -fno-rtti -fcheck-new
     
    20822088TEMPLATE_VBOXR0DRV_CXXFLAGS.kprofile   = $(TEMPLATE_VBOXR0DRV_CXXFLAGS.release)
    20832089TEMPLATE_VBOXR0DRV_CFLAGS              = $(VBOX_DARWIN_DEF_SDK_CFLAGS) \
    2084         -g -Wall -Wno-long-long -Wno-trigraphs -pipe -fno-common -nostdinc -fno-builtin -finline \
     2090        -g $(VBOX_GCC_WARN) -Wno-long-long -pipe -fno-common -nostdinc -fno-builtin -finline \
    20852091        -fno-keep-inline-functions -force_cpusubtype_ALL -fno-exceptions -msoft-float -static \
    20862092        -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations
     
    21052111TEMPLATE_VBOXR0DRV_LDFLAGS.amd64       = -64
    21062112# Exclude -Wall because of solaris headers' pragma ident warnings that gcc refuses to supress.
    2107 TEMPLATE_VBOXR0DRV_CFLAGS              = -Wno-trigraphs -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
     2113TEMPLATE_VBOXR0DRV_CFLAGS              = -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
    21082114        -Wmissing-prototypes -Wstrict-prototypes -Wnested-externs \
    21092115        -O2 -ffreestanding -nodefaultlibs -fno-strict-aliasing -fno-common -std=c99
     
    21112117TEMPLATE_VBOXR0DRV_CFLAGS.amd64        = -m64 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow $(if $(VBOX_SOLARIS_10),,-msave-args) -mno-red-zone -mcmodel=kernel \
    21122118        -fno-reorder-blocks -fno-asynchronous-unwind-tables -funit-at-a-time
    2113 TEMPLATE_VBOXR0DRV_CXXFLAGS           = -Wno-trigraphs -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
     2119TEMPLATE_VBOXR0DRV_CXXFLAGS           = -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
    21142120        -O2 -nodefaultlibs -fno-strict-aliasing -fno-common -fno-exceptions -fno-rtti
    21152121TEMPLATE_VBOXR0DRV_CXXFLAGS.x86       = $(TEMPLATE_VBOXR0DRV_CFLAGS.x86)
     
    21472153# omitting: -Wcast-qual, -Wredundant-decls
    21482154TEMPLATE_VBOXR0DRV_CFLAGS              =  \
    2149         -Wall -Wno-trigraphs -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
     2155        $(VBOX_GCC_WARN) -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
    21502156        -Wstrict-prototypes -Wmissing-prototypes -Wstrict-prototypes -Wnested-externs \
    21512157        -O2 -fformat-extensions -ffreestanding -fno-strict-aliasing -fno-common -finline-limit=8000 \
     
    21552161TEMPLATE_VBOXR0DRV_CFLAGS.amd64        = -m64 "Port me to amd64 FreeBSD"
    21562162TEMPLATE_VBOXR0DRV_CXXFLAGS            = -fno-exceptions -fno-rtti \
    2157         -Wall -Wno-trigraphs -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
     2163        $(VBOX_GCC_WARN) -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \
    21582164        -O2 -fno-format-extensions -fno-strict-aliasing -fno-common -finline-limit=8000 \
    21592165        $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_OPT) $(VBOX_GCC_FP) \
     
    22392245else # the gcc guys
    22402246TEMPLATE_VBOXR3EXE_TOOL                = $(VBOX_GCC_TOOL)
    2241 TEMPLATE_VBOXR3EXE_CXXFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden)
     2247TEMPLATE_VBOXR3EXE_CXXFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden)
    22422248TEMPLATE_VBOXR3EXE_CXXFLAGS.x86        = -m32
    22432249TEMPLATE_VBOXR3EXE_CXXFLAGS.amd64      = -m64
     
    22472253        $(DEBUG_L4)
    22482254TEMPLATE_VBOXR3EXE_CXXFLAGS.kprofile   = -finstrument-functions
    2249 TEMPLATE_VBOXR3EXE_CFLAGS              = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-hidden)
     2255TEMPLATE_VBOXR3EXE_CFLAGS              = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-hidden)
    22502256TEMPLATE_VBOXR3EXE_CFLAGS.x86          = $(TEMPLATE_VBOXR3EXE_CXXFLAGS.x86)
    22512257TEMPLATE_VBOXR3EXE_CFLAGS.amd64        = $(TEMPLATE_VBOXR3EXE_CXXFLAGS.amd64)
     
    24322438ifneq ($(KBUILD_TARGET),win) # (only gcc)
    24332439 TEMPLATE_VBOXR3NPEXE_TOOL                = $(VBOX_GCC_TOOL)
    2434  TEMPLATE_VBOXR3NPEXE_CXXFLAGS            = $(filter-out -pedantic,$(TEMPLATE_VBOXR3EXE_CXXFLAGS))
    2435  TEMPLATE_VBOXR3NPEXE_CFLAGS              = $(filter-out -pedantic -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations,$(TEMPLATE_VBOXR3EXE_CFLAGS))
     2440 TEMPLATE_VBOXR3NPEXE_CXXFLAGS            = $(filter-out -pedantic -Wno-sign-compare,$(TEMPLATE_VBOXR3EXE_CXXFLAGS))
     2441 TEMPLATE_VBOXR3NPEXE_CFLAGS              = $(filter-out -pedantic -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Wno-sign-compare,$(TEMPLATE_VBOXR3EXE_CFLAGS))
    24362442endif
    24372443
     
    24652471TEMPLATE_VBOXNOCRTGCC_DEFS              = IN_RING3 IPRT_NO_CRT $(ARCH_BITS_DEFS)
    24662472TEMPLATE_VBOXNOCRTGCC_ASDEFS            = ASM_CALL64_GCC
    2467 TEMPLATE_VBOXNOCRTGCC_CFLAGS            = -nostdinc -fno-strict-aliasing -fno-math-errno -Wall
     2473TEMPLATE_VBOXNOCRTGCC_CFLAGS            = -nostdinc -fno-strict-aliasing -fno-math-errno $(VBOX_GCC_WARN)
    24682474TEMPLATE_VBOXNOCRTGCC_CFLAGS.x86        = -m32
    24692475TEMPLATE_VBOXNOCRTGCC_CFLAGS.amd64      = -m64 -mcmodel=medium -fno-common
     
    25892595
    25902596TEMPLATE_VBOXMAINEXE_TOOL                = $(VBOX_GCC_TOOL)
    2591 TEMPLATE_VBOXMAINEXE_CXXFLAGS            = -g -Wall -Wno-long-long -Wno-trigraphs -pipe -Wno-non-virtual-dtor -fshort-wchar -fpermissive -fexceptions -frtti $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden)
     2597TEMPLATE_VBOXMAINEXE_CXXFLAGS            = -g $(VBOX_GCC_WARN) -Wno-long-long -pipe -Wno-non-virtual-dtor -fshort-wchar -fpermissive -fexceptions -frtti $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-inlines-hidden) $(VBOX_GCC_fvisibility-hidden)
    25922598TEMPLATE_VBOXMAINEXE_CXXFLAGS.x86        = -m32
    25932599TEMPLATE_VBOXMAINEXE_CXXFLAGS.amd64      = -m64
    25942600TEMPLATE_VBOXMAINEXE_CXXFLAGS.kprofile   = -finstrument-functions
    2595 TEMPLATE_VBOXMAINEXE_CFLAGS              = -g -Wall -Wno-long-long -Wno-trigraphs -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-hidden)
     2601TEMPLATE_VBOXMAINEXE_CFLAGS              = -g $(VBOX_GCC_WARN) -Wno-long-long -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_OPT) $(VBOX_GCC_FP) -fno-strict-aliasing $(VBOX_GCC_fvisibility-hidden)
    25962602TEMPLATE_VBOXMAINEXE_CFLAGS.x86          = -m32
    25972603TEMPLATE_VBOXMAINEXE_CFLAGS.amd64        = -m64
     
    28202826        $(LIB_SDL_INC)
    28212827 TEMPLATE_VBOXQTGUIEXE_CXXFLAGS = \
    2822         -pipe -Wall -W -frtti -fno-exceptions -Wno-non-virtual-dtor \
     2828        -pipe $(VBOX_GCC_WARN) -frtti -fno-exceptions -Wno-non-virtual-dtor \
    28232829        -Wno-long-long -fshort-wchar -fno-strict-aliasing \
    28242830        $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_fvisibility-inlines-hidden)
     
    30473053        $(LIB_SDL_INC)
    30483054 TEMPLATE_VBOXQT4GUIEXE_CXXFLAGS = \
    3049         -g -pipe -Wall -W -frtti -fno-exceptions -Wno-non-virtual-dtor \
     3055        -g -pipe $(VBOX_GCC_WARN) -frtti -fno-exceptions -Wno-non-virtual-dtor \
    30503056        -Wno-long-long -fshort-wchar -fno-strict-aliasing \
    30513057        $(VBOX_GCC_fvisibility-hidden) $(VBOX_GCC_fvisibility-inlines-hidden)
     
    32003206# (gcc of some kind )
    32013207TEMPLATE_VBOXBLDPROG_TOOL                = GXX3
    3202 TEMPLATE_VBOXBLDPROG_CFLAGS              = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs $(VBOX_GCC_Wno-variadic-macros) -pipe  -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations
     3208TEMPLATE_VBOXBLDPROG_CFLAGS              = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long $(VBOX_GCC_Wno-variadic-macros) -pipe  -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations
    32033209TEMPLATE_VBOXBLDPROG_CFLAGS.x86          = -m32
    32043210TEMPLATE_VBOXBLDPROG_CFLAGS.amd64        = -m64
     
    32063212TEMPLATE_VBOXBLDPROG_CFLAGS.profile      = $(TEMPLATE_VBOXBLDPROG_CXXFLAGS.profile)
    32073213TEMPLATE_VBOXBLDPROG_CFLAGS.kprofile     = $(TEMPLATE_VBOXBLDPROG_CXXFLAGS.kprofile)
    3208 TEMPLATE_VBOXBLDPROG_CXXFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs -pipe
     3214TEMPLATE_VBOXBLDPROG_CXXFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long -pipe
    32093215TEMPLATE_VBOXBLDPROG_CXXFLAGS.x86        = -m32
    32103216TEMPLATE_VBOXBLDPROG_CXXFLAGS.amd64      = -m64
     
    32703276TEMPLATE_VBOXLNXHOSTR3EXE_ASFLAGS           = $(VBOX_ASFLAGS)
    32713277TEMPLATE_VBOXLNXHOSTR3EXE_DEFS              = IN_RING3 $(ARCH_BITS_DEFS)
    3272 TEMPLATE_VBOXLNXHOSTR3EXE_CXXFLAGS          = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs -pipe $(VBOX_GCC_fno-stack-protector)
     3278TEMPLATE_VBOXLNXHOSTR3EXE_CXXFLAGS          = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long -pipe $(VBOX_GCC_fno-stack-protector)
    32733279TEMPLATE_VBOXLNXHOSTR3EXE_CXXFLAGS.debug    = -fno-inline
    32743280TEMPLATE_VBOXLNXHOSTR3EXE_CXXFLAGS.release  = -O2 -fno-omit-frame-pointer -fno-strict-aliasing
     
    32793285TEMPLATE_VBOXLNXHOSTR3EXE_CFLAGS.profile    = $(TEMPLATE_VBOXLNXHOSTR3EXE_CXXFLAGS.profile)
    32803286TEMPLATE_VBOXLNXHOSTR3EXE_CFLAGS.kprofile   = $(TEMPLATE_VBOXLNXHOSTR3EXE_CXXFLAGS.kprofile)
    3281 TEMPLATE_VBOXLNXHOSTR3EXE_CFLAGS            = -g -Wall -pedantic -Wno-long-long -Wno-trigraphs -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_fno-stack-protector)
     3287TEMPLATE_VBOXLNXHOSTR3EXE_CFLAGS            = -g $(VBOX_GCC_WARN) -pedantic -Wno-long-long -pipe -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations $(VBOX_GCC_fno-stack-protector)
    32823288TEMPLATE_VBOXLNXHOSTR3EXE_LIBS              = pthread m rt dl
    32833289
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette