robotology / robotology-superbuild

CMake/YCM-based superbuild to simplify the build process of robotology projects.
47 stars 48 forks source link

icub-basic-demos CI conda on Windows fails June 2024 #1664

Closed traversaro closed 2 weeks ago

traversaro commented 2 months ago

Error:

2024-06-11T03:53:15.2400657Z   1>Creating directories for 'icub-basic-demos'
2024-06-11T03:53:15.3843166Z   Performing download step (git clone) for 'icub-basic-demos'
2024-06-11T03:53:15.4184897Z   Cloning into 'icub-basic-demos'...
2024-06-11T03:53:16.0388360Z   Your branch is up to date with 'origin/master'.
2024-06-11T03:53:16.0392988Z   Already on 'master'
2024-06-11T03:53:16.5101250Z   Building Custom Rule D:/a/robotology-superbuild/robotology-superbuild/CMakeLists.txt
2024-06-11T03:53:16.5310547Z   No patch step for 'icub-basic-demos'
2024-06-11T03:53:16.5631329Z   Performing update step for 'icub-basic-demos'
2024-06-11T03:53:16.9138559Z   Current branch master is up to date.
2024-06-11T03:53:17.3548813Z   Performing configure step for 'icub-basic-demos'
2024-06-11T03:53:17.3696198Z   Not searching for unused variables given on the command line.
2024-06-11T03:53:17.3721963Z   loading initial cache file D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/CMakeFiles/YCMTmp/icub-basic-demos-cache-Release.cmake
2024-06-11T03:53:18.2931372Z   -- The C compiler identification is MSVC 19.40.33811.0
2024-06-11T03:53:18.8932078Z   -- The CXX compiler identification is MSVC 19.40.33811.0
2024-06-11T03:53:18.9122784Z   -- Detecting C compiler ABI info
2024-06-11T03:53:19.5132072Z   -- Detecting C compiler ABI info - done
2024-06-11T03:53:19.5152124Z   -- Check for working C compiler: C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
2024-06-11T03:53:19.5158080Z   -- Detecting C compile features
2024-06-11T03:53:19.5171242Z   -- Detecting C compile features - done
2024-06-11T03:53:19.5272701Z   -- Detecting CXX compiler ABI info
2024-06-11T03:53:20.1273860Z   -- Detecting CXX compiler ABI info - done
2024-06-11T03:53:20.1295692Z   -- Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
2024-06-11T03:53:20.1300425Z   -- Detecting CXX compile features
2024-06-11T03:53:20.1313804Z   -- Detecting CXX compile features - done
2024-06-11T03:53:20.1857019Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:20.1913479Z   -- Libraries are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/lib
2024-06-11T03:53:20.1914805Z   -- Executables are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/bin
2024-06-11T03:53:20.2156027Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:20.2186537Z   -- Found YCM: D:/a/robotology-superbuild/robotology-superbuild/b/install/share/cmake/YCM (found version "0.16.4")
2024-06-11T03:53:20.2524339Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:20.9520735Z   -- Found GSL: C:/Users/runneradmin/miniconda3/envs/test/Library/include (found version "2.7") 
2024-06-11T03:53:21.1397879Z   -- Found IPOPT: C:/Users/runneradmin/miniconda3/envs/test/Library/lib/ipopt-3.lib  
2024-06-11T03:53:21.1708763Z   -- Found ICUB 2.6.2 (Components: iCubDev ctrlLib skinDynLib iKin iDyn learningMachine perceptiveModels actionPrimitives optimization)
2024-06-11T03:53:21.1885259Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:21.2418107Z   -- Libraries are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/lib
2024-06-11T03:53:21.2419933Z   -- Executables are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/bin
2024-06-11T03:53:21.2653756Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:21.2676499Z   -- Found YCM: D:/a/robotology-superbuild/robotology-superbuild/b/install/share/cmake/YCM (found version "0.16.4")
2024-06-11T03:53:21.3004592Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:21.5099748Z   -- Found ICUB 2.6.2 (Components: iCubDev ctrlLib skinDynLib iKin iDyn learningMachine perceptiveModels actionPrimitives optimization)
2024-06-11T03:53:21.5274052Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:21.5329986Z   -- Libraries are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/lib
2024-06-11T03:53:21.5331119Z   -- Executables are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/bin
2024-06-11T03:53:21.5563949Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:21.5586639Z   -- Found YCM: D:/a/robotology-superbuild/robotology-superbuild/b/install/share/cmake/YCM (found version "0.16.4")
2024-06-11T03:53:21.5912776Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:21.7971781Z   -- Found ICUB 2.6.2 (Components: iCubDev ctrlLib skinDynLib iKin iDyn learningMachine perceptiveModels actionPrimitives optimization)
2024-06-11T03:53:21.8146685Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:21.8199436Z   -- Libraries are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/lib
2024-06-11T03:53:21.8200538Z   -- Executables are placed in D:/a/robotology-superbuild/robotology-superbuild/b/src/icub-basic-demos/bin
2024-06-11T03:53:21.8619088Z   -- Found PkgConfig: C:/Users/runneradmin/miniconda3/envs/test/Library/bin/pkg-config.exe (found version "0.29.2") 
2024-06-11T03:53:21.9425035Z   -- Found assimp: C:/Users/runneradmin/miniconda3/envs/test/Library/lib/cmake/assimp-5.3/assimpConfig.cmake (found version "5.3.0") 
2024-06-11T03:53:22.1025652Z   -- Performing Test CMAKE_HAVE_LIBC_PTHREAD
2024-06-11T03:53:22.5452177Z   -- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
2024-06-11T03:53:22.5453616Z   -- Looking for pthread_create in pthreads
2024-06-11T03:53:23.0600634Z   -- Looking for pthread_create in pthreads - not found
2024-06-11T03:53:23.0601670Z   -- Looking for pthread_create in pthread
2024-06-11T03:53:23.5828127Z   -- Looking for pthread_create in pthread - not found
2024-06-11T03:53:23.5846790Z   -- Found Threads: TRUE  
2024-06-11T03:53:23.5930110Z   -- Found DART: C:/Users/runneradmin/miniconda3/envs/test/Library/include (Required is at least version "6.6") found components: dart 
2024-06-11T03:53:23.6434134Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6478195Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6579856Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6632818Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6674692Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6731257Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6781630Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6834172Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6883875Z   -- Boost toolset is unknown (compiler MSVC 19.40.33811.0)
2024-06-11T03:53:23.6918823Z   -- Found Boost: C:/Users/runneradmin/miniconda3/envs/test/Library/lib/cmake/Boost-1.82.0/BoostConfig.cmake (found suitable version "1.82.0", minimum required is "1.40.0") found components: thread system filesystem program_options regex iostreams date_time 
2024-06-11T03:53:23.8114392Z   -- Found ZLIB: C:/Users/runneradmin/miniconda3/envs/test/Library/lib/z.lib (found version "1.2.13")  
2024-06-11T03:53:23.9286337Z   -- Looking for ignition-math6 -- found version 6.15.1
2024-06-11T03:53:23.9640631Z   -- Searching for dependencies of ignition-math6
2024-06-11T03:53:23.9940795Z   -- Found OGRE
2024-06-11T03:53:23.9941316Z   --   static     : OFF
2024-06-11T03:53:23.9942336Z   --   components : Bites;HLMS;MeshLodGenerator;Overlay;Paging;Property;RTShaderSystem;Terrain;Volume
2024-06-11T03:53:23.9944502Z   --   plugins    : Plugin_BSPSceneManager;Plugin_OctreeSceneManager;Plugin_PCZSceneManager;Plugin_ParticleFX;RenderSystem_GL;RenderSystem_GL3Plus;RenderSystem_Direct3D11
2024-06-11T03:53:23.9946365Z   --   media      : C:/Users/runneradmin/miniconda3/envs/test/Library/Media
2024-06-11T03:53:23.9955409Z   -- Looking for ignition-math6 -- found version 6.15.1
2024-06-11T03:53:24.0203550Z   -- Looking for ignition-transport8 -- found version 8.4.0
2024-06-11T03:53:24.0221551Z   -- Searching for dependencies of ignition-transport8
2024-06-11T03:53:24.0795113Z   -- Looking for ignition-msgs5 -- found version 5.11.0
2024-06-11T03:53:24.0801653Z   -- Searching for dependencies of ignition-msgs5
2024-06-11T03:53:24.0855233Z   -- Looking for ignition-math6 -- found version 6.15.1
2024-06-11T03:53:24.1009885Z   -- Checking for module 'tinyxml2'
2024-06-11T03:53:24.2586471Z   --   Found tinyxml2, version 9.0.0
2024-06-11T03:53:24.4929727Z   -- Looking for ignition-msgs5 -- found version 5.11.0
2024-06-11T03:53:24.5176525Z   -- Looking for ignition-common3 -- found version 3.15.1
2024-06-11T03:53:24.5183454Z   -- Searching for dependencies of ignition-common3
2024-06-11T03:53:24.5474681Z   -- Found DL: TRUE  
2024-06-11T03:53:24.5491129Z   -- Searching for <ignition-common3> component [graphics]
2024-06-11T03:53:24.5737622Z   -- Looking for ignition-common3-graphics -- found version 3.15.1
2024-06-11T03:53:24.5745191Z   -- Searching for dependencies of ignition-common3-graphics
2024-06-11T03:53:24.5755004Z   -- Looking for ignition-math6 -- found version 6.15.1
2024-06-11T03:53:24.6024970Z   -- Looking for ignition-fuel_tools4 -- found version 4.6.0
2024-06-11T03:53:24.6031414Z   -- Searching for dependencies of ignition-fuel_tools4
2024-06-11T03:53:24.9915587Z   -- Found CURL: C:/Users/runneradmin/miniconda3/envs/test/Library/lib/libcurl.lib (found version "8.8.0")  
2024-06-11T03:53:25.0176771Z   CMake Deprecation Warning at C:/Users/runneradmin/miniconda3/envs/test/Library/lib/cmake/jsoncpp/jsoncppConfig.cmake:2 (cmake_policy):
2024-06-11T03:53:25.0178132Z     Compatibility with CMake < 3.5 will be removed from a future version of
2024-06-11T03:53:25.0178643Z     CMake.
2024-06-11T03:53:25.0178853Z   
2024-06-11T03:53:25.0179245Z     Update the VERSION argument <min> value or use a ...<max> suffix to tell
2024-06-11T03:53:25.0179961Z     CMake that the project does not need compatibility with older versions.
2024-06-11T03:53:25.0180513Z   Call Stack (most recent call first):
2024-06-11T03:53:25.0181563Z     C:/Users/runneradmin/miniconda3/envs/test/Library/share/cmake/ignition-cmake2/cmake2/FindJSONCPP.cmake:34 (find_package)
2024-06-11T03:53:25.0183252Z     C:/Users/runneradmin/miniconda3/envs/test/Library/lib/cmake/ignition-fuel_tools4/ignition-fuel_tools4-config.cmake:94 (find_package)
2024-06-11T03:53:25.0184683Z     C:/Users/runneradmin/miniconda3/envs/test/Library/lib/cmake/gazebo/gazebo-config.cmake:250 (find_package)
2024-06-11T03:53:25.0185491Z     demoRedBall/CMakeLists.txt:26 (find_package)
2024-06-11T03:53:25.0185859Z   
2024-06-11T03:53:25.0186045Z   
2024-06-11T03:53:25.0342228Z   -- Checking for module 'jsoncpp'
2024-06-11T03:53:25.0839429Z   --   Found jsoncpp, version 1.9.5
2024-06-11T03:53:25.5374127Z   -- Found JSONCPP: TRUE  
2024-06-11T03:53:25.5774283Z   -- Checking for module 'libzip'
2024-06-11T03:53:25.6277067Z   --   Found libzip, version 1.10.1
2024-06-11T03:53:25.8629631Z   -- Found ZIP: TRUE  
2024-06-11T03:53:25.8640113Z   -- Looking for ignition-common3 -- found version 3.15.1
2024-06-11T03:53:25.8652023Z   -- Looking for ignition-math6 -- found version 6.15.1
2024-06-11T03:53:25.8663182Z   -- Looking for ignition-msgs5 -- found version 5.11.0
2024-06-11T03:53:25.9200424Z   -- Found YARP: D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP (found version "3.9.0+14-20240603.1+git169ae4656")
2024-06-11T03:53:25.9305639Z   CMake Error at D:/a/robotology-superbuild/robotology-superbuild/b/install/lib/cmake/YARP/YARPConfig.cmake:150 (find_package):
2024-06-11T03:53:25.9307672Z     Could not find a package configuration file provided by "YARP_cv" with any
2024-06-11T03:53:25.9308319Z     of the following names:
2024-06-11T03:53:25.9308653Z   
2024-06-11T03:53:25.9308905Z       YARP_cvConfig.cmake
2024-06-11T03:53:25.9309512Z       yarp_cv-config.cmake
2024-06-11T03:53:25.9309852Z   
2024-06-11T03:53:25.9310520Z     Add the installation prefix of "YARP_cv" to CMAKE_PREFIX_PATH or set
2024-06-11T03:53:25.9311408Z     "YARP_cv_DIR" to a directory containing one of the above files.  If
2024-06-11T03:53:25.9312199Z     "YARP_cv" provides a separate development package or SDK, be sure it has
2024-06-11T03:53:25.9312799Z     been installed.
2024-06-11T03:53:25.9313123Z   Call Stack (most recent call first):
2024-06-11T03:53:25.9313679Z     pf3dTracker/CMakeLists.txt:9 (find_package)
2024-06-11T03:53:25.9314103Z   
2024-06-11T03:53:25.9314320Z   
2024-06-11T03:53:25.9314698Z   -- Configuring incomplete, errors occurred!

