TOP		:= drivers/staging/rcar/rogue
OUT		:= $(TOP)
bridge_base	:= $(TOP)/generated

include $(OUT)/config_kernel.mk

ccflags-y += -D__linux__ -include $(srctree)/$(OUT)/config_kernel.h \
 -I$(OUT)/include \
 -I$(TOP)/include \
 -I$(TOP)/include/public \
 -I$(TOP)/hwdefs/km \
 -I$(TOP)/services/include \
 -I$(TOP)/services/include/shared \
 -I$(TOP)/services/shared/include \
 -I$(TOP)/services/shared/common \
 -I$(TOP)/services/system/$(PVR_SYSTEM) \
 -I$(TOP)/services/system/include \
 -I$(TOP)/services/server/common \
 -I$(TOP)/services/server/devices/rgx \
 -I$(TOP)/services/server/env/linux \
 -I$(TOP)/services/server/include

ccflags-y += -W
ccflags-y += -Wall
ccflags-y += -Wdeclaration-after-statement
ccflags-y += -Wno-format-zero-length
ccflags-y += -Wmissing-prototypes
ccflags-y += -Wstrict-prototypes
ccflags-y += -Wno-unused-parameter
ccflags-y += -Wno-sign-compare
ccflags-y += -Wmissing-include-dirs
ccflags-y += -Wno-type-limits
ccflags-y += -Wno-pointer-arith
ccflags-y += -Wno-aggregate-return
ccflags-y += -Wno-unused-but-set-variable
ccflags-y += -Wno-bad-function-cast
ccflags-y += -Wno-cast-qual
ccflags-y += -Wno-cast-align
ccflags-y += -Wno-conversion
ccflags-y += -Wno-disabled-optimization
ccflags-y += -Wno-logical-op
ccflags-y += -Wno-missing-declarations
ccflags-y += -Wno-missing-include-dirs
ccflags-y += -Wno-nested-externs
ccflags-y += -Wno-missing-field-initializers
ccflags-y += -Wno-old-style-definition
ccflags-y += -Wno-overlength-strings
ccflags-y += -Wno-packed
ccflags-y += -Wno-packed-bitfield-compat
ccflags-y += -Wno-padded
ccflags-y += -Wno-redundant-decls
ccflags-y += -Wno-shadow
ccflags-y += -Wno-switch-default
ccflags-y += -Wno-vla
ccflags-y += -Wno-write-strings

ccflags-y += -D_FILE_OFFSET_BITS=64
ccflags-y += -D_LARGEFILE64_SOURCE
ccflags-y += -D_LARGEFILE_SOURCE

include $(TOP)/services/server/env/linux/Kbuild.mk

obj-$(CONFIG_RCAR_POWERVR_GPU_GSX_SERVER) += pvrsrvkm.o
