This package 'checks' for compiler compatibility by comparing strings. This naturally leads to disaster from false positives and negatives. The newest clang version 10 is rejected even though it is newer than the minimum required version 5. This means it can not be configured and thus not installed.
Click to expand log
Configuration:
[settings]
arch=x86_64
arch_build=x86_64
build_type=Release
compiler=clang
compiler.libcxx=libstdc++11
compiler.version=10
os=Linux
os_build=Linux
[options]
[build_requires]
[env]
CC=clang-10
CXX=clang++-10
ERROR: magic_enum/0.6.2@neargye/stable: Invalid configuration: magic_enum: Unsupported compiler (https://github.com/Neargye/magic_enum#compiler-compatibility).
Quick search (rg ">= \"\d\"") reveals this pattern of version checks affects a few more packages.
Ooops, if we expand the pattern to any stringly comparison between version numbers (rg "(>|<)=? \"\\d*\"") then the list grows to many, many more:
A list of files with matches
recipes/xz_utils/all/conanfile.py recipes/xtensor/all/conanfile.py recipes/tesseract/all/conanfile.py recipes/stduuid/all/conanfile.py recipes/stlab/all/conanfile.py recipes/rocksdb/all/conanfile.py recipes/range-v3/all/conanfile.py recipes/physx/4.x.x/conanfile.py recipes/nanorange/all/conanfile.py recipes/protobuf/all/conanfile.py recipes/opus/all/conanfile.py recipes/opengl/all/conanfile.py recipes/oatpp/all/conanfile.py recipes/oatpp-websocket/all/conanfile.py recipes/mpir/all/conanfile.py recipes/nameof/all/conanfile.py recipes/libsolace/all/conanfile.py recipes/magic_enum/all/conanfile.py recipes/libuv/all/conanfile.py recipes/libpq/all/conanfile.py recipes/libmysqlclient/all/conanfile.py recipes/lcms/all/conanfile.py recipes/icu/all/conanfile.py recipes/gtest/all/conanfile.py recipes/folly/all/conanfile.py recipes/double-conversion/all/conanfile.py recipes/doxygen/all/conanfile.py recipes/ctre/all/conanfile.py recipes/charls/all/conanfile.py recipes/botan/all/conanfile.py recipes/boost/all/conanfile.py
Weird
>>> from conans.tools import Version
>>> Version("10") > "5"
True
Does it behave the same without the stringification at
https://github.com/conan-io/conan-center-index/blob/9de6bc079ab052a981d8799d8a5b5733fd29eebd/recipes/magic_enum/all/conanfile.py#L33
?
Maybe some of the version are stringified and not proper Version instances?
Not according to the code you've linked to.
This is a link to the code of the Version class.
As you see, it makes sure to always compare Version objects.
Turns out I was referring to an outdated conanfile.py.. Sorry for the noise.
Most helpful comment
Turns out I was referring to an outdated
conanfile.py.. Sorry for the noise.