Andrew Geissler | 26e4bea | 2020-11-30 19:54:03 -0600 | [diff] [blame] | 1 | From d08003ab30452b4268121bcf82e03fdf21c89cdd Mon Sep 17 00:00:00 2001 |
Andrew Geissler | 062316f | 2020-05-15 14:19:14 -0500 | [diff] [blame] | 2 | From: Khem Raj <raj.khem@gmail.com> |
| 3 | Date: Tue, 31 Mar 2020 11:51:02 -0700 |
Andrew Geissler | 26e4bea | 2020-11-30 19:54:03 -0600 | [diff] [blame] | 4 | Subject: [PATCH] cmake: Disable format-overflow warning as error |
Andrew Geissler | 062316f | 2020-05-15 14:19:14 -0500 | [diff] [blame] | 5 | |
| 6 | gcc10 complains about a check which could potentially be null |
| 7 | |
| 8 | build/inc/interface/vcos/vcos_logging.h:234:88: error: '%s' directive argument is null [-Werror=format-overflow=] |
| 9 | 234 | # define _VCOS_LOG_X(cat, _level, fmt...) do { if (vcos_is_log_enabled(cat,_level)) vcos_log_impl(cat,_level,fmt); } while (0) |
| 10 | | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 11 | |
| 12 | A potential fix would be to check for fmt not being null but lets leave |
| 13 | that to experts |
| 14 | |
| 15 | Upstream-Status: Pending |
| 16 | |
| 17 | Signed-off-by: Khem Raj <raj.khem@gmail.com> |
| 18 | --- |
| 19 | host_applications/linux/libs/bcm_host/CMakeLists.txt | 2 +- |
| 20 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 21 | |
Andrew Geissler | 5d59ec7 | 2020-07-24 16:09:26 -0500 | [diff] [blame] | 22 | diff --git a/host_applications/linux/libs/bcm_host/CMakeLists.txt b/host_applications/linux/libs/bcm_host/CMakeLists.txt |
Andrew Geissler | 26e4bea | 2020-11-30 19:54:03 -0600 | [diff] [blame] | 23 | index 2f4beb9..7a4ab06 100644 |
Andrew Geissler | 062316f | 2020-05-15 14:19:14 -0500 | [diff] [blame] | 24 | --- a/host_applications/linux/libs/bcm_host/CMakeLists.txt |
| 25 | +++ b/host_applications/linux/libs/bcm_host/CMakeLists.txt |
| 26 | @@ -3,7 +3,7 @@ if (WIN32) |
| 27 | set(VCOS_PLATFORM win32) |
| 28 | else () |
| 29 | set(VCOS_PLATFORM pthreads) |
| 30 | - add_definitions(-Wall -Werror) |
Andrew Geissler | 5d59ec7 | 2020-07-24 16:09:26 -0500 | [diff] [blame] | 31 | + add_definitions(-Wall -Werror -Wno-error=format-overflow) |
Andrew Geissler | 062316f | 2020-05-15 14:19:14 -0500 | [diff] [blame] | 32 | endif () |
| 33 | |
| 34 | # set this as we want all the source of vchostif to be available in libbcm_host |