From: Sebastian Pipping Date: Sun, 1 Sep 2019 22:32:08 +0000 (+0200) Subject: CMake: Do not produce expat.pc pkg-config file with MSVC X-Git-Tag: R_2_2_8~19^2~6 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=201094142d935de87c16ec4fd8ec225fb4b3a423;p=libexpat CMake: Do not produce expat.pc pkg-config file with MSVC --- diff --git a/expat/CMakeLists.txt b/expat/CMakeLists.txt index b046e631..4328b982 100644 --- a/expat/CMakeLists.txt +++ b/expat/CMakeLists.txt @@ -271,12 +271,14 @@ expat_install(FILES lib/expat.h lib/expat_external.h DESTINATION ${CMAKE_INSTALL # # pkg-config file # -set(prefix ${CMAKE_INSTALL_PREFIX}) -set(exec_prefix "\${prefix}") -set(libdir "\${exec_prefix}/${CMAKE_INSTALL_LIBDIR}") -set(includedir "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}") -configure_file(expat.pc.in ${CMAKE_CURRENT_BINARY_DIR}/expat.pc @ONLY) -expat_install(FILES ${CMAKE_CURRENT_BINARY_DIR}/expat.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) +if(NOT MSVC) + set(prefix ${CMAKE_INSTALL_PREFIX}) + set(exec_prefix "\${prefix}") + set(libdir "\${exec_prefix}/${CMAKE_INSTALL_LIBDIR}") + set(includedir "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}") + configure_file(expat.pc.in ${CMAKE_CURRENT_BINARY_DIR}/expat.pc @ONLY) + expat_install(FILES ${CMAKE_CURRENT_BINARY_DIR}/expat.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) +endif() # # C command line tool xmlwf