The actual problem seems that OpenCV is not found by YARP, see the output:

2024-06-11T02:38:08.2536633Z   --  [ ] OpenCV (>= 3): not found
traversaro commented 2 months ago

This may be related to:

traversaro commented 2 months ago

Last successful: https://github.com/robotology/robotology-superbuild/actions/runs/9394035049 First failing: https://github.com/robotology/robotology-superbuild/actions/runs/9410586127

traversaro commented 2 months ago

The most relevant change see the change in vc-related packages:

-vc14_runtime              14.38.33135         h835141b_20    conda-forge
-vs2015_runtime            14.38.33135         h22015db_20 
+vc14_runtime              14.40.33810         ha82c5b3_20    conda-forge
+vs2015_runtime            14.40.33810         h3bf8584_20    conda-forge
traversaro commented 2 months ago

In general, that update apparently created a lot of regressions on the GitHub Actions side: https://github.com/actions/runner-images/issues/10004 (big hugs to anyone involved in dealing with these on GitHub Actions side).

traversaro commented 2 months ago

I reproduced the issue, it is some strange interaction between libopencv 4.9.0 and msvc 14.40:

conda create -n testopencvvs2022 vs2022_win-64 libopencv==4.9.0 cmake pkg-config ninja cmake-package-check
conda activate testopencvvs2022 
(robsub) D:\src\test1106\robsub\buildninja2>conda list
# packages in environment at D:\miniforge3\envs\robsub:
#
# Name                    Version                   Build  Channel
ace                       8.0.0                he0c23c2_1    conda-forge
aiohttp                   3.9.5           py312he70551f_0    conda-forge
aiosignal                 1.3.1              pyhd8ed1ab_0    conda-forge
aom                       3.9.0                he0c23c2_0    conda-forge
asio                      1.29.0               h63175ca_0    conda-forge
assimp                    5.4.1                h0dbab56_0    conda-forge
attrs                     23.2.0             pyh71513ae_0    conda-forge
blosc                     1.21.5               hbd69f2e_1    conda-forge
boost                     1.84.0               h7e22eef_3    conda-forge
bzip2                     1.0.8                hcfcfb64_5    conda-forge
ca-certificates           2024.6.2             h56e8100_0    conda-forge
cairo                     1.18.0               h1fef639_0    conda-forge
cmake                     3.28.3               hf0feee3_0    conda-forge
cmake-package-check       0.0.4              pyh4af843d_0    conda-forge
colorama                  0.4.6              pyhd8ed1ab_0    conda-forge
cudatoolkit               11.8.0              h09e9e62_13    conda-forge
dav1d                     1.2.1                hcfcfb64_0    conda-forge
double-conversion         3.3.0                h63175ca_0    conda-forge
eigen                     3.4.0                h91493d7_0    conda-forge
expat                     2.5.0                h63175ca_1    conda-forge
ffmpeg                    6.1.1           gpl_h7cec250_112    conda-forge
flann                     1.9.2                h23e6bae_0    conda-forge
fmt                       10.2.1               h181d51b_0    conda-forge
font-ttf-dejavu-sans-mono 2.37                 hab24e00_0    conda-forge
font-ttf-inconsolata      3.000                h77eed37_0    conda-forge
font-ttf-source-code-pro  2.038                h77eed37_0    conda-forge
font-ttf-ubuntu           0.83                 h77eed37_2    conda-forge
fontconfig                2.14.2               hbde0cde_0    conda-forge
fonts-conda-ecosystem     1                             0    conda-forge
fonts-conda-forge         1                             0    conda-forge
freeglut                  3.2.2                h63175ca_2    conda-forge
freetype                  2.12.1               hdaf720e_2    conda-forge
fribidi                   1.0.10               h8d14728_0    conda-forge
frozenlist                1.4.1           py312he70551f_0    conda-forge
getopt-win32              0.1                  hcfcfb64_1    conda-forge
gl2ps                     1.4.2                h0597ee9_0    conda-forge
glew                      2.1.0                h39d44d4_2    conda-forge
glfw                      3.4                  hcfcfb64_0    conda-forge
glib                      2.80.2               h0df6a38_0    conda-forge
glib-tools                2.80.2               h2f9d560_0    conda-forge
glm                       0.9.9.8              h181d51b_0    conda-forge
graphite2                 1.3.13            h63175ca_1003    conda-forge
graphviz                  9.0.0                h51cb2cd_1    conda-forge
gsl                       2.7                  hdfb1a43_0    conda-forge
gst-plugins-base          1.24.4               hba88be7_0    conda-forge
gstreamer                 1.24.4               h5006eae_0    conda-forge
gts                       0.7.6                h6b5321d_4    conda-forge
harfbuzz                  8.5.0                h81778c3_0    conda-forge
hdf4                      4.2.15               h5557f11_7    conda-forge
hdf5                      1.14.3          nompi_h2b43c12_105    conda-forge
icu                       73.2                 h63175ca_0    conda-forge
idna                      3.7                pyhd8ed1ab_0    conda-forge
imath                     3.1.11               h12be248_0    conda-forge
intel-openmp              2024.1.0           h57928b3_966    conda-forge
ipopt                     3.14.16              ha31d76d_3    conda-forge
irrlicht                  1.8.5                h65f4d7e_4    conda-forge
jasper                    4.2.4                hcb1a123_0    conda-forge
jinja2                    3.1.4              pyhd8ed1ab_0    conda-forge
jsoncpp                   1.9.5                h2d74725_1    conda-forge
khronos-opencl-icd-loader 2023.04.17           h64bf75a_1    conda-forge
krb5                      1.21.2               heb0366b_0    conda-forge
lerc                      4.0.0                h63175ca_0    conda-forge
libabseil                 20240116.2      cxx17_h63175ca_0    conda-forge
libaec                    1.1.3                h63175ca_0    conda-forge
libasprintf               0.22.5               h5728263_2    conda-forge
libblas                   3.9.0              22_win64_mkl    conda-forge
libboost                  1.84.0               h9a677ad_3    conda-forge
libboost-devel            1.84.0               h91493d7_3    conda-forge
libboost-headers          1.84.0               h57928b3_3    conda-forge
libboost-python           1.84.0          py312hbaa7e33_3    conda-forge
libboost-python-devel     1.84.0          py312h7e22eef_3    conda-forge
libcblas                  3.9.0              22_win64_mkl    conda-forge
libccd-double             2.1                  h63175ca_3    conda-forge
libclang13                18.1.7          default_h97ce8ae_0    conda-forge
libcurl                   8.8.0                hd5e4a3a_0    conda-forge
libdeflate                1.20                 hcfcfb64_0    conda-forge
libexpat                  2.5.0                h63175ca_1    conda-forge
libffi                    3.4.2                h8ffe710_5    conda-forge
libflang                  5.0.0           h6538335_20180525    conda-forge
libgd                     2.3.3                h312136b_9    conda-forge
libgettextpo              0.22.5               h5728263_2    conda-forge
libglib                   2.80.2               h0df6a38_0    conda-forge
libhwloc                  2.10.0          default_h8125262_1001    conda-forge
libiconv                  1.17                 hcfcfb64_2    conda-forge
libintl                   0.22.5               h5728263_2    conda-forge
libintl-devel             0.22.5               h5728263_2    conda-forge
libjpeg-turbo             3.0.0                hcfcfb64_1    conda-forge
liblapack                 3.9.0              22_win64_mkl    conda-forge
liblapacke                3.9.0              22_win64_mkl    conda-forge
libmatio                  1.5.27               h0a2718b_0    conda-forge
libnetcdf                 4.9.2           nompi_h92078aa_114    conda-forge
libode                    0.16.2              h53d5487_14    conda-forge
libogg                    1.3.4                h8ffe710_1    conda-forge
libopencv                 4.9.0           qt6_py312h5b8f1c0_615    conda-forge
libopenvino               2024.1.0             hfe1841e_7    conda-forge
libopenvino-auto-batch-plugin 2024.1.0             h04f32e0_7    conda-forge
libopenvino-auto-plugin   2024.1.0             h04f32e0_7    conda-forge
libopenvino-hetero-plugin 2024.1.0             h372dad0_7    conda-forge
libopenvino-intel-cpu-plugin 2024.1.0             hfe1841e_7    conda-forge
libopenvino-intel-gpu-plugin 2024.1.0             hfe1841e_7    conda-forge
libopenvino-ir-frontend   2024.1.0             h372dad0_7    conda-forge
libopenvino-onnx-frontend 2024.1.0             hdeef14f_7    conda-forge
libopenvino-paddle-frontend 2024.1.0             hdeef14f_7    conda-forge
libopenvino-pytorch-frontend 2024.1.0             he0c23c2_7    conda-forge
libopenvino-tensorflow-frontend 2024.1.0             h7c40eac_7    conda-forge
libopenvino-tensorflow-lite-frontend 2024.1.0             he0c23c2_7    conda-forge
libopus                   1.3.1                h8ffe710_1    conda-forge
libpng                    1.6.43               h19919ed_0    conda-forge
libprotobuf               4.25.3               h503648d_0    conda-forge
libsqlite                 3.46.0               h2466b09_0    conda-forge
libssh2                   1.11.0               h7dfc565_0    conda-forge
libtheora                 1.1.1             h8d14728_1005    conda-forge
libtiff                   4.6.0                hddb2be6_3    conda-forge
libuv                     1.48.0               hcfcfb64_0    conda-forge
libvorbis                 1.3.7                h0e60522_0    conda-forge
libwebp                   1.4.0                h2466b09_0    conda-forge
libwebp-base              1.4.0                hcfcfb64_0    conda-forge
libxcb                    1.15                 hcd874cb_0    conda-forge
libxml2                   2.12.7               h283a6d9_1    conda-forge
libzip                    1.10.1               h1d365fa_3    conda-forge
libzlib                   1.2.13               h2466b09_6    conda-forge
llvm-meta                 5.0.0                         0    conda-forge
loguru                    0.7.2           py312h2e8e312_1    conda-forge
lua                       5.4.6                h2466b09_1    conda-forge
lz4-c                     1.9.4                hcfcfb64_0    conda-forge
m2w64-gcc-libgfortran     5.3.0                         6    conda-forge
m2w64-gcc-libs            5.3.0                         7    conda-forge
m2w64-gcc-libs-core       5.3.0                         7    conda-forge
m2w64-gmp                 6.1.0                         2    conda-forge
m2w64-libwinpthread-git   5.0.0.4634.697f757               2    conda-forge
make                      4.3                  h3d2af85_1    conda-forge
markupsafe                2.1.5           py312he70551f_0    conda-forge
metis                     5.1.0             h63175ca_1007    conda-forge
mkl                       2024.1.0           h66d3029_692    conda-forge
msgpack-python            1.0.8           py312hd5eb7cc_0    conda-forge
msys2-conda-epoch         20160418                      1    conda-forge
multidict                 6.0.5           py312he70551f_0    conda-forge
mumps-seq                 5.7.1                h7c2359a_1    conda-forge
ninja                     1.12.1               hc790b64_0    conda-forge
nlohmann_json             3.11.3               h1537add_0    conda-forge
numpy                     1.26.4          py312h8753938_0    conda-forge
onnxruntime-cpp           1.18.0          h10ec4a7_202_cuda    conda-forge
opencv                    4.9.0           qt6_py312hfab33ed_615    conda-forge
openexr                   3.2.2                h72640d8_1    conda-forge
openh264                  2.4.1                h63175ca_0    conda-forge
openmp                    5.0.0                    vc14_1    conda-forge
openssl                   3.3.1                h2466b09_0    conda-forge
pango                     1.54.0               h2231ffd_0    conda-forge
pcl                       1.14.1               hadb3925_0    conda-forge
pcre2                     10.43                h17e33f8_0    conda-forge
pip                       24.0               pyhd8ed1ab_0    conda-forge
pixman                    0.43.4               h63175ca_0    conda-forge
pkg-config                0.29.2            h2bf4dc2_1008    conda-forge
portaudio                 19.6.0               h63175ca_9    conda-forge
proj                      9.3.1                he13c7e8_0    conda-forge
pthread-stubs             0.4               hcd874cb_1001    conda-forge
pthreads-win32            2.9.1                hfa6e2cd_3    conda-forge
pugixml                   1.14                 h63175ca_0    conda-forge
py-opencv                 4.9.0           qt6_py312hb11cbc4_615    conda-forge
python                    3.12.2          h2628c8c_0_cpython    conda-forge
python_abi                3.12                    4_cp312    conda-forge
qhull                     2020.2               h70d2c02_2    conda-forge
qt-main                   5.15.8              hcef0176_21    conda-forge
qt6-main                  6.7.1                h9e9f2d0_2    conda-forge
sdl                       1.2.68               h21dd15a_0    conda-forge
sdl2                      2.30.2               h63175ca_0    conda-forge
setuptools                70.0.0             pyhd8ed1ab_0    conda-forge
snappy                    1.2.0                hfb803bf_1    conda-forge
soxr                      0.1.3                hcfcfb64_3    conda-forge
spdlog                    1.13.0               h64d2f7d_0    conda-forge
sqlite                    3.46.0               h2466b09_0    conda-forge
svt-av1                   2.1.0                he0c23c2_0    conda-forge
tbb                       2021.12.0            hc790b64_1    conda-forge
tbb-devel                 2021.12.0            hb551fcf_1    conda-forge
tinyxml                   2.6.2                h2d74725_2    conda-forge
tinyxml2                  10.0.0               h63175ca_0    conda-forge
tk                        8.6.13               h5226925_1    conda-forge
tomlplusplus              3.3.0                h63175ca_0    conda-forge
tzdata                    2024a                h0c530f3_0    conda-forge
ucrt                      10.0.22621.0         h57928b3_0    conda-forge
utfcpp                    4.0.5                h57928b3_0    conda-forge
vc                        14.3                h8a93ad2_20    conda-forge
vc14_runtime              14.40.33810         ha82c5b3_20    conda-forge
vs2015_runtime            14.40.33810         h3bf8584_20    conda-forge
vs2022_win-64             19.40.33808         h753ab0a_20    conda-forge
vswhere                   3.1.4                h57928b3_0    conda-forge
vtk                       9.2.6           qt_py312h1234567_223    conda-forge
vtk-base                  9.2.6           qt_py312h1234567_223    conda-forge
wheel                     0.43.0             pyhd8ed1ab_1    conda-forge
win32_setctime            1.1.0              pyhd8ed1ab_0    conda-forge
wslink                    2.0.5              pyhd8ed1ab_0    conda-forge
x264                      1!164.3095           h8ffe710_2    conda-forge
x265                      3.5                  h2d74725_3    conda-forge
xorg-kbproto              1.0.7             hcd874cb_1002    conda-forge
xorg-libice               1.1.1                hcd874cb_0    conda-forge
xorg-libsm                1.2.4                hcd874cb_0    conda-forge
xorg-libx11               1.8.9                hefa74cf_0    conda-forge
xorg-libxau               1.0.11               hcd874cb_0    conda-forge
xorg-libxdmcp             1.1.3                hcd874cb_0    conda-forge
xorg-libxext              1.3.4                hcd874cb_2    conda-forge
xorg-libxpm               3.5.17               hcd874cb_0    conda-forge
xorg-libxt                1.3.0                hcd874cb_1    conda-forge
xorg-xextproto            7.3.0             hcd874cb_1003    conda-forge
xorg-xproto               7.0.31            hcd874cb_1007    conda-forge
xz                        5.2.6                h8d14728_0    conda-forge
yarl                      1.9.4           py312he70551f_0    conda-forge
zlib                      1.2.13               h2466b09_6    conda-forge
zstd                      1.5.6                h0ea2cb4_0    conda-forge

