Added INSTALL_LIBXML2 option to control the generation of CMake installation rules
This change introduces an option to disable creation of installation rules when the libxml2 sources are embedded within a larger project.
Useful when linking statically to the libxml2 library.
set(LIBXML2_INSTALL OFF CACHE BOOL "" FORCE)
set(BUILD_SHARED_LIBS OFF CACHE BOOL "" FORCE)
set(LIBXML2_WITH_ICONV OFF CACHE BOOL "" FORCE)
set(LIBXML2_WITH_ZLIB OFF CACHE BOOL "" FORCE)
add_subdirectory(libxml2)
target_link_libraries(MyApplication LibXml2::LibXml2)