diff --git a/bin/setup.sh b/bin/setup.sh index 6457a1a..95af8c3 100755 --- a/bin/setup.sh +++ b/bin/setup.sh @@ -19,8 +19,11 @@ if [[ ${OS} == "darwin" ]]; then brew install cmake python@3.11 wget unzip || true elif [[ ${OS} == "linux" ]]; then echo "Detected Linux" - # NOTE: this is written under the assumption that it will be built in canon - sudo apt -y update && sudo apt -y upgrade && sudo apt install -y cmake python3.11 python3.11-venv wget + # Do not pin a python minor version here. This runs both in canon (python3.11) and in the Viam + # cloud build image used by `viam module reload` / `viam module build`, which is Debian bullseye + # and has no python3.11 package at all, so pinning it fails the build outright. Conan needs + # >= 3.6, and the venv below is created with whatever python3 resolves to. + sudo apt -y update && sudo apt -y upgrade && sudo apt install -y cmake python3 python3-venv wget else echo "Unsupported OS: ${OS}" exit 1 diff --git a/conanfile.py b/conanfile.py index df16d49..6440e59 100644 --- a/conanfile.py +++ b/conanfile.py @@ -33,6 +33,12 @@ def requirements(self): self.requires("libcurl/8.9.1") self.requires("libzip/1.11.1") self.requires("libpng/1.6.50") + # viam-cpp-sdk pulls xtensor in transitively, and 0.20.1 asks for an unbounded + # `xtensor/[>=0.24.3]` at cppstd >= 17. That now resolves to 0.27.1, which itself requires + # C++20, so the graph fails to resolve at all against conancenter. The SDK added the + # matching upper bound in releases/v0.37.0, so drop this override once the pin above moves + # to v0.37.0 or newer rather than carrying it forward. + self.requires("xtensor/[>=0.24.3 <0.27]", override=True) def validate(self): check_min_cppstd(self, 17)