diff --git a/src/Conan.cmake b/src/Conan.cmake index 136e1d64..4929eb50 100644 --- a/src/Conan.cmake +++ b/src/Conan.cmake @@ -169,6 +169,9 @@ macro(_run_conan1) # Pass either autodetected settings or a conan profile ${CONAN_SETTINGS} ${OUTPUT_QUIET} + CONF + -c tools.system.package_manager:mode=install + -c tools.system.package_manager:sudo=True ) endforeach() endif() @@ -217,7 +220,11 @@ macro(_run_conan2) endif() if(NOT _args_INSTALL_ARGS) - set(_args_INSTALL_ARGS "--build=missing") + set(_args_INSTALL_ARGS + --build=missing + -c tools.system.package_manager:mode=install + -c tools.system.package_manager:sudo=True + ) endif() set(CONAN_HOST_PROFILE "${_args_HOST_PROFILE}" CACHE STRING "Conan host profile" FORCE)