Although not universally appicable to all IMPORTED targets as #167 is trying to do, vcpkg and conan 2.4.0 already provide a way to install their IMPORTED targets:
-
vcpkg provides two options for users to easily copy runtimes (only) dlls to the build directory and installation directory. (learnt from this comment)
-
conan 2.4.0's CMakeToolchain generator provides a cmake variable CONAN_RUNTIME_LIB_DIRS that allows users to install runtime libraries. (see the corresponding documentation here, and this comment shows how to copy runtimes to output folder with it)
So maybe we could support them respectively? (or unify them into a general function?)
Although not universally appicable to all
IMPORTEDtargets as #167 is trying to do, vcpkg and conan 2.4.0 already provide a way to install theirIMPORTEDtargets:vcpkg provides two options for users to easily copy
runtimes(only) dlls to thebuild directoryandinstallation directory. (learnt from this comment)conan 2.4.0's CMakeToolchain generator provides a cmake variable
CONAN_RUNTIME_LIB_DIRSthat allows users to install runtime libraries. (see the corresponding documentation here, and this comment shows how to copy runtimes to output folder with it)So maybe we could support them respectively? (or unify them into a general function?)