Skip to content

Commit 417fb5c

Browse files
authored
fix tinyxml cmake files (#333)
1 parent fbf754a commit 417fb5c

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tinyxml2/CMakeLists.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,15 @@ add_library(${target_name} STATIC
1515

1616
target_include_directories(${target_name} PUBLIC .)
1717

18+
include(../cmake/CocosExternalConfig.cmake)
19+
if(WINDOWS)
20+
if(BUILD_SHARED_LIBS)
21+
target_compile_definitions(${target_name} PRIVATE _USRDLL)
22+
else()
23+
target_compile_definitions(${target_name} PRIVATE CC_STATIC)
24+
endif()
25+
endif()
26+
1827
set_target_properties(${target_name}
1928
PROPERTIES
2029
ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/lib"

0 commit comments

Comments
 (0)