Homepage Books Releases Docs Discourse

How to fix the cmake error "cannot migrate old registry with conan" on windows

I am mostly working with ogs6 on windows. Recent I have encountered an error with cmake configuration. The error message read as follows

ERROR: Cannot migrate old registry: Requested 'Boost/1.64.0@conan/stable' but found case incompatible 'boost' 
Case insensitive filesystem can't manage this
CMake Error at scripts/cmake/conan/conan.cmake:454 (if):
if given arguments:
"VERSION_LESS" "1.3.0"
Unknown arguments specified
Call Stack (most recent call first):
scripts/cmake/ConanSetup.cmake:81 (conan_check)
CMakeLists.txt:69 (include)

Reason behind:
Lars has recently migrated all conan packages to lower cases. This will cause an issue on operation systems which is case insensitive. Please see Lars’ explanation here:

My treatment to fix this:

  1. uninstall the current conan program in “Add or Remove Program” page in windows
  2. complete remove the folder C:\user\YOUR_NAME\.conan
  3. install conan using your current python. In my case, in the cmd window:
    pip install conan
  4. clean the cache in cmake and re-run the cmake configuration.

That solves my problem. Hope this is useful to you.

1 Like

Thanks @HBShao for the description on solving the problem! On the different machines I had to resolve this the steps I outlined in the PR description was enough but maybe as you had Conan installed via a regular Windows installer (and not via pip) it required some more cleanup for you…