diff --git a/recipes/prometheus-cpp/all/conandata.yml b/recipes/prometheus-cpp/all/conandata.yml index 0aa86dd0d07dd..f087398f73aad 100644 --- a/recipes/prometheus-cpp/all/conandata.yml +++ b/recipes/prometheus-cpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.0": + url: "https://github.com/jupp0r/prometheus-cpp/archive/v1.3.0.tar.gz" + sha256: "ac6e958405a29fbbea9db70b00fa3c420e16ad32e1baf941ab233ba031dd72ee" "1.2.4": url: "https://github.com/jupp0r/prometheus-cpp/archive/v1.2.4.tar.gz" sha256: "48dbad454d314b836cc667ec4def93ec4a6e4255fc8387c20cacb3b8b6faee30" @@ -8,18 +11,3 @@ sources: "1.0.1": url: "https://github.com/jupp0r/prometheus-cpp/archive/v1.0.1.tar.gz" sha256: "593e028d401d3298eada804d252bc38d8cab3ea1c9e88bcd72095281f85e6d16" - "1.0.0": - url: "https://github.com/jupp0r/prometheus-cpp/archive/v1.0.0.tar.gz" - sha256: "07018db604ea3e61f5078583e87c80932ea10c300d979061490ee1b7dc8e3a41" - "0.12.3": - url: "https://github.com/jupp0r/prometheus-cpp/archive/v0.12.3.tar.gz" - sha256: "e021e76e8e933672f1af0d223307282004f585a054354f8d894db39debddff8e" - "0.12.1": - url: "https://github.com/jupp0r/prometheus-cpp/archive/v0.12.1.tar.gz" - sha256: "2102609457f812dbeaaafd55736461fd0538fc7e7568174b1cdec43399dbded4" - "0.11.0": - url: "https://github.com/jupp0r/prometheus-cpp/archive/v0.11.0.tar.gz" - sha256: "aab4ef8342319f631969e01b8c41e355704847cbe76131cb1dd5ea1862000bda" -patches: - "0.11.0": - - patch_file: "patches/0001-include-limits.patch" diff --git a/recipes/prometheus-cpp/all/conanfile.py b/recipes/prometheus-cpp/all/conanfile.py index 09bc0c369ee74..06f45f304071f 100644 --- a/recipes/prometheus-cpp/all/conanfile.py +++ b/recipes/prometheus-cpp/all/conanfile.py @@ -1,13 +1,13 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir +from conan.tools.files import get, copy, rmdir from conan.tools.build import check_min_cppstd, valid_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.scm import Version import os -required_conan_version = ">=1.53.0" +required_conan_version = ">=2.0" class PrometheusCppConan(ConanFile): name = "prometheus-cpp" @@ -37,21 +37,6 @@ class PrometheusCppConan(ConanFile): def _min_cppstd(self): return "14" if Version(self.version) == "1.1.0" else "11" - @property - def _compilers_minimum_version(self): - return { - "14": { - "gcc": "7", - "clang": "7", - "apple-clang": "10", - "Visual Studio": "15", - "msvc": "191", - }, - }.get(self._min_cppstd, {}) - - def export_sources(self): - export_conandata_patches(self) - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -69,18 +54,13 @@ def requirements(self): if self.options.with_pull: self.requires("civetweb/1.16") if self.options.with_push: - self.requires("libcurl/[>=7.78.0 <9]") + self.requires("libcurl/[>=7.78.0 <9]", transitive_headers=True) if self.options.get_safe("with_compression"): self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.info.settings.compiler.cppstd: check_min_cppstd(self, self._min_cppstd) - minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if minimum_version and Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration( - f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." - ) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -101,7 +81,6 @@ def generate(self): deps.generate() def build(self): - apply_conandata_patches(self) cmake = CMake(self) cmake.configure() cmake.build() diff --git a/recipes/prometheus-cpp/config.yml b/recipes/prometheus-cpp/config.yml index 11d3240cb85c5..50ed34cd33932 100644 --- a/recipes/prometheus-cpp/config.yml +++ b/recipes/prometheus-cpp/config.yml @@ -1,15 +1,9 @@ versions: + "1.3.0": + folder: all "1.2.4": folder: all "1.1.0": folder: all "1.0.1": folder: all - "1.0.0": - folder: all - "0.12.3": - folder: all - "0.12.1": - folder: all - "0.11.0": - folder: all