and the check:

(robsub) D:\src\test1106\robsub\buildninja2>cmake-package-check OpenCV
===================================
=== Generated CMakeLists.txt file:
===================================
cmake_minimum_required(VERSION 3.12...3.29)

project(CMakePackageCheckTestCMakeProject)

find_package(OpenCV REQUIRED)

find_package(OpenCV REQUIRED)

# Create dummy executable
file(WRITE ${CMAKE_CURRENT_BINARY_DIR}/cmake_package_check_dummy_executable.cpp "int main() {return 0;}")
add_executable(cmake_package_check_dummy_executable ${CMAKE_CURRENT_BINARY_DIR}/cmake_package_check_dummy_executable.cpp)

===================================
=== CMake configure output:
===================================
-- The C compiler identification is MSVC 19.40.33811.0
-- The CXX compiler identification is MSVC 19.40.33811.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/MSVC/14.40.33807/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- OpenCV ARCH: x64
-- OpenCV RUNTIME:
-- OpenCV STATIC: OFF
CMake Warning at D:/miniforge3/envs/robsub/Library/cmake/OpenCVConfig.cmake:190 (message):
  Found OpenCV Windows Pack but it has no binaries compatible with your
  configuration.

  You should manually point CMake variable OpenCV_DIR to your build of OpenCV
  library.
