Skip to content

Commit

Permalink
Fix expat link error on Windows.
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinbackhouse committed Aug 27, 2021
1 parent 9722e03 commit ab170bf
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,11 @@ target_include_directories(exiv2lib SYSTEM PRIVATE
)

target_include_directories(exiv2lib PRIVATE ${EXPAT_INCLUDE_DIR})
target_link_libraries(exiv2lib PRIVATE EXPAT::EXPAT)
target_link_libraries(exiv2lib PRIVATE ${EXPAT_LIBRARIES})

if (WIN32)
target_compile_definitions(exiv2lib PRIVATE XML_STATIC)
endif()

if (EXIV2_ENABLE_XMP)
target_link_libraries(exiv2lib PRIVATE exiv2-xmp)
Expand Down

0 comments on commit ab170bf

Please sign in to comment.