Closed philsuess closed 1 week ago
This seems to be a simple and a not uncommon issue of a package binary not being generated and uploaded correctly by the ConanCenter CI. Perhaps one of the team members can trigger a rebuild of coin-utils
to fix this.
@valgur conancenter doesn't generate packages with msvc static runtime.
[ERROR:vcvars.bat] Toolset directory for version '14.3' was not found.
[ERROR:VsDevCmd.bat] *** VsDevCmd.bat encountered errors. Environment may be incomplete and/or incorrect. ***
[ERROR:VsDevCmd.bat] In an uninitialized command prompt, please 'set VSCMD_DEBUG=[value]' and then re-run
[ERROR:VsDevCmd.bat] vsdevcmd.bat [args] for additional details.
[ERROR:VsDevCmd.bat] Where [value] is:
[ERROR:VsDevCmd.bat] 1 : basic debug logging
[ERROR:VsDevCmd.bat] 2 : detailed debug logging
[ERROR:VsDevCmd.bat] 3 : trace level logging. Redirection of output to a file when using this level is recommended.
[ERROR:VsDevCmd.bat] Example: set VSCMD_DEBUG=3
[ERROR:VsDevCmd.bat] vsdevcmd.bat > vsdevcmd.trace.txt 2>&1
Never seen such error. Is there a mismatch between default toolset of Visual Studio 2022 and actual toolset installed on your system?
Default platform toolset is v143 for Visual Studio 2022 (compiler.version=193 or compiler.version=194 in conan)
Is there a mismatch between default toolset of Visual Studio 2022 and actual toolset installed on your system?
conan profile detect
returns
[settings]
arch=x68_64
build_type=Release
compiler=msvc
compiler.cppstd=14
compiler.runtime=dynamic
compiler.version=194
os=Windows
Also: I have no issue with compilations of other packages. When I don't enfore the static runtime, all goes well also.
You may want to ask to conan maintainers instead: https://github.com/conan-io/conan/issues. This issue seems to come from VCVars
generator called under the hood by AutotoolsToolchain
.
For example if you try to build a CMake based recipe (let's say zlib) by using Ninja instead of Visual Studio generator in conan (add -c tools.cmake.cmaketoolchain:generator=Ninja
while calling conan install), do you see this issue also (VCVars
is not called by CMakeToolchain
when cmake generator is Visual Studio, and conan defaults to Visual Studio generator if compiler is msvc)?
Thank you @SpaceIm for the suggestion. For completeness, the call
conan install --requires coin-utils/2.11.10 -s compiler.runtime=static --build=missing -c tools.cmake.cmaketoolchain:generator=Ninja
goes through without trouble.
I was pointed to this issue by a colleague: https://github.com/conan-io/conan/issues/16897.
Will inquire there.
This fixed it for me: https://github.com/conan-io/conan/issues/16897#issuecomment-2324086401
These versions of the Microsoft compiler are killing me...
Thank you all for reading and supporting!
Description
I have a package that
self.requires("coin-clp/1.17.7")
. My profile to build using MSVC sets the runtime to static. The build of the packagecoin-utils
fails.I have to run
conan build
with--build=missing
because of the missingstatic
binaries. The resulting output is shown below.Package and Environment Details
Conan profile
======== Input profiles ======== Profile host: [settings] arch=x86_64 build_type=Release compiler=msvc compiler.cppstd=14 compiler.runtime=static compiler.runtime_type=Release compiler.version=193 os=Windows
Profile build: [settings] arch=x86_64 build_type=Release compiler=msvc compiler.cppstd=14 compiler.runtime=static compiler.runtime_type=Release compiler.version=193 os=Windows
Steps to reproduce
conan build -pr:h msvc_static -pr:b msvc_static --build=missing
where
msvc_static
is the profile shown above.Logs
Click to expand log
``` (...) zlib/1.3.1: Running CMake.build() zlib/1.3.1: RUN: cmake --build "C:\Users\XXXX\.conan2\p\b\zlib465ca28466ef9\b\build" --config Release MSBuild version 17.11.2+c078802d4 for .NET Framework 1>Checking Build System Building Custom Rule C:/Users/XXXX/.conan2/p/b/zlib465ca28466ef9/b/src/CMakeLists.txt adler32.c compress.c crc32.c deflate.c gzclose.c gzlib.c gzread.c gzwrite.c inflate.c infback.c inftrees.c inffast.c trees.c uncompr.c zutil.c zlib.vcxproj -> C:\Users\XXXX\.conan2\p\b\zlib465ca28466ef9\b\build\Release\zlib.lib Building Custom Rule C:/Users/XXXX/.conan2/p/b/zlib465ca28466ef9/b/src/CMakeLists.txt zlib/1.3.1: Package '04a6c37bc15f9f5fab59d7085ff6c17c75bc552d' built zlib/1.3.1: Build folder C:\Users\XXXX\.conan2\p\b\zlib465ca28466ef9\b\build zlib/1.3.1: Generating the package zlib/1.3.1: Packaging in folder C:\Users\XXXX\.conan2\p\b\zlib465ca28466ef9\p zlib/1.3.1: Calling package() zlib/1.3.1: Running CMake.install() zlib/1.3.1: RUN: cmake --install "C:\Users\XXXX\.conan2\p\b\zlib465ca28466ef9\b\build" --config Release --prefix "C:/Users/XXXX/.conan2/p/b/zlib465ca28466ef9/p" -- Installing: C:/Users/XXXX/.conan2/p/b/zlib465ca28466ef9/p/lib/zlib.lib -- Installing: C:/Users/XXXX/.conan2/p/b/zlib465ca28466ef9/p/include/zconf.h -- Installing: C:/Users/XXXX/.conan2/p/b/zlib465ca28466ef9/p/include/zlib.h zlib/1.3.1: package(): Packaged 2 '.h' files: zconf.h, zlib.h zlib/1.3.1: package(): Packaged 1 '.lib' file: zlib.lib zlib/1.3.1: package(): Packaged 1 file: LICENSE zlib/1.3.1: Created package revision 7e27ad508ef505939db166f852195b93 zlib/1.3.1: Package '04a6c37bc15f9f5fab59d7085ff6c17c75bc552d' created zlib/1.3.1: Full package reference: zlib/1.3.1#f52e03ae3d251dec704634230cd806a2:04a6c37bc15f9f5fab59d7085ff6c17c75bc552d#7e27ad508ef505939db166f852195b93 zlib/1.3.1: Package folder C:\Users\XXXX\.conan2\p\b\zlib465ca28466ef9\p pkgconf/2.0.3: WARN: The use of 'unix_path_legacy_compat' is deprecated in Conan 2.0 and does not perform path conversions. This is retained for compatibility with Conan 1.x and will be removed in a future version. pkgconf/2.1.0: WARN: The use of 'unix_path_legacy_compat' is deprecated in Conan 2.0 and does not perform path conversions. This is retained for compatibility with Conan 1.x and will be removed in a future version. coin-utils/2.11.9: Sources downloaded from 'conancenter' coin-utils/2.11.9: Calling source() in C:\Users\XXXX\.conan2\p\coin-0495469609a44\s\src coin-utils/2.11.9: Unzipping 2.11.9.tar.gz to . -------- Installing package coin-utils/2.11.9 (11 of 13) -------- coin-utils/2.11.9: Building from source coin-utils/2.11.9: Package coin-utils/2.11.9:fda87c64c621e4084d4dda98a4e1a50b96ab162f coin-utils/2.11.9: Copying sources to build folder coin-utils/2.11.9: Building your package in C:\Users\XXXX\.conan2\p\b\coin-172a97e9e74c1\b coin-utils/2.11.9: Calling generate() coin-utils/2.11.9: Generators folder: C:\Users\XXXX\.conan2\p\b\coin-172a97e9e74c1\b\build-release\conan coin-utils/2.11.9: Generating aggregated env files coin-utils/2.11.9: Generated aggregated env files: ['conanbuild.sh', 'conanbuild.bat'] coin-utils/2.11.9: Calling build() coin-utils/2.11.9: Apply patch (file): patches/0001-no-check-pkgconfig.patch coin-utils/2.11.9: Apply patch (portability): C++17 compatibility thout-blas --without-lapack --enable-msvc=static conanvcvars.bat: Activating environment Visual Studio 17 - amd64 - winsdk_version=None - vcvars_ver=14.3 [ERROR:vcvars.bat] Toolset directory for version '14.3' was not found. [ERROR:VsDevCmd.bat] *** VsDevCmd.bat encountered errors. Environment may be incomplete and/or incorrect. *** [ERROR:VsDevCmd.bat] In an uninitialized command prompt, please 'set VSCMD_DEBUG=[value]' and then re-run [ERROR:VsDevCmd.bat] vsdevcmd.bat [args] for additional details. [ERROR:VsDevCmd.bat] Where [value] is: [ERROR:VsDevCmd.bat] 1 : basic debug logging [ERROR:VsDevCmd.bat] 2 : detailed debug logging [ERROR:VsDevCmd.bat] 3 : trace level logging. Redirection of output to a file when using this level is recommended. [ERROR:VsDevCmd.bat] Example: set VSCMD_DEBUG=3 [ERROR:VsDevCmd.bat] vsdevcmd.bat > vsdevcmd.trace.txt 2>&1 coin-utils/2.11.9: ERROR: Package 'fda87c64c621e4084d4dda98a4e1a50b96ab162f' build failed coin-utils/2.11.9: WARN: Build folder C:\Users\XXXX\.conan2\p\b\coin-172a97e9e74c1\b\build-release ERROR: coin-utils/2.11.9: Error in build() method, line 153 autotools.configure() ConanException: Error 1 while executing ```