Open hanyufeng0520 opened 3 months ago
I have the same issue. I need help too.
It is definitely regarding to cpp standard.
In your profile, compiler version is 194 and C++ standard is 20. In the logs, it seems vc_version dictionary doesn't have 194 entry, hence the error.
Try to build with C++17. conan install . -s compiler.cppstd=17 <other params>
Description
conanfile.txt [requires] ffmpeg/6.1
[generators] CMakeDeps CMakeToolchain
CMakeLists.txt
cmake_minimum_required(VERSION 3.15) project(testffmpeg CXX)
find_package(ffmpeg REQUIRED)
add_executable(${PROJECT_NAME} source/main.cpp) target_link_libraries(${PROJECT_NAME} ffmpeg::ffmpeg)
Package and Environment Details
Conan profile
Profile host: [settings] arch=x86_64 build_type=RelWithDebInfo compiler=msvc compiler.cppstd=20 compiler.runtime=dynamic compiler.runtime_type=Release compiler.version=194 os=Windows
Profile build: [settings] arch=x86_64 build_type=Release compiler=msvc compiler.cppstd=20 compiler.runtime=dynamic compiler.runtime_type=Release compiler.version=194 os=Windows
Steps to reproduce
conan install . --output-folder=build --build=missing -s build_type=RelWithDebInfo
or
conan install . --output-folder=build --build=missing -s build_type=Debug
Logs
-------- Installing package libvpx/1.13.1 (24 of 37) -------- libvpx/1.13.1: Building from source libvpx/1.13.1: Package libvpx/1.13.1:76fbe7d7e1df9e5c95356e5f53e5363b07c3bfb6 libvpx/1.13.1: Copying sources to build folder libvpx/1.13.1: Building your package in C:\Users\JKL.conan2\p\b\libvpf7caa53ad0d99\b libvpx/1.13.1: Calling generate() libvpx/1.13.1: Generators folder: C:\Users\JKL.conan2\p\b\libvpf7caa53ad0d99\b\build-relwithdebinfo\conan ERROR: libvpx/1.13.1: Error in generate() method, line 169 "--target": self._target_name, while calling '_target_name', line 106 vc_version = {"170": "11", "180": "12", "190": "14", "191": "15", "192": "16", "193": "17"}[vc_version] KeyError: '194'
E:\conan\testffmpeg>