Re: [OpenWrt-Devel] [PATCH] lantiq: don't unnecessarily disable gcc's format-security

2015-12-05 Thread Andre Heider
Hi,

On Sat, Dec 5, 2015 at 10:38 AM, Felix Fietkau  wrote:
> /Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:
>  In function 'DSL_DRV_debug_printf':
> /Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:364:21:
>  error: format not a string literal and no format arguments 
> [-Werror=format-security]
>nRet = printk(msg);

that looks like some debug config I might not have enabled on my tests?
I'll take a look.

Thanks,
Andre
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [PATCH] lantiq: don't unnecessarily disable gcc's format-security

2015-12-05 Thread Felix Fietkau
On 2015-11-30 20:02, Andre Heider wrote:
> ltq-adsl-mei as well as ltq-adsl build just fine with these compiler
> flags, there's no need to disable it.
> 
> Signed-off-by: Andre Heider 
I don't know about ltq-adsl-mei, but ltq-adsl does not build with
this patch:

Applications/Xcode.app/Contents/Developer/usr/bin/make ARCH=mips -C 
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/linux-4.1.13
 
O=/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/linux-4.1.13
 
M=/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src
 modules
egrep: empty (sub)expression
  CC [M]  
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_api.o
  CC [M]  
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_fifo.o
  CC [M]  
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_autoboot.o
  CC [M]  
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_debug.o
  CC [M]  
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.o
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:
 In function 'DSL_DRV_debug_printf':
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:364:21:
 error: format not a string literal and no format arguments 
[-Werror=format-security]
   nRet = printk(msg);
 ^
In file included from 
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:14:0:
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:
 In function 'DSL_DRV_ThreadInit':
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:619:87:
 error: format not a string literal and no format arguments 
[-Werror=format-security]
  pThrCntrl->pid = kthread_run(DSL_DRV_KernelThreadStartup, (void 
*)pThrCntrl, pThrCntrl->thrParams.pName);

   ^
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/linux-4.1.13/include/linux/kthread.h:14:45:
 note: in definition of macro 'kthread_create'
  kthread_create_on_node(threadfn, data, -1, namefmt, ##arg)
 ^
/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.c:619:27:
 note: in expansion of macro 'kthread_run'
  pThrCntrl->pid = kthread_run(DSL_DRV_KernelThreadStartup, (void 
*)pThrCntrl, pThrCntrl->thrParams.pName);
   ^
cc1: some warnings being treated as errors
make[7]: *** 
[/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src/common/drv_dsl_cpe_os_linux.o]
 Error 1
make[6]: *** 
[_module_/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/src]
 Error 2
make[5]: *** [sub-make] Error 2
make[4]: *** [drv_dsl_cpe_api.ko] Error 2
make[3]: *** [all-recursive] Error 1
make[2]: *** 
[/Users/nbd/openwrt/build_dir/target-mips_34kc+dsp_musl-1.1.11/linux-lantiq_xrx200/ltq-dsl-ar9/drv_dsl_cpe_api-3.24.4.4/.built]
 Error 2
make[2]: Leaving directory `/Users/nbd/openwrt/package/kernel/lantiq/ltq-adsl'
make[1]: *** [package/kernel/lantiq/ltq-adsl/compile] Error 2
make[1]: Leaving directory `/Users/nbd/openwrt'
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH] lantiq: don't unnecessarily disable gcc's format-security

2015-11-30 Thread Andre Heider
ltq-adsl-mei as well as ltq-adsl build just fine with these compiler
flags, there's no need to disable it.

Signed-off-by: Andre Heider 
---
 package/kernel/lantiq/ltq-adsl-mei/Makefile | 1 -
 package/kernel/lantiq/ltq-adsl/Makefile | 1 -
 2 files changed, 2 deletions(-)

diff --git a/package/kernel/lantiq/ltq-adsl-mei/Makefile 
b/package/kernel/lantiq/ltq-adsl-mei/Makefile
index a76591c..790b891 100644
--- a/package/kernel/lantiq/ltq-adsl-mei/Makefile
+++ b/package/kernel/lantiq/ltq-adsl-mei/Makefile
@@ -11,7 +11,6 @@ PKG_RELEASE:=1
 PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/ltq-adsl-mei-$(BUILD_VARIANT)/
 
 PKG_MAINTAINER:=John Crispin 
-PKG_CHECK_FORMAT_SECURITY:=0
 
 include $(INCLUDE_DIR)/package.mk
 
diff --git a/package/kernel/lantiq/ltq-adsl/Makefile 
b/package/kernel/lantiq/ltq-adsl/Makefile
index 26c931e..7931c87 100644
--- a/package/kernel/lantiq/ltq-adsl/Makefile
+++ b/package/kernel/lantiq/ltq-adsl/Makefile
@@ -18,7 +18,6 @@ PKG_MD5SUM:=c45bc531c1ed2ac80f68fb986b63bb87
 PKG_MAINTAINER:=John Crispin 
 
 PKG_USE_MIPS16:=0
-PKG_CHECK_FORMAT_SECURITY:=0
 PKG_FIXUP:=autoreconf
 
 include $(INCLUDE_DIR)/package.mk
-- 
2.6.2
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel