Skip to content

Commit 09fd84d

Browse files
cristianadamtordex
authored andcommitted
Allow building with Clang using MSVC ABI
The official LLVM build of Clang is using the MSVC ABI, and if you are using clang.exe and not clang-cl.exe you get the GNU command line interface. CMake would not set the MSVC variable, but the CMAKE_CXX_SIMULATE_ID as "MSVC". Since clang.exe is targeting the MSVC ABI it needs the build support the MSVC has.
1 parent 35ecd69 commit 09fd84d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/gumbo/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ set_target_properties(${PROJECT_NAME} PROPERTIES
5858
PUBLIC_HEADER "${HEADER_GUMBO}"
5959
)
6060

61-
if (MSVC)
61+
if (MSVC OR CMAKE_CXX_SIMULATE_ID STREQUAL "MSVC")
6262
target_include_directories(${PROJECT_NAME} PRIVATE visualc/include)
6363
endif()
6464

0 commit comments

Comments
 (0)