Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
compiler.h: only use __no_stack_protector if supported by the compiler
The __attribute__((no_stack_protector)) was introduced in GCC 11. Building a TA with a version of GCC older than that would trigger a -Wattributes warning on the ta/user_ta_header.c file. Use __has_attribute() to check support of the no_stack_protector attribute before using it. If not supported, define the __no_stack_protector alias as a NOP. Fixes: e3fb2bd ("compiler.h: add __no_stack_protector") Signed-off-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr> Acked-by: Jens Wiklander <jens.wiklander@linaro.org>
- Loading branch information