cmake: lookup strip tool and set CMAKE_STRIP for host-gnu target

Fixes: #51821

Set CMAKE_STRIP using `find_program(CMAKE_STRIP strip)` to support
strip when building on native posix.

Signed-off-by: Torsten Rasmussen <Torsten.Rasmussen@nordicsemi.no>
This commit is contained in:
Torsten Rasmussen 2022-11-01 09:15:49 +01:00 committed by Carles Cufí
commit 1ee86a883d

View file

@ -8,6 +8,7 @@ find_program(CMAKE_AR ar )
find_program(CMAKE_RANLIB ranlib )
find_program(CMAKE_READELF readelf)
find_program(CMAKE_NM nm)
find_program(CMAKE_STRIP strip)
find_program(CMAKE_GDB gdb )