lantiq: ltq-vdsl: Do not leak user space CFLAGS into kernel space
[openwrt/openwrt.git] / package / kernel / lantiq / ltq-vdsl / patches / 020-not-leak-cflags.patch
1 --- a/src/Makefile.am
2 +++ b/src/Makefile.am
3 @@ -244,10 +244,7 @@ else
4 drv_dsl_cpe_api_common_mod_cflags =
5 endif
6
7 -drv_dsl_cpe_api_common_cflags = -DLINUX -D__LINUX__ -D__KERNEL__ -DEXPORT_SYMTAB \
8 - -pipe -Wall -Wformat -Wimplicit -Wunused -Wswitch -Wcomment -Winline \
9 - -Wuninitialized -Wparentheses -Wsign-compare -Wreturn-type \
10 - -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common
11 +drv_dsl_cpe_api_common_cflags = -DLINUX -D__LINUX__ -D__KERNEL__ -DEXPORT_SYMTAB
12
13 if DSL_DBG_MAX_LEVEL_SET
14 drv_dsl_cpe_api_common_cflags += -DDSL_DBG_MAX_LEVEL=$(DSL_DBG_MAX_LEVEL_PRE)
15 @@ -257,7 +254,7 @@ endif
16 drv_dsl_cpe_api_target_cflags = $(ADD_DRV_CFLAGS)
17
18 # compile cflags
19 -drv_dsl_cpe_api_compile_cflags = $(EXTRA_DRV_CFLAGS)
20 +drv_dsl_cpe_api_compile_cflags =
21
22 if !KERNEL_2_6
23 # the headerfile of linux kernels 2.6.x contain to much arithmetic
24 @@ -311,7 +308,7 @@ drv_dsl_cpe_api.ko: $(drv_dsl_cpe_api_SO
25 @echo -e "# drv_dsl_cpe_api: Generated to build Linux 2.6.x kernel object" > $(PWD)/Kbuild
26 @echo -e "obj-m := $(subst .ko,.o,$@)" >> $(PWD)/Kbuild
27 @echo -e "$(subst .ko,,$@)-y := $(drv_dsl_cpe_api_OBJS)" >> $(PWD)/Kbuild
28 - @echo -e "EXTRA_CFLAGS := $(CFLAGS) -DHAVE_CONFIG_H $(drv_dsl_cpe_api_CFLAGS) $(DSL_DRIVER_INCL_PATH) $(IFXOS_INCLUDE_PATH) -I@abs_srcdir@/include -I$(PWD)/include" >> $(PWD)/Kbuild
29 + @echo -e "EXTRA_CFLAGS := -DHAVE_CONFIG_H $(drv_dsl_cpe_api_CFLAGS) $(DSL_DRIVER_INCL_PATH) $(IFXOS_INCLUDE_PATH) -I@abs_srcdir@/include -I$(PWD)/include" >> $(PWD)/Kbuild
30 $(MAKE) ARCH=@KERNEL_ARCH@ -C @KERNEL_BUILD_PATH@ O=@KERNEL_BUILD_PATH@ M=$(PWD) modules
31
32 clean-generic: