ANDROID: Makefile: Add '-fsplit-lto-unit' to cfi-clang-flags
After r350949 in clang, linking an CONFIG_CFI_CLANG kernel fails with the following error: aarch64-linux-gnu-ld.gold: fatal error: LLVM gold plugin: linking module flags 'EnableSplitLTOUnit': IDs have conflicting values -fsplit-lto-unit is needed when using -fsanitize-cfi so add the flag if it is supported by the compiler. CONFIG_CFI_CLANG works as expected with a tip of tree LLVM toolchain after this commit. Change-Id: I358ff024204c7abcef57b43a583ae960b89113f7 Link: https://github.com/ClangBuiltLinux/linux/issues/406 Link: https://github.com/llvm/llvm-project/commit/84cecfcb3db7c3275ae2d64c419a752d9f5311d6 Signed-off-by:Nathan Chancellor <natechancellor@gmail.com>
Loading
Please register or sign in to comment