Call Stack (most recent call first):
  CMakeLists.txt:5 (find_package)

CMake Error at CMakeLists.txt:5 (find_package):
  Found package configuration file:

    D:/miniforge3/envs/robsub/Library/cmake/OpenCVConfig.cmake

  but it set OpenCV_FOUND to FALSE so package "OpenCV" is considered to be
  NOT FOUND.

-- Configuring incomplete, errors occurred!
Error occurred: Command '['cmake', '-GNinja', '-S.', '-B.']' returned non-zero exit status 1.
===================================
=== Result:
===================================
cmake-package-check: FAILURE.

The problem does not occur with OpenCV 4.10.0 .

traversaro commented 2 months ago

The upstream fix in opencv is https://github.com/opencv/opencv/pull/25632 and https://github.com/opencv/opencv/pull/25638 .

traversaro commented 2 months ago

Either we patch 4.9 in conda, or we ensure that the opencv 4.10 migration works fine.

traversaro commented 2 months ago

The root change on the MSVC side is https://devblogs.microsoft.com/cppblog/msvc-toolset-minor-version-number-14-40-in-vs-2022-v17-10/ .

traversaro commented 2 months ago

Either we patch 4.9 in conda, or we ensure that the opencv 4.10 migration works fine.

Actually the opencv 4.10 was already ok, but it turns out that it is not possible to install opencv 4.10 with a recent python due to https://github.com/conda-forge/opencv-feedstock/issues/418 .

traversaro commented 2 months ago

Either we patch 4.9 in conda, or we ensure that the opencv 4.10 migration works fine.

Actually the opencv 4.10 was already ok, but it turns out that it is not possible to install opencv 4.10 with a recent python due to conda-forge/opencv-feedstock#418 .

That issue was solved, but libopencv 4.9.0 still gets installed due to https://github.com/conda-forge/vtk-feedstock/issues/329 .

traversaro commented 2 weeks ago

Solved by the link PRs.