Skip to content

Commit 59b2163

Browse files
dcpleungmmahadevan108
authored andcommitted
cmake: toolchain/xt-clang: force assembler ID to GNU
xt-clang uses GNU Assembler (xt-as) based on binutils. However, CMake doesn't recognize it when invoking through xt-clang. This results in CMake going through all possible combinations of command line arguments while invoking xt-clang to determine assembler vendor. This multiple invocation of xt-clang unnecessarily lengthens the CMake phase of build, especially when xt-clang needs to obtain license information from remote licensing servers. So here forces the assembler ID to be GNU to speed things up a bit. Signed-off-by: Daniel Leung <[email protected]>
1 parent ff1857a commit 59b2163

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

cmake/toolchain/xt-clang/generic.cmake

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,14 @@ set(CC clang)
77
set(C++ clang++)
88
set(LINKER xt-ld)
99

10+
# xt-clang uses GNU Assembler (xt-as) based on binutils.
11+
# However, CMake doesn't recognize it when invoking through xt-clang.
12+
# This results in CMake going through all possible combinations of
13+
# command line arguments while invoking xt-clang to determine
14+
# assembler vendor. This multiple invocation of xt-clang unnecessarily
15+
# lengthens the CMake phase of build, especially when xt-clang needs to
16+
# obtain license information from remote licensing servers. So here
17+
# forces the assembler ID to be GNU to speed things up a bit.
18+
set(CMAKE_ASM_COMPILER_ID "GNU")
19+
1020
message(STATUS "Found toolchain: xt-clang (${XTENSA_TOOLCHAIN_PATH})")

0 commit comments

Comments
 (0)