From: David Capello Date: Wed, 14 Jun 2017 23:19:20 +0000 (-0300) Subject: Create libarchive.pc inside the cmake build dir X-Git-Tag: v3.4.3~14^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F1362%2Fhead;p=thirdparty%2Flibarchive.git Create libarchive.pc inside the cmake build dir In case that we don't have write access in the source dir, we have to write generated files in the build dir. --- diff --git a/build/cmake/CreatePkgConfigFile.cmake b/build/cmake/CreatePkgConfigFile.cmake index fc8529a57..bc5a43f72 100644 --- a/build/cmake/CreatePkgConfigFile.cmake +++ b/build/cmake/CreatePkgConfigFile.cmake @@ -24,10 +24,10 @@ ENDFOREACH() # thus there's a good chance it'll make some binutils versions unhappy... # This only affects Libs.private (looked up for static builds) though. CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/build/pkgconfig/libarchive.pc.in - ${CMAKE_CURRENT_SOURCE_DIR}/build/pkgconfig/libarchive.pc + ${CMAKE_CURRENT_BINARY_DIR}/build/pkgconfig/libarchive.pc @ONLY) # And install it, of course ;). IF(ENABLE_INSTALL) - INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/build/pkgconfig/libarchive.pc + INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/build/pkgconfig/libarchive.pc DESTINATION "lib/pkgconfig") ENDIF()