* [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized
@ 2023-01-11 17:59 Peter Hoyes
2023-01-11 17:59 ` [PATCH 2/2][langdale] arm/scp-firmware: Disable cppcheck Peter Hoyes
2023-01-13 18:05 ` [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized Jon Mason
0 siblings, 2 replies; 3+ messages in thread
From: Peter Hoyes @ 2023-01-11 17:59 UTC (permalink / raw)
To: meta-arm; +Cc: Peter Hoyes
From: Peter Hoyes <Peter.Hoyes@arm.com>
If CMAKE_BUILD_TYPE=debug (lowercase), SCP-firmware builds with debug
compiler flags but BUILD_MODE_DEBUG is not defined in C code so features
that are conditionally enabled/disabled in debug mode are not active.
Pass capitalized "Debug" and "Release" strings to CMAKE_BUILD_TYPE to
ensure Debug mode is fully enabled when SCP_BUILD_RELEASE = "0".
SCP_BUILD_RELEASE = "1" (the default) for all machines in meta-arm-bsp
so they are unaffected.
Issue-Id: SCM-5864
Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>
Change-Id: I93220420eedd2e3e6c169679efcaf4642dd5bc51
---
meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb b/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb
index 4828fb55..5dbbff94 100644
--- a/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb
+++ b/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb
@@ -27,7 +27,7 @@ DEPENDS = "virtual/arm-none-eabi-gcc-native \
# For now we only build with GCC, so stop meta-clang trying to get involved
TOOLCHAIN = "gcc"
-SCP_BUILD_STR = "${@bb.utils.contains('SCP_BUILD_RELEASE', '1', 'release', 'debug', d)}"
+SCP_BUILD_STR = "${@bb.utils.contains('SCP_BUILD_RELEASE', '1', 'Release', 'Debug', d)}"
inherit deploy
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2][langdale] arm/scp-firmware: Disable cppcheck
2023-01-11 17:59 [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized Peter Hoyes
@ 2023-01-11 17:59 ` Peter Hoyes
2023-01-13 18:05 ` [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized Jon Mason
1 sibling, 0 replies; 3+ messages in thread
From: Peter Hoyes @ 2023-01-11 17:59 UTC (permalink / raw)
To: meta-arm; +Cc: Peter Hoyes
From: Peter Hoyes <Peter.Hoyes@arm.com>
The SCP-firmware CMake compile step automatically attempts to execute
cppcheck if both:
* cppcheck can be located using find_program
* DISABLE_CPPCHECK is not defined
cppcheck is not readily available in OE-core and is not an essential
part of the compilation process for end-users, so explicitly disable the
cppcheck step by passing DISABLE_CPPCHECK to CMake.
Additionally, because the OE-core CMake toolchain file cannot be used,
find_program may locate cppcheck on the host machine, which will cause
the build to fail if it is not the recommended version (as it is in
recent Linux distros).
Issue-Id: SCM-5864
Signed-off-by: Peter Hoyes <Peter.Hoyes@arm.com>
Change-Id: Ia87a0cbbb67ac1d6f3b26cfb5747a85b46131f81
---
meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb | 1 +
1 file changed, 1 insertion(+)
diff --git a/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb b/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb
index 5dbbff94..055e0c1b 100644
--- a/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb
+++ b/meta-arm/recipes-bsp/scp-firmware/scp-firmware_2.10.0.bb
@@ -46,6 +46,7 @@ CFLAGS[unexport] = "1"
EXTRA_OECMAKE = "-D CMAKE_BUILD_TYPE=${SCP_BUILD_STR} \
-D SCP_LOG_LEVEL=${SCP_LOG_LEVEL} \
-D SCP_PLATFORM_FEATURE_SET=${SCP_PLATFORM_FEATURE_SET} \
+ -D DISABLE_CPPCHECK=1 \
"
do_configure() {
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized
2023-01-11 17:59 [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized Peter Hoyes
2023-01-11 17:59 ` [PATCH 2/2][langdale] arm/scp-firmware: Disable cppcheck Peter Hoyes
@ 2023-01-13 18:05 ` Jon Mason
1 sibling, 0 replies; 3+ messages in thread
From: Jon Mason @ 2023-01-13 18:05 UTC (permalink / raw)
To: meta-arm, Peter Hoyes; +Cc: Peter Hoyes
On Wed, 11 Jan 2023 17:59:28 +0000, Peter Hoyes wrote:
> If CMAKE_BUILD_TYPE=debug (lowercase), SCP-firmware builds with debug
> compiler flags but BUILD_MODE_DEBUG is not defined in C code so features
> that are conditionally enabled/disabled in debug mode are not active.
>
> Pass capitalized "Debug" and "Release" strings to CMAKE_BUILD_TYPE to
> ensure Debug mode is fully enabled when SCP_BUILD_RELEASE = "0".
>
> [...]
Applied, thanks!
[1/2] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized
commit: b5fe2bf2b7295d258e781934b27f99e32ceee774
[2/2] arm/scp-firmware: Disable cppcheck
commit: fd414c303c1cc9b2fa47001ab555c5e22ee1c5a4
Best regards,
--
Jon Mason <jon.mason@arm.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-01-13 18:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-11 17:59 [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized Peter Hoyes
2023-01-11 17:59 ` [PATCH 2/2][langdale] arm/scp-firmware: Disable cppcheck Peter Hoyes
2023-01-13 18:05 ` [PATCH 1/2][langdale] arm/scp-firmware: Ensure CMAKE_BUILD_TYPE is capitalized Jon Mason
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).