From 40378a17c6f9893a8e1125c30ef3b95e37c496fd Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Nov 2024 22:52:30 +0900 Subject: [PATCH 1/2] prometheus-cpp: add version 1.3.0 --- recipes/prometheus-cpp/all/conandata.yml | 3 +++ recipes/prometheus-cpp/all/conanfile.py | 2 +- recipes/prometheus-cpp/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/prometheus-cpp/all/conandata.yml b/recipes/prometheus-cpp/all/conandata.yml index 0aa86dd0d07dd..de8390b524fcf 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" diff --git a/recipes/prometheus-cpp/all/conanfile.py b/recipes/prometheus-cpp/all/conanfile.py index 09bc0c369ee74..af6fe70ff5768 100644 --- a/recipes/prometheus-cpp/all/conanfile.py +++ b/recipes/prometheus-cpp/all/conanfile.py @@ -69,7 +69,7 @@ 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]") diff --git a/recipes/prometheus-cpp/config.yml b/recipes/prometheus-cpp/config.yml index 11d3240cb85c5..3445cc11f4c3e 100644 --- a/recipes/prometheus-cpp/config.yml +++ b/recipes/prometheus-cpp/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.0": + folder: all "1.2.4": folder: all "1.1.0": From c1793452c92586e2a8fa56df920c74c590d866b6 Mon Sep 17 00:00:00 2001 From: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> Date: Mon, 4 Nov 2024 12:44:06 +0000 Subject: [PATCH 2/2] prometheus-cpp: remove older versions and cleanup --- recipes/prometheus-cpp/all/conandata.yml | 15 -------------- recipes/prometheus-cpp/all/conanfile.py | 25 ++---------------------- recipes/prometheus-cpp/config.yml | 8 -------- 3 files changed, 2 insertions(+), 46 deletions(-) diff --git a/recipes/prometheus-cpp/all/conandata.yml b/recipes/prometheus-cpp/all/conandata.yml index de8390b524fcf..f087398f73aad 100644 --- a/recipes/prometheus-cpp/all/conandata.yml +++ b/recipes/prometheus-cpp/all/conandata.yml @@ -11,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 af6fe70ff5768..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 @@ -76,11 +61,6 @@ def requirements(self): 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 3445cc11f4c3e..50ed34cd33932 100644 --- a/recipes/prometheus-cpp/config.yml +++ b/recipes/prometheus-cpp/config.yml @@ -7,11 +7,3 @@ versions: 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