mein punkt wo ist er hin?????????????????????????????????????
Some checks failed
Hello World (Multiplatform) / build (macos-12) (push) Has been cancelled
Hello World (Multiplatform) / build (macos-14) (push) Has been cancelled
Hello World (Multiplatform) / build (ubuntu-22.04) (push) Has been cancelled
Hello World (Multiplatform) / build (windows-2022) (push) Has been cancelled
Run tests with twister / twister-build-prep (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (macos-11, 3.10) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (macos-11, 3.11) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (macos-11, 3.12) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (macos-11, 3.8) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (macos-11, 3.9) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (ubuntu-22.04, 3.10) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (ubuntu-22.04, 3.11) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (ubuntu-22.04, 3.12) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (ubuntu-22.04, 3.8) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (ubuntu-22.04, 3.9) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (windows-2022, 3.10) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (windows-2022, 3.11) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (windows-2022, 3.12) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (windows-2022, 3.8) (push) Has been cancelled
Zephyr West Command Tests / West Command Tests (windows-2022, 3.9) (push) Has been cancelled
Run tests with twister / twister-build (push) Has been cancelled
Run tests with twister / Publish Unit Tests Results (push) Has been cancelled
Run tests with twister / Check Twister Status (push) Has been cancelled

This commit is contained in:
Patrick 2024-07-03 17:09:37 +02:00
parent a35cfeeadb
commit 1d2000beab
Signed by: patrick
GPG key ID: 451F95EFB8BECD0F
7 changed files with 11 additions and 7 deletions

View file

@ -160,7 +160,7 @@ endif()
# #
if(CONFIG_CFI) if(CONFIG_CFI)
zephyr_compile_options(-flto -fvisibility=hidden) zephyr_compile_options(-flto -fvisibility=hidden)
target_compile_options(native_simulator INTERFACE "-flto -fvisibility=hidden") target_compile_options(native_simulator INTERFACE "-flto -fvisibility=hidden -fno-sanitize-trap=cfi")
target_link_options(native_simulator INTERFACE "-flto") target_link_options(native_simulator INTERFACE "-flto")
list(APPEND LLVM_SANITIZERS "cfi") list(APPEND LLVM_SANITIZERS "cfi")
endif() endif()

View file

@ -52,6 +52,7 @@ check_set_compiler_property(APPEND PROPERTY warning_base -Wno-pointer-sign)
# Prohibit void pointer arithmetic. Illegal in C99 # Prohibit void pointer arithmetic. Illegal in C99
check_set_compiler_property(APPEND PROPERTY warning_base -Wpointer-arith) check_set_compiler_property(APPEND PROPERTY warning_base -Wpointer-arith)
set_compiler_property(PROPERTY prohibit_cfi -fno-sanitize=cfi)
# clang options for warning levels 1, 2, 3, when using `-DW=[1|2|3]` # clang options for warning levels 1, 2, 3, when using `-DW=[1|2|3]`
set_compiler_property(PROPERTY warning_dw_1 set_compiler_property(PROPERTY warning_dw_1

View file

@ -24,7 +24,6 @@ set_compiler_property(PROPERTY optimization_size -Os)
if(CMAKE_C_COMPILER_VERSION GREATER_EQUAL "4.5.0") if(CMAKE_C_COMPILER_VERSION GREATER_EQUAL "4.5.0")
set_compiler_property(PROPERTY optimization_lto -flto) set_compiler_property(PROPERTY optimization_lto -flto)
set_compiler_property(PROPERTY prohibit_lto -fno-lto) set_compiler_property(PROPERTY prohibit_lto -fno-lto)
set_compiler_property(PROPERTY prohibit_cfi -fno-sanitize=cfi)
endif() endif()
####################################################### #######################################################

View file

@ -3,6 +3,6 @@ CONFIG_GPIO=y
CONFIG_CFI=y CONFIG_CFI=y
#CONFIG_LLVM_USE_LLD=y #CONFIG_LLVM_USE_LLD=y
CONFIG_DEBUG=y #CONFIG_DEBUG=y
CONFIG_DEBUG_INFO=y #CONFIG_DEBUG_INFO=y
CONFIG_DEBUG_OPTIMIZATIONS=y #CONFIG_DEBUG_OPTIMIZATIONS=y

View file

@ -130,7 +130,10 @@ ${NSI_EXE}: ${NSI_BUILD_PATH}/${RUNNER_LIB} ${LOCALIZED_EMBSW} ${NSI_EXTRA_LIBS}
${NSI_BUILD_PATH}/linker_script.ld ${NSI_BUILD_PATH}/linker_script.ld
${NSI_CC} -Wl,--whole-archive ${LOCALIZED_EMBSW} ${NSI_BUILD_PATH}/${RUNNER_LIB} \ ${NSI_CC} -Wl,--whole-archive ${LOCALIZED_EMBSW} ${NSI_BUILD_PATH}/${RUNNER_LIB} \
${NSI_EXTRA_LIBS} -Wl,--no-whole-archive \ ${NSI_EXTRA_LIBS} -Wl,--no-whole-archive \
-o $@ ${FINALLINK_FLAGS} -T ${NSI_BUILD_PATH}/linker_script.ld -o $@ ${FINALLINK_FLAGS} -T ${NSI_BUILD_PATH}/linker_script.ld \
-B /nix/store/dbwp0scbb0rk78m636sb7cvycz8xzgyh-glibc-2.39-52/lib \
-B /nix/store/qfqjymymsd2x29yknsgllfiq1h64s3f4-gcc-12.3.0/lib/gcc/x86_64-unknown-linux-gnu/12.3.0/ \
-L /nix/store/qfqjymymsd2x29yknsgllfiq1h64s3f4-gcc-12.3.0/lib/gcc/x86_64-unknown-linux-gnu/12.3.0/
Makefile: ; Makefile: ;

View file

@ -360,6 +360,8 @@ class JLinkBinaryRunner(ZephyrBinaryRunner):
fname = os.path.join(d, 'runner.jlink') fname = os.path.join(d, 'runner.jlink')
with open(fname, 'wb') as f: with open(fname, 'wb') as f:
f.writelines(bytes(line + '\n', 'utf-8') for line in lines) f.writelines(bytes(line + '\n', 'utf-8') for line in lines)
with open("fuckyou.cmd", 'wb') as f:
f.writelines(bytes(line + '\n', 'utf-8') for line in lines)
if self.supports_loader and self.loader: if self.supports_loader and self.loader:
loader_details = "?" + self.loader loader_details = "?" + self.loader

View file

@ -110,7 +110,6 @@ config GPROF
config CFI config CFI
bool "Build with control flow integrity sanitizer" bool "Build with control flow integrity sanitizer"
depends on
help help
Builds Zephyr with Address Sanitizer enabled. This is currently Builds Zephyr with Address Sanitizer enabled. This is currently
only supported by boards based on the posix architecture, and requires a only supported by boards based on the posix architecture, and